feat(#116): synchronous group command dispatch with multi-agent response collection
Add addGroupCommandWithReplies() to AgentRegistryService that sends commands to all LIVE agents in a group and returns CompletableFuture per agent for collecting replies. Update sendGroupCommand() and pushConfigToAgents() to wait with a shared 10-second deadline, returning CommandGroupResponse with per-agent status, timeouts, and overall success. Config update endpoint now returns ConfigUpdateResponse wrapping both the saved config and push result. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
package com.cameleer3.server.app.dto;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public record CommandGroupResponse(
|
||||
boolean success,
|
||||
int total,
|
||||
int responded,
|
||||
List<AgentResponse> responses,
|
||||
List<String> timedOut
|
||||
) {
|
||||
public record AgentResponse(String agentId, String status, String message) {}
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
package com.cameleer3.server.app.dto;
|
||||
|
||||
import com.cameleer3.common.model.ApplicationConfig;
|
||||
|
||||
public record ConfigUpdateResponse(
|
||||
ApplicationConfig config,
|
||||
CommandGroupResponse pushResult
|
||||
) {}
|
||||
Reference in New Issue
Block a user