I am trying to execute a jar file. It needs both program arguments and the jvm arguments. Do we need to do something different while passing the command line parameters in order for it to be able to differentiate them, or it will be handled automatically?
Currently I am using eclipse IDE, so I can configure it. However it will be finally run using command line only. Please let me know if something needs to be done differently.
Well, the JVM arguments are typed before using '-D', then after the jar file you'll type your program arguments:
java -Djvm_argument1=XXX -Djvm_argument2=YYY -jar myjar.jar my_argument1 my_argument2
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With