The following process describes what happens when a process running within
the Business Process Component uses the Database Table Mapping service to
retrieve a record in a database table when the auto-connect and auto-commit
attributes are enabled. Note that the process omits many of the initialization
and messaging steps that normally happens in a service. See How the services
work for information on these steps.
- An activity in the process retrieves the name of the service requester
from the ServiceRequesterIDs.properties resource bundle.
- The activity uses the resource bundle name to get a table mapping requester
from the requester factory. The factory creates and configures the requester
instance.
- The activity in the process invokes a method in the requester instance
to retrieve a record.
- The requester accesses the formatter service to format the data for the
retrieval request.
- The requester sends the retrieval request and its parameters to the service
container using a WSIF message.
- The services container invokes the retrieve function in the table mapping
service object.
- The table mapping service object creates an SQL statement using the contents
of the WSIF message. Note that the service object obtains the datasource name
from the application server's service definition file (dsesrvce.xml).
- The table mapping service object passes the SQL statement to the database
through the data source and connection manager.
- The services container returns the response to the requester.
- The requester accesses the formatter service to unformat the response
and sends the unformatted response to the activity.
The process for a single action EJB accessing the Database Table Mapping
service is similar. The primary difference is that EJB must do the work of
the activity mentioned in the above steps.