Converting akka scala futures to java futures

Back in akka land! I’m using the ask pattern to get results back from actors since I have a requirement to block and get a result (I can’t wait for an actor to push at a later date). Thats fine, but converting from scala futures to java completable futures is a pain. I also, (like mentioned in another post) want to make sure that my async responses capture and set the MDC for proper logging.

Share this:

Related

2 comments

Hey – this looks really cool and exactly what I’m after … my brain is too addled (And possibly not good enough in the first place) to follow the missing steps – ie what AkkaOnCompleteCallback and what .toScalaCallback() look like, any clues you can give me? Thanks!