Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I was running my ESB based REST webservices directly using "start/ trun".
I recently setup the "wrapper" so that I can run the it as an OS service. I had set certain KARAF_OPTS in setenv.bat earlier. However, the KARAF_OPTS no longer take into effect since I moved to the wrapper.
How does one set "KARAF_OPTS" while running the ESB service as a wrapper?
I have tried the following in container\etc\myservice.conf:
set.KARAF_OPTS="-Dcontrast.appname=<MyAPP> -Dcontrast.classpath.libs=true -Dcontrast.server=<MyServer> -javaagent:E:/contrast.jar"
wrapper.java.additional.11=-Dcontrast.appname=<MyAPP> -Dcontrast.classpath.libs=true -Dcontrast.server=<MyServer> -javaagent:E:/contrast.jar
None of these worked. Any help is appreciated.
The correct way to set system properties to Talend Runtime when installing it as an OS service (using the "wrapper") is the following (in container\etc\myservice.conf config file😞
wrapper.java.additional.11=-Dcontrast.appname=<MyApp> -Dcontrast.classpath.libs=true -Dcontrast.server=<MyServer> -javaagent:D:/MyAgent.jar
For my tests I've used a different java agent. With the above configuration my agent was picked up at Talend Runtime start and also the other properties were correctly added.
You can inspect the system properties using:
system:property
You can use jconsole to inspect the VM arguments and Class path in the VM Summary tab. There you should identify if your agent and parameters are set properly.
If you still have the default configuration of Karaf, you can use the following service URL for the JMXConnectorServer
service:jmx:rmi://0.0.0.0:44444/jndi/rmi://0.0.0.0:1099/karaf-trun
Username/password: karaf/karaf