Package kalix.javasdk
Interface DeferredCall<I,O>
- Type Parameters:
I
- The type of message the call acceptsO
- The type of message the call returns
public interface DeferredCall<I,O>
Represents a call to another component, performed as a forward, a side effect, or a
request-reply.
Not for user extension.
-
Method Summary
Modifier and TypeMethodDescriptionexecute()
Execute this call right away and get the async result back for composition.message()
The message to pass to the call when the call is invoked.metadata()
withMetadata
(Metadata metadata)
-
Method Details
-
message
I message()The message to pass to the call when the call is invoked. -
metadata
Metadata metadata()- Returns:
- The metadata to pass with the message when the call is invoked.
-
execute
CompletionStage<O> execute()Execute this call right away and get the async result back for composition. Can be used to create an async reply in anAction
witheffects().asyncReply
andeffects().asyncEffect
-
withMetadata
- Returns:
- DeferredCall with updated metadata
-