paketo-buildpacks / nodejs

A Cloud Native Buildpack for Node.JS
Apache License 2.0
55 stars 21 forks source link

Upgrade Datadog Buildpack to Version 4.6.0 #828

Open hadirgax opened 6 months ago

hadirgax commented 6 months ago

Describe the Enhancement

I'm requesting an upgrade of the Datadog Buildpack from its current version 3.6.0 to the latest version 4.6.0. This upgrade will provide several benefits, including:

Possible Solution

To implement this change, the following steps can be taken:

  1. Update the Datadog Buildpack dependency in the buildpack.toml and package.toml files to version 4.6.0.
  2. Thoroughly test the updated buildpack to ensure compatibility and functionality with NodeJS applications.
  3. Update any relevant documentation to reflect the new buildpack version and its usage.

Motivation

The primary motivation for this request is to:

dmikusa commented 2 months ago

@hadirgax & @gitricko - Hi, thanks for reaching out here. I'm hoping to get a little bit of detail from you on your usage of the Datadog buildpack w/Node.js.

The way the Datadog, and our other APM buildpacks, work with Node.js is that they basically run an npm install of the agent libraries and then modify your app's main JS file to inject the agent code.

I'm hoping to get some feedback from you on this approach, and if you've considered installing the APM module directly and adding it to the source code of your project directly also (essentially the out-of-the-box approach for your APM tool of choice).

The approach that the buildpack takes currently has a number of drawbacks for Node.js integration:

Anyway, if you have a moment and can send some feedback on your use case for using this feature & the benefits you get from using it this way, it would be much appreciated.

tl;dr - I'm considering an RFC to deprecate adding the Node.js APM agents directly, but before that, I'd like to gather feedback from people using it.

Thanks!

mhdawson commented 2 weeks ago

@hadirgax, @gitricko , @qard, @bengl it would be good to get some contenxt/help.

I had to back out the update to the 5.x line of the DataDog package as it failed the existing tests.