Testing routes

Route specifications are the paths where messages flow from source threads to destination threads. Construct route specifications using a "From the Connection" approach.

Use the Routes tab to simulate the translation thread. Given a message, it determines the transaction ID and brings up the appropriate route configuration. This tool gets most of its configuration information from the Network Configurator.

The Route Testing Tool supports testing route configurations that contain DICOM transactions.

hciroutetest runs any inbound TPS for the source thread before it passes the messages to route and translate. This is necessary because the TPS often sets up metadata that is required for further processing.

If possible, then configure and verify complex routes without TPS modules. As the route is verified, add the modules in a logical order. The systematic insertion of TPS modules into the route specification makes isolating potential problems quicker.

It is important to verify each route. Valid message record formats for a thread and valid translations do not guarantee that the messages arrive at their correct destinations.

Test the route specifications for a particular source thread before starting the engine, after all message record formats and translations that are used by that thread are verified.

For hciroutetest to run translate procs in startup mode, select the Run Translation Procs in Start Mode check box on the Process Configuration dialog box. This is found at Process > Configure in Network Configurator.

Note: Global variable support is available for the hciroutetest command line tool. The global variable indicator $$ (double dollar) has a confict with the shell special variable, which has meaning as the current PID on Linux/AIX platforms. To use a global variable in the Testing Tool on Linux/AIX plaforms, escape the $$ using one of these forms. For example:
  • hciroutetest -a '$$variablename'
  • hciroutetest -a \$\$variablename

On Windows, use hciroutetest -a $$variablename.

  1. For Select Source Thread, click the arrow to open a list of available threads.
  2. Specify the testing data file in Choose Data File. You can also click the folder button to open a file browser to select the data file. By default, the file browser locates on the $HCISITEDIR/formats/ folder.
  3. Select Leak Detection to check for memory leaks.
  4. Select the line termination format in which to save the test messages. Click the arrow to open a list of formats.
    Newline Terminated reads the data in the file until it finds a newline character, making all that data one message, and sends that to the parser. It then reads until it finds the next newline character, makes a second message, and sends that to the parser.
    Length Encoded reads the first 10 characters to determine how long the first message is, reads that many characters into a message, and then sends it to the parser.
    EOF Terminated reads the file until it gets to the end-of-file character, takes that as a message, and sends it to the parser.
  5. Specify the encoding in the Encoding field, or click the arrow to open a list of different encodings that identify the encoding of messages in the selected data file. The command converts the messages from the identified encoding to UTF-8 to perform the test. When you select an encoding from the list, an -x encoding option is added to the corresponding command line.
  6. Select how to process records.
    process all records reads the selected data file and processes all the records in it.
    process one record reads the selected data file and processes only the first record in the file.
  7. Select Inbound Type Data to test the data routes configured in the Network Configurator.
  8. Select Inbound Type Reply and select a Reply Thread to test the reply routes configured in the Network Configurator. This is available only whenInbound Type Reply is selected.
  9. Select OB TPS for all outbound TPS that are defined in the route path destination threads to run once with start mode. If both OB TPS and Send to Proc are selected, then the outbound TPS are run before the procedure is run. Output messages become input messages to the procedure. TPS uses the same disposition policy as the translation post queue (the message for KILL, OVER, and ERROR dispositions are discarded). OB TPS and Send to Proc use different Tcl interpreters. OB TPS uses the same Tcl interpreter as IB TPS.
    If the check box is selected, then there must be a defined outbound TPS; otherwise, a warning results.
  10. Select Show Source Message ID to show the input source message ID in the output.

    This option displays the message between the translation and destination in hciroutetest.

    When this option is selected and Send to proc is hciroutetestshowbydest, then the message between the translation and destination is displayed. Example:

    test1.xlt msg
    test2.xlt msg
    dest msg

    If the option is enabled and Save to file is enabled, then the message between the translation and destination is saved to file. Example:

    Run hciroutetest there are files aaa, aaa.branch_dest1 and aaa.branch_dest2, messages after test2.xlt and 
    test3.xlt saved in file aaa, messages after test3.xlt and the branch_dest1 msg saved in file aaa.branch_dest1, 
    messages after test1.xlt and the branch_dest2 saved in file aa.branch_dest2.

    For remote commands, this option is -n.

  11. Select Save To File to save messages to a file. Specify the file name in the field. When this is selected, CONTINUE messages are saved to base.dest.thread. If base is not specified, then it defaults to routeout.
  12. Select Send To Proc to control the message disposition and save to a Tcl end procedure. This enables the selection list. Click the arrow to select from a list of procs.
  13. In the Arguments field, specify any arguments to pass in. This field is available when Send To Proc is selected.
  14. Select Error Database Proc to enable the control for failed messages. Click Edit to open the TPS Editor. Then, click Add to open the TPS Properties dialog box, where you can select the procedure or Java class and arguments for failed messages.
    Only one procedure or Java Class is supported.
    When the check box is cleared, the error TPS that is defined in NetConfig is used.
  15. If required, then select Grep to filter the output.
  16. Click Run Command to run the command shown in Preview Command to Issue.
    As the test is being configured, a command-line command and the requisite parameters are generated in Preview Command to Issue. This is for display only. A command cannot be manually entered.