Documentation ¶
Overview ¶
Server-side for handling agent functions
Index ¶
- Variables
- type Agents
- func (a Agents) GetAgents(ctx context.Context) (map[string][]string, error)
- func (a Agents) GetAgentsForGroup(ctx context.Context, agentGroup string) ([]string, error)
- func (a Agents) ListAutoScaleControlPoints(ctx context.Context) ([]transport.Result[*cmdv1.ListAutoScaleControlPointsAgentResponse], error)
- func (a Agents) ListDiscoveryEntities(ctx context.Context, agentGroup string) ([]transport.Result[*cmdv1.ListDiscoveryEntitiesAgentResponse], error)
- func (a Agents) ListDiscoveryEntity(ctx context.Context, req *cmdv1.ListDiscoveryEntityRequest) (*cmdv1.ListDiscoveryEntityAgentResponse, error)
- func (a Agents) ListFlowControlPoints(ctx context.Context) ([]transport.Result[*cmdv1.ListFlowControlPointsAgentResponse], error)
- func (a Agents) PreviewFlowLabels(ctx context.Context, agent string, req *previewv1.PreviewRequest) (*previewv1.PreviewFlowLabelsResponse, error)
- func (a Agents) PreviewHTTPRequests(ctx context.Context, agent string, req *previewv1.PreviewRequest) (*previewv1.PreviewHTTPRequestsResponse, error)
Constants ¶
This section is empty.
Variables ¶
var Module = fx.Provide(NewAgents)
Module is fx module for controlling Agents on controller side.
Functions ¶
This section is empty.
Types ¶
type Agents ¶
type Agents struct {
// contains filtered or unexported fields
}
Agents wraps rpc.Clients where clients are agents and provides wrapper
Agents wraps functions registered in agentfunctions, types should match.
func NewAgents ¶
func NewAgents(transport *transport.EtcdTransportClient, client *etcdclient.Client) Agents
NewAgents wraps Clients with Agent-specific function wrappers.
func (Agents) GetAgents ¶
GetAgents lists the agents registered on etcd under /peers/aperture-agent.
func (Agents) GetAgentsForGroup ¶
GetAgentsForGroup lists the agents under an agent-group registered on etcd under /peers/aperture-agent.
func (Agents) ListAutoScaleControlPoints ¶
func (a Agents) ListAutoScaleControlPoints(ctx context.Context) ([]transport.Result[*cmdv1.ListAutoScaleControlPointsAgentResponse], error)
ListAutoScaleControlPoints lists auto-scale control points of all agents.
func (Agents) ListDiscoveryEntities ¶
func (a Agents) ListDiscoveryEntities(ctx context.Context, agentGroup string) ([]transport.Result[*cmdv1.ListDiscoveryEntitiesAgentResponse], error)
ListDiscoveryEntities lists discovery entities.
func (Agents) ListDiscoveryEntity ¶
func (a Agents) ListDiscoveryEntity(ctx context.Context, req *cmdv1.ListDiscoveryEntityRequest) (*cmdv1.ListDiscoveryEntityAgentResponse, error)
ListDiscoveryEntity lists discovery entity by ip address or name.
func (Agents) ListFlowControlPoints ¶
func (a Agents) ListFlowControlPoints(ctx context.Context) ([]transport.Result[*cmdv1.ListFlowControlPointsAgentResponse], error)
ListFlowControlPoints lists control points of all agents.
Handled by agentfunctions.ControlPointsHandler.
func (Agents) PreviewFlowLabels ¶
func (a Agents) PreviewFlowLabels( ctx context.Context, agent string, req *previewv1.PreviewRequest, ) (*previewv1.PreviewFlowLabelsResponse, error)
PreviewFlowLabels previews flow labels on a given agent.
Handled by agentfunctions.PreviewHandler.
func (Agents) PreviewHTTPRequests ¶
func (a Agents) PreviewHTTPRequests( ctx context.Context, agent string, req *previewv1.PreviewRequest, ) (*previewv1.PreviewHTTPRequestsResponse, error)
PreviewHTTPRequests previews flow labels on a given agent.
Handled by agentfunctions.PreviewHandler.