opentelemetry-collector/processor/resourceprocessor
Akash Suresh caadbbc476
Decentralize component documentation (#1089)
* Split out processor READMEs

* Split out exporter READMEs

* Split out extension READMEs

* Split out receiver READMEs

* Add new line at end of READMEs
2020-06-05 11:33:32 -07:00
..
testdata Add Resource Processor (#423) 2019-11-26 11:50:54 -05:00
README.md Decentralize component documentation (#1089) 2020-06-05 11:33:32 -07:00
config.go Remove year from copyright (#964) 2020-05-26 12:44:22 -04:00
config_test.go Remove year from copyright (#964) 2020-05-26 12:44:22 -04:00
doc.go Remove year from copyright (#964) 2020-05-26 12:44:22 -04:00
factory.go Remove year from copyright (#964) 2020-05-26 12:44:22 -04:00
factory_test.go Remove year from copyright (#964) 2020-05-26 12:44:22 -04:00
resource_processor.go Remove year from copyright (#964) 2020-05-26 12:44:22 -04:00
resource_processor_test.go Remove year from copyright (#964) 2020-05-26 12:44:22 -04:00

README.md

Resource Processor

Supported pipeline types: metrics, traces

The resource processor can be used to override a resource. Please refer to config.go for the config spec.

The following configuration options are required:

  • type: Resource type to be applied. If specified, this value overrides the original resource type. Otherwise, the original resource type is kept.
  • labels: Map of key/value pairs that should be added to the resource.

Examples:

processors:
  resource:
    type: "host"
    labels: {
      "cloud.zone": "zone-1",
      "k8s.cluster.name": "k8s-cluster",
      "host.name": "k8s-node",
    }

Refer to config.yaml for detailed examples on using the processor.