@ceon-oy/monitor-sdk 1.5.3 → 1.5.5

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/dist/index.js CHANGED
@@ -53,8 +53,9 @@ var CONFIG_LIMITS = {
53
53
  // 10MB
54
54
  AUDIT_TIMEOUT_MS: 6e4,
55
55
  // 60 seconds (default)
56
- MAX_AUDIT_TIMEOUT_MS: 3e5,
57
- // 5 minutes (max configurable)
56
+ MAX_AUDIT_TIMEOUT_MS: 18e5,
57
+ // 30 minutes (max configurable) - was 5 minutes, which every
58
+ // real npm audit run on Cloud Run (slow registry egress) exceeded, silently returning null
58
59
  SETTINGS_POLL_INTERVAL_MS: 5 * 60 * 1e3,
59
60
  // 5 minutes
60
61
  REGISTRY_TIMEOUT_MS: 5e3,
@@ -1261,7 +1262,9 @@ var MonitorClient = class {
1261
1262
  maxBuffer: CONFIG_LIMITS.AUDIT_MAX_BUFFER
1262
1263
  });
1263
1264
  if (result2.timedOut) {
1264
- console.error(`[MonitorClient] yarn audit timed out after ${this.auditTimeoutMs}ms`);
1265
+ const message = `yarn audit timed out after ${this.auditTimeoutMs}ms`;
1266
+ console.error(`[MonitorClient] ${message}`);
1267
+ this.reportError("VULNERABILITY_SCAN", message);
1265
1268
  return null;
1266
1269
  }
1267
1270
  auditOutput = result2.stdout;
@@ -1294,7 +1297,9 @@ var MonitorClient = class {
1294
1297
  maxBuffer: CONFIG_LIMITS.AUDIT_MAX_BUFFER
1295
1298
  });
1296
1299
  if (result2.timedOut) {
1297
- console.error(`[MonitorClient] npm audit timed out after ${this.auditTimeoutMs}ms`);
1300
+ const message = `npm audit timed out after ${this.auditTimeoutMs}ms`;
1301
+ console.error(`[MonitorClient] ${message}`);
1302
+ this.reportError("VULNERABILITY_SCAN", message);
1298
1303
  return null;
1299
1304
  }
1300
1305
  auditOutput = result2.stdout;
package/dist/index.mjs CHANGED
@@ -17,8 +17,9 @@ var CONFIG_LIMITS = {
17
17
  // 10MB
18
18
  AUDIT_TIMEOUT_MS: 6e4,
19
19
  // 60 seconds (default)
20
- MAX_AUDIT_TIMEOUT_MS: 3e5,
21
- // 5 minutes (max configurable)
20
+ MAX_AUDIT_TIMEOUT_MS: 18e5,
21
+ // 30 minutes (max configurable) - was 5 minutes, which every
22
+ // real npm audit run on Cloud Run (slow registry egress) exceeded, silently returning null
22
23
  SETTINGS_POLL_INTERVAL_MS: 5 * 60 * 1e3,
23
24
  // 5 minutes
24
25
  REGISTRY_TIMEOUT_MS: 5e3,
@@ -1225,7 +1226,9 @@ var MonitorClient = class {
1225
1226
  maxBuffer: CONFIG_LIMITS.AUDIT_MAX_BUFFER
1226
1227
  });
1227
1228
  if (result2.timedOut) {
1228
- console.error(`[MonitorClient] yarn audit timed out after ${this.auditTimeoutMs}ms`);
1229
+ const message = `yarn audit timed out after ${this.auditTimeoutMs}ms`;
1230
+ console.error(`[MonitorClient] ${message}`);
1231
+ this.reportError("VULNERABILITY_SCAN", message);
1229
1232
  return null;
1230
1233
  }
1231
1234
  auditOutput = result2.stdout;
@@ -1258,7 +1261,9 @@ var MonitorClient = class {
1258
1261
  maxBuffer: CONFIG_LIMITS.AUDIT_MAX_BUFFER
1259
1262
  });
1260
1263
  if (result2.timedOut) {
1261
- console.error(`[MonitorClient] npm audit timed out after ${this.auditTimeoutMs}ms`);
1264
+ const message = `npm audit timed out after ${this.auditTimeoutMs}ms`;
1265
+ console.error(`[MonitorClient] ${message}`);
1266
+ this.reportError("VULNERABILITY_SCAN", message);
1262
1267
  return null;
1263
1268
  }
1264
1269
  auditOutput = result2.stdout;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ceon-oy/monitor-sdk",
3
- "version": "1.5.3",
3
+ "version": "1.5.5",
4
4
  "description": "Client SDK for Ceon Monitor - Error tracking, health monitoring, security events, and vulnerability scanning",
5
5
  "author": "Ceon",
6
6
  "license": "MIT",