예제 #1
0
        public Task NotifyDeactivationAsync()
        {
            var message = new DeactivateEventForwarding(typeof(TEvent));

            Console.WriteLine($"Sending 'DeactivateEventForwarding' for event type '{message.EventType.FullName}'.");

            return(_messageEndPoint.SendAsync(message));
        }
예제 #2
0
        public Task HandleAsync(DeactivateEventForwarding message)
        {
            if (message == null)
            {
                throw new ArgumentNullException(nameof(message));
            }

            Console.WriteLine($"Receiving 'DeactivateEventForwarding' for event type '{message.EventType.FullName}'.");

            _remoteEventDispatcher.NotifyForwardingInactive(message.EventType);

            return(Task.CompletedTask);
        }