Skip to content

zuluecho9/opentelemetry-exporter-go

 
 

Repository files navigation

New Relic Go OpenTelemetry exporter GoDoc

The "github.com/newrelic/opentelemetry-exporter-go/newrelic" package provides an exporter for sending OpenTelemetry data to New Relic. Currently, only traces are supported.

Example use:

import (
	"log"
	"os"

	"github.com/newrelic/opentelemetry-exporter-go/newrelic"
	"go.opentelemetry.io/otel/api/global"
	"go.opentelemetry.io/otel/sdk/trace"
)

func initTracer() {
	exporter, err := newrelic.NewExporter("My Service", os.Getenv("NEW_RELIC_API_KEY"))
	if err != nil {
		log.Fatal(err)
	}
	tp, err := trace.NewProvider(trace.WithSyncer(exporter))
	if err != nil {
		log.Fatal(err)
	}
	global.SetTraceProvider(tp)
}

Disclaimer

This exporter is built with the alpha release of OpenTelemetry Go client. Due to the rapid development of OpenTelemetry, this exporter does not guarantee compatibility with future releases of the OpenTelemetry APIs. Additionally, this exporter may introduce changes that are not backwards compatible without a major version increment. We will strive to ensure backwards compatibility when a stable version of the OpenTelemetry Go client is released.

Find and use your data

For tips on how to find and query your data in New Relic, see Find trace/span data.

For general querying information, see:

Licensing

The New Relic Go OpenTelemetry exporter is licensed under the Apache 2.0 License. The New Relic Go OpenTelemetry exporter also uses source code from third party libraries. Full details on which libraries are used and the terms under which they are licensed can be found in the third party notices document.

Contributing

Full details are available in our CONTRIBUTING.md file. We'd love to get your contributions to improve the Go OpenTelemetry exporter! Keep in mind when you submit your pull request, you'll need to sign the CLA via the click-through using CLA-Assistant. You only have to sign the CLA one time per project. To execute our corporate CLA, which is required if your contribution is on behalf of a company, or if you have any questions, please drop us an email at [email protected].

Limitations

The New Relic Telemetry APIs are rate limited. Please reference the documentation for New Relic Metrics API and New Relic Trace API requirements and limits on the specifics of the rate limits.

About

New Relic's Golang OpenTelemetry Exporter

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 100.0%