예제 #1
0
 internal ServiceManager(ServiceManagerOptions serviceManagerOptions)
 {
     _serviceManagerOptions = serviceManagerOptions;
     _endpoint           = new ServiceEndpoint(_serviceManagerOptions.ConnectionString, EndpointType.Secondary);
     _endpointProvider   = new ServiceEndpointProvider(_endpoint, appName: _serviceManagerOptions.ApplicationName);
     _serverNameProvider = new DefaultServerNameProvider();
 }
 public RestHubLifetimeManager(ServiceManagerOptions serviceManagerOptions, string hubName, string productInfo)
 {
     _restApiProvider = new RestApiProvider(serviceManagerOptions.ConnectionString);
     _productInfo     = productInfo;
     _appName         = serviceManagerOptions.ApplicationName;
     _hubName         = hubName;
 }
예제 #3
0
 public void SetValueFromOptions(ServiceManagerOptions options)
 {
     ServiceEndpoints = options.ServiceEndpoints ?? (options.ServiceEndpoint != null
             ? (new ServiceEndpoint[] { options.ServiceEndpoint })
             : (new ServiceEndpoint[] { new ServiceEndpoint(options.ConnectionString) }));
     ApplicationName      = options.ApplicationName;
     ConnectionCount      = options.ConnectionCount;
     Proxy                = options.Proxy;
     ServiceTransportType = options.ServiceTransportType;
 }
예제 #4
0
 internal ServiceManager(ServiceManagerOptions serviceManagerOptions, string productInfo)
 {
     _serviceManagerOptions = serviceManagerOptions;
     _endpoint         = new ServiceEndpoint(_serviceManagerOptions.ConnectionString, EndpointType.Secondary);
     _endpointProvider = new ServiceEndpointProvider(_endpoint, Options.Create(new ServiceOptions
     {
         ApplicationName = _serviceManagerOptions.ApplicationName
     }));
     _serverNameProvider = new DefaultServerNameProvider();
     _productInfo        = productInfo;
 }
예제 #5
0
 internal ServiceManager(ServiceManagerOptions serviceManagerOptions, string productInfo)
 {
     _serviceManagerOptions = serviceManagerOptions;
     _endpoint         = new ServiceEndpoint(_serviceManagerOptions.ConnectionString, EndpointType.Secondary);
     _endpointProvider = new ServiceEndpointProvider(_endpoint, Options.Create(new ServiceOptions
     {
         ApplicationName = _serviceManagerOptions.ApplicationName,
         Proxy           = serviceManagerOptions.Proxy
     }).Value);
     _serverNameProvider = new DefaultServerNameProvider();
     _productInfo        = productInfo;
     _restClient         = new RestClient();
     _restApiProvider    = new RestApiProvider(_serviceManagerOptions.ConnectionString);
 }
예제 #6
0
 public RestHubLifetimeManager(ServiceManagerOptions serviceManagerOptions, string hubName)
 {
     _restApiProvider = new RestApiProvider(serviceManagerOptions.ConnectionString, hubName);
 }
 public ServiceHubLifetimeManagerFactory(IServiceProvider sp, IOptions <ServiceManagerOptions> context)
 {
     _serviceProvider = sp;
     _options         = context.Value;
 }
 public HostedServiceFactory(IServiceProvider serviceProvider, IOptions <ServiceManagerOptions> options)
 {
     _serviceProvider = serviceProvider;
     _options         = options.Value;
 }
예제 #9
0
 internal ServiceManager(ServiceManagerOptions serviceManagerOptions)
 {
     _serviceManagerOptions = serviceManagerOptions;
     _endpoint         = new ServiceEndpoint(_serviceManagerOptions.ConnectionString, EndpointType.Secondary);
     _endpointProvider = new ServiceEndpointProvider(_endpoint);
 }
예제 #10
0
 internal ServiceManager(ServiceManagerOptions serviceManagerOptions)
 {
     _serviceManagerOptions = serviceManagerOptions;
     _endpoint = new ServiceEndpointProvider(new ServiceEndpoint(_serviceManagerOptions.ConnectionString));
 }