Exemplo n.º 1
0
 public DataServiceBase(IDataServiceConfig config, IHystrixCommandFactory hystrixCommandFactory,
                        ILogger <IDataService <T> > logger)
 {
     _config = config ?? throw new ArgumentNullException(nameof(config));
     _hystrixCommandFactory = hystrixCommandFactory ?? throw new ArgumentNullException(nameof(hystrixCommandFactory));
     _logger = logger ?? throw new ArgumentNullException(nameof(logger));
 }
        public HystrixMetricsStreamEndpoint(IHystrixCommandFactory commandFactory, int pollingInterval)
        {
            if (pollingInterval < 100)
            {
                throw new ArgumentOutOfRangeException(nameof(pollingInterval), "Parameter pollingInterval needs to be greater than or equal to 100");
            }

            this.commandFactory  = commandFactory ?? throw new ArgumentNullException(nameof(commandFactory));
            this.pollingInterval = pollingInterval;
        }
Exemplo n.º 3
0
 public TransformationServices(IHystrixCommandFactory hystrixCommandFactory)
 {
     hystrixCommand = hystrixCommandFactory.GetHystrixCommand("TestGroup", "TestCommand");
 }
Exemplo n.º 4
0
 public HystrixMiddleware(Middleware <HandleContext> actualHandle, IHystrixCommandFactory commandFactory)
 {
     this.commandFactory = commandFactory;
     this.actualHandle   = actualHandle;
 }
Exemplo n.º 5
0
 public HelloController(IHystrixCommandFactory hystrixCommandFactory)
 {
     hystrixCommand = hystrixCommandFactory.GetHystrixCommand("TestGroup", "TestCommand");
 }
 public HystrixMetricsStreamEndpoint(IHystrixCommandFactory commandFactory, HystrixOptions options) :
     this(commandFactory, options?.MetricsStreamPollIntervalInMilliseconds ?? 500)
 {
 }
Exemplo n.º 7
0
 public JsonServices(IHystrixCommandFactory hystrixCommandFactory)
 {
     hystrixCommand = hystrixCommandFactory.GetHystrixCommand("JsonGroup", "JsonCommand");
 }
Exemplo n.º 8
0
 public HystrixController(IHystrixCommandFactory hystrixCommandFactory, IHttpClientFactory httpClientFactory)
 {
     this.hystrixCommand    = hystrixCommandFactory.GetHystrixCommand("GroupKey", "CommandKey");
     this.httpClientFactory = httpClientFactory;
 }
Exemplo n.º 9
0
 public HttpRepoServiceBase(IHttpRepoServiceConfig config, IHystrixCommandFactory hystrixCommandFactory,
                            ILogger <IDataService <T> > logger) : base((IDataServiceConfig)config, hystrixCommandFactory, logger)
 {
 }
 public MongoHttpRepoService(IMongoHttpRepoServiceConfig config, IHystrixCommandFactory hystrixCommandFactory,
                             ILogger <IDataService <T> > logger) : base((IHttpRepoServiceConfig)config, hystrixCommandFactory, logger)
 {
     client = new MongoClient(config.ConnectionString);
     db     = client.GetDatabase(config.DatabaseName);
 }
Exemplo n.º 11
0
 public XmlServices(IHystrixCommandFactory hystrixCommandFactory)
 {
     hystrixCommand = hystrixCommandFactory.GetHystrixCommand("XmlGroup", "XmlCommand");
 }