Entering content frame

Procedure documentation Connecting to the Configuration Manager Locate the document in its SAP Library structure

Use

To be able to open a configuration and modify it, you must first connect to the Configuration Manager, which is the module that manages the configuration tree.

Prerequisites

To connect to the Configuration Manager, you must have added a reference to the Configuration Service in the SAP-specific deployment descriptor of your application – that is, application-j2ee-engine.xml. The reference must have the following parameters:

This graphic is explained in the accompanying text

These entries are stored in the application-j2ee-engine.xml as follows:

<reference

   reference-type="hard">

   <reference-target

      provider-name="sap.com"

      target-type="service">configuration</reference-target>

</reference>

<provider-name>sap.com</provider-name>

 

For more information about setting references, see Editing Application References.

Procedure

       1.      Obtain an instance of com.sap.engine.services.configuration.appconfiguration.ApplicationConfigHandlerFactory from the JNDI registry. To look it up, use the name ApplicationConfiguration.

Example

//obtain JNDI context

Context ctx = new InitialContext();

 

//get ApplicationConfigHandlerFactory instance from JNDI

ApplicationConfigHandlerFactory appCfgHdlFctry = (ApplicationConfigHandlerFactory)ctx.lookup("ApplicationConfiguration");

 

       2.      Use the ApplicationConfigHandlerFactory to obtain an instance of com.sap.engine.services.configuration.appconfiguration.ApplicationConfigurationHandler.

Example

//request ApplicationConfigurationHandler instance from the factory

ApplicationConfigurationHandler cfgHandler =

  appCfgHdlFctry.getApplicationConfigurationHandler();

 

Result

You can now open and modify the configuration subtree of the application.

 

 

Leaving content frame