Creating client emulator startup scripts

Although many types of benchmarks can be performed with real clients, it is often desirable to remove the complexity associated with having to prepare the applications and configure the clients. To satisfy this requirement, you can use libraries provided by IBM WebSphere InterChange Server that emulate connector agents.

About starting IBM WebSphere InterChange Server clients

This section discusses some of the concepts and implementations for starting IBM WebSphere InterChange Server clients.

For an IBM WebSphere InterChange Server client to start up, it must start a Java program and do the following:

These actions are accomplished through startup scripts, which are similar in function across Windows and UNIX-based systems, though there are slight differences in implementation.

Creating benchmark connector- emulator startup scripts

To create a benchmark connector-emulator startup script for a particular connector, you must create a connector-emulator startup script that invokes the following Java class for a connector emulator:
CxCommon.BenchConnector.BenchMarkConnector.

The steps to create this connector-emulator startup script depend on your operating-system environment.

Connector-emulator startup scripts for Windows

To create a benchmark connector-emulator startup script on a Windows system, take the following steps:

  1. Make a copy of the connector startup script template, which is located in the following directory:
    ProductDir\templates\start_connName.bat.
    Give the copy a name that suggests its role in emulating a connector for the purpose of benchmarking (such as start_benchmark.bat) and put it in the bin subdirectory of the product directory.
  2. Edit the copied startup script so that it invokes the benchmark connector emulator's Java class.
    For the Windows environment, the line in the startup-script template to invoke a Java connector class appears as follows:
    call startup_adapter.bat -nconnName -sserverName -lconnectorSpecificClasses
    where:

    In this line, change the name of the Java-class (connectorSpecificClasses) to the name of the Java class for the connector emulator, so that the line appears as follows:
    call startup_adapter.bat -nconnName -sserverName
    -lCxCommon.BenchConnector.BenchMarkConnector

  3. Save the benchmark-connector-emulator startup script.
  4. Configure the startup mechanism so that the name of the connector is passed as the value to the -n parameter (connName) and the name of the InterChange Server instance (serverName) is passed as the value to the -s parameter.
    Implement one of these three approaches to create a solution that allows you to emulate each connector you are benchmarking:

Connector-emulator startup scripts for UNIX

To create a benchmark connector-emulator startup script on a UNIX-based system, take the following steps:

  1. Make a copy of the low-level connector startup-script template, which is located in the following directory:
    ProductDir\templates\start_connName.sh
    Give the copy a name that suggests its role in emulating a connector for the purpose of benchmarking (such as start_Benchmark.sh) and put it in the bin subdirectory of the product directory.
  2. Edit the copied startup script so that it invokes the benchmark connector emulator's Java class.
    For UNIX-based environments, the line in the startup-script template to invoke a Java connector class appears as follows:
    exec ${ADAPTER_RUNTIME}/bin/start_adapter.sh -nconnName -sserverName -lconnSpecificClasses -f... -p... -c... ...
    where:

    In this line, change the name of the Java-class (connSpecificClasses) to the name of the Java class for the connector emulator, so that the line appears as follows:
    exec ${ADAPTER_RUNTIME}/bin/start_adapter.sh -nconnName -sserverName -lCxCommon.Bench.Connector.BenchMarkConnector -f... -p... -c... ....
    The "-f... -p... -c... ..." string indicates the position for other command-line parameters that thestart_adapter.sh script supports. You must decide if any of these command-line parameters are useful. For more information on these parameters, see the System Administration Guide.

  3. Save the benchmark-connector-emulator startup script.
  4. Configure the startup mechanism in one of the following ways so that the name of the connector is passed as the value to the -n parameter (connName) and the name of the InterChange Server instance (serverName) is passed as the value to the -s parameter.
    Implement one of these three approaches to create a solution that allows you to emulate each connector you are benchmarking:

Copyright IBM Corp. 1997, 2004