protected override Action <TSourceMessage> FindReceiver(IInlet <TSourceMessage> inletSendingMessage) { var receiver = Outlet.FindReceiver(); if (receiver == null) { return(null); } return(m => receiver(Map(m))); }
protected override Action <TMessage> FindReceiver(IInlet <TMessage> inletSendingMessage) { if (storedMessages.Any()) { if (HasSpareCapacity()) { return(message => storedMessages.Enqueue(message)); } } else { var receiver = Outlet.FindReceiver(); if (receiver != null) { return(receiver); } if (HasSpareCapacity()) { return(message => storedMessages.Enqueue(message)); } } return(null); }
protected override Action <TMessage> FindReceiver(IInlet <TMessage> inletSendingMessage) { return(Outlet.FindReceiver()); }