Skip to content

fix(mcp): use the cluster endpoint for Pulsar admin and Kafka Connect, not the StreamNative proxy - #108

Open
ciiiii wants to merge 1 commit into
mainfrom
fix/sa-direct-cluster-endpoint
Open

ciiiii wants to merge 1 commit into
mainfrom
fix/sa-direct-cluster-endpoint

Conversation

@ciiiii

@ciiiii ciiiii commented Nov 13, 2026 •

Copy link
Copy Markdown
Member

Summary

The MCP server now sends Pulsar admin and Kafka Connect requests to the cluster endpoint directly, not through the proxy.

Changes

  • getBasePath(proxyLocation, org, clusterID) → getWebServiceURL(dnsName): https://<cluster service endpoint>.
  • Kafka Connect URL: <proxy>/admin/kafkaconnect/ → https://<cluster service endpoint>/admin/kafkaconnect/. This matches what snctl uses for direct connections.
  • The cluster's service endpoint was already required (the context setup fails without one), and the Pulsar binary protocol and Schema Registry URLs already used it.
  • --proxy-location and proxy-location config stay for compatibility, but the Pulsar context no longer uses them.

Testing

  • go build ./..., go vet ./pkg/mcp/, go test ./pkg/mcp/ pass. New TestClusterEndpointURLs.
  • The same direct-endpoint behavior was verified with snctl and a service account key against the test environment (streamnative/cloud-cli#270).

Release note

snctl mcp embeds this module (cloud-cli pins v0.1.10), so snctl needs a dependency bump after this is released.

@ciiiii
ciiiii requested a review from a team as a code owner November 13, 2026 11:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants