@multiplayer-app/session-recorder-browser 1.3.21 → 1.3.22

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.umd.js CHANGED
@@ -24326,7 +24326,7 @@ const CONTINUOUS_DEBUGGING_TIMEOUT = 60000; // 1 minutes
24326
24326
  const DEBUG_SESSION_MAX_DURATION_SECONDS = 10 * 60 + 30; // TODO: move to shared config otel core
24327
24327
  const REMOTE_SESSION_RECORDING_START = 'remote-session-recording:start';
24328
24328
  const REMOTE_SESSION_RECORDING_STOP = 'remote-session-recording:stop';
24329
- const PACKAGE_VERSION_EXPORT = "1.3.21" || 0;
24329
+ const PACKAGE_VERSION_EXPORT = "1.3.22" || 0;
24330
24330
  // Regex patterns for OpenTelemetry ignore URLs
24331
24331
  const OTEL_IGNORE_URLS = [
24332
24332
  // Traces endpoint
@@ -25324,6 +25324,7 @@ class TracerBrowserSDK {
25324
25324
  this.clientId = _multiplayer_app_session_recorder_common__WEBPACK_IMPORTED_MODULE_1__.SessionRecorderSdk.getIdGenerator(_multiplayer_app_session_recorder_common__WEBPACK_IMPORTED_MODULE_1__.MULTIPLAYER_TRACE_CLIENT_ID_LENGTH)();
25325
25325
  const { application, version, environment } = this.config;
25326
25326
  this.idGenerator = new _multiplayer_app_session_recorder_common__WEBPACK_IMPORTED_MODULE_1__.SessionRecorderIdGenerator();
25327
+ this.setSessionId('', _multiplayer_app_session_recorder_common__WEBPACK_IMPORTED_MODULE_1__.SessionType.SESSION_CACHE);
25327
25328
  this.exporter = new _multiplayer_app_session_recorder_common__WEBPACK_IMPORTED_MODULE_1__.SessionRecorderBrowserTraceExporter({
25328
25329
  apiKey: options.apiKey,
25329
25330
  url: (0,_helpers__WEBPACK_IMPORTED_MODULE_3__.getExporterEndpoint)(options.exporterEndpoint),
@@ -25463,7 +25464,7 @@ class TracerBrowserSDK {
25463
25464
  if (!this.tracerProvider) {
25464
25465
  throw new Error('Configuration not initialized. Call init() before start().');
25465
25466
  }
25466
- this.setSessionId('');
25467
+ this.setSessionId('', _multiplayer_app_session_recorder_common__WEBPACK_IMPORTED_MODULE_1__.SessionType.SESSION_CACHE);
25467
25468
  }
25468
25469
  setApiKey(apiKey) {
25469
25470
  if (!this.exporter) {
@@ -27912,13 +27913,11 @@ class SessionRecorder extends lib0_observable__WEBPACK_IMPORTED_MODULE_16__.Obse
27912
27913
  }, 5000);
27913
27914
  });
27914
27915
  this._socketService.on(_config__WEBPACK_IMPORTED_MODULE_5__.REMOTE_SESSION_RECORDING_START, (payload) => {
27915
- console.log('REMOTE_SESSION_RECORDING_START', payload);
27916
27916
  if (this.sessionState === _types__WEBPACK_IMPORTED_MODULE_4__.SessionState.stopped) {
27917
27917
  this.start();
27918
27918
  }
27919
27919
  });
27920
27920
  this._socketService.on(_config__WEBPACK_IMPORTED_MODULE_5__.REMOTE_SESSION_RECORDING_STOP, (payload) => {
27921
- console.log('REMOTE_SESSION_RECORDING_STOP', payload);
27922
27921
  if (this.sessionState !== _types__WEBPACK_IMPORTED_MODULE_4__.SessionState.stopped) {
27923
27922
  this.stop();
27924
27923
  }
@@ -30201,7 +30200,9 @@ var SessionRecorderIdGenerator = /** @class */ (function () {
30201
30200
  }
30202
30201
  SessionRecorderIdGenerator.prototype.generateTraceId = function () {
30203
30202
  var traceId = this.generateLongId();
30204
- if (!this.sessionShortId && !this.sessionType) {
30203
+ if (!this.sessionShortId
30204
+ && !this.sessionType
30205
+ && !this.clientId) {
30205
30206
  return traceId;
30206
30207
  }
30207
30208
  var sessionTypePrefix = _constants_constants_base__WEBPACK_IMPORTED_MODULE_2__.MULTIPLAYER_TRACE_PREFIX_MAP[this.sessionType];