Configurationedit

Configure the agent with AgentConfiguration in the agent’s start() function.

let config =  AgentConfiguration()
config.collectorHost = "192.168.0.1"
config.collectorPort = 8200
config.collectorTLS = true
Agent.start(with:config)

Configuration optionsedit

collectorHostedit

  • Type: String
  • Default: 127.0.0.1

The APM Server host.

collectorPortedit

  • Type: Int
  • Default: 8200

The APM Server port.

collectorTLSedit

  • Type: Bool
  • Default: false

Flags whether the APM Server is secured with TLS.