Ejemplo n.º 1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="SchemaProvider"/> class.
        /// </summary>
        /// <param name="bus">Message bus</param>
        /// <param name="log">Application error log</param>
        /// <param name="manager">Branch manager service</param>
        /// <param name="mutations">GraphQL mutations</param>
        /// <param name="queries">GraphQL queries</param>
        /// <param name="services">Asp.Net services collection</param>
        /// <param name="graph">QGraph</param>
        /// <param name="messageQueue">Message queue</param>
        /// <param name="observer">Diagnostic observer</param>
        /// <param name="recordLog">Record log</param>
        /// <param name="remote">Remote service</param>
        /// <param name="timeline">Timeline</param>
        public SchemaProvider(IBus bus, ILog log, IBranchManager manager, IEnumerable <IGraphQlMutation> mutations, IEnumerable <IGraphQlQuery> queries, IServiceCollection services, IGraph graph, IMessageQueue messageQueue, IDiagnosticObserver observer, IRecordLog recordLog, IRemote remote, ITimeline timeline)
        {
            _bus          = bus;
            _log          = log;
            _manager      = manager;
            _mutations    = mutations;
            _queries      = queries;
            _services     = services;
            _graph        = graph;
            _messageQueue = messageQueue;
            _observer     = observer;
            _recordLog    = recordLog;
            _remote       = remote;
            _timeline     = timeline;

            InitialiseServices();
        }
Ejemplo n.º 2
0
        public void Subscribe(IDiagnosticObserver diagnosticObserver)
        {
            var subscription = DiagnosticListener.AllListeners.Subscribe(diagnosticObserver);

            _subscriptions.Add(subscription);
        }