Class Runner.Builder
java.lang.Object
com.google.adk.runner.Runner.Builder
- Enclosing class:
Runner
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionartifactService(BaseArtifactService artifactService) build()instantSource(@Nullable InstantSource instantSource) Sets theInstantSourcethat supplies every timestamp this runner generates: event timestamps, and thelastUpdateTimeof sessions created by the default in-memory session service, which is created on the firstbuild().memoryService(BaseMemoryService memoryService) scheduler(@Nullable io.reactivex.rxjava3.core.Scheduler scheduler) Sets theSchedulerfor the work ADK hands off to worker threads in this runner's invocations: the sub-agents of aParallelAgent, tool calls inRunConfig.ToolExecutionMode.PARALLEL_SUBSCRIBEmode, and the hop that starts the live send loop.sessionService(BaseSessionService sessionService) uuidProvider(@Nullable UuidProvider uuidProvider) Sets theUuidProviderthat supplies every identifier this runner generates: event, invocation, and client function-call ids, and the ids of sessions created by the default in-memory session service, which is created on the firstbuild().
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
app
-
agent
-
appName
-
artifactService
-
sessionService
-
memoryService
-
plugins
-
plugins
-
scheduler
@CanIgnoreReturnValue public Runner.Builder scheduler(@Nullable io.reactivex.rxjava3.core.Scheduler scheduler) Sets theSchedulerfor the work ADK hands off to worker threads in this runner's invocations: the sub-agents of aParallelAgent, tool calls inRunConfig.ToolExecutionMode.PARALLEL_SUBSCRIBEmode, and the hop that starts the live send loop. The runs that anAgentToolnests inherit it. An agent-levelParallelAgent.Builder#schedulerorLlmAgent.Builder#executortakes precedence.null(the default) selectsSchedulers.io().Only these hand-offs are affected; work that completes asynchronously elsewhere (model clients, session services, MCP, plugins) stays on its own threads.
Schedulers.trampoline()runs the hand-offs inline, so sub-agents and tools are subscribed sequentially, but anything they start asynchronously can still overlap. -
instantSource
Sets theInstantSourcethat supplies every timestamp this runner generates: event timestamps, and thelastUpdateTimeof sessions created by the default in-memory session service, which is created on the firstbuild().null(the default) selectsInstantSource.system(). -
uuidProvider
Sets theUuidProviderthat supplies every identifier this runner generates: event, invocation, and client function-call ids, and the ids of sessions created by the default in-memory session service, which is created on the firstbuild().null(the default) selectsUuidProvider.SYSTEM. -
build
-