Class A2aSkillRegistry

java.lang.Object
com.xebialabs.xlrelease.a2a.server.A2aSkillRegistry

public class A2aSkillRegistry extends Object
The live set of skills the A2A server serves: the host's built-in skills (seeded at construction, never removable) plus plugin-contributed ones that come and go with their bundles. The card and endpoint servlets read it per request, so a contribution shows up on the Agent Card the moment its bundle starts — the A2A counterpart of the MCP server's runtime tool list.

Skill ids are the namespace: a contribution whose id collides with an existing skill — built-in or contributed — is refused and logged, never silently overriding. First one wins; plugins do not get to shadow request-deployment-approval.

  • Constructor Details

  • Method Details

    • all

      public List<A2aServerSkill> all()
      A stable snapshot for one request (card build or skill selection).
    • byId

      public A2aServerSkill byId(String skillId)
      The skill with this id, or null.
    • register

      public boolean register(A2aServerSkill skill)
      Registers a contributed skill; refused (with a log line naming both parties) when the id is taken.
      Returns:
      whether the skill was registered — the caller tracks only accepted ids for removal
    • unregister

      public void unregister(String skillId)
      Removes a contributed skill by id; built-in ids are never removed.