I’m looking at AKKA’s Java Futures API, and I see a lot of ways to handle multiple futures of the same type, but I don’t see anything that pops out at me for handling futures of different types. I’m guessing that I’m making this more complicated than it is.
Anyways let’s say we have two different Actors: actorA and actorB. They are based on different classes and they each return a different Future. However, actorB is dependent on a Future from actorA. Is the following logic, how to best handle this case?
Future<A> a = actorA.sendRequestReplyFuture(...);
Future<B> b = actorB.sendRequestReplyFuture(a);
How about if we have a list of actorAs and actorBs?
WARNING, just written from memory, might not compile OOTB: