public Connection(IAppId appId, IPrepareConfigService configuration, IHealthcheck healthcheck) { Configuration = configuration; IsConnected = false; AppId = appId; healthcheck.AddCheck(() => IsConnected); }
public CoreDispatcher(IPrepareConfigService config, IAppId appId, ICoreConnection coreConnection, IResolver resolver, IHealthcheck healthcheck) { Config = config; AppId = appId.CurrentUID; Connection = coreConnection; Resolver = resolver; healthcheck.AddCheck(() => running); Resolver.Stopped += (appid) => { running = false; }; Resolver.Started += Resolver_Started; }
public FanoutService1(ICoreConnection coreConnection, IConfiguration configuration, IAppId appId) { CoreConnection = coreConnection; Configuration = configuration; AppId = appId; }
// public ConcurrentDictionary<string, List<ResolverInvoker>> pending = new ConcurrentDictionary<string, List<ResolverInvoker>>(); public Resolver(IMemoryCache memoryCache, ICoreConnection connection, IPrepareConfigService configuration, IHealthcheck healthcheck, IAppId appId) { Configuration = configuration; AppId = appId.CurrentUID; Connection = connection; Cache = memoryCache; Bind = false; healthcheck.AddCheck(() => Bind); connection.Connected += Connection_Connected; connection.Disconnected += (appid) => { Bind = false; Stopped?.Invoke(appid); if (cancellationRefreshCache != null) { Trace.TraceInformation("Cache refresh stopped"); cancellationRefreshCache.Cancel(); } }; }
public CustomService(IAppId appId) { AppId = appId.CurrentUID; }
public Service2(IAppId appId, IConfiguration configuration) { AppId = appId.CurrentUID; Configuration = configuration; }