Fix snippet example in stream-rate doc #21006
Fix #section-buffer by replacing .withAttributes by .addAttributes to avoid overwriting the .async option. * Update StreamBuffersRateDocTest.java Fix #section-buffer by replacing .withAttributes by .addAttributes to avoid overwriting the .async option.
This commit is contained in:
parent
210c11e85e
commit
c8dfa2458d
2 changed files with 2 additions and 2 deletions
|
|
@ -30,7 +30,7 @@ class StreamBuffersRateSpec extends AkkaSpec {
|
|||
|
||||
//#section-buffer
|
||||
val section = Flow[Int].map(_ * 2).async
|
||||
.withAttributes(Attributes.inputBuffer(initial = 1, max = 1)) // the buffer size of this map is 1
|
||||
.addAttributes(Attributes.inputBuffer(initial = 1, max = 1)) // the buffer size of this map is 1
|
||||
val flow = section.via(Flow[Int].map(_ / 2)).async // the buffer size of this map is the default
|
||||
//#section-buffer
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue