futureSource creates an Akka Streams source from a Future that produces another source. It is useful when an external asynchronous call, such as a gRPC request, returns a stream only after the Future completes. section 16.3.4
Wrapping a gRPC streaming call
Source.futureSource { val responseStream: Source[Location, NotUsed] = client.follow() Future(responseStream) }
Combined with RestartSource.withBackoff, futureSource lets a stream retry a failed service call. Backoff increases between attempts, while restart limits and jitter control retry duration and synchronization. section 16.3.4
