The c8-services.xml file requires a section for every remote service before you can use the service in a CCL query.
Your specific service entry depends on the RPC plugin and remote procedure you are using. All remote service entries, however, require the following information:
A unique service name.
A type of REMOTESERVICE.
The name of the plugin library for the RPC plugin.
The names of the initialize, execute and shutdown function calls within the .dll or .so.
Optionally, the service entry may also include the names and functions of configuration parameters for the functions in the RPC plugin (for example, the HTTP URL of the RPC server). See the Sybase CEP Integration Guide for more information about the RPC plugin name, its initialize, execute and shutdown calls and its optional parameters.
The c8-services.xml file contains an example of a remote service entry, using the SOAP RPC plugin. The Sybase CEP Integration Guide includes a detailed description of the example plugin. You can use the example plugin to send two zip codes to an RPC server and receive the distance between these two zip codes. You can also use the SOAP RPC plugin section of the c8-services.xml file to create a service entry for your own RPC plugin.
To create a service entry for your plugin, make a copy of the SOAP RPC plugin section within the c8-services.xml file and replace the values as explained in this section.
<Service Name="GetZipCodeDistance"1 Type="REMOTESERVICE"2> <Description> Computes the distance between two US zip codes. </Description>3 <!-- RPC Plugin --> <Param Name="RpcLibrary">c8_rpc_http_soap_lib4</Param> <Param Name="RpcInitCallback">c8_rpc_soap_initialize5</Param> <Param Name="RpcExecuteCallback">c8_rpc_soap_execute6</Param> <Param Name="RpcShutdownCallback">c8_rpc_soap_shutdown7</Param> <!-- SOAP/RPC Plugin --> <Param Name="HttpURI">8http://teachatechie.com/GJTTWebservices/ZipCode.asmx </Param> <Param Name="HttpTimeout">50</Param> <Param Name="HttpKeepAlive">true</Param> <Param Name="HttpEnableLogging">true</Param> <Param Name="SoapURI">http://teachatechie.com/</Param> <Param Name="SoapMethod">GetDistance</Param> <Param Name="SoapAction"> "http://teachatechie.com/GetDistance" </Param> </Service>
You can also configure the remote service entry for a number of additional settings, as described in "Setting Optional Preferences for Services".