Ejemplo n.º 1
0
        public ConsulProvider(ConsulProviderOptions options, Action <ConsulClientConfiguration> consulConfig)
        {
            _serviceTtl         = options.ServiceTtl.Value;
            _refreshTtl         = options.RefreshTtl.Value;
            _deregisterCritical = options.DeregisterCritical.Value;
            _blockingWaitTime   = options.BlockingWaitTime.Value;

            _client = new ConsulClient(consulConfig);
        }
Ejemplo n.º 2
0
        public ConsulProvider(ConsulProviderOptions options, Action <ConsulClientConfiguration> consulConfig)
        {
            _serviceTtl         = options.ServiceTtl ?? TimeSpan.FromSeconds(3);
            _refreshTtl         = options.RefreshTtl ?? TimeSpan.FromSeconds(1);
            _deregisterCritical = options.DeregisterCritical ?? TimeSpan.FromSeconds(10);
            _blockingWaitTime   = options.BlockingWaitTime ?? TimeSpan.FromSeconds(20);

            _client = new ConsulClient(consulConfig);
        }
Ejemplo n.º 3
0
 public ConsulProvider(ConsulProviderOptions options) : this(options, config => { })
 {
 }
 public ConsulClusterMonitor(ActorSystem system, ConsulProviderOptions options, Action <ConsulClientConfiguration> consulConfig)
 {
     _system  = system;
     _options = options;
     _client  = new ConsulClient(consulConfig);
 }
Ejemplo n.º 5
0
 public ConsulProvider(ConsulProviderOptions options, Action <ConsulClientConfiguration> consulConfig)
 {
     _options      = options;
     _consulConfig = consulConfig;
 }