• /
  • EnglishEspañol日本語한국어Português
  • ログイン今すぐ開始

Go agent compatibility and requirements

If you don't have one already, create a New Relic account. It's free, forever. Before you install New Relic for Go, ensure your system meets these requirements.

Golang versions

New Relic supports Golang 1.19 or higher.

Operating environments

The agent supports Linux, macOS, and Windows. You can also use the Go agent in a Google App Engine (GAE) flexible environment.

Integrations

The following integration packages extend the base newrelic package to support other frameworks and libraries. If frameworks and databases don't have an integration package, you can still instrument them using the newrelic package primitives. For more information about instrumenting your database using these primitives, see the Go agent's datastore segments documentation on GitHub.

The following integration packages must be imported along with the newrelic package, as shown in the nrgin example on GitHub.

Project

Integration package

Purpose

aws/aws-sdk-go

v3/integrations/nrawssdk-v1

Instrument outbound calls made using Go AWS SDK

aws/aws-sdk-go-v2

v3/integrations/nrawssdk-v2

Instrument outbound calls made using Go AWS SDK v2

labstack/echo

v3/integrations/nrecho-v3

Instrument inbound requests through version 3 of the Echo framework

labstack/echo

v3/integrations/nrecho-v4

Instrument inbound requests through version 4 of the Echo framework

gin-gonic/gin

v3/integrations/nrgin

Instrument inbound requests through the Gin framework

gorilla/mux

v3/integrations/nrgorilla

Instrument inbound requests through the Gorilla framework

julienschmidt/httprouter

v3/integrations/nrhttprouter

Instrument inbound requests through the HttpRouter framework

aws/aws-lambda-go

v3/integrations/nrlambda

Instrument AWS Lambda applications

sirupsen/logrus

v3/integrations/nrlogrus

Send agent log messages to Logrus

rs/zerolog

v3/integrations/logcontext-v2/zerologWriter

Capture and send logs in context data from logs written in zerolog

sirupsen/logrus

v3/integrations/logcontext-v2/nrlogrus

Capture and send logs in context data from logs written in logrus

log

v3/integrations/logcontext-v2/logWriter

Capture and send logs in context data from logs written in the standard library log package

mgutz/logxi

v3/integrations/nrlogxi

Send agent log messages to Logxi

uber-go/zap

v3/integrations/nrzap

Send agent log messages to Zap

pkg/errors

v3/integrations/nrpkgerrors

Wrap pkg/errors errors to improve stack traces and error class information

openzipkin/b3-propagation

v3/integrations/nrb3

Add B3 headers to outgoing requests

database/sql

Use a supported database driver or built-in instrumentation

Instrument database calls with SQL

jmoiron/sqlx

Use a supported database driver or builtin instrumentation

Instrument database calls with SQLx

go-sql-driver/mysql

v3/integrations/nrmysql

Instrument database calls to MySQL

lib/pq

v3/integrations/nrpq

Instrument database calls to Postgres using the database/sql library and pq

jackc/pgx

v3/integrations/nrpgx

Instrument database calls to Postgres using the database/sql library and jackc/pgx

jackc/pgx/v5

v3/integrations/nrpgx5

Instrument database calls to Postgres using the jackc/pgx/v5 library for direct Postgres calls without database/sql.

snowflakedb/gosnowflake

v3/integrations/nrsnowflake

Instrument database calls to Snowflake

go-redis/redis

v3/integrations/nrredis-v7

Instrument calls to Redis Version 7

go-redis/redis

v3/integrations/nrredis-v8

Instrument calls to Redis Version 8

mattn/go-sqlite3

v3/integrations/nrsqlite3

Instrument database calls to SQLite

mongodb/mongo-go-driver

v3/integrations/nrmongo

Instrument MongoDB calls

google.golang.org/grpc

v3/integrations/nrgrpc

Instrument gRPC servers and clients

micro/go-micro

v3/integrations/nrmicro

Instrument servers, clients, publishers, and subscribers through the Micro framework

nats-io/nats.go

v3/integrations/nrnats

Instrument publishers and subscribers using the NATS client

nats-io/stan.go

v3/integrations/nrstan

Instrument publishers and subscribers using the NATS streaming client

graphql-go/graphql

v3/integrations/nrgraphqlgo

Instrument inbound requests using graphql-go/graphql

graph-gophers/graphql-go

v3/integrations/nrgraphgophers

Instrument inbound requests using graph-gophers/graphql-go

Database and instance-level performance

New Relic collects instance details for a variety of databases and database drivers. The ability to view specific instances and the types of database information in depends on your agent version.

The New Relic Go agent version 1.4 or higher supports instance details for all database drivers.

Connect the agent to other features

The Go agent integrates with other features to give you observability across your entire stack:

Product

Capability

AI monitoring

If you have version 3.31.0 or higher of Go agent, you can collect AI data from certain AI libraries and frameworks:

Infrastructure monitoring

When you install the infrastructure and APM agents on the same host, they automatically detect one another. You can then view a list of hosts in the APM UI, and filter your hosts by APM app in our infrastructure UI. For more information, see APM data in infrastructure monitoring.

New Relic dashboards

The Go agent sends default events and attributes to New Relic for NRQL queries. You can also record custom events for advanced analysis.

Synthetic monitoring

Synthetic transaction traces connect requests from synthetic monitors to the underlying APM transaction.

Browser monitoring

The Go agent has an API for returning the browser agent's JavaScript. After using this API method on each request, you can view browser data in the APM Summary page and quickly switch between the APM and browser data for a particular app.

Copyright © 2024 New Relic株式会社。

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.