Zipkin and Google Cloud Monitoring Integration

Powerful performance with an easy integration, powered by Telegraf, the open source data connector built by InfluxData.

info

This is not the recommended configuration for real-time query at scale. For query and compression optimization, high-speed ingest, and high availability, you may want to consider Zipkin and InfluxDB.

5B+

Telegraf downloads

#1

Time series database
Source: DB Engines

1B+

Downloads of InfluxDB

2,800+

Contributors

Table of Contents

Powerful Performance, Limitless Scale

Collect, organize, and act on massive volumes of high-velocity data. Any data is more valuable when you think of it as time series data. with InfluxDB, the #1 time series platform built to scale with Telegraf.

See Ways to Get Started

Input and output integration overview

The Zipkin Input Plugin allows for the collection of tracing information and timing data from microservices. This capability is essential for diagnosing latency troubles within complex service-oriented environments.

The Stackdriver plugin allows users to send metrics directly to a specified project in Google Cloud Monitoring, facilitating robust monitoring capabilities across their cloud resources.

Integration details

Zipkin

This plugin implements the Zipkin HTTP server to gather trace and timing data necessary for troubleshooting latency issues in microservice architectures. Zipkin is a distributed tracing system that helps gather timing data across various microservices, allowing teams to visualize the flow of requests and identify bottlenecks in performance. The plugin offers support for input traces in JSON or thrift formats based on the specified Content-Type. Additionally, it utilizes span metadata to track the timing of requests, enhancing the observability of applications that adhere to the OpenTracing standard. As an experimental feature, its configuration and schema may evolve over time to better align with user requirements and advancements in distributed tracing methodologies.

Google Cloud Monitoring

This plugin writes metrics to a project in Google Cloud Monitoring, which used to be known as Stackdriver. Authentication is a prerequisite and can be achieved via service accounts or user credentials. The plugin is designed to group metrics by a namespace variable and metric key, facilitating organized data management. However, users are encouraged to use the official naming format for enhanced query efficiency. The plugin supports additional configurations for managing metric representation and allows tags to be treated as resource labels. Notably, it imposes certain restrictions on the data it can accept, such as not allowing string values or points that are out of chronological order.

Configuration

Zipkin

[[inputs.zipkin]]
  ## URL path for span data
  # path = "/api/v1/spans"

  ## Port on which Telegraf listens
  # port = 9411

  ## Maximum duration before timing out read of the request
  # read_timeout = "10s"
  ## Maximum duration before timing out write of the response
  # write_timeout = "10s"

Google Cloud Monitoring

[[outputs.stackdriver]]
  ## GCP Project
  project = "project-id"

  ## Quota Project
  ## Specifies the Google Cloud project that should be billed for metric ingestion.
  ## If omitted, the quota is charged to the service account’s default project.
  ## This is useful when sending metrics to multiple projects using a single service account.
  ## The caller must have the `serviceusage.services.use` permission on the specified project.
  # quota_project = ""

  ## The namespace for the metric descriptor
  ## This is optional and users are encouraged to set the namespace as a
  ## resource label instead. If omitted it is not included in the metric name.
  namespace = "telegraf"

  ## Metric Type Prefix
  ## The DNS name used with the metric type as a prefix.
  # metric_type_prefix = "custom.googleapis.com"

  ## Metric Name Format
  ## Specifies the layout of the metric name, choose from:
  ##  * path: 'metric_type_prefix_namespace_name_key'
  ##  * official: 'metric_type_prefix/namespace_name_key/kind'
  # metric_name_format = "path"

  ## Metric Data Type
  ## By default, telegraf will use whatever type the metric comes in as.
  ## However, for some use cases, forcing int64, may be preferred for values:
  ##   * source: use whatever was passed in
  ##   * double: preferred datatype to allow queries by PromQL.
  # metric_data_type = "source"

  ## Tags as resource labels
  ## Tags defined in this option, when they exist, are added as a resource
  ## label and not included as a metric label. The values from tags override
  ## the values defined under the resource_labels config options.
  # tags_as_resource_label = []

  ## Custom resource type
  # resource_type = "generic_node"

  ## Override metric type by metric name
  ## Metric names matching the values here, globbing supported, will have the
  ## metric type set to the corresponding type.
  # metric_counter = []
  # metric_gauge = []
  # metric_histogram = []

  ## NOTE: Due to the way TOML is parsed, tables must be at the END of the
  ## plugin definition, otherwise additional config options are read as part of
  ## the table

  ## Additional resource labels
  # [outputs.stackdriver.resource_labels]
  #   node_id = "$HOSTNAME"
  #   namespace = "myapp"
  #   location = "eu-north0"

Input and output integration examples

Zipkin

  1. Latency Monitoring in Microservices: Use the Zipkin Input Plugin to capture and analyze tracing data from a microservices architecture. By visualizing the request flow and pinpointing latency sources, development teams can optimize service interactions, improve response times, and ensure a smoother user experience across services.

  2. Performance Optimization in Essential Services: Integrate the plugin within critical services to monitor not only the response times but also track specific annotations that could highlight performance issues. The ability to gather span data can help prioritize areas needing performance enhancements, leading to targeted improvements.

  3. Dynamic Service Dependency Mapping: With the collected trace data, automatically map service dependencies and visualize them in dashboards. This helps teams understand how different services interact and the impact of failures or slowdowns, ultimately leading to better architectural decisions and faster resolutions of issues.

  4. Anomaly Detection in Service Latency: Combine Zipkin data with machine learning models to detect unusual patterns in service latencies and request processing times. By automatically identifying anomalies, operations teams can respond proactively to emerging issues before they escalate into critical failures.

Google Cloud Monitoring

  1. Multi-Project Metric Aggregation: Use this plugin to send aggregated metrics from various applications across different projects into a single Google Cloud Monitoring project. This use case helps centralize metrics for teams managing multiple applications, providing a unified view for performance monitoring and enhancing decision-making. By configuring different quota projects for billing, organizations can ensure proper cost management while benefiting from a consolidated monitoring strategy.

  2. Anomaly Detection Setup: Integrate the plugin with a machine learning-based analytics tool that identifies anomalies in the collected metrics. Using the historical data provided by the plugin, the tool can learn normal baseline behavior and promptly alert the operations team when unusual patterns arise, enabling proactive troubleshooting and minimizing service disruptions.

  3. Dynamic Resource Labeling: Implement dynamic tagging by utilizing the tags_as_resource_label option to adaptively attach resource labels based on runtime conditions. This setup allows metrics to provide context-sensitive information, such as varying environmental parameters or operational states, enhancing the granularity of monitoring and reporting without changing the fundamental metric structure.

  4. Custom Metric Visualization Dashboards: Leverage the data collected by the Google Cloud Monitoring output plugin to feed a custom metrics visualization dashboard using a third-party framework. By visualizing metrics in real-time, teams can achieve better situational awareness, notably by correlating different metrics, improving operational decision-making, and streamlining performance management workflows.

Feedback

Thank you for being part of our community! If you have any general feedback or found any bugs on these pages, we welcome and encourage your input. Please submit your feedback in the InfluxDB community Slack.

Powerful Performance, Limitless Scale

Collect, organize, and act on massive volumes of high-velocity data. Any data is more valuable when you think of it as time series data. with InfluxDB, the #1 time series platform built to scale with Telegraf.

See Ways to Get Started

Related Integrations

HTTP and InfluxDB Integration

The HTTP plugin collects metrics from one or more HTTP(S) endpoints. It supports various authentication methods and configuration options for data formats.

View Integration

Kafka and InfluxDB Integration

This plugin reads messages from Kafka and allows the creation of metrics based on those messages. It supports various configurations including different Kafka settings and message processing options.

View Integration

Kinesis and InfluxDB Integration

The Kinesis plugin allows for reading metrics from AWS Kinesis streams. It supports multiple input data formats and offers checkpointing features with DynamoDB for reliable message processing.

View Integration