示例#1
0
 public EventProcessor(IEventDataHandler Handler, string EventHubName, string ServiceBusNamespace, string ConsumerGroupName)
 {
     this.m_Handler             = Handler;
     this.m_EventHubName        = EventHubName;
     this.m_ServiceBusNamespace = ServiceBusNamespace;
     this.m_CounsumerGroupName  = ConsumerGroupName;
 }
 public EventProcessor(IEventDataHandler Handler, string EventHubName, string ServiceBusNamespace, string ConsumerGroupName)
 {
     this.m_Handler = Handler;
     this.m_EventHubName = EventHubName;
     this.m_ServiceBusNamespace = ServiceBusNamespace;
     this.m_CounsumerGroupName = ConsumerGroupName;
 }
示例#3
0
 public EventsService(IEventDataHandler eventDataHandler, IEventsMapping eventMapping, HttpClient client, IDistributionService distributionService, LoggerBase logger)
 {
     this._client              = client;
     this._eventDataHandler    = eventDataHandler;
     this._eventMapping        = eventMapping;
     this._distributionService = distributionService;
     this._logger              = logger.Logger;
 }
 public EventHubCommunicationListener(
     ITraceWriter TraceWriter,
     IReliableStateManager stateManager,
     IReliableDictionary <string, string> stateDictionary,
     ServiceInitializationParameters serviceParameters,
     string eventHubName,
     string eventHubConnectionString,
     string eventHubConsumerGroupName,
     IEventDataHandler handler) : this(TraceWriter,
                                       stateManager,
                                       stateDictionary,
                                       serviceParameters,
                                       eventHubName,
                                       eventHubConnectionString,
                                       eventHubConsumerGroupName,
                                       handler,
                                       EventHubCommunicationListenerMode.SafeDistribute,
                                       string.Empty)
 {
 }
示例#5
0
 public EventHubCommunicationListener(
     ITraceWriter TraceWriter,
     IReliableStateManager stateManager,
     IReliableDictionary<string, string> stateDictionary,
     ServiceContext serviceContext,
     string eventHubName,
     string eventHubConnectionString,
     string eventHubConsumerGroupName,
     IEventDataHandler handler) : this(TraceWriter,
         stateManager,
         stateDictionary,
         serviceContext,
         eventHubName,
         eventHubConnectionString,
         eventHubConsumerGroupName,
         handler,
         EventHubCommunicationListenerMode.SafeDistribute,
         string.Empty)
 {
 }
        public EventHubCommunicationListener(
            ITraceWriter TraceWriter,
            IReliableStateManager stateManager,
            IReliableDictionary <string, string> stateDictionary,
            ServiceInitializationParameters serviceParameters,
            string eventHubName,
            string eventHubConnectionString,
            string eventHubConsumerGroupName,
            IEventDataHandler handler,
            EventHubCommunicationListenerMode Mode,
            string eventHubPartitionId)
        {
            this.ListenerMode = Mode;
            if (this.ListenerMode == EventHubCommunicationListenerMode.Single && string.IsNullOrEmpty(eventHubPartitionId))
            {
                throw new InvalidOperationException("Event hub communication listener in single mode requires a partition id");
            }


            this.m_TraceWriter = TraceWriter;

            this.m_InitParams             = serviceParameters;
            this.EventHubName             = eventHubName;
            this.EventHubConnectionString = eventHubConnectionString;
            this.Handler = handler;
            this.EventHubConsumerGroupName = eventHubConsumerGroupName;
            this.StateManager    = stateManager;
            this.StateDictionary = stateDictionary;
            this.ListenerMode    = Mode;


            this.m_TraceWriter.TraceMessage(
                string.Format(
                    "Event Hub Listener created for {0} on {1} group:{2} mode:{3}",
                    this.EventHubName,
                    this.Namespace,
                    this.EventHubConsumerGroupName,
                    this.ListenerMode.ToString()));
        }
        public EventHubCommunicationListener(
          ITraceWriter TraceWriter,
          IReliableStateManager stateManager,
          IReliableDictionary<string, string> stateDictionary,
          ServiceInitializationParameters serviceParameters,
          string eventHubName,
          string eventHubConnectionString,
          string eventHubConsumerGroupName,
          IEventDataHandler handler,
          EventHubCommunicationListenerMode Mode,
          string eventHubPartitionId)
        {
            this.ListenerMode = Mode;
            if (this.ListenerMode == EventHubCommunicationListenerMode.Single && string.IsNullOrEmpty(eventHubPartitionId))
            {
                throw new InvalidOperationException("Event hub communication listener in single mode requires a partition id");
            }


            this.m_TraceWriter = TraceWriter;

            this.m_InitParams = serviceParameters;
            this.EventHubName = eventHubName;
            this.EventHubConnectionString = eventHubConnectionString;
            this.Handler = handler;
            this.EventHubConsumerGroupName = eventHubConsumerGroupName;
            this.StateManager = stateManager;
            this.StateDictionary = stateDictionary;
            this.ListenerMode = Mode;


            this.m_TraceWriter.TraceMessage(
                string.Format(
                    "Event Hub Listener created for {0} on {1} group:{2} mode:{3}",
                    this.EventHubName,
                    this.Namespace,
                    this.EventHubConsumerGroupName,
                    this.ListenerMode.ToString()));
        }
示例#8
0
 public EventDataReporter(ILogger <EventDataReporter> logger, IEventDataHandler dataHandler)
 {
     _logger      = logger;
     _dataHandler = dataHandler;
 }
示例#9
0
 public ManageApiController(Sys.IServiceProvider serviceProvider, IManageService manageService, ISchedulerService schedulerService, IEventDataHandler dataHandler) : base(serviceProvider)
 {
     _schedule      = schedulerService;
     _dataHandler   = dataHandler;
     _manageService = manageService;
 }