Documentation
¶
Overview ¶
Package agentclientparams implements function parameters for [e2e.Agent]
Index ¶
- type Option
- func WithAgentInstallPath(path string) Option
- func WithAuthToken(authToken string) Option
- func WithAuthTokenPath(path string) Option
- func WithProcessAgent() Option
- func WithProcessAgentOnPort(port int) Option
- func WithSecurityAgent() Option
- func WithSecurityAgentOnPort(port int) Option
- func WithSkipWaitForAgentReady() Option
- func WithTraceAgent() Option
- func WithTraceAgentOnPort(port int) Option
- func WithWaitForDuration(d time.Duration) Option
- func WithWaitForTick(d time.Duration) Option
- type Params
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Option ¶
type Option func(*Params)
Option alias to a functional option changing a given Params instance
func WithAgentInstallPath ¶
WithAgentInstallPath sets the agent installation path
func WithAuthTokenPath ¶
WithAuthTokenPath sets the path to the auth token file. The file is read from the remote host. This is not used if the auth token is provided directly with WithAuthToken.
func WithProcessAgent ¶
func WithProcessAgent() Option
WithProcessAgent enables waiting for the Process Agent, using the default API port.
func WithProcessAgentOnPort ¶
WithProcessAgentOnPort enables waiting for the Process Agent, using the given port for the API.
func WithSecurityAgent ¶
func WithSecurityAgent() Option
WithSecurityAgent enables waiting for the Security Agent, using the default API port.
func WithSecurityAgentOnPort ¶
WithSecurityAgentOnPort enables waiting for the Security Agent, using the given port for the API.
func WithSkipWaitForAgentReady ¶
func WithSkipWaitForAgentReady() Option
WithSkipWaitForAgentReady skips waiting for agent readiness after setting up the agent client Use it to testagent configuration that are expected to have an unhealthy agent
func WithTraceAgent ¶
func WithTraceAgent() Option
WithTraceAgent enables waiting for the Trace Agent, using the default API port.
func WithTraceAgentOnPort ¶
WithTraceAgentOnPort enables waiting for the Trace Agent, using the given port for the API.
func WithWaitForDuration ¶
WithWaitForDuration sets the duration to wait for the agents to be ready.
func WithWaitForTick ¶
WithWaitForTick sets the duration between checks for the agents to be ready.
type Params ¶
type Params struct {
ShouldWaitForReady bool
AgentInstallPath string
AuthToken string
AuthTokenPath string
ProcessAgentPort int
TraceAgentPort int
SecurityAgentPort int
WaitForDuration time.Duration
WaitForTick time.Duration
}
Params defines the parameters for the Agent client. The Params configuration uses the Functional options pattern.
The available options are: