uCosminexus Service Platform, Overview

[Contents][Glossary][Index][Back][Next]

8.11.3 Transaction design

To simplify recovery from error, design transactions in FTP integration with the following policy:

Organization of this subsection
(1) Scope of a transaction
(2) Deleting files when an error occurs
(3) Points to be considered on designing a business process

(1) Scope of a transaction

The transactions are managed by using EJB transactions in order to synchronize the content of response to the FTP client, such as normal and abnormal termination, and the processing status of the business process.

This subsection describes the scope of a transaction for each file transfer pattern.

(a) For synchronous business processes

The following figure shows the transaction scope for synchronous business processes.

For details on the file transfer patterns using synchronous business processes, see "8.3.1(1) Procedure of file transfer using synchronous business processes" and "8.3.2 Transfer of files from an FTP server to an FTP client".

Figure 8-42 For synchronous business processes (To transfer files from an FTP client to an FTP server)

[Figure]

Figure 8-43 For synchronous business processes (To transfer files from an FTP server to an FTP client)

[Figure]

(b) For asynchronous business processes

The following figure shows the transaction scope for the asynchronous business processes.

For details on the file transfer patterns using asynchronous business processes, see "8.3.1(2) Procedure of file transfer using asynchronous business processes".

Figure 8-44 For asynchronous business processes

[Figure]

(c) For the transfer of files from an FTP client to another FTP client

The following figure shows the transaction scope for the transfer of files from an FTP client to another FTP client.

For details on the file transfer pattern from an FTP client to another FTP client, see "8.3.3 Transfer of files from an FTP client to another FTP client".

Figure 8-45 For the transfer of files from an FTP client to another FTP client (To transfer files to the common folder in the HCSC server)

[Figure]

Figure 8-46 For the transfer of files from an FTP client to another FTP client (To obtain files from the common folder in the HCSC server)

[Figure]

(2) Deleting files when an error occurs

In FTP integration, when an error occurs, each component deletes the output files to match the processing results and file status.

The following table describes the processing in FTP integration and the processing in the corresponding components:

Table 8-30 Handling of files in FTP integration

Processing Component Assumed cause of error Handling of files in the case of error
Input file Output file
File transmission from FTP client FTP reception
  • File transfer interrupted
  • Network error
  • Insufficient disk space
  • Disk error
-- Delete
File reception from FTP client FTP reception
  • File transfer interrupted
  • Network error
  • Insufficient disk space
  • Disk error
State before processing is guaranteed --
File transmission to FTP server FTP adapter
  • Network error
  • Insufficient disk space
  • Disk error
State before processing is guaranteed --
File reception from FTP server FTP adapter
  • Network error
  • Insufficient disk space
  • Disk error
-- Delete
File conversion File operations adapter
  • Conversion error
  • Insufficient disk space
  • Disk error
State before processing is guaranteed Delete
File replication File operations adapter
  • Insufficient disk space
  • Disk error
State before processing is guaranteed Delete

Legend:
--: Not applicable.

Note that if the file deletion process does not terminate normally due to the following causes, restart the system: #1#2

#1
If the file being written to cannot be deleted when an error occurs, the exclusive lock for that file is not released. Therefore, the error does not reach the files to be deleted due to access from the other business processes.

#2
To delete the error files on a shared folder, you must stop the entire system configuring the cluster.

(3) Points to be considered on designing a business process

To consider the entire transfer processing for one file as one-phase transaction, you must consider the updated resources as one. In FTP integration, you cannot perform two-phase commit to match the synchronization of updates for multiple resources. Therefore, when you design a business process, you must consider the following points: