The three provided business operations, fund transfer (TransferAccessOp),
get balance (BalanceAccessOp), and get customer account information
(CustInfoAccessOp) are externalized in XML files. In creating the Web
Services Sample Application, this was done using the following guidelines:
- Use self-defined operations and self-defined processors.
- Avoid, as much as possible, dependencies between the self-defined
modules and the configuration file. This enables you to deploy new
functions without re-initializing the server. It also enables you
to update deployed functions without interfering with the rest of
the application. To avoid dependencies, do the following things:
- Name files to match the names of the operations or processors. With
this approach, the name and path of the file containing the definitions
does not have to be specified, which isolates the definitions from
the configuration file (btt.xml).
- Use the implClass attribute when the class is particular for a
specific definition or when the implementation class may change frequently.
- Use the tag/class relationships specified in the configuration
file when the implementation class is generic and does not change
frequently.
- Define generic types used by the application in the type.xml file.
- Define generic formatters used by the application in the format.xml file.
- Define generic contexts used by the application in the context.xml file.
- Define generic services used by the application in the service.xml file.
- Define generic operations used by the application in the operation.xml file.
- Define generic processors used by the application in the processor.xml file.
- Define generic data elements belonging to the server context and
the session context in the data.xml file.
These guidelines were followed for this particular application,
but you can change the approach in a real environment.
If you are creating your
own Web Service application, you must create the business operations
and processor in the Transaction Editor and generate them to .xml file.