public CommandListener(IBusProvider busProvider, ICommandCallbackRegistry commandCallbackRegistry)
        {
            _busProvider      = busProvider;
            _callbackRegistry = commandCallbackRegistry;

            _busProvider.EnsureConnection();
        }
Exemplo n.º 2
0
        public EventListener(IBusProvider busProvider, IEventCallbackRegistry callbackRegistry)
        {
            _busProvider      = busProvider;
            _callbackRegistry = callbackRegistry;

            _busProvider.EnsureConnection();
        }
Exemplo n.º 3
0
        public CommandPublisher(IBusProvider busProvider)
        {
            EnsureArg.IsNotNull(busProvider, nameof(busProvider));

            _busProvider      = busProvider;
            _commandCallbacks = new ConcurrentDictionary <Guid, Action <string, bool> >();

            _busProvider.EnsureConnection();

            _callbackQueue = $"CommandQueue-{Guid.NewGuid().ToString()}";
            _busProvider.BasicConsume(_callbackQueue, HandleCommandCallback);
        }
Exemplo n.º 4
0
        public EventPublisher(IBusProvider busProvider)
        {
            _busProvider = busProvider;

            _busProvider.EnsureConnection();
        }