コード例 #1
0
        static async Task <DedupeResult> InnerSendWithDedupe(IMessageSession session, object message, Guid messageId, SendOptions options, string?context)
        {
            var pipelineState = new DedupePipelineState
            {
                Context = context
            };

            DedupePipelineState.Set(options, pipelineState);
            options.SetMessageId(messageId.ToString());

            await session.Send(message, options);

            return(new DedupeResult
                   (
                       dedupeOutcome: pipelineState.DedupeOutcome,
                       context: pipelineState.Context
                   ));
        }