pekko/akka-docs/src/main/paradox/stream/operators/Sink/queue.md

28 lines
670 B
Markdown
Raw Normal View History

# Sink.queue
Materialize a `SinkQueue` that can be pulled to trigger demand through the sink.
@ref[Sink operators](../index.md#sink-operators)
## Signature
2020-04-30 08:59:22 +02:00
@apidoc[Sink.queue](Sink$) { scala="#queue[T](maxConcurrentPulls:Int):akka.stream.scaladsl.Sink[T,akka.stream.scaladsl.SinkQueueWithCancel[T]]" java="#queue(int)" }
## Description
Materialize a `SinkQueue` that can be pulled to trigger demand through the sink. The queue contains
a buffer in case stream emitting elements faster than queue pulling them.
## Reactive Streams semantics
@@@div { .callout }
**cancels** when `SinkQueue.cancel` is called
**backpressures** when buffer has some space
@@@