Exemplo n.º 1
0
 GetConnectionObserver(Ice.ConnectionInfo ci,
                       Ice.IEndpoint ei,
                       Ice.Instrumentation.ConnectionState s,
                       Ice.Instrumentation.IConnectionObserver o)
 {
     return(null);
 }
Exemplo n.º 2
0
 GetConnectionObserver(Ice.ConnectionInfo c,
                       Ice.IEndpoint e,
                       Ice.Instrumentation.ConnectionState s,
                       Ice.Instrumentation.IConnectionObserver old)
 {
     lock (this)
     {
         Debug.Assert(old == null || old is ConnectionObserver);
         if (connectionObserver == null)
         {
             connectionObserver = new ConnectionObserver();
             connectionObserver.reset();
         }
         return(connectionObserver);
     }
 }
Exemplo n.º 3
0
 public Ice.Instrumentation.IConnectionObserver? GetConnectionObserver(ConnectionInfo c,
                                                                       IEndpoint e,
                                                                       Ice.Instrumentation.ConnectionState s,
                                                                       Ice.Instrumentation.IConnectionObserver obsv)
 {
     if (_connections.IsEnabled())
     {
         try
         {
             Ice.Instrumentation.IConnectionObserver?del = null;
             ConnectionObserverI?o = obsv is ConnectionObserverI ? (ConnectionObserverI)obsv : null;
             if (_delegate != null)
             {
                 del = _delegate.GetConnectionObserver(c, e, s, o != null ? o.GetDelegate() : obsv);
             }
             return(_connections.GetObserver(new ConnectionHelper(c, e, s), obsv, del));
         }
         catch (System.Exception ex)
         {
             _metrics.GetLogger().Error("unexpected exception trying to obtain observer:\n" + ex);
         }
     }
     return(null);
 }