package
1.2.0
Repository: https://github.com/couchbase/tools-common.git
Documentation: pkg.go.dev

# README

genmetrics - Generate metrics metadata & boilerplate

Since 7.6.0 Couchbase services have been expected to describe what metrics they expose in a JSON file, which is then used to generate documentation. This tool will generate both the boilerplate and the JSON file from another JSON file. This input JSON file is the same as the metadata file, but with the additional histogram_buckets field.

Usage

$ genmetrics <input-file> <code-output-file> <json-output-file>
  • input-file: the path to a JSON file containing the metrics info
  • code-output-file: the path to the file where the generated Go code will be written
  • json-output-file: the path to the file where the metrics_metadata.json file will be written

# Constants

No description provided by the author
No description provided by the author
No description provided by the author
StabilityCommitted means the metric will retain semantics across server versions and only be removed once it has been deprecated for some time.
StabilityInternal means the metric will not be shown in our user-facing documentation.
StabilityVolatile means the metric can be changed at any time.

# Structs

MetricInfo contains information about metrics that is used to generate code for them and their documentation.

# Type aliases

MetricsInfo is a map of metric names to their metadata.
MetricType denotes the type of a metric we expose.
Stability is how stable a metric is.