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 ¶ added in v0.54.0
WithAgentInstallPath sets the agent installation path
func WithAuthToken ¶ added in v0.55.0
WithAuthToken sets the auth token.
func WithAuthTokenPath ¶ added in v0.55.0
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 ¶ added in v0.55.0
func WithProcessAgent() Option
WithProcessAgent enables waiting for the Process Agent, using the default API port.
func WithProcessAgentOnPort ¶ added in v0.55.0
WithProcessAgentOnPort enables waiting for the Process Agent, using the given port for the API.
func WithSecurityAgent ¶ added in v0.55.0
func WithSecurityAgent() Option
WithSecurityAgent enables waiting for the Security Agent, using the default API port.
func WithSecurityAgentOnPort ¶ added in v0.55.0
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 ¶ added in v0.55.0
func WithTraceAgent() Option
WithTraceAgent enables waiting for the Trace Agent, using the default API port.
func WithTraceAgentOnPort ¶ added in v0.55.0
WithTraceAgentOnPort enables waiting for the Trace Agent, using the given port for the API.
func WithWaitForDuration ¶ added in v0.55.0
WithWaitForDuration sets the duration to wait for the agents to be ready.
func WithWaitForTick ¶ added in v0.55.0
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: