Class StdioMcpTransport.Builder
java.lang.Object
dev.langchain4j.mcp.client.transport.stdio.StdioMcpTransport.Builder
- Enclosing class:
StdioMcpTransport
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()environment(Map<String, String> environment) executorService(ExecutorService executorService) Sets theExecutorServiceto use for background I/O operations.logEvents(boolean logEvents) logger(org.slf4j.Logger logger)
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
command
-
environment
-
logEvents
-
executorService
Sets theExecutorServiceto use for background I/O operations. If not provided, will useDefaultExecutorProvider.getDefaultExecutorService().Frameworks like Quarkus should provide their managed executor here. If an executor is provided, it will not be shut down when the transport is closed.
- Parameters:
executorService- the executor service to use- Returns:
this
-
logger
- Parameters:
logger- an alternateLoggerto be used instead of the default one provided by Langchain4J for traffic logging.- Returns:
this.
-
build
-