This might help: System.setProperty( "wrapper.config", getWrapperConf().toString() ); String jnaTemp = getWrapperConf().getParent().resolve( "tmp" ).toString(); System.setProperty( "jna_tmpdir", jnaTemp ); if ( debug ) { System.out.println( "Wrapper config path: " + getWrapperConf().toString() ); System.out.println( "jna_tmpdir: " + jnaTemp ); } try { service = new WrappedService(); service.init(); service.install(); } catch ( Exception exc ) { LOG.error( "Trying to install service.", exc ); }
http://yajsw.sourceforge.net/#mozTocId444599 Section: Installing a Service These instructions do not work. The problem is that your service definition "Path to executable" contains the classpath of the calling application instead of the classpath specified in the wrapper.conf. This is way wrong. Is there any way to override this behavior? We are setting the system property for the wrapper.config, as well as the jnaTemp folder.
Disregard. It looks like the problem is caused by a fouled up java.class.path system property caused by our EXE generator, that has decided to simply stop working for no reason. The problem is not in YAJSW. But it would be nice to have better error handling here.
Forgot to mention that we are using embedded mode so we are calling WrappedService.init();
SF converted what I typed in, ugh! \.\.
wrapper.conf does not support relative paths with ".."
KB4338818 is the culprit. And its causing other services issues. The services console gets corrupted.
We believe that a recent Windows Server update from MS changed the behavior of some Windows service that either YAJSW/Tomcat uses to kill applications/servlets. However, our code did have a bug that prevented the shutdown from happening in a reasonable amount of time, which likely hit the timeout for YAJSW which should have triggered a kill. But that kill is no longer working after the updates. That is what is broken.