Testing the socket server

The socket DSA provides a command line client that you can use to test the availability of socket servers, including the sample server provided in the DSA tar file. You use this client to send messages to a socket server using a simple command line input. The client is named TestClient and is located in the DSA jar file.

About this task

Procedure

  • To test the socket server, enter the following command at a command-line prompt on the system where you are running Tivoli Netcool®/Impact:

    java -cp [$Impact_home]/wlp/usr/servers/NCI_A/apps/NCI_A.ear/nci.jar com.micromuse.dsa.socketdsa.TestClient hostname port

    Where hostname is the name of the system where the socket server is running and port is the port number used by the server.

  • To test the availability of a socket server, enter the following string at the command line:
    hi

    The test client sends this string to the socket server and prints the response. If the socket server is running correctly, the response will be a hi string identical to the one sent from the command line.

What to do next

You can perform additional testing by entering additional strings at the command line, following the command sequence documented in the code comments in Server.pl.