开发者

Way to programmatically set Java options for Tomcat as a Windows Service

开发者 https://www.devze.com 2022-12-16 07:59 出处:网络
I am looking for a way to programmatically set Java Options for Tomcat 6.0 running as a Windows service.When using startup.bat and shutdown.bat, you can set these variables in a setenv.bat or catalina

I am looking for a way to programmatically set Java Options for Tomcat 6.0 running as a Windows service. When using startup.bat and shutdown.bat, you can set these variables in a setenv.bat or catalina.bat file. However, for Tomcat running as a Windows Service, these options must be manually set in the Java Options section of the configuration utility.

Is there any way to programmatically set these options?

Background: I am trying to write an installer that will deploy my app to an existing Tomcat 6.0 server. I can do everything else programmatically, but I'll still have to ask the user to manually add a few Java Options in these settings. This is l开发者_如何学Goess than ideal, especially since these options are case- and whitespace-sensitive.


The Tomcat6 binary for running Tomcat as a Windows service has a bunch of command-line parameters that will likely help you. The only issue I foresee is that it's hard (impossible?) to retrieve the current settings so that you can modify them...

0

精彩评论

暂无评论...
验证码 换一张
取 消