• /
  • EnglishEspañol日本語한국어Português
  • 로그인지금 시작하기

Code-level metrics

Code-level metrics allow developers using the New Relic CodeStream extension to see APM data displayed contextually in their IDE, alongside individual methods in the code. This allows developers to be more proactive about addressing performance issues as they write and review code.

Getting started

First, install the New Relic CodeStream extension into your supported IDE of choice and log in.

중요

Code-level metrics are available for Java agent version 7.10.0 or higher, and enabled by default for version 7.11.0 and higher. See Java agent configuration: Config file for instructions on how to enabled or disable it.

Agent attributes

The Java agent reports and attaches the following attributes to spans produced by your application:

Name

Description

Example

code.function

The name of the instrumented function (Java method).

retrieveData

code.namespace

The namespace (fully qualified class name) in which code.function is defined

com.example.MyService

중요

Spans created using the API method NewRelic.getAgent().getTransaction().startSegment() will not contain these attributes. To create a span that contain these attributes annotate a method with @Trace or use XML instrumentation.

Copyright © 2024 New Relic Inc.

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