@ama-sdk/client-fetch 13.0.0-next.1 → 13.0.0-next.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.
@@ -8,7 +8,13 @@ Object.defineProperty(exports, "PerformanceMetricPlugin", {
8
8
  return PerformanceMetricPlugin;
9
9
  }
10
10
  });
11
- var _uuid = require("uuid");
11
+ var _core = require("@ama-sdk/core");
12
+ function _assert_this_initialized(self) {
13
+ if (self === void 0) {
14
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
15
+ }
16
+ return self;
17
+ }
12
18
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
13
19
  try {
14
20
  var info = gen[key](arg);
@@ -38,6 +44,10 @@ function _async_to_generator(fn) {
38
44
  });
39
45
  };
40
46
  }
47
+ function _call_super(_this, derived, args) {
48
+ derived = _get_prototype_of(derived);
49
+ return _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
50
+ }
41
51
  function _class_call_check(instance, Constructor) {
42
52
  if (!(instance instanceof Constructor)) {
43
53
  throw new TypeError("Cannot call a class as a function");
@@ -57,57 +67,49 @@ function _create_class(Constructor, protoProps, staticProps) {
57
67
  if (staticProps) _defineProperties(Constructor, staticProps);
58
68
  return Constructor;
59
69
  }
60
- function _define_property(obj, key, value) {
61
- if (key in obj) {
62
- Object.defineProperty(obj, key, {
63
- value: value,
64
- enumerable: true,
65
- configurable: true,
66
- writable: true
67
- });
68
- } else {
69
- obj[key] = value;
70
- }
71
- return obj;
70
+ function _get_prototype_of(o) {
71
+ _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
72
+ return o.__proto__ || Object.getPrototypeOf(o);
73
+ };
74
+ return _get_prototype_of(o);
72
75
  }
73
- function _object_spread(target) {
74
- for(var i = 1; i < arguments.length; i++){
75
- var source = arguments[i] != null ? arguments[i] : {};
76
- var ownKeys = Object.keys(source);
77
- if (typeof Object.getOwnPropertySymbols === "function") {
78
- ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
79
- return Object.getOwnPropertyDescriptor(source, sym).enumerable;
80
- }));
81
- }
82
- ownKeys.forEach(function(key) {
83
- _define_property(target, key, source[key]);
84
- });
76
+ function _inherits(subClass, superClass) {
77
+ if (typeof superClass !== "function" && superClass !== null) {
78
+ throw new TypeError("Super expression must either be null or a function");
85
79
  }
86
- return target;
87
- }
88
- function ownKeys(object, enumerableOnly) {
89
- var keys = Object.keys(object);
90
- if (Object.getOwnPropertySymbols) {
91
- var symbols = Object.getOwnPropertySymbols(object);
92
- if (enumerableOnly) {
93
- symbols = symbols.filter(function(sym) {
94
- return Object.getOwnPropertyDescriptor(object, sym).enumerable;
95
- });
80
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
81
+ constructor: {
82
+ value: subClass,
83
+ writable: true,
84
+ configurable: true
96
85
  }
97
- keys.push.apply(keys, symbols);
98
- }
99
- return keys;
86
+ });
87
+ if (superClass) _set_prototype_of(subClass, superClass);
100
88
  }
101
- function _object_spread_props(target, source) {
102
- source = source != null ? source : {};
103
- if (Object.getOwnPropertyDescriptors) {
104
- Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
105
- } else {
106
- ownKeys(Object(source)).forEach(function(key) {
107
- Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
108
- });
89
+ function _possible_constructor_return(self, call) {
90
+ if (call && (_type_of(call) === "object" || typeof call === "function")) {
91
+ return call;
109
92
  }
110
- return target;
93
+ return _assert_this_initialized(self);
94
+ }
95
+ function _set_prototype_of(o, p) {
96
+ _set_prototype_of = Object.setPrototypeOf || function setPrototypeOf(o, p) {
97
+ o.__proto__ = p;
98
+ return o;
99
+ };
100
+ return _set_prototype_of(o, p);
101
+ }
102
+ function _type_of(obj) {
103
+ "@swc/helpers - typeof";
104
+ return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
105
+ }
106
+ function _is_native_reflect_construct() {
107
+ try {
108
+ var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
109
+ } catch (_) {}
110
+ return (_is_native_reflect_construct = function() {
111
+ return !!result;
112
+ })();
111
113
  }
112
114
  function _ts_generator(thisArg, body) {
113
115
  var f, y, t, _ = {
@@ -200,119 +202,14 @@ function _ts_generator(thisArg, body) {
200
202
  };
201
203
  }
202
204
  }
203
- var PerformanceMetricPlugin = /*#__PURE__*/ function() {
205
+ var PerformanceMetricPlugin = /*#__PURE__*/ function(PerformanceMetricService) {
204
206
  "use strict";
205
- function PerformanceMetricPlugin(options) {
207
+ _inherits(PerformanceMetricPlugin, PerformanceMetricService);
208
+ function PerformanceMetricPlugin() {
206
209
  _class_call_check(this, PerformanceMetricPlugin);
207
- /**
208
- * Callback function called when a mark is closed.
209
- */ _define_property(this, "onMarkComplete", void 0);
210
- /**
211
- * Callback function called when a mark is closed with an error.
212
- */ _define_property(this, "onMarkError", void 0);
213
- /**
214
- * Callback function called when a mark is opened.
215
- */ _define_property(this, "onMarkOpen", void 0);
216
- /**
217
- * Opened marks.
218
- */ _define_property(this, "openMarks", {});
219
- /**
220
- * Performance reporter to use for performance measurements.
221
- * @default window.performance on browser only, undefined on node
222
- */ _define_property(this, "performance", void 0);
223
- /**
224
- * Method used to get the current time as default implementation if no Performance API available.
225
- * Date.now() is used by default.
226
- */ _define_property(this, "getTime", Date.now);
227
- /**
228
- * Retrieve the performance tag name
229
- * @param status status of the call
230
- * @param markId Mark ID
231
- */ _define_property(this, "getPerformanceTag", function(status, markId) {
232
- return "sdk:".concat(status, ":").concat(markId);
233
- });
234
- this.getPerformanceTag = (options === null || options === void 0 ? void 0 : options.getPerformanceTag) || this.getPerformanceTag;
235
- this.performance = (options === null || options === void 0 ? void 0 : options.performance) || (typeof window === 'undefined' ? undefined : window.performance);
236
- this.onMarkComplete = options ? options.onMarkComplete : this.onMarkComplete;
237
- this.onMarkError = options ? options.onMarkError : this.onMarkError;
238
- this.onMarkOpen = options ? options.onMarkOpen : this.onMarkOpen;
210
+ return _call_super(this, PerformanceMetricPlugin, arguments);
239
211
  }
240
212
  _create_class(PerformanceMetricPlugin, [
241
- {
242
- key: "openMark",
243
- value: /**
244
- * Opens a mark associated to a call.
245
- * @param url URL of the call associated to the mark to open
246
- * @param requestOptions Options of the call associated to the mark to open
247
- */ function openMark(url, requestOptions) {
248
- var _this_performance;
249
- var markId = (0, _uuid.v4)();
250
- var perfMark = ((_this_performance = this.performance) === null || _this_performance === void 0 ? void 0 : _this_performance.mark(this.getPerformanceTag('start', markId))) || undefined;
251
- var _perfMark_startTime;
252
- var startTime = (_perfMark_startTime = perfMark === null || perfMark === void 0 ? void 0 : perfMark.startTime) !== null && _perfMark_startTime !== void 0 ? _perfMark_startTime : this.getTime();
253
- var mark = {
254
- markId: markId,
255
- url: url,
256
- requestOptions: requestOptions,
257
- startTime: startTime
258
- };
259
- this.openMarks[markId] = mark;
260
- if (this.onMarkOpen) {
261
- void this.onMarkOpen(mark);
262
- }
263
- return markId;
264
- }
265
- },
266
- {
267
- key: "closeMark",
268
- value: /**
269
- * Closes the mark matching the given mark id.
270
- * @param markId Id of the mark to close
271
- * @param response Response of the call associated to the mark to close
272
- */ function closeMark(markId, response) {
273
- var _this_performance, _this_performance1;
274
- var perfMark = ((_this_performance = this.performance) === null || _this_performance === void 0 ? void 0 : _this_performance.mark(this.getPerformanceTag('end', markId))) || undefined;
275
- var _perfMark_startTime;
276
- var endTime = (_perfMark_startTime = perfMark === null || perfMark === void 0 ? void 0 : perfMark.startTime) !== null && _perfMark_startTime !== void 0 ? _perfMark_startTime : this.getTime();
277
- (_this_performance1 = this.performance) === null || _this_performance1 === void 0 ? void 0 : _this_performance1.measure(this.getPerformanceTag('measure', markId), this.getPerformanceTag('start', markId), this.getPerformanceTag('end', markId));
278
- var mark = this.openMarks[markId];
279
- if (!mark) {
280
- return;
281
- }
282
- if (this.onMarkComplete) {
283
- void this.onMarkComplete(_object_spread_props(_object_spread({}, mark), {
284
- response: response,
285
- endTime: endTime
286
- }));
287
- }
288
- delete this.openMarks[markId];
289
- }
290
- },
291
- {
292
- key: "closeMarkWithError",
293
- value: /**
294
- * Closes the mark matching the given mark id with an error.
295
- * @param markId Id of the mark to close
296
- * @param error Optional error of the call associated to the mark to close
297
- */ function closeMarkWithError(markId, error) {
298
- var _this_performance, _this_performance1;
299
- var perfMark = ((_this_performance = this.performance) === null || _this_performance === void 0 ? void 0 : _this_performance.mark(this.getPerformanceTag('error', markId))) || undefined;
300
- var _perfMark_startTime;
301
- var endTime = (_perfMark_startTime = perfMark === null || perfMark === void 0 ? void 0 : perfMark.startTime) !== null && _perfMark_startTime !== void 0 ? _perfMark_startTime : this.getTime();
302
- (_this_performance1 = this.performance) === null || _this_performance1 === void 0 ? void 0 : _this_performance1.measure(this.getPerformanceTag('measure', markId), this.getPerformanceTag('start', markId), this.getPerformanceTag('error', markId));
303
- var mark = this.openMarks[markId];
304
- if (!mark) {
305
- return;
306
- }
307
- if (this.onMarkError) {
308
- void this.onMarkError(_object_spread_props(_object_spread({}, mark), {
309
- error: error,
310
- endTime: endTime
311
- }));
312
- }
313
- delete this.openMarks[markId];
314
- }
315
- },
316
213
  {
317
214
  key: "load",
318
215
  value: /** @inheritDoc */ function load(context) {
@@ -361,4 +258,4 @@ var PerformanceMetricPlugin = /*#__PURE__*/ function() {
361
258
  }
362
259
  ]);
363
260
  return PerformanceMetricPlugin;
364
- }();
261
+ }(_core.PerformanceMetricService);
@@ -1,3 +1,9 @@
1
+ function _assert_this_initialized(self) {
2
+ if (self === void 0) {
3
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
4
+ }
5
+ return self;
6
+ }
1
7
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
2
8
  try {
3
9
  var info = gen[key](arg);
@@ -27,6 +33,10 @@ function _async_to_generator(fn) {
27
33
  });
28
34
  };
29
35
  }
36
+ function _call_super(_this, derived, args) {
37
+ derived = _get_prototype_of(derived);
38
+ return _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
39
+ }
30
40
  function _class_call_check(instance, Constructor) {
31
41
  if (!(instance instanceof Constructor)) {
32
42
  throw new TypeError("Cannot call a class as a function");
@@ -46,57 +56,49 @@ function _create_class(Constructor, protoProps, staticProps) {
46
56
  if (staticProps) _defineProperties(Constructor, staticProps);
47
57
  return Constructor;
48
58
  }
49
- function _define_property(obj, key, value) {
50
- if (key in obj) {
51
- Object.defineProperty(obj, key, {
52
- value: value,
53
- enumerable: true,
54
- configurable: true,
55
- writable: true
56
- });
57
- } else {
58
- obj[key] = value;
59
- }
60
- return obj;
59
+ function _get_prototype_of(o) {
60
+ _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
61
+ return o.__proto__ || Object.getPrototypeOf(o);
62
+ };
63
+ return _get_prototype_of(o);
61
64
  }
62
- function _object_spread(target) {
63
- for(var i = 1; i < arguments.length; i++){
64
- var source = arguments[i] != null ? arguments[i] : {};
65
- var ownKeys = Object.keys(source);
66
- if (typeof Object.getOwnPropertySymbols === "function") {
67
- ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
68
- return Object.getOwnPropertyDescriptor(source, sym).enumerable;
69
- }));
70
- }
71
- ownKeys.forEach(function(key) {
72
- _define_property(target, key, source[key]);
73
- });
65
+ function _inherits(subClass, superClass) {
66
+ if (typeof superClass !== "function" && superClass !== null) {
67
+ throw new TypeError("Super expression must either be null or a function");
74
68
  }
75
- return target;
76
- }
77
- function ownKeys(object, enumerableOnly) {
78
- var keys = Object.keys(object);
79
- if (Object.getOwnPropertySymbols) {
80
- var symbols = Object.getOwnPropertySymbols(object);
81
- if (enumerableOnly) {
82
- symbols = symbols.filter(function(sym) {
83
- return Object.getOwnPropertyDescriptor(object, sym).enumerable;
84
- });
69
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
70
+ constructor: {
71
+ value: subClass,
72
+ writable: true,
73
+ configurable: true
85
74
  }
86
- keys.push.apply(keys, symbols);
87
- }
88
- return keys;
75
+ });
76
+ if (superClass) _set_prototype_of(subClass, superClass);
89
77
  }
90
- function _object_spread_props(target, source) {
91
- source = source != null ? source : {};
92
- if (Object.getOwnPropertyDescriptors) {
93
- Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
94
- } else {
95
- ownKeys(Object(source)).forEach(function(key) {
96
- Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
97
- });
78
+ function _possible_constructor_return(self, call) {
79
+ if (call && (_type_of(call) === "object" || typeof call === "function")) {
80
+ return call;
98
81
  }
99
- return target;
82
+ return _assert_this_initialized(self);
83
+ }
84
+ function _set_prototype_of(o, p) {
85
+ _set_prototype_of = Object.setPrototypeOf || function setPrototypeOf(o, p) {
86
+ o.__proto__ = p;
87
+ return o;
88
+ };
89
+ return _set_prototype_of(o, p);
90
+ }
91
+ function _type_of(obj) {
92
+ "@swc/helpers - typeof";
93
+ return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
94
+ }
95
+ function _is_native_reflect_construct() {
96
+ try {
97
+ var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
98
+ } catch (_) {}
99
+ return (_is_native_reflect_construct = function() {
100
+ return !!result;
101
+ })();
100
102
  }
101
103
  function _ts_generator(thisArg, body) {
102
104
  var f, y, t, _ = {
@@ -189,122 +191,17 @@ function _ts_generator(thisArg, body) {
189
191
  };
190
192
  }
191
193
  }
192
- import { v4 } from 'uuid';
194
+ import { PerformanceMetricService } from '@ama-sdk/core';
193
195
  /**
194
196
  * Performance metric plugin.
195
- */ export var PerformanceMetricPlugin = /*#__PURE__*/ function() {
197
+ */ export var PerformanceMetricPlugin = /*#__PURE__*/ function(PerformanceMetricService) {
196
198
  "use strict";
197
- function PerformanceMetricPlugin(options) {
199
+ _inherits(PerformanceMetricPlugin, PerformanceMetricService);
200
+ function PerformanceMetricPlugin() {
198
201
  _class_call_check(this, PerformanceMetricPlugin);
199
- /**
200
- * Callback function called when a mark is closed.
201
- */ _define_property(this, "onMarkComplete", void 0);
202
- /**
203
- * Callback function called when a mark is closed with an error.
204
- */ _define_property(this, "onMarkError", void 0);
205
- /**
206
- * Callback function called when a mark is opened.
207
- */ _define_property(this, "onMarkOpen", void 0);
208
- /**
209
- * Opened marks.
210
- */ _define_property(this, "openMarks", {});
211
- /**
212
- * Performance reporter to use for performance measurements.
213
- * @default window.performance on browser only, undefined on node
214
- */ _define_property(this, "performance", void 0);
215
- /**
216
- * Method used to get the current time as default implementation if no Performance API available.
217
- * Date.now() is used by default.
218
- */ _define_property(this, "getTime", Date.now);
219
- /**
220
- * Retrieve the performance tag name
221
- * @param status status of the call
222
- * @param markId Mark ID
223
- */ _define_property(this, "getPerformanceTag", function(status, markId) {
224
- return "sdk:".concat(status, ":").concat(markId);
225
- });
226
- this.getPerformanceTag = (options === null || options === void 0 ? void 0 : options.getPerformanceTag) || this.getPerformanceTag;
227
- this.performance = (options === null || options === void 0 ? void 0 : options.performance) || (typeof window === 'undefined' ? undefined : window.performance);
228
- this.onMarkComplete = options ? options.onMarkComplete : this.onMarkComplete;
229
- this.onMarkError = options ? options.onMarkError : this.onMarkError;
230
- this.onMarkOpen = options ? options.onMarkOpen : this.onMarkOpen;
202
+ return _call_super(this, PerformanceMetricPlugin, arguments);
231
203
  }
232
204
  _create_class(PerformanceMetricPlugin, [
233
- {
234
- key: "openMark",
235
- value: /**
236
- * Opens a mark associated to a call.
237
- * @param url URL of the call associated to the mark to open
238
- * @param requestOptions Options of the call associated to the mark to open
239
- */ function openMark(url, requestOptions) {
240
- var _this_performance;
241
- var markId = v4();
242
- var perfMark = ((_this_performance = this.performance) === null || _this_performance === void 0 ? void 0 : _this_performance.mark(this.getPerformanceTag('start', markId))) || undefined;
243
- var _perfMark_startTime;
244
- var startTime = (_perfMark_startTime = perfMark === null || perfMark === void 0 ? void 0 : perfMark.startTime) !== null && _perfMark_startTime !== void 0 ? _perfMark_startTime : this.getTime();
245
- var mark = {
246
- markId: markId,
247
- url: url,
248
- requestOptions: requestOptions,
249
- startTime: startTime
250
- };
251
- this.openMarks[markId] = mark;
252
- if (this.onMarkOpen) {
253
- void this.onMarkOpen(mark);
254
- }
255
- return markId;
256
- }
257
- },
258
- {
259
- key: "closeMark",
260
- value: /**
261
- * Closes the mark matching the given mark id.
262
- * @param markId Id of the mark to close
263
- * @param response Response of the call associated to the mark to close
264
- */ function closeMark(markId, response) {
265
- var _this_performance, _this_performance1;
266
- var perfMark = ((_this_performance = this.performance) === null || _this_performance === void 0 ? void 0 : _this_performance.mark(this.getPerformanceTag('end', markId))) || undefined;
267
- var _perfMark_startTime;
268
- var endTime = (_perfMark_startTime = perfMark === null || perfMark === void 0 ? void 0 : perfMark.startTime) !== null && _perfMark_startTime !== void 0 ? _perfMark_startTime : this.getTime();
269
- (_this_performance1 = this.performance) === null || _this_performance1 === void 0 ? void 0 : _this_performance1.measure(this.getPerformanceTag('measure', markId), this.getPerformanceTag('start', markId), this.getPerformanceTag('end', markId));
270
- var mark = this.openMarks[markId];
271
- if (!mark) {
272
- return;
273
- }
274
- if (this.onMarkComplete) {
275
- void this.onMarkComplete(_object_spread_props(_object_spread({}, mark), {
276
- response: response,
277
- endTime: endTime
278
- }));
279
- }
280
- delete this.openMarks[markId];
281
- }
282
- },
283
- {
284
- key: "closeMarkWithError",
285
- value: /**
286
- * Closes the mark matching the given mark id with an error.
287
- * @param markId Id of the mark to close
288
- * @param error Optional error of the call associated to the mark to close
289
- */ function closeMarkWithError(markId, error) {
290
- var _this_performance, _this_performance1;
291
- var perfMark = ((_this_performance = this.performance) === null || _this_performance === void 0 ? void 0 : _this_performance.mark(this.getPerformanceTag('error', markId))) || undefined;
292
- var _perfMark_startTime;
293
- var endTime = (_perfMark_startTime = perfMark === null || perfMark === void 0 ? void 0 : perfMark.startTime) !== null && _perfMark_startTime !== void 0 ? _perfMark_startTime : this.getTime();
294
- (_this_performance1 = this.performance) === null || _this_performance1 === void 0 ? void 0 : _this_performance1.measure(this.getPerformanceTag('measure', markId), this.getPerformanceTag('start', markId), this.getPerformanceTag('error', markId));
295
- var mark = this.openMarks[markId];
296
- if (!mark) {
297
- return;
298
- }
299
- if (this.onMarkError) {
300
- void this.onMarkError(_object_spread_props(_object_spread({}, mark), {
301
- error: error,
302
- endTime: endTime
303
- }));
304
- }
305
- delete this.openMarks[markId];
306
- }
307
- },
308
205
  {
309
206
  key: "load",
310
207
  value: /** @inheritDoc */ function load(context) {
@@ -353,4 +250,4 @@ import { v4 } from 'uuid';
353
250
  }
354
251
  ]);
355
252
  return PerformanceMetricPlugin;
356
- }();
253
+ }(PerformanceMetricService);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ama-sdk/client-fetch",
3
- "version": "13.0.0-next.1",
3
+ "version": "13.0.0-next.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -16,9 +16,6 @@
16
16
  },
17
17
  ".": {
18
18
  "module": "./src/public_api.js",
19
- "esm2020": "./src/public_api.js",
20
- "esm2015": "./esm2015/public_api.js",
21
- "es2020": "./cjs/public_api.js",
22
19
  "default": "./cjs/public_api.js",
23
20
  "typings": "./src/public_api.d.ts",
24
21
  "import": "./src/public_api.js",
@@ -38,18 +35,18 @@
38
35
  "build:builders": "tsc -b tsconfig.builders.json --pretty && yarn generate-cjs-manifest"
39
36
  },
40
37
  "dependencies": {
41
- "@o3r/schematics": "^13.0.0-next.1",
38
+ "@o3r/schematics": "^13.0.0-next.2",
42
39
  "@swc/helpers": "~0.5.0",
43
40
  "ts-node": "~10.9.2",
44
41
  "tslib": "^2.6.2",
45
42
  "uuid": "^11.0.5"
46
43
  },
47
44
  "peerDependencies": {
48
- "@ama-sdk/core": "^13.0.0-next.1",
45
+ "@ama-sdk/core": "^13.0.0-next.2",
49
46
  "@angular-devkit/schematics": "^19.0.0",
50
47
  "@angular/cli": "^19.0.0",
51
48
  "@angular/common": "^19.0.0",
52
- "@o3r/schematics": "^13.0.0-next.1",
49
+ "@o3r/schematics": "^13.0.0-next.2",
53
50
  "@schematics/angular": "^19.0.0",
54
51
  "isomorphic-fetch": "^3.0.0",
55
52
  "type-fest": "^4.30.1",
@@ -82,7 +79,7 @@
82
79
  }
83
80
  },
84
81
  "devDependencies": {
85
- "@ama-sdk/core": "^13.0.0-next.1",
82
+ "@ama-sdk/core": "^13.0.0-next.2",
86
83
  "@angular-devkit/core": "~19.2.0",
87
84
  "@angular-devkit/schematics": "~19.2.0",
88
85
  "@angular/common": "~19.2.0",
@@ -90,9 +87,9 @@
90
87
  "@eslint-community/eslint-plugin-eslint-comments": "^4.4.0",
91
88
  "@nx/eslint-plugin": "~20.8.0",
92
89
  "@nx/jest": "~20.8.0",
93
- "@o3r/build-helpers": "^13.0.0-next.1",
94
- "@o3r/eslint-plugin": "^13.0.0-next.1",
95
- "@o3r/test-helpers": "^13.0.0-next.1",
90
+ "@o3r/build-helpers": "^13.0.0-next.2",
91
+ "@o3r/eslint-plugin": "^13.0.0-next.2",
92
+ "@o3r/test-helpers": "^13.0.0-next.2",
96
93
  "@schematics/angular": "~19.2.0",
97
94
  "@stylistic/eslint-plugin": "~3.1.0",
98
95
  "@stylistic/eslint-plugin-ts": "~3.1.0",
@@ -100,7 +97,6 @@
100
97
  "@swc/core": "~1.12.0",
101
98
  "@types/jest": "~29.5.2",
102
99
  "@types/node": "^20.0.0",
103
- "@types/uuid": "^10.0.0",
104
100
  "@typescript-eslint/parser": "~8.35.0",
105
101
  "angular-eslint": "~19.4.0",
106
102
  "cpy-cli": "^5.0.0",
@@ -1,133 +1,23 @@
1
+ import { PerformanceMetricService } from '@ama-sdk/core';
2
+ import type { Mark as CoreMark, PerformanceMetricOptions as CorePerformanceMetricOptions } from '@ama-sdk/core';
1
3
  import type { FetchCall, FetchPlugin, FetchPluginContext } from '../../fetch-plugin';
2
4
  /**
3
5
  * Performance metric mark associated to a call.
6
+ * @deprecated use {@link CoreMark|Mark from @ama-sdk/core} instead. Will be removed in v15
4
7
  */
5
- export interface Mark {
6
- /**
7
- * Id of the mark.
8
- */
9
- markId: string;
10
- /**
11
- * URL of the call.
12
- */
13
- url: string;
14
- /**
15
- * Options of the call.
16
- */
17
- requestOptions: RequestInit;
18
- /**
19
- * Start time of the call.
20
- */
21
- startTime: number;
22
- /**
23
- * Response of the call.
24
- */
25
- response?: Response;
26
- /**
27
- * Error of the call.
28
- */
29
- error?: Error;
30
- /**
31
- * End time of the call.
32
- */
33
- endTime?: number;
34
- }
35
- /** Performance object supporting NodeJs Performance and Web Performance reporting */
36
- type CrossPlatformPerformance = {
37
- /** @see Performance.mark */
38
- mark: (...x: Parameters<Performance['mark']>) => ReturnType<Performance['mark']> | void;
39
- /** @see Performance.measure */
40
- measure: (measureName: string, startOrMeasureOptions?: string, endMark?: string) => ReturnType<Performance['measure']> | void;
41
- };
8
+ export type Mark = CoreMark;
42
9
  /**
43
- * Options for this plugin.
10
+ * Options for the Performance Metric Plugin.
11
+ * @deprecated use {@link CorePerformanceMetricOptions|PerformanceMetricOptions from @ama-sdk/core} instead. Will be removed in v15
44
12
  */
45
- export interface PerformanceMetricOptions {
46
- /**
47
- * Callback function to be called when a mark is closed.
48
- */
49
- onMarkComplete: (mark: Mark) => void | Promise<void>;
50
- /**
51
- * Callback function to be called when a mark is closed with an error.
52
- */
53
- onMarkError: (mark: Mark) => void | Promise<void>;
54
- /**
55
- * Callback function called when a mark is opened.
56
- */
57
- onMarkOpen: (mark: Mark) => void | Promise<void>;
58
- /**
59
- * Instance of the performance reporter to use for performance measurements.
60
- * @default window.performance on browser only, undefined on node
61
- */
62
- performance: CrossPlatformPerformance;
63
- /**
64
- * Retrieve the performance tag name
65
- * @param status status of the call
66
- * @param markId Mark ID
67
- */
68
- getPerformanceTag: (status: string, markId: string) => string;
69
- }
13
+ export type PerformanceMetricOptions = CorePerformanceMetricOptions;
70
14
  /**
71
15
  * Performance metric plugin.
72
16
  */
73
- export declare class PerformanceMetricPlugin implements FetchPlugin {
74
- /**
75
- * Callback function called when a mark is closed.
76
- */
77
- onMarkComplete?: (mark: Mark) => void | Promise<void>;
78
- /**
79
- * Callback function called when a mark is closed with an error.
80
- */
81
- onMarkError?: (mark: Mark) => void | Promise<void>;
82
- /**
83
- * Callback function called when a mark is opened.
84
- */
85
- onMarkOpen?: (mark: Mark) => void | Promise<void>;
86
- /**
87
- * Opened marks.
88
- */
89
- protected readonly openMarks: {
90
- [markId: string]: Mark;
91
- };
92
- /**
93
- * Performance reporter to use for performance measurements.
94
- * @default window.performance on browser only, undefined on node
95
- */
96
- protected readonly performance: CrossPlatformPerformance | undefined;
97
- /**
98
- * Method used to get the current time as default implementation if no Performance API available.
99
- * Date.now() is used by default.
100
- */
101
- protected getTime: () => number;
102
- constructor(options?: Partial<PerformanceMetricOptions>);
103
- /**
104
- * Retrieve the performance tag name
105
- * @param status status of the call
106
- * @param markId Mark ID
107
- */
108
- protected getPerformanceTag: (status: string, markId: string) => string;
109
- /**
110
- * Opens a mark associated to a call.
111
- * @param url URL of the call associated to the mark to open
112
- * @param requestOptions Options of the call associated to the mark to open
113
- */
114
- openMark(url: string, requestOptions: RequestInit): string;
115
- /**
116
- * Closes the mark matching the given mark id.
117
- * @param markId Id of the mark to close
118
- * @param response Response of the call associated to the mark to close
119
- */
120
- closeMark(markId: string, response: Response): void;
121
- /**
122
- * Closes the mark matching the given mark id with an error.
123
- * @param markId Id of the mark to close
124
- * @param error Optional error of the call associated to the mark to close
125
- */
126
- closeMarkWithError(markId: string, error: Error | undefined): void;
17
+ export declare class PerformanceMetricPlugin extends PerformanceMetricService implements FetchPlugin {
127
18
  /** @inheritDoc */
128
19
  load(context: FetchPluginContext): {
129
20
  transform: (fetchCall: FetchCall) => Promise<Response>;
130
21
  };
131
22
  }
132
- export {};
133
23
  //# sourceMappingURL=perf-metric.fetch.d.ts.map
@@ -1 +1 @@
1
- {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IAAI,CAAC,OAAO,EAAE,kBAAkB;+BAEN,SAAS;;CAc3C"}
1
+ {"version":3,"file":"perf-metric.fetch.d.ts","sourceRoot":"","sources":["../../../../src/plugins/perf-metric/perf-metric.fetch.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACzB,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,EACV,IAAI,IAAI,QAAQ,EAChB,wBAAwB,IAAI,4BAA4B,EACzD,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,EACV,SAAS,EACT,WAAW,EACX,kBAAkB,EACnB,MAAM,oBAAoB,CAAC;AAE5B;;;GAGG;AACH,MAAM,MAAM,IAAI,GAAG,QAAQ,CAAC;AAE5B;;;GAGG;AACH,MAAM,MAAM,wBAAwB,GAAG,4BAA4B,CAAC;AAEpE;;GAEG;AACH,qBAAa,uBAAwB,SAAQ,wBAAyB,YAAW,WAAW;IAC1F,kBAAkB;IACX,IAAI,CAAC,OAAO,EAAE,kBAAkB;+BAEN,SAAS;;CAc3C"}
@@ -1,95 +1,8 @@
1
- import { v4, } from 'uuid';
1
+ import { PerformanceMetricService, } from '@ama-sdk/core';
2
2
  /**
3
3
  * Performance metric plugin.
4
4
  */
5
- export class PerformanceMetricPlugin {
6
- constructor(options) {
7
- /**
8
- * Opened marks.
9
- */
10
- this.openMarks = {};
11
- /**
12
- * Method used to get the current time as default implementation if no Performance API available.
13
- * Date.now() is used by default.
14
- */
15
- this.getTime = Date.now;
16
- /**
17
- * Retrieve the performance tag name
18
- * @param status status of the call
19
- * @param markId Mark ID
20
- */
21
- this.getPerformanceTag = (status, markId) => `sdk:${status}:${markId}`;
22
- this.getPerformanceTag = options?.getPerformanceTag || this.getPerformanceTag;
23
- this.performance = options?.performance || (typeof window === 'undefined' ? undefined : window.performance);
24
- this.onMarkComplete = options ? options.onMarkComplete : this.onMarkComplete;
25
- this.onMarkError = options ? options.onMarkError : this.onMarkError;
26
- this.onMarkOpen = options ? options.onMarkOpen : this.onMarkOpen;
27
- }
28
- /**
29
- * Opens a mark associated to a call.
30
- * @param url URL of the call associated to the mark to open
31
- * @param requestOptions Options of the call associated to the mark to open
32
- */
33
- openMark(url, requestOptions) {
34
- const markId = v4();
35
- const perfMark = this.performance?.mark(this.getPerformanceTag('start', markId)) || undefined;
36
- const startTime = perfMark?.startTime ?? this.getTime();
37
- const mark = {
38
- markId,
39
- url,
40
- requestOptions,
41
- startTime
42
- };
43
- this.openMarks[markId] = mark;
44
- if (this.onMarkOpen) {
45
- void this.onMarkOpen(mark);
46
- }
47
- return markId;
48
- }
49
- /**
50
- * Closes the mark matching the given mark id.
51
- * @param markId Id of the mark to close
52
- * @param response Response of the call associated to the mark to close
53
- */
54
- closeMark(markId, response) {
55
- const perfMark = this.performance?.mark(this.getPerformanceTag('end', markId)) || undefined;
56
- const endTime = perfMark?.startTime ?? this.getTime();
57
- this.performance?.measure(this.getPerformanceTag('measure', markId), this.getPerformanceTag('start', markId), this.getPerformanceTag('end', markId));
58
- const mark = this.openMarks[markId];
59
- if (!mark) {
60
- return;
61
- }
62
- if (this.onMarkComplete) {
63
- void this.onMarkComplete({
64
- ...mark,
65
- response,
66
- endTime
67
- });
68
- }
69
- delete this.openMarks[markId];
70
- }
71
- /**
72
- * Closes the mark matching the given mark id with an error.
73
- * @param markId Id of the mark to close
74
- * @param error Optional error of the call associated to the mark to close
75
- */
76
- closeMarkWithError(markId, error) {
77
- const perfMark = this.performance?.mark(this.getPerformanceTag('error', markId)) || undefined;
78
- const endTime = perfMark?.startTime ?? this.getTime();
79
- this.performance?.measure(this.getPerformanceTag('measure', markId), this.getPerformanceTag('start', markId), this.getPerformanceTag('error', markId));
80
- const mark = this.openMarks[markId];
81
- if (!mark) {
82
- return;
83
- }
84
- if (this.onMarkError) {
85
- void this.onMarkError({
86
- ...mark,
87
- error,
88
- endTime
89
- });
90
- }
91
- delete this.openMarks[markId];
92
- }
5
+ export class PerformanceMetricPlugin extends PerformanceMetricService {
93
6
  /** @inheritDoc */
94
7
  load(context) {
95
8
  return {
@@ -1 +1 @@
1
- {"version":3,"file":"perf-metric.fetch.js","sourceRoot":"","sources":["../../../../src/plugins/perf-metric/perf-metric.fetch.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,EAAE,GACH,MAAM,MAAM,CAAC;AAwFd;;GAEG;AACH,MAAM,OAAO,uBAAuB;IAiClC,YAAY,OAA2C;QAjBvD;;WAEG;QACgB,cAAS,GAA+B,EAAE,CAAC;QAQ9D;;;WAGG;QACO,YAAO,GAAiB,IAAI,CAAC,GAAG,CAAC;QAU3C;;;;WAIG;QACO,sBAAiB,GAAG,CAAC,MAAc,EAAE,MAAc,EAAE,EAAE,CAAC,OAAO,MAAM,IAAI,MAAM,EAAE,CAAC;QAZ1F,IAAI,CAAC,iBAAiB,GAAG,OAAO,EAAE,iBAAiB,IAAI,IAAI,CAAC,iBAAiB,CAAC;QAC9E,IAAI,CAAC,WAAW,GAAG,OAAO,EAAE,WAAW,IAAI,CAAC,OAAO,MAAM,KAAK,WAAW,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;QAC5G,IAAI,CAAC,cAAc,GAAG,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC;QAC7E,IAAI,CAAC,WAAW,GAAG,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC;QACpE,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC;IACnE,CAAC;IASD;;;;OAIG;IACI,QAAQ,CAAC,GAAW,EAAE,cAA2B;QACtD,MAAM,MAAM,GAAG,EAAE,EAAE,CAAC;QACpB,MAAM,QAAQ,GAAG,IAAI,CAAC,WAAW,EAAE,IAAI,CAAC,IAAI,CAAC,iBAAi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