36 Implementing WebSphere BI Express for Item Synchronization
Series of commands that you execute from time to time but are not required to be
executed during the start-up of the agent can be stored in a work order file. You
can then use the batch command to execute the commands whenever this is
appropriate. Work order files also can be executed automatically. The agent can
be configured to monitor a directory for files with a given extension. (The default
extension is .wo.) When such a file is dropped in the correct directory, the agent
will read it and execute the commands.
Example 4-2 shows a sample work order file. It has an XML format where
individual commands are the data values of a command XML element. The
actual command can be any command that is supported by the agent. The actual
command does not look any different from what you would have typed in an
interactive session.
Example 4-2 Sample work order file
<xml>
<command> send http QA_a QA_b -fNedi\edifile.x12 -r1 -cE</command>
</xml>
In addition to file-based work orders, you can use a message queue. However,
the contents of the message should not be in the XML format that is shown in
Example 4-2. The contents of the message should be the command text only,
without the xml and command tags. Unfortunately, the response or output of the
command is not sent back as a reply message. The output of the command is
shown in the console view and in the log file, if activated.
Web-based status reporting can be turned on by executing the command start
GUI. The P2PAgent will then listen on port 80 for any HTTP requests. If a request
is received, it responds with the output of the status command. The standard
product does not offer a complete Web-based administration tool. However, this
functionality is available as an add-on product.
4.4 Load-balancing and multi-machine setup
For environments where many documents need to be sent and received, a single
machine might not be sufficient to handle all the workload. iSoft’s P2PAgent
provides a solution to this problem. The task of sending and receiving documents
can be split into three different roles:
The Transport role: This is the task of encrypting, decrypting, signing and
verifying signatures, as well as sending and receiving documents. Encryption
and digital signature algorithms are mathematically-intensive operations.
Therefore, it is useful if these tasks can be spread over multiple machines.