예제 #1
0
 public void Publish(string channel, HeartbeatMessage retMessage)
 {
     _conn.Publish(channel, Encoding.Default.GetBytes(retMessage.ToString()));
 }
예제 #2
0
        private void _heartbeat_Elapsed(object sender, ElapsedEventArgs e)
        {
            HeartbeatMessage heartbeat = HeartbeatMessage.Parse(_serviceInfo);

            _conn.Publish("MOL.HEARTBEAT", Encoding.Default.GetBytes(heartbeat.ToString()));
        }