Oracle Agile Engineering Data Management Enterprise Integration Platform Development Guide for Agile Release e6.2.0.0 E52569-01 |
|
![]() Previous |
![]() Next |
To provide own Web Services to the Enterprise Integration Platform, you have to create an implementation class, add it to the configuration and deploy it to the Web Server's directory.
When implementing the Web Service Java class, you may inherit your class from com.eigner.eai.connector.net.ws.WebService. This abstract base class provides you with a Logger instance and convenience methods for handling the Web Service request.
Basically, your code should do the following:
// The context (name of the web service connector) must be either provided by // the method call or by a dynamic mapping.WebServiceContext wsc = WebServiceContextFactory.getContext(context); // Extract the required data from the method call. // key: Unique key for data// noun: Business Object noun (e.g. ITEM) // verb: Business Object verb (e.g. CREATE) // message: XML data // language: Language code (see Common Section in the Administration Manual) // synchronous: Flag for synchronous data transmissionString resultString = wsc.process(key, noun, verb, message, language, synchronous); // Prepare the result XML string for the return value of the method call (if any)
For further information regarding the data, please refer to the chapter about the XDOs in the Enterprise Integration Platform Administration Guide for Agile e6.2.0.0.
Depending on the type of connector, the definition of the Web Service must be added to the synchronous connector's configuration or the asynchronous connector's configuration, although the definition is identical.
Example:
<connector name="ws" version="2.2.0" active="false" class="com.eigner.eai.connector.net.WebServiceConnector"> <connection name="default" active="true"> … <service name="myservice" wsdd="/com/foo/MyService.wsdd" location="/axis/services/MyService"/> … </connection> … </connector>
For deploying your Web Service into the EIP, please provide a proper WSDD (Web Service Deployment Description) file.
Example:
<deployment name="eip" xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java"> <service name="MyService" provider="java:MSG"> <parameter name="className" value="com.foo.MyService"/> <parameter name="allowedMethods" value="*"/> </service> </deployment>
For further information, please see http://ws.apache.org/axis/java/user-guide.html (esp. "Custom Deployment - Introducing WSDD" and "Service Styles - RPC, Document, Wrapped, and Message").
Then pack your Java classes and this WSDD file into a JAR and deploy it to the webapps's axis/WEB-INF/lib directory. The webapps's directory is specified in the file conf/eai_ini.xml under eai-root/controller/webserver.
You may need to delete the file axis/WEB-INF/server-config.xml and restart the Integration Platform in order to use your Web Service.