Skip to content

Unix Domain Sockets for MCP transport #415

@scottslewis

Description

@scottslewis

It would be very helpful to use unix domain sockets (supported in Java 17) for localhost MCP Client <-> MCP Server communication.

Currently, stdio transport is used for testing, debugging, and deployment of MCP servers.

unix domain sockets would provide both better performance (avoid tcp/ip stack), and would free up the use of stdin and stdout in the stdio transport (helpful for testing and debugging).

I can provide the implementation of this if there is interest. I suspect that it will be desirable to create AbstractLocalhostServer/ClientTransport classes, which could then be used as a super class for the current StdioServerTransport and StdioClientTransport...without breaking existing code that uses these...and these abstract super classes could make the implementation of the unix domain socket classes easier as well, since both the stdio client/server transports and the unix socket client/server transport implementations will likely use InputStreams and OutputStreams.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions