Beispiel #1
0
 private static IServiceConnectionContainer CreateContainer(IServiceConnectionFactory serviceConnectionFactory, HubServiceEndpoint endpoint, int count, ILoggerFactory loggerFactory)
 {
     if (endpoint.EndpointType == EndpointType.Primary)
     {
         return(new StrongServiceConnectionContainer(serviceConnectionFactory, count, endpoint, loggerFactory.CreateLogger <StrongServiceConnectionContainer>()));
     }
     else
     {
         return(new WeakServiceConnectionContainer(serviceConnectionFactory, count, endpoint, loggerFactory.CreateLogger <WeakServiceConnectionContainer>()));
     }
 }
Beispiel #2
0
 public StrongServiceConnectionContainer(IServiceConnectionFactory serviceConnectionFactory,
                                         int fixedConnectionCount, HubServiceEndpoint endpoint, ILogger logger = null) : base(serviceConnectionFactory, fixedConnectionCount, endpoint, logger: logger)
 {
     _onDemandServiceConnections = new List <IServiceConnection>();
 }