RandomRoutingGateway Sample

The RandomRoutingGateway example consists of 3 executables. A client, a server and a gateway. Client acts a buy side sending New Order, Order Cancel and Order Cancel/Replace messages. Server sends back random execution reports and random cancel rejects.

Both client and server implement 4 FIX sessions running FIX version from 4.1 to 4.4. Client and server are not directly connected. They both connect to the gateway. The gateway has 8 FIX sessions, 4 for client and 4 for server.

Gateway uses a random generator to route the incoming buy side orders to random sell side FIX sessions.

 

Configuring the Sample

All sample processes require to know the URI of the repository server (IP, port and password). A local log directory is also required. Read source code for corresponding command line paramaters.

The configuration of all three processes are already included in the default repository. The IP and port of each FIX session may need to be modified in order to successfully run the sample codes. If all three processes are running on the same machine, no need to modify the configuration.

For more information about modifying the configuration, please refer to the QWFIX Enterprise Manager User Manual.