OnixS Brokertec ITCH Market Data Handler for C++  1.1.0.1
Adjusting Handler's Settings
Getting Started

Handler Settings

All Handler's constructors accept instance of corresponding handler's settings class which defines values of various parameters for determination Handler's behavior. Role of the most important parameters that used in regular cases is described below.

Primary Settings

Directory for Log Files

By default, all important aspects of handler's activity are logged. Therefore, the handler must know where this kind of information can be stored on a local file system. The OnixS::Brokertec::MarketData::Itch::HandlerSettings::logDirectory parameter needs to be defined for pointing the handler's place where log files can be stored.

Licensing

To run a handler's instance, it is required to have a license file. When the instance is not able to find a valid license, it throws an exception at the initialization stage.

OnixS::Brokertec::MarketData::Itch::HandlerSettings contains OnixS::Brokertec::MarketData::Itch::HandlerSettings::licenseDirectory member which contains path to directory containing license file(s). If it's value is empty, the handler looks for the license file in current directory.

Note:
When there is more than one license file in the license directory, the most significant one is used (for example, production instead of trial if both are available).

Example

The following example demonstrates how to setup primary settings for OnixS::Brokertec::MarketData::Itch::Handler:

	// Create an instance handler's settings. 
	OnixS::Brokertec::MarketData::Itch::HandlerSettings handlerSettings;

	// This option is used to control verbosity of logger.
	settings.logLevel = OnixS::Brokertec::MarketData::Itch::LogLevel::Debug;

	// This option is used to specify extra logger settings.
	settings.logSettings = OnixS::Brokertec::MarketData::Itch::LogSettings::Default;

	// Logs will be stored in 'logs' local sub folder.
	settings.logDirectory = "logs";

	// This option is used to instruct the Handler where to look for a valid license.
	settings.licenseDirectory = "../../license";

	// Set up IP addresses and port numbers for multicast feeds
	handlerSettings.useFeedA                        = true;
	handlerSettings.useFeedB                        = true;
	
	handlerSettings.multicastFeed.serviceA.address  = "194.169.8.210";
	handlerSettings.multicastFeed.serviceA.port     = 53032;
	handlerSettings.multicastFeed.serviceB.address  = "194.169.8.211";
	handlerSettings.multicastFeed.serviceB.port     = 54033;
	
    handlerSettings.retransmitionServer.address = "194.169.8.212";
    handlerSettings.retransmitionServer.port = 54034;	

	OnixS::Brokertec::MarketData::Itch::Handler handler (settings);