Class AgentscopeAdminAutoConfiguration

java.lang.Object
io.agentscope.spring.boot.admin.AgentscopeAdminAutoConfiguration

@AutoConfiguration @ConditionalOnClass(io.agentscope.core.agent.Agent.class) @ConditionalOnProperty(prefix="agentscope.admin", name="enabled", havingValue="true") @EnableConfigurationProperties(AdminProperties.class) @Import(AdminOpenApiConfiguration.class) public class AgentscopeAdminAutoConfiguration extends Object
Spring Boot auto-configuration for the AgentScope admin/ops starter.

Activation rules:

  • agentscope.admin.enabled=true — master switch (defaults to false so this starter never accidentally exposes admin endpoints just by being on the classpath).
  • Agent on the classpath — guards against running without agentscope-core.

Web controllers register only when a Servlet web application is detected (ConditionalOnWebApplication). Actuator endpoints register only when the Actuator Endpoint type is on the classpath.

  • Constructor Details

    • AgentscopeAdminAutoConfiguration

      public AgentscopeAdminAutoConfiguration()
  • Method Details

    • agentscopeAgentRegistry

      @Bean @ConditionalOnMissingBean public AgentRegistry agentscopeAgentRegistry(org.springframework.beans.factory.ObjectProvider<Map<String,io.agentscope.core.agent.Agent>> agentBeans)
      Default AgentRegistry. Auto-seeded from any singleton Agent beans found in the context — applications using prototype-scoped agents (the AgentScope default) must call AgentRegistry.register(Agent) themselves when they create an agent.
    • agentscopeAdminCommandRegistry

      @Bean @ConditionalOnMissingBean public AdminCommandRegistry agentscopeAdminCommandRegistry()
    • agentscopeBuiltinCommandRegistrar

      @Bean public BuiltinCommandRegistrar agentscopeBuiltinCommandRegistrar(AdminCommandRegistry registry, AdminProperties properties)
    • agentscopeAdminAuditLogger

      @Bean @ConditionalOnMissingBean public AdminAuditLogger agentscopeAdminAuditLogger(AdminProperties properties, org.springframework.context.ApplicationEventPublisher publisher)
    • agentscopeSummarizationStrategy

      @Bean @ConditionalOnMissingBean public SummarizationStrategy agentscopeSummarizationStrategy()
    • agentscopeSnapshotStore

      @Bean @ConditionalOnMissingBean public SnapshotStore agentscopeSnapshotStore()
    • agentscopeSessionOperations

      @Bean @ConditionalOnMissingBean public SessionOperations agentscopeSessionOperations(AgentRegistry registry, SummarizationStrategy summarizer, AdminProperties properties, SnapshotStore snapshots)
    • agentscopeAgentInventory

      @Bean @ConditionalOnMissingBean public AgentInventory agentscopeAgentInventory(AgentRegistry registry, org.springframework.beans.factory.ObjectProvider<Map<String,io.agentscope.core.tool.Toolkit>> toolkits, org.springframework.beans.factory.ObjectProvider<Map<String,io.agentscope.core.model.Model>> models)
    • agentscopeSubagentInventory

      @Bean @ConditionalOnMissingBean public SubagentInventory agentscopeSubagentInventory(org.springframework.beans.factory.ObjectProvider<Map<String,io.agentscope.harness.agent.middleware.SubagentEntry>> entryBeans, org.springframework.beans.factory.ObjectProvider<Map<String,io.agentscope.harness.agent.subagent.SubagentDeclaration>> declarationBeans)
    • agentscopeSubagentTaskOperations

      @Bean @ConditionalOnMissingBean public SubagentTaskOperations agentscopeSubagentTaskOperations(org.springframework.beans.factory.ObjectProvider<io.agentscope.harness.agent.subagent.task.TaskRepository> repoProvider)
    • agentscopeMetricsRecorder

      @Bean @ConditionalOnMissingBean public MetricsRecorder agentscopeMetricsRecorder()
    • agentscopeMetricsHookLifecycle

      @Bean @ConditionalOnMissingBean public AgentscopeAdminAutoConfiguration.MetricsHookLifecycle agentscopeMetricsHookLifecycle(MetricsRecorder recorder)
      Registers a MetricsHook into AgentBase.addSystemHook(Hook) at startup so every subsequently constructed agent contributes token-usage counters.

      The hook is unregistered on context close, so reloading the starter does not double-count.