Esempio n. 1
0
 /// <summary>
 /// Creates a <see cref="Sink{TIn,TMat}"/> to publish messages in batches
 /// to a SQS queue using a <paramref name="client"/>.
 /// See also: https://getakka.net/articles/streams/builtinstages.html#groupedwithin
 /// </summary>
 public static Sink <IEnumerable <SendMessageRequest>, Task> BatchedMessageSink(IAmazonSQS client, string queueUrl, SqsPublishBatchSettings settings = null) =>
 SqsPublishFlow.Batch(client, queueUrl, settings)
 .ToMaterialized(Sink.Ignore <IReadOnlyList <SqsPublishResultEntry> >(), Keep.Right);
Esempio n. 2
0
 /// <summary>
 /// Creates a <see cref="Sink{TIn,TMat}"/> that groups messages and publishes
 /// them in batches to a SQS queue using a <paramref name="client"/>.
 /// See also: https://getakka.net/articles/streams/builtinstages.html#groupedwithin
 /// </summary>
 public static Sink <SendMessageRequest, Task> GroupedMessageSink(IAmazonSQS client, string queueUrl, SqsPublishGroupedSettings settings = null) =>
 SqsPublishFlow.Grouped(client, queueUrl, settings)
 .ToMaterialized(Sink.Ignore <SqsPublishResultEntry>(), Keep.Right);