/// <summary> /// The reply. /// </summary> /// <param name="message"> /// The message. /// </param> /// <param name="replyTo"> /// The reply to. /// </param> /// <param name="correlationId"> /// The correlation id. /// </param> public void Reply(IMessage message, RabbitRoute replyTo, string correlationId) { Func <IBasicProperties, IDictionary <string, object> > propsVisitor = p => { p.CorrelationId = correlationId; return(message.Headers); }; this.Publish(new RabbitRoute(replyTo.Exchange, replyTo.RoutingKey), message, propsVisitor); }
/// <summary> /// The reply. /// </summary> /// <param name="message"> /// The message. /// </param> /// <param name="replyTo"> /// The reply to. /// </param> /// <param name="correlationId"> /// The correlation id. /// </param> public void Reply(IMessage message, RabbitRoute replyTo, string correlationId) { Action <IBasicProperties> propsVisitor = props => { props.CorrelationId = correlationId; }; this.Publish(new RabbitRoute(replyTo.Exchange, replyTo.RoutingKey), message, propsVisitor); }
/// <summary> /// The reply. /// </summary> /// <param name="message"> /// The message. /// </param> /// <param name="replyTo"> /// The reply to. /// </param> /// <param name="correlationId"> /// The correlation id. /// </param> public void Reply(IMessage message, RabbitRoute replyTo, string correlationId) { Action<IBasicProperties> propsVisitor = props => { props.CorrelationId = correlationId; }; this.Publish(new RabbitRoute(replyTo.Exchange, replyTo.RoutingKey), message, propsVisitor); }