public void Send(IConfigureSendContext context) { var envelope = new CloudQueueMessageEnvelope(). SetFrom(context.From). SetTo(context.To). SetMessageId(context.MessageId). SetRelatesToMessageId(context.RelatesToMessageId). SetCorrelationId(context.CorrelationId). SetContentType(Resolver.GetContentType(context.Message)). SetContent(SerializeMessage(context)). SetTime(DateTimeOffset.UtcNow); InnerSender.Send(envelope); }
void Publish(IConfigureSendContext context, string address) { Sender.Send( context. SetFrom(Configuration.SenderConfiguration.FromQueue). SetTo(address). SetCorrelationId(SerialGuid.NewGuid())); }