|
| Copyright © Cloud Software Group, Inc. All Rights Reserved |
The RMI Lookup activity allows you to use a registry server to retrieve a Java object that implements a client stub of a remote object. You can then pass the object to a Java Code or Java Method activity and invoke methods on the object. Figure 24 illustrates using the RMI Lookup activity to obtain a client stub for a remote Java object and then mapping that object to an input parameter for the Java Code activity.Figure 24 Using the RMI Lookup activityThe object obtained by the lookup activity is an instance of the server's stub class for the actual server object interface. To call methods on this object with a Java Code activity, use the stub class interface to cast the object before making the calls. Similarly, the Java Method activity should specify the stub class interface in its Class field. The generated client stub’s .jar file must be either in the TIBCO ActiveMatrix BusinessWorks classpath or in an AliasLibrary resource before it can be used by the Java Method activity.The RMI Server process starter registers the specified object name with the specified registry server. Then, requests from RMI clients for the object are directed to the RMI Server process starter. A new process instance is created to handle each incoming request.The RMI Server process starter can output two Java objects, one for the request and one for the reply. Either the request or reply objects can be nil. Optionally, you can also specify an output schema in the Output Editor tab of the RMI Server process starter. This allows you to specify fields that are expected in the request object and the data from the request object is used to populate the desired output schema. You can then process the request based on the specified output schema, and you can also access the actual request object by passing it to a Java Code or Java Method activity.Figure 25 illustrates using the RMI Server process starter.Figure 25 Using the RMI Server process starter
|
| Copyright © Cloud Software Group, Inc. All Rights Reserved |