Jolt 1.2 Developer's Guide
Table Of Contents
- Jolt for NonStop(TM) TUXEDO Developer's Guide
- Jolt for NonStop(TM) TUXEDO Developer's Guide
- About This Guide
- 1. Introducing Jolt
- 2. Installing Jolt
- 3. Configuring the Jolt System
- 4. Bulk Loading NonStopTM TUXEDO Services
- 5. Using the Jolt Repository Editor
- 6. Using the Jolt Class Library
- 7. Using JoltBeans
- 8. Using Servlet Connectivity for NonStopTM TUXEDO
- 9. Using Jolt 1.2 ASP Connectivity for NonStopTM TUXEDO
- A. NonStopTM TUXEDO Errors
- B. System Messages
- Index

trans = new JoltTransaction(timeout, session)
Jolt uses an explicit transaction model for any services involved in a transaction. The transaction service invocation requires a JoltTransaction object
as a parameter. Jolt also requires that the service and the transaction belong to the same session. Jolt does not allow you to use services and
transactions that are not bound to the same session.
Jolt Class Library Walk-through
Example 6-1 shows how to use the Jolt Class Library and includes the use of the JoltSessionAttributes, JoltSession, JoltRemoteService, and
JoltTransaction classes.
The example combines two user-defined NonStop
TM
TUXEDO services (WITHDRAWAL and DEPOSIT) to perform a simulated TRANSFER
transaction. If the WITHDRAWAL operation fails, a rollback is performed. Otherwise, a DEPOSIT is performed and a commit completes the
transaction.
Example 6-1. Jolt Transfer of Funds Example (SimXfer.java)
/* Copyright 1996 BEA Systems, Inc. All Rights Reserved */
import bea.jolt.*;
public class SimXfer
{
public static void main (String[] args)
{
JoltSession session;
JoltSessionAttributes sattr;
JoltRemoteService withdrawal;
JoltRemoteService deposit;
JoltTransaction trans;
String userName=null;
String userPassword=null;
String appPassword=null;
String userRole="myapp";
sattr = new JoltSessionAttributes();
sattr.setString(sattr.APPADDRESS, "//bluefish:8501");










