newrelic 10.3.0 → 10.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/NEWS.md CHANGED
@@ -1,13 +1,43 @@
1
- ### v10.3.0 (2023-06-13)
2
-
3
- #### Features
4
-
5
- * Added Interactive Application Security Testing(IAST) mode of security agent when `config.security.agent.enabled` is true. ([#1664](https://github.com/newrelic/node-newrelic/pull/1664)) ([3e926e5](https://github.com/newrelic/node-newrelic/commit/3e926e59ab5feba4b2759d8a108c424b237b5eda))
6
-
7
- **NOTE**: The security agent IAST mode is in public preview and should only be used in non-production environments.
8
-
9
- * To enable the security agent set `config.security.agent.enabled` and `config.security.enabled` to true.
10
-
1
+ ### v10.3.2 (2023-06-26)
2
+
3
+ #### Bug Fixes
4
+
5
+ * **prisma:** check for query args in string property ([#1684](https://github.com/newrelic/node-newrelic/pull/1684)) ([8d9b176](https://github.com/newrelic/node-newrelic/commit/8d9b176e05424d34dd2eafe243a8cee7284efe64))
6
+
7
+ #### Security Improvements
8
+
9
+ * **deps:** Updated security agent to v0.1.3 ([#1696](https://github.com/newrelic/node-newrelic/pull/1696)) ([0f957bd](https://github.com/newrelic/node-newrelic/commit/0f957bd0e39a32614337b5ade33f07d9729f1897))
10
+
11
+ #### Miscellaneous Chores
12
+
13
+ * **test:** Added t.end() to trace unit test ([#1698](https://github.com/newrelic/node-newrelic/pull/1698)) ([254c9c0](https://github.com/newrelic/node-newrelic/commit/254c9c0e2aae73ed154a009d264aa262cb3799e3))
14
+ * **test:** convert error-trace-aggregator.test.js to tap-style ([#1690](https://github.com/newrelic/node-newrelic/pull/1690)) ([44b17ab](https://github.com/newrelic/node-newrelic/commit/44b17abf3c6295661736932e9c9dc5b5a42eb3e1))
15
+ * **test:** convert trace unit test to tap style ([#1692](https://github.com/newrelic/node-newrelic/pull/1692)) ([727c17f](https://github.com/newrelic/node-newrelic/commit/727c17f4163ff44b90be87f71e43ad6924874fe4))
16
+ * **test:** Fixed tap end/autoend calls in trace unit test ([#1700](https://github.com/newrelic/node-newrelic/pull/1700)) ([b4a4948](https://github.com/newrelic/node-newrelic/commit/b4a4948719af7c20c22b12150bb3070f6526c247))
17
+
18
+ ### v10.3.1 (2023-06-22)
19
+
20
+ #### Security
21
+
22
+ * **deps:** Updated semver to v7.5.2, also in native-metrics and test utils ([#1685](https://github.com/newrelic/node-newrelic/pull/1685)) ([e207a6b](https://github.com/newrelic/node-newrelic/commit/e207a6b3a5cdd3d927f212f73d66e9aad52c5910))
23
+
24
+ #### Miscellaneous Chores
25
+
26
+ * Added test for getRedisParams ([#1670](https://github.com/newrelic/node-newrelic/pull/1670)) ([e9f8556](https://github.com/newrelic/node-newrelic/commit/e9f8556750a88314f0faeb993364fe2d67adc231))
27
+ * temporarily limit prisma tests to non-breaking version ([#1680](https://github.com/newrelic/node-newrelic/pull/1680)) ([76d3ade](https://github.com/newrelic/node-newrelic/commit/76d3adea11b077a506aeeb6af49391620b0fb1a5))
28
+ * **testing:** convert query-test-aggregator tests to tap style ([#1676](https://github.com/newrelic/node-newrelic/pull/1676)) ([d2e45ad](https://github.com/newrelic/node-newrelic/commit/d2e45ada751e9ae9cdca8b617834230d7d91f7b2))
29
+ * **testing:** Converted error-event-aggregator.test.js to tap ([#1683](https://github.com/newrelic/node-newrelic/pull/1683)) ([9f1d66f](https://github.com/newrelic/node-newrelic/commit/9f1d66f9df88512f353f01d16c1e6c93173dc88f))
30
+
31
+ ### v10.3.0 (2023-06-13)
32
+
33
+ #### Features
34
+
35
+ * Added Interactive Application Security Testing(IAST) mode of security agent when `config.security.agent.enabled` is true. ([#1664](https://github.com/newrelic/node-newrelic/pull/1664)) ([3e926e5](https://github.com/newrelic/node-newrelic/commit/3e926e59ab5feba4b2759d8a108c424b237b5eda))
36
+
37
+ **NOTE**: The security agent IAST mode is in public preview and should only be used in non-production environments.
38
+
39
+ * To enable the security agent set `config.security.agent.enabled` and `config.security.enabled` to true.
40
+
11
41
  ### v10.2.0 (2023-06-06)
12
42
 
13
43
  #### Features
@@ -953,7 +953,7 @@ Apache License
953
953
 
954
954
  ### @newrelic/security-agent
955
955
 
956
- This product includes source derived from [@newrelic/security-agent](https://github.com/newrelic/csec-node-agent) ([v0.1.2](https://github.com/newrelic/csec-node-agent/tree/v0.1.2)), distributed under the [New Relic Pre-Release License](https://github.com/newrelic/csec-node-agent/blob/v0.1.2/LICENSE):
956
+ This product includes source derived from [@newrelic/security-agent](https://github.com/newrelic/csec-node-agent) ([v0.1.3](https://github.com/newrelic/csec-node-agent/tree/v0.1.3)), distributed under the [New Relic Pre-Release License](https://github.com/newrelic/csec-node-agent/blob/v0.1.3/LICENSE):
957
957
 
958
958
  ```
959
959
  ## New Relic Pre-Release Software Notice
@@ -1395,7 +1395,7 @@ IN THE SOFTWARE.
1395
1395
 
1396
1396
  ### semver
1397
1397
 
1398
- This product includes source derived from [semver](https://github.com/npm/node-semver) ([v5.7.1](https://github.com/npm/node-semver/tree/v5.7.1)), distributed under the [ISC License](https://github.com/npm/node-semver/blob/v5.7.1/LICENSE):
1398
+ This product includes source derived from [semver](https://github.com/npm/node-semver) ([v7.5.3](https://github.com/npm/node-semver/tree/v7.5.3)), distributed under the [ISC License](https://github.com/npm/node-semver/blob/v7.5.3/LICENSE):
1399
1399
 
1400
1400
  ```
1401
1401
  The ISC License
@@ -1884,7 +1884,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
1884
1884
 
1885
1885
  ### @newrelic/test-utilities
1886
1886
 
1887
- This product includes source derived from [@newrelic/test-utilities](https://github.com/newrelic/node-test-utilities) ([v7.3.1](https://github.com/newrelic/node-test-utilities/tree/v7.3.1)), distributed under the [Apache-2.0 License](https://github.com/newrelic/node-test-utilities/blob/v7.3.1/LICENSE):
1887
+ This product includes source derived from [@newrelic/test-utilities](https://github.com/newrelic/node-test-utilities) ([v7.3.2](https://github.com/newrelic/node-test-utilities/tree/v7.3.2)), distributed under the [Apache-2.0 License](https://github.com/newrelic/node-test-utilities/blob/v7.3.2/LICENSE):
1888
1888
 
1889
1889
  ```
1890
1890
  Apache License
@@ -9556,7 +9556,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
9556
9556
 
9557
9557
  ### @newrelic/native-metrics
9558
9558
 
9559
- This product includes source derived from [@newrelic/native-metrics](https://github.com/newrelic/node-native-metrics) ([v9.0.0](https://github.com/newrelic/node-native-metrics/tree/v9.0.0)), distributed under the [Apache-2.0 License](https://github.com/newrelic/node-native-metrics/blob/v9.0.0/LICENSE):
9559
+ This product includes source derived from [@newrelic/native-metrics](https://github.com/newrelic/node-native-metrics) ([v9.0.1](https://github.com/newrelic/node-native-metrics/tree/v9.0.1)), distributed under the [Apache-2.0 License](https://github.com/newrelic/node-native-metrics/blob/v9.0.1/LICENSE):
9560
9560
 
9561
9561
  ```
9562
9562
  Apache License
@@ -67,6 +67,8 @@ function getRedisParams(clientOpts) {
67
67
  return {
68
68
  host: clientOpts?.socket?.host || 'localhost',
69
69
  port_path_or_id: clientOpts?.socket?.path || clientOpts?.socket?.port || '6379',
70
- database_name: clientOpts.database || 0
70
+ database_name: clientOpts?.database || 0
71
71
  }
72
72
  }
73
+
74
+ module.exports.getRedisParams = getRedisParams
@@ -87,7 +87,8 @@ function extractQueryArgs(args, pkgVersion) {
87
87
  let query = ''
88
88
  try {
89
89
  if (semver.gte(pkgVersion, '4.11.0')) {
90
- query = args[0].args[0]
90
+ // Prisma 4.16.0 moved the query to a `strings` property
91
+ query = args[0].args[0] || args[0].args.strings[0]
91
92
  if (Array.isArray(query)) {
92
93
  // RawUnsafe pass in a string, but plain Raw methods pass in an
93
94
  // array containing a prepared SQL statement and the SQL parameters
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "newrelic",
3
- "version": "10.3.0",
3
+ "version": "10.3.2",
4
4
  "author": "New Relic Node.js agent team <nodejs@newrelic.com>",
5
5
  "license": "Apache-2.0",
6
6
  "contributors": [
@@ -187,7 +187,7 @@
187
187
  "@mrleebo/prisma-ast": "^0.5.2",
188
188
  "@newrelic/aws-sdk": "^5.0.2",
189
189
  "@newrelic/koa": "^7.1.1",
190
- "@newrelic/security-agent": "0.1.2",
190
+ "@newrelic/security-agent": "0.1.3",
191
191
  "@newrelic/superagent": "^6.0.0",
192
192
  "@tyriar/fibonacci-heap": "^2.0.7",
193
193
  "concat-stream": "^2.0.0",
@@ -195,18 +195,18 @@
195
195
  "json-bigint": "^1.0.0",
196
196
  "json-stringify-safe": "^5.0.0",
197
197
  "readable-stream": "^3.6.1",
198
- "semver": "^5.3.0",
198
+ "semver": "^7.5.2",
199
199
  "winston-transport": "^4.5.0"
200
200
  },
201
201
  "optionalDependencies": {
202
202
  "@contrast/fn-inspect": "^3.3.0",
203
- "@newrelic/native-metrics": "^9.0.0"
203
+ "@newrelic/native-metrics": "^9.0.1"
204
204
  },
205
205
  "devDependencies": {
206
206
  "@newrelic/eslint-config": "^0.3.0",
207
207
  "@newrelic/newrelic-oss-cli": "^0.1.2",
208
208
  "@newrelic/proxy": "^2.0.0",
209
- "@newrelic/test-utilities": "^7.3.0",
209
+ "@newrelic/test-utilities": "^7.3.2",
210
210
  "@octokit/rest": "^18.0.15",
211
211
  "@slack/bolt": "^3.7.0",
212
212
  "ajv": "^6.12.6",