Skip to content

Commit

Permalink
Merge pull request #888 from nr-swilloughby/Release_3.31.0
Browse files Browse the repository at this point in the history
Release 3.31.0
  • Loading branch information
nr-swilloughby authored Mar 27, 2024
2 parents 487703c + 27d840e commit cb651c4
Show file tree
Hide file tree
Showing 80 changed files with 3,662 additions and 68 deletions.
1 change: 1 addition & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ jobs:
- dirs: v3/integrations/nrmongo
- dirs: v3/integrations/nrgraphqlgo,v3/integrations/nrgraphqlgo/example
- dirs: v3/integrations/nrmssql
- dirs: v3/integrations/nropenai
steps:
- name: Checkout Code
uses: actions/checkout@v2
Expand Down
52 changes: 47 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,45 @@
## 3.31.0
### Added
* Integration packages to instrument AI model invocations (see below).
* New package nrawsbedrock v1.0.0 introduced to instrument calls to Amazon Bedrock Runtime Client API `InvokeModel` and `InvokeModelWithResponseStream` calls. Also provides a simple one-step method which invokes stream invocations and harvests the response stream data for you.
* New package nropenai v1.0.0 introduced to instrument calls to OpenAI using `NRCreateChatCompletion`, `NRCreateChatCompletionStream`, and `NRCreateEmbedding` calls.
* Dockerfile in the `examples/server` sample app which facilitates the easy creation of a containerized ready-to-run sample app for situations where that makes testing easier.

### Fixed
* `.Ignore` was not ignoring transaction. Fixes [Issue #845](https://github.com/newrelic/go-agent/issues/845).
* Added nil error check in wrap function. Fixes [Issue #862](https://github.com/newrelic/go-agent/issues/862).
* `WrapBackgroundCore` background logger was not sending logs to New Relic. Fixes [Issue #859](https://github.com/newrelic/go-agent/issues/859).
* Corrected pgx5 integration example which caused a race condition. Thanks to @WillAbides! Fixes [Issue #855](https://github.com/newrelic/go-agent/issues/855).
* Updated third-party library versions due to reported security or other supportability issues:
* `github.com/jackc/pgx/v5` to 5.5.4 in `nrpgx5` integration
* `google.gopang.org/protobuf` to 1.33.0 in `nrmicro` and `nrgrpc` integrations
* `github.com/jackc/pgx/v4` to 4.18.2 in `nrpgx` integration

### AI Monitoring Configuration
New configuration options are available specific to AI monitoring. These settings include:
* `AIMonitoring.Enabled`, configured via `ConfigAIMonitoring.Enabled(`_bool_`)` [default `false`]
* `AIMonitoring.Streaming.Enabled`, configured via `ConfigAIMonitoringStreamingEnabled(`_bool_`)` [default `true`]
* `AIMonitoring.Content.Enabled`, configured via `ConfigAIMonitoringContentEnabled(`_bool_`)` [default `true`]

### AI Monitoring Public API Methods
Two new AI monitoring related public API methods have been added, as methods of the `newrelic.Application` value returned by `newrelic.NewApplication`:
* [app.RecordLLMFeedbackEvent](https://pkg.go.dev/github.com/newrelic/go-agent/v3/newrelic#Application.RecordLLMFeedbackEvent)
* [app.SetLLMTokenCountCallback](https://pkg.go.dev/github.com/newrelic/go-agent/v3/newrelic#Application.SetLLMTokenCountCallback)

### AI Monitoring
New Relic AI monitoring is the industry’s first APM solution that provides end-to-end visibility for AI Large Language Model (LLM) applications. It enables end-to-end visibility into the key components of an AI LLM application. With AI monitoring, users can monitor, alert, and debug AI-powered applications for reliability, latency, performance, security and cost. AI monitoring also enables AI/LLM specific insights (metrics, events, logs and traces) which can easily integrate to build advanced guardrails for enterprise security, privacy and compliance.

AI monitoring offers custom-built insights and tracing for the complete lifecycle of an LLM’s prompts and responses, from raw user input to repaired/polished responses. AI monitoring provides built-in integrations with popular LLMs and components of the AI development stack. This release provides instrumentation for [OpenAI](https://pkg.go.dev/github.com/newrelic/go-agent/v3/integrations/nropenai)
and [Bedrock](https://pkg.go.dev/github.com/newrelic/go-agent/v3/integrations/nrawsbedrock).

When AI monitoring is enabled with `ConfigAIMonitoringEnabled(true)`, the agent will now capture AI LLM related data. This data will be visible under a new APM tab called AI Responses. See our [AI Monitoring documentation](https://docs.newrelic.com/docs/ai-monitoring/intro-to-ai-monitoring/) for more details.

### Support statement
We use the latest version of the Go language. At minimum, you should be using no version of Go older than what is supported by the Go team themselves.
See the [Go agent EOL Policy](https://docs.newrelic.com/docs/apm/agents/go-agent/get-started/go-agent-eol-policy/) for details about supported versions of the Go agent and third-party components.



## 3.30.0
### Added
* Updated the depencency on nrsecurityagent to 1.0.0.
Expand All @@ -8,7 +50,7 @@

### Support statement
We use the latest version of the Go language. At minimum, you should be using no version of Go older than what is supported by the Go team themselves.
See the [Go agent EOL Policy](/docs/apm/agents/go-agent/get-started/go-agent-eol-policy) for details about supported versions of the Go agent and third-party components.
See the [Go agent EOL Policy](https://docs.newrelic.com/docs/apm/agents/go-agent/get-started/go-agent-eol-policy/) for details about supported versions of the Go agent and third-party components.

## 3.29.1
### Added
Expand All @@ -19,7 +61,7 @@ See the [Go agent EOL Policy](/docs/apm/agents/go-agent/get-started/go-agent-eol

### Support statement
We use the latest version of the Go language. At minimum, you should be using no version of Go older than what is supported by the Go team themselves.
See the [Go agent EOL Policy](/docs/apm/agents/go-agent/get-started/go-agent-eol-policy) for details about supported versions of the Go agent and third-party components.
See the [Go agent EOL Policy](https://docs.newrelic.com/docs/apm/agents/go-agent/get-started/go-agent-eol-policy/) for details about supported versions of the Go agent and third-party components.

## 3.29.0
### Added
Expand All @@ -31,7 +73,7 @@ See the [Go agent EOL Policy](/docs/apm/agents/go-agent/get-started/go-agent-eol

### Support statement
We use the latest version of the Go language. At minimum, you should be using no version of Go older than what is supported by the Go team themselves.
See the [Go agent EOL Policy](/docs/apm/agents/go-agent/get-started/go-agent-eol-policy) for details about supported versions of the Go agent and third-party components.
See the [Go agent EOL Policy](https://docs.newrelic.com/docs/apm/agents/go-agent/get-started/go-agent-eol-policy/) for details about supported versions of the Go agent and third-party components.

## 3.28.1
### Added
Expand All @@ -43,7 +85,7 @@ Fixed an issue where `nil` `Request.Body` could be set to non-`nil` `request.Bod
More Secure URL Redaction
### Support statement
We use the latest version of the Go language. At minimum, you should be using no version of Go older than what is supported by the Go team themselves.
See the [Go agent EOL Policy](/docs/apm/agents/go-agent/get-started/go-agent-eol-policy) for details about supported versions of the Go agent and third-party components.
See the [Go agent EOL Policy](https://docs.newrelic.com/docs/apm/agents/go-agent/get-started/go-agent-eol-policy/) for details about supported versions of the Go agent and third-party components.

## 3.28.0
### Fixed
Expand All @@ -57,7 +99,7 @@ See the [Go agent EOL Policy](/docs/apm/agents/go-agent/get-started/go-agent-eol

We use the latest version of the Go language. At minimum, you should be using no version of Go older than what is supported by the Go team themselves.

See the [Go agent EOL Policy](/docs/apm/agents/go-agent/get-started/go-agent-eol-policy) for details about supported versions of the Go agent and third-party components.
See the [Go agent EOL Policy](https://docs.newrelic.com/docs/apm/agents/go-agent/get-started/go-agent-eol-policy/) for details about supported versions of the Go agent and third-party components.


## 3.27.0
Expand Down
51 changes: 51 additions & 0 deletions v3/examples/server/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# If it is more convenient for you to run an instrumented test server in a Docker
# container, you can use this Dockerfile to build an image for that purpose.
#
# To build this image, have this Dockerfile in the current directory and run:
# docker build -t go-agent-test .
#
# To run a test, run the following:
# docker run -e NEW_RELIC_LICENSE_KEY="YOUR_KEY_HERE" -p 127.0.0.1:8000:8000 go-agent-test
# then drive traffic to it on localhost port 8000
#
# This running application will write debugging logs showing all interaction
# with the collector on its standard output.
#
# The following HTTP endpoints can be accessed on port 8000 to invoke different
# instrumented server features:
# /
# /add_attribute
# /add_span_attribute
# /async
# /background
# /background_log
# /browser
# /custom_event
# /custommetric
# /external
# /ignore
# /log
# /message
# /mysql
# /notice_error
# /notice_error_with_attributes
# /notice_expected_error
# /roundtripper
# /segments
# /set_name
# /version
#
FROM golang:1.22
MAINTAINER Steve Willoughby <[email protected]>
WORKDIR /go
RUN git clone https://github.com/newrelic/go-agent
WORKDIR /go/go-agent/v3
RUN go mod tidy
WORKDIR /go/go-agent/v3/examples/server
RUN go mod tidy
RUN go build
EXPOSE 8000
CMD ["/go/go-agent/v3/examples/server/server"]
#
# END
#
1 change: 1 addition & 0 deletions v3/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ go 1.19

require (
github.com/golang/protobuf v1.5.3
golang.org/x/exp v0.0.0-20240318143956-a85f2c67cd81
google.golang.org/grpc v1.56.3
)

Expand Down
2 changes: 1 addition & 1 deletion v3/integrations/logcontext-v2/logWriter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/newrelic/go-agent/v3/integrations/logcontext-v2/logWriter
go 1.19

require (
github.com/newrelic/go-agent/v3 v3.30.0
github.com/newrelic/go-agent/v3 v3.31.0
github.com/newrelic/go-agent/v3/integrations/logcontext-v2/nrwriter v1.0.0
)

Expand Down
2 changes: 1 addition & 1 deletion v3/integrations/logcontext-v2/nrlogrus/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/newrelic/go-agent/v3/integrations/logcontext-v2/nrlogrus
go 1.19

require (
github.com/newrelic/go-agent/v3 v3.30.0
github.com/newrelic/go-agent/v3 v3.31.0
github.com/sirupsen/logrus v1.8.1
)

Expand Down
3 changes: 2 additions & 1 deletion v3/integrations/logcontext-v2/nrslog/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ module github.com/newrelic/go-agent/v3/integrations/logcontext-v2/nrslog

go 1.19

require github.com/newrelic/go-agent/v3 v3.30.0
require github.com/newrelic/go-agent/v3 v3.31.0


replace github.com/newrelic/go-agent/v3 => ../../..
2 changes: 1 addition & 1 deletion v3/integrations/logcontext-v2/nrwriter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ module github.com/newrelic/go-agent/v3/integrations/logcontext-v2/nrwriter

go 1.19

require github.com/newrelic/go-agent/v3 v3.30.0
require github.com/newrelic/go-agent/v3 v3.31.0


replace github.com/newrelic/go-agent/v3 => ../../..
2 changes: 1 addition & 1 deletion v3/integrations/logcontext-v2/nrzap/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/newrelic/go-agent/v3/integrations/logcontext-v2/nrzap
go 1.19

require (
github.com/newrelic/go-agent/v3 v3.30.0
github.com/newrelic/go-agent/v3 v3.31.0
go.uber.org/zap v1.24.0
)

Expand Down
2 changes: 1 addition & 1 deletion v3/integrations/logcontext-v2/nrzerolog/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/newrelic/go-agent/v3/integrations/logcontext-v2/nrzerolog
go 1.19

require (
github.com/newrelic/go-agent/v3 v3.30.0
github.com/newrelic/go-agent/v3 v3.31.0
github.com/rs/zerolog v1.26.1
)

Expand Down
2 changes: 1 addition & 1 deletion v3/integrations/logcontext-v2/zerologWriter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/newrelic/go-agent/v3/integrations/logcontext-v2/zerologWriter
go 1.19

require (
github.com/newrelic/go-agent/v3 v3.30.0
github.com/newrelic/go-agent/v3 v3.31.0
github.com/newrelic/go-agent/v3/integrations/logcontext-v2/nrwriter v1.0.0
github.com/rs/zerolog v1.27.0
)
Expand Down
2 changes: 1 addition & 1 deletion v3/integrations/logcontext/nrlogrusplugin/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module github.com/newrelic/go-agent/v3/integrations/logcontext/nrlogrusplugin
go 1.19

require (
github.com/newrelic/go-agent/v3 v3.30.0
github.com/newrelic/go-agent/v3 v3.31.0
// v1.4.0 is required for for the log.WithContext.
github.com/sirupsen/logrus v1.4.0
)
Expand Down
2 changes: 1 addition & 1 deletion v3/integrations/nramqp/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/newrelic/go-agent/v3/integrations/nramqp
go 1.19

require (
github.com/newrelic/go-agent/v3 v3.30.0
github.com/newrelic/go-agent/v3 v3.31.0
github.com/rabbitmq/amqp091-go v1.9.0
)
replace github.com/newrelic/go-agent/v3 => ../..
Loading

0 comments on commit cb651c4

Please sign in to comment.