Пример #1
0
 internal void AddAmqpClientRef(AmqpClient client)
 {
     lock (clientReferences)
     {
         clientReferences.Add(client);
     }
 }
Пример #2
0
 internal void RemoveAmqpClientRef(AmqpClient client)
 {
     lock (clientReferences)
     {
         clientReferences.Remove(client);
         if (clientReferences.Count == 0)
         {
             // no more clients, start a timer to eventually shutdown the connection.
             // we'll leave it open for a bit, just in case a client decides to connect again.
             throw new NotImplementedException("Start Timer to Shutdown the Connection.");
         }
     }
 }