AgentTool SPI + module restructure: agent-plugin tree, agent -> agent-runtime, connector-api under connector-plugin (follow-up to #5408) - #5409
Merged
Conversation
- Annotate AgentTool with @EventMeshSPI (new AGENT_TOOL extension type); custom tools now register via META-INF/eventmesh/<AgentTool-FQCN> service files exactly like storage/connector plugins - ToolRegistry.registerSpi(name) resolves implementations through EventMeshExtensionFactory (singleton semantics, classpath + plugin-jar loaders) - AgentApplication: -Dagent.tools.spi=<name,...> enables SPI tools alongside connector-backed tools - start-agent.sh: jars under plugin/agent/ join the agent classpath (same convention as plugin/connector/ in the connector runtime) - Tests: AgentToolSpiTest drives the real factory + a test service file (echo-test) through registerSpi; unknown-name rejection path covered - Docs: agent-tools.md SPI section + config-table entry; agent.properties key doc
…nector-plugin, agent -> agent-runtime, new agent-plugin tree - Move eventmesh-connector-api -> eventmesh-connector-plugin/eventmesh-connector-api (SPI jar lives with its plugin family, like storage/protocol) - Rename eventmesh-agent -> eventmesh-agent-runtime (it is a process runtime, matching eventmesh-connector-runtime) - New eventmesh-agent-plugin/ tree: umbrella + eventmesh-agent-plugin-http-fetch (first in-tree AgentTool plugin: fetch a URL, return truncated body; pluginType=agentTool, pluginName=http-fetch, META-INF service file included) - dist-agent now installs pluginType==agentTool modules into dist-agent/plugin/agent/<name>/ (same convention as dist-connector/plugin/connector) - References updated: settings.gradle, root build.gradle (findProject paths), all 23 connector plugin build files, architecture-guard, runtime test dep, docs
…r-api path (double-quote form)
…s resolve via agent-runtime)
Contributor
Author
|
Docs pass added (
|
qqeasonchen
added a commit
that referenced
this pull request
Sep 22, 2026
…ter #5409 was merged) (#5410) These changes were pushed to the #5409 branch minutes after it was squash-merged and missed the merge; resubmitting on top of develop:/n/n- README.md / README.zh-CN.md: LLM streaming agent runtime feature bullet, Agent tools & event triggers capability row, docs-list entries - Connector Runtime and A2A / Agent Gateway promoted to Beta (the Testcontainers E2E gate #5340 closed 2026-09) - docs/feature/a2a.md: Related capabilities section pairing A2A with the streaming agent runtime - docs/index.md: A2A entry cross-links agent-tools
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #5408 (discussion in #5407): turn
AgentToolinto a real repo-standard SPI extension point plus the module restructure to host agent plugins in-tree.Commit 1 — AgentTool SPI
@EventMeshSPIonAgentTool+ a newAGENT_TOOLentry inEventMeshExtensionType. Implementations register via aMETA-INF/eventmesh/org.apache.eventmesh.agent.tool.AgentToolservice file (mytool=com.example.MyTool) — the same convention as every other EventMesh plugin.ToolRegistry.registerSpi(name)— resolves an implementation by SPI name throughEventMeshExtensionFactory(singleton semantics, classpath + plugin-jar loaders).-Dagent.tools.spi=<name,...>inAgentApplication— enables SPI tools alongside the connector-backed tools from Agent extension points: LlmClient/ConversationMemory SPI, connector-backed agent tools, event triggers #5408.plugin/agent/classpath convention — the agent launcher puts every jar underplugin/agent/on the classpath (mirrorsplugin/connector/in the connector runtime).Commit 2 — module restructure (rename detection = pure
R100moves)eventmesh-connector-api→eventmesh-connector-plugin/eventmesh-connector-api— the connector SPI jar lives under its plugin family, like storage/protocol.eventmesh-agent→eventmesh-agent-runtime— it is a process runtime, matchingeventmesh-connector-runtime.eventmesh-agent-plugin/tree — umbrella +eventmesh-agent-plugin-http-fetch(first in-tree AgentTool plugin: fetch a URL, return the truncated body;pluginType=agentTool,pluginName=http-fetch, service file included). New in-tree tools need zero wiring:dist-agentinstalls everypluginType==agentToolmodule intodist-agent/plugin/agent/<name>/.settings.gradle, rootbuild.gradle(findProjectpaths + the new plugin install block), all 23 connector pluginbuild.gradlefiles, architecture-guard, runtime test dep, docs (agent-tools.md,client-java.md).User-facing workflows after this PR
Tests
AgentToolSpiTest.registerSpiResolvesThroughTheFactory— resolvesecho-testthrough the realEventMeshExtensionFactoryusing a test service file +EchoTestTool, invokes it end-to-endAgentToolSpiTest.registerSpiRejectsUnknownName— unknown SPI name throwsIllegalArgumentExceptionHttpFetchToolcompiles + checkstyle cleanR100, zero content diff) — no semantic change to moved codeNotes
eventmesh-agent-runtimegains an explicit compile dep oneventmesh-spi(the factory module); already transitively present via the SDK.