TS/MP Pathsend and Server Programming Manual (G06.24+, H06.03+)
Designing Your Application
NonStop TS/MP Pathsend and Server Programming Manual–132500
2-7
Protecting Transactions
Database Consistency and Concurrency
Potentially, all operations that alter the database are candidates for TMF protection. But 
before you can apply TMF protection to your transactions, you need to determine: 
•
When to begin a TMF transaction
•
Whether all of the database update operations have to happen together in the same 
TMF transaction or whether they can be parts of different transactions
To answer these issues, you have to establish your criteria for database consistency and 
decide how much processing concurrency you can achieve in the application. For 
example, the Enter Sales transaction affects several pieces of information: order data, 
inventory data, shipping data, customer credit, and receivables. Upon examination of this 
transaction, you will see that it is possible to make one general assertion about order 
processing and about the Enter Sales transaction in particular: An order is not complete 
until every piece of information associated with the order is recorded in the \REG, 
\CORP, and \WHS databases. 
Figure 2-3. Pathway Application Programming for the TMF Subsystem
BEGINTRANSACTION
 •
 •
 •
Request database 
services
 •
 •
Perform checkpointing 
as needed
 •
 •
Abort and restart 
transaction if necessary
 •
 •
ABORTTRANSACTION
or
ENDTRANSACTION
COBOL85, C, 
C++, Pascal, 
TAL, ...
TRANSID TRANSID
Audited 
Database 
Files
Requester Server
COBOL85, C, 
C++, Pascal, or 
TAL
Process request by:
—Reading files
—Locking records
 (following TMF
 record-locking rules)
—Changing records
 in files (changes are
 associated with
 TRANSID supplied
 by requester)
—Aborting transaction 
 if necessary
 •
 •
 Reply to request
CDT032










