refactor: introduce Pool interface, move agent_pool to agent module

This commit is contained in:
yusing
2025-04-13 06:11:06 +08:00
parent 12a63a66f6
commit 90214ff752
13 changed files with 132 additions and 91 deletions

View File

@@ -83,7 +83,7 @@ func FromDocker(c *container.Summary, dockerHost string) (res *Container) {
if agent.IsDockerHostAgent(dockerHost) {
var ok bool
res.Agent, ok = config.GetInstance().GetAgent(dockerHost)
res.Agent, ok = agent.Agents.Get(dockerHost)
if !ok {
logging.Error().Msgf("agent %q not found", dockerHost)
}