=str #25045 adding Java/Scala interop to SourceQueue and SinkQueue

adding MiMa filters

preserving binary compat
This commit is contained in:
Stefano Bonetti 2018-05-14 12:11:20 +01:00 committed by Patrik Nordwall
parent 4399e499c4
commit 1ad174cf8c
11 changed files with 205 additions and 95 deletions

View file

@ -176,5 +176,15 @@ class QueueSinkSpec extends StreamSpec {
Source.single(()).runWith(Sink.queue().withAttributes(inputBuffer(0, 0)))
}
}
"materialize to a queue which is seamlessly translatable between scala and java DSL" in assertAllStagesStopped {
val expected = List(Some(1), Some(2), Some(3), None)
val javadslQueue = Source(expected.flatten).runWith(Sink.queue()).asJava
val scaladslQueue = akka.stream.javadsl.SinkQueueWithCancel.asScala(javadslQueue)
expected.foreach { v
scaladslQueue.pull().pipeTo(testActor)
expectMsg(v)
}
}
}
}