arvo-core 2.1.8 → 2.1.10

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.
@@ -10,6 +10,17 @@ var __assign = (this && this.__assign) || function () {
10
10
  };
11
11
  return __assign.apply(this, arguments);
12
12
  };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
13
24
  var __importDefault = (this && this.__importDefault) || function (mod) {
14
25
  return (mod && mod.__esModule) ? mod : { "default": mod };
15
26
  };
@@ -101,9 +112,10 @@ exports.ArvoOpenTelemetry = ArvoOpenTelemetry;
101
112
  */
102
113
  var logToSpan = function (params, span) {
103
114
  if (span === void 0) { span = api_1.trace.getActiveSpan(); }
104
- var toLog = __assign(__assign({}, params), { timestamp: performance.now() });
115
+ var level = params.level, message = params.message, restParams = __rest(params, ["level", "message"]);
116
+ var toLog = __assign({ 'log.severity': level, 'log.message': message, 'log.timestamp': performance.now() }, restParams);
105
117
  if (span) {
106
- span.addEvent('log_message', toLog);
118
+ span.addEvent('log', toLog);
107
119
  }
108
120
  else {
109
121
  console.log(JSON.stringify(toLog, null, 2));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "arvo-core",
3
- "version": "2.1.8",
3
+ "version": "2.1.10",
4
4
  "description": "This core package contains all the core classes and components of the Arvo Event Driven System",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {