Adapter for Enterprise JavaBeans 6.5 SP3 | webMethods Adapter for Enterprise JavaBeans Documentation | webMethods Adapter for Enterprise JavaBeans Installation and User’s Documentation | Overview of webMethods Adapter for Enterprise JavaBeans | Adapter Services | CreateEJB 2.1 Adapter Service | Run-Time Processing for a CreateEJB 2.1 Service
 
Run-Time Processing for a CreateEJB 2.1 Service
At run time, the service's only inputs are the parameter values required by the EJBHome method (if any).
If the operation is successful, the CreateEJB 2.1 service returns to the caller an array of javax.ejb.Handle instances that represent the remote EJBs found or created by the EJBHome method. These handles may subsequently be de-serialized by the caller to obtain the underlying EJBs or may be passed into a suitably configured InvokeEJB 2.1 adapter service.
Note:
In general, session EJBHome methods will always return a single EJBObject, entity EJBHome methods (for example, finder methods) may return multiple EJBObjects. To accommodate the possibility of multiple objects being returned, a CreateEJB 2.1 service always wraps the output of the create/find method in an array.
If the CreateEJB 2.1 service fails, it throws an adapter exception.
Step
Description
1
An Integration Server client runs a flow service or Java service on Integration Server.
2
The flow or Java service invokes a CreateEJB 2.1 adapter service on Integration Server.
You configured the adapter service earlier using Designer.
3
The CreateEJB 2.1 adapter service gets a connection from the service's connection pool.
You created and enabled the adapter connection earlier using Integration Server Administrator.
4
Through its connection, the CreateEJB 2.1 adapter service accesses the application server's JNDI to look up the EJBHome interface of the EJB for which the service was configured. JNDI will return the remote stub representing this EJBHome.
5
The CreateEJB 2.1 adapter service invokes the configured EJBHome method on the application server. If the method takes any parameters, the values are extracted from the pipeline and passed to the remote method.
If the operation is successful, the adapter service returns an array of javax.ejb.Handle instances that represent the remote EJBs.
If the operation is unsuccessful, the adapter service throws an AdapterException or AdapterConnectionException. For more information about how the adapter handles exceptions, see Adapter Logging and Exception Handling.
6
The CreateEJB 2.1 adapter service saves the resulting remote EJB handle(s) and status on pipeline. These handles may then be de-serialized by the caller to obtain the underlying EJBs or simply passed into a suitably configured InvokeEJB 2.1 adapter service.