Closed
Description
I would like Spring Boot application to support guideline 10 of POSIX.1-2017 - Utility argument convention section:
The first -- argument that is not an option-argument should be accepted as a delimiter indicating the end of options. Any following arguments should be treated as operands, even if they begin with the '-' character.
The desired behavior is to recognize the --
and leave all the arguments to the right of it alone.
Just for context: in 2.0.x
passing --
to a SpringBoot application results in an error (sample trace below). The double dash is treated as an invalid option (whose name is zero-length) and there seems to be no way to configure this behavior.
java.lang.IllegalArgumentException: Invalid argument syntax: --
at org.springframework.core.env.SimpleCommandLineArgsParser.parse(SimpleCommandLineArgsParser.java:75)
at org.springframework.core.env.SimpleCommandLinePropertySource.<init>(SimpleCommandLinePropertySource.java:90)
at org.springframework.boot.DefaultApplicationArguments$Source.<init>(DefaultApplicationArguments.java:76)
at org.springframework.boot.DefaultApplicationArguments.<init>(DefaultApplicationArguments.java:42)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:321)
at com.netflix.genie.GenieAgentApplication.run(GenieAgentApplication.java:63)