public WorkerSource() { try { string strError = string.Empty; zmqPublisher = new ZMQPublisher(); zmqPublisher.InitialisePublisher(IOHelper.AgentConfig.ZMQAddress, out strError, 1000, IOHelper.AgentConfig.ZMQSecurity); } catch (Exception ex) { WorkerLogger.TraceLog(MessageType.Error, ex.Message); } }
//public static void TraceLog(MessageType enumMessageType, string strText) //{ // try // { // IOLog.TraceLog("", strText, enumMessageType); // } // catch // { // // ignored // } //} public static void InitializeSIOTHLoggingPublisher(string SIOTHLogZMQAddress, bool UseSecurity) { try { ZMQLogPublisher = new ZMQPublisher(); string strError; ZMQLogPublisher.InitialiseLogggerPublisher(SIOTHLogZMQAddress, out strError, 1000, UseSecurity); if (!string.IsNullOrEmpty(strError)) { IOLog.TraceLog(AgentName, "Error occurred while Initializing Logging Publisher", MessageType.Error); } } catch (Exception ex) { } }
/// <summary> /// Constructor for the form /// </summary> public PricesForm() { InitializeComponent(); m_priceGrid = new DynamicDisplayGrid(gridPrices, this); m_spreadGrid = new DynamicDisplayGrid(gridSpreads, this); m_priceGrid.InitializeColumns(PriceRow.Columns, Color.White); m_spreadGrid.InitializeColumns(SpreadRow.Columns, Color.White); m_spreadGrid.Columns["Formula"].MinimumWidth = 300; m_spreadGrid.Columns["Formula"].CellTemplate.Style.Alignment = DataGridViewContentAlignment.MiddleLeft; m_publisher = new ZMQPublisher(); m_subscriber = new ZMQSubscriber(); m_subscriberClientTask = Task.Factory.StartNew(() => m_subscriber.SubscriptionLoop()); }