|
From: Leif M. <lei...@ta...> - 2009-04-20 08:43:17
|
Roma, You can pass parameters to your application the same as with other Java Applications. Normally you would run it as "java -jar myjar.jar arg0 arg1 arg2" With the Wrapper, this would be: wrapper.java.mainclass=org.tanukisoftware.wrapper.WrapperJarApp wrapper.app.parameter.1=../lib/wrappertest.jar wrapper.app.parameter.2=arg0 wrapper.app.parameter.3=arg1 wrapper.app.parameter.4=arg2 If you want to set the first argument from the command line, then it would be done like this: wrapper.exe -c ..¥conf¥wrapper.conf wrapper.app.parameter.2=arg0 Note that this can only be used to install the service: wrapper.exe -i ..¥conf¥wrapper.conf wrapper.app.parameter.2=arg0 When the service is started and stopped, there is no way to specify other parameter values from the command line. You can do so however by creating a small included configuration file dynamically. Let me know exactly what you want to do and I might be able to help out further. Cheers, Leif On Sun, Apr 19, 2009 at 3:49 AM, Roma <shm...@ya...> wrote: > Hi! > > How can I pass parameters to my application? > I use WrapperJarApp to launch it as service.. > > Thank you! |