Document toolboxDocument toolbox

Properties File Location

Single ServiceManager Instance

The default deployment expects there to be a single ServiceManager instance running within a single application server.  In this configuration the simplest method of defining the location of this properties file is via a system property passed to the JVM.

For example: 

-Dcom.servicepower.servicemanager.propertiesFile=<path>/service_manager.properties

Note: the existence of this property effectively overrides any other settings for the location of the service_manager.properties file.  

Multiple Co-located ServiceManager Instances

If the intention is to deploy multiple instances of ServiceManager to the same application server then the preceding method of defining the location of service_manager.properties is not recommended as all ServiceManager instances will have access to this property and consequently will all use the same service_manager.properties settings.

To achieve co-existence with separate service_manager.properties files the preceding system property must be removed and the individual ServiceManager struts-config.xml file must be edited.

 

At the bottom of this file is the definition of a plug-in called ApplicationSetupPlugIn, within this there is a single property defined (managerPropertyLocation).  Change the value setting for this property to point to the physical location of the service_manager.properties file.

For example:

<plug-in  
    className="com.servicepower.servicemanager.ApplicationSetupPlugIn">
    <set-property 
        property="managerPropertyLocation" 
        value="\sm_properties\service_manager.properties" />
</plug-in>

Note: there is only one line in this file that should be edited, the rest of it must be left unaltered. ServiceManager is reliant on this file for correct operation, erroneous modifications may lead to unexpected behaviour.

If both methods of defining the location of service_manager.properties file are defined, the -D system property takes precedence.  If this occurs a warning message will be written to the console (standard out) noting this fact, but execution will continue:

SERVICEManager: ** WARNING ** setupPropertiesFile found both -D com.servicepower.servicemanager.properties file and plug-in configured
 
SERVICEManager: ** WARNING ** setupPropertiesFile will use -D com.servicepower.servicemanager.properties=C:\web-servers\SERVICEManager\sm_properties\service_manager.properties