wrapper.pausable.stop_jvm

Compatibility :3.5.0
Editions :Professional EditionStandard EditionCommunity Edition
Platforms :WindowsMac OSXLinuxIBM AIXFreeBSDHP-UXSolarisIBM z/OSIBM z/Linux

WARNING

DO NOT modify the value of this property while an application using the configuration file is running. Please stop the existing service BEFORE modifying this property. The service with the new value can then be safely restarted later.

This property controls what happens when the Wrapper is Paused using one of the actions described in the wrapper.pausable property documentation. This property has no effect unless the wrapper.pausable property is TRUE.

Setting this property to TRUE will cause the JVM to be shutdown until the service is resumed or stopped. If, on the other hand, it is FALSE, the JVM will continue to run normally and the Wrapper will send a service control event to the JVM which can be handled in user code to put the Application into a paused state.

The default value is "TRUE".

Example:
wrapper.pausable=TRUE
wrapper.pausable.stop_jvm=TRUE

To receive and handle the service control events in a JVM that is left running, it is necessary to implement code like the following. This example creates and registers a WrapperEventListener which is flagged to only receive service events.

Example:
WrapperManager.addWrapperEventListener( new WrapperEventListener() {
    public void fired( WrapperEvent event ) {
       if ( event instanceof WrapperServiceControlEvent ) {
          WrapperServiceControlEvent scEvent = (WrapperServiceControlEvent)event;
          switch ( scEvent.getServiceControlCode() ) {
          case WrapperManager.SERVICE_CONTROL_CODE_PAUSE:
             myPauseCallback();
             break;
          case WrapperManager.SERVICE_CONTROL_CODE_CONTINUE:
             myContinueCallback();
             break;
          }
       }
    }
}, WrapperEventListener.EVENT_FLAG_SERVICE );

NOTE

For backwards compatibility, this property defaults to the value of the wrapper.ntservice.pausable.stop_jvm property.

Reference: Pausable