Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
dashboards
docs
img
10-kong.conf
LICENSE
README.md
meta.yaml

README.md

Kong

Metadata associated with the Kong plugin for collectd can be found here.

The relevant code for the integration can be found here and for its Kong plugin dependency here.

DESCRIPTION

The SignalFx Kong collectd plugin provides users with the ability to gather and report their service traffic metrics with collectd, in tandem with kong-plugin-signalfx.

This plugin emits metrics for configurable request/response lifecycle groups including:

  • Counters for response counts
  • Counters for cumulative response and request sizes
  • Counters for cumulative request, upstream, and Kong latencies

These request/response lifecycle groups can be optionally partitioned by tunable levels of granularity by:

  • API or Service Name/ID
  • Route ID
  • Request HTTP Method
  • Response HTTP Status Code

In addition to these groups, system-wide connection stats can be provided, including:

  • A counter for total fielded requests
  • Gauges for active connections and their various states
  • A gauge for database connectivity

FEATURES

Built-in dashboards
  • Kong Servers Overview: High-level Kong performance for all reporting servers

  • Kong Server Overview: High-level Kong performance for an individual server

  • API Objects: API object activity metrics

  • Service Objects: Service object activity metrics

  • Route Objects: Route object activity metrics

REQUIREMENTS AND DEPENDENCIES

This plugin requires:

Software Version
collectd 4.9+
Python plugin for collectd (included with SignalFx collectd agent)
Python 2.6+
Kong 0.11.2+
Configured kong-plugin-signalfx 0.0.1+

INSTALLATION

Both the SignalFx Smart Agent and collectd agent report metrics made available by the kong-plugin-signalfx metric endpoint. Please download and install this Lua module on all Kong servers using its instructions.

  • If you are using the SignalFx Smart Agent, collectd-kong is already included. Please see the monitor documentation for configuration instructions.

  • If you are using the SignalFx collectd agent follow the steps below.

  1. Download and install the collectd-kong Python module.

  2. Download SignalFx’s sample configuration file to /etc/collectd/managed_config.

  3. Modify the configuration file as described in Configuration below.

  4. Restart collectd.

CONFIGURATION

Using the example configuration file 10-kong.conf as a guide, provide values for the configuration options listed below that make sense for your environment.

Configuration option Definition Example value
URL The URL for the /signalfx kong-plugin-signalfx metric endpoint "https://my_kong_server:8443/signalfx"
AuthHeader The name and value of a header to be passed with GETs to the URL "Authorization" "Basic YWRtaW46cGFzc3dvcmQ="
VerifyCerts Whether to verify the ssl certificates for HTTPS requests to the URL true
CABundle Path to a CA_BUNDLE file or directory with certificates of trusted CAs when VerifyCerts is true "/path/ca_bundle/"
ClientCert Client side certificate to use for HTTPS requests to the URL "/path/client.cert"
ClientCertKey Separate client side certificate key if not included with cert file "/path/client.key"
Metric The short name and report boolean for (un)desired metrics to emit. See Metrics. "request_latency" false
ExtraDimension The name and value of any custom dimension to be sent with each datapoint "my_dimension" "my_dimension_value"
ReportAPIIDs The UUID assigned to each API object upon creation false
ReportAPINames The optional, user-created name assigned to API objects (recommended) true
ReportServiceIDs The UUID assigned to each Service object upon creation false
ReportServiceNames The optional, user-created name assigned to Service objects (recommended) true
ReportRouteIDs The UUID assigned to each Route object upon creation (recommended) true
ReportHTTPMethods The HTTP method of each request made to the Kong proxy true
ReportStatusCodeGroups The HTTP status code group (e.g. 4xx) for each proxy server fielded request (recommended) true
ReportStatusCodes The HTTP status code for each fielded request false
APIIDs The pattern(s) of API IDs to add as dimensions for applicable datapoints "my-api-id"
APIIDsBlacklist The pattern(s) of API IDs to not report as dimensions for applicable datapoints "my-unwanted-id" "my-other-unwanted-id"
APINames The pattern(s) of API Names to add as dimensions for applicable datapoints "MyAPI"
APINamesBlacklist The pattern(s) of API Names to not report as dimensions for applicable datapoints "MyUnwantedAPI" "MyOtherUnwantedAPI"
ServiceIDs The pattern(s) of Service IDs to add as dimensions for applicable datapoints "my-service-id"
ServiceIDsBlacklist The pattern(s) of Service IDs to not report as dimensions for applicable datapoints "my-unwanted-id" "my-other-unwanted-id"
ServiceNames The pattern(s) of Service Names to add as dimensions for applicable datapoints "MyService"
ServiceNamesBlacklist The pattern(s) of Service Names to not report as dimensions for applicable datapoints "MyUnwantedService" "MyOtherUnwantedService"
RouteIDs The pattern(s) of Route IDs to add as dimensions for applicable datapoints "my-route-id"
RouteIDsBlacklist The pattern(s) of Route IDs to not report as dimensions for applicable datapoints "my-unwanted-id" "my-other-unwanted-id"
HTTPMethods The pattern(s) of HTTP methods to add as dimensions for applicable datapoints "GET" "POST" "DELETE"
HTTPMethodsBlacklist The pattern(s) of HTTP methods to not report as dimensions for applicable datapoints "HEAD" "OPTIONS"
StatusCodes The pattern(s) of status codes to add as dimensions for applicable datapoints "2*"
StatusCodesBlacklist The pattern(s) of status codes to not report as dimensions for applicable datapoints "1*" "3*"
Interval How often, in seconds, Kong metrics are obtained. 10
Verbose Whether to emit lower level metric collection and processing statements to the LogFile plugin true

USAGE

Sample of built-in dashboard in SignalFx:

METRICS

For documentation of the metrics emitted by this plugin, click here.

LICENSE

This integration is released under the Apache 2.0 license. See LICENSE for more details.