@sasjs/api 0.17.3 → 0.17.4

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/build/browser.js CHANGED
@@ -1,4 +1,4 @@
1
- /* @sasjs/api 0.17.3 - the SASjs Server API, for a service worker. https://github.com/sasjs/api */
1
+ /* @sasjs/api 0.17.4 - the SASjs Server API, for a service worker. https://github.com/sasjs/api */
2
2
  "use strict";
3
3
  var SASjsApi = (() => {
4
4
  var __defProp = Object.defineProperty;
@@ -5276,13 +5276,17 @@ var SASjsApi = (() => {
5276
5276
  route: "GET /SASjsApi/session/{sessionId}",
5277
5277
  description: "answers an administrator another account's session",
5278
5278
  request: { subject: ADMIN, params: { sessionId: "sess-restricted" } },
5279
+ // both stamps: the document requires them, and this host stamps a session's
5280
+ // death time at creation rather than at completion - a running session
5281
+ // answers with the moment it is due to be destroyed
5279
5282
  expect: {
5280
5283
  status: 200,
5281
5284
  body: {
5282
5285
  sessionId: "sess-restricted",
5283
5286
  state: "running",
5284
5287
  pid: 4243,
5285
- creationTimeStamp: "2026-11-07T09:05:00.000Z"
5288
+ creationTimeStamp: "2026-11-07T09:05:00.000Z",
5289
+ deathTimeStamp: "2026-11-07T09:20:00.000Z"
5286
5290
  }
5287
5291
  }
5288
5292
  },
@@ -5448,7 +5452,13 @@ var SASjsApi = (() => {
5448
5452
  sessionId: "sess-restricted",
5449
5453
  state: "running",
5450
5454
  pid: 4243,
5451
- creationTimeStamp: "2026-11-07T09:05:00.000Z"
5455
+ creationTimeStamp: "2026-11-07T09:05:00.000Z",
5456
+ // the document makes both stamps required, and a real session carries
5457
+ // the death stamp from the moment it is created: sasjs/server writes
5458
+ // creation + its default lifetime, which is what a poller reads to know
5459
+ // when the folder will be gone. A running session without one is a shape
5460
+ // no host produces.
5461
+ deathTimeStamp: "2026-11-07T09:20:00.000Z"
5452
5462
  }
5453
5463
  },
5454
5464
  "sess-silent": {
@@ -29,13 +29,17 @@ exports.SESSION_CORPUS = [
29
29
  route: 'GET /SASjsApi/session/{sessionId}',
30
30
  description: "answers an administrator another account's session",
31
31
  request: { subject: ADMIN, params: { sessionId: 'sess-restricted' } },
32
+ // both stamps: the document requires them, and this host stamps a session's
33
+ // death time at creation rather than at completion - a running session
34
+ // answers with the moment it is due to be destroyed
32
35
  expect: {
33
36
  status: 200,
34
37
  body: {
35
38
  sessionId: 'sess-restricted',
36
39
  state: 'running',
37
40
  pid: 4243,
38
- creationTimeStamp: '2026-11-07T09:05:00.000Z'
41
+ creationTimeStamp: '2026-11-07T09:05:00.000Z',
42
+ deathTimeStamp: '2026-11-07T09:20:00.000Z'
39
43
  }
40
44
  }
41
45
  },
@@ -27,7 +27,13 @@ exports.DEFAULT_SESSIONS = {
27
27
  sessionId: 'sess-restricted',
28
28
  state: 'running',
29
29
  pid: 4243,
30
- creationTimeStamp: '2026-11-07T09:05:00.000Z'
30
+ creationTimeStamp: '2026-11-07T09:05:00.000Z',
31
+ // the document makes both stamps required, and a real session carries
32
+ // the death stamp from the moment it is created: sasjs/server writes
33
+ // creation + its default lifetime, which is what a poller reads to know
34
+ // when the folder will be gone. A running session without one is a shape
35
+ // no host produces.
36
+ deathTimeStamp: '2026-11-07T09:20:00.000Z'
31
37
  }
32
38
  },
33
39
  'sess-silent': {
@@ -1 +1 @@
1
- {"version":3,"file":"session.d.ts","sourceRoot":"","sources":["../../../src/corpus/session.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AAQ5C,eAAO,MAAM,cAAc,EAAE,UAAU,EAwItC,CAAA"}
1
+ {"version":3,"file":"session.d.ts","sourceRoot":"","sources":["../../../src/corpus/session.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AAQ5C,eAAO,MAAM,cAAc,EAAE,UAAU,EA4ItC,CAAA"}
@@ -26,13 +26,17 @@ export const SESSION_CORPUS = [
26
26
  route: 'GET /SASjsApi/session/{sessionId}',
27
27
  description: "answers an administrator another account's session",
28
28
  request: { subject: ADMIN, params: { sessionId: 'sess-restricted' } },
29
+ // both stamps: the document requires them, and this host stamps a session's
30
+ // death time at creation rather than at completion - a running session
31
+ // answers with the moment it is due to be destroyed
29
32
  expect: {
30
33
  status: 200,
31
34
  body: {
32
35
  sessionId: 'sess-restricted',
33
36
  state: 'running',
34
37
  pid: 4243,
35
- creationTimeStamp: '2026-11-07T09:05:00.000Z'
38
+ creationTimeStamp: '2026-11-07T09:05:00.000Z',
39
+ deathTimeStamp: '2026-11-07T09:20:00.000Z'
36
40
  }
37
41
  }
38
42
  },
@@ -1 +1 @@
1
- {"version":3,"file":"memory-host.d.ts","sourceRoot":"","sources":["../../../src/session/memory-host.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,WAAW,EACX,eAAe,EACf,WAAW,EACX,oBAAoB,EACrB,MAAM,cAAc,CAAA;AAErB;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CA8BxD,CAAA;AAyBD;;;;;;;GAOG;AACH,qBAAa,iBAAkB,YAAW,WAAW;IAEjD,SAAS,CAAC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CAAC;IAGxD,SAAS,CAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAAC;IAG/D,SAAS,CAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAC/C,SAAS,CAAC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC;gBAPxC,QAAQ,GAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CAEtD,EACkB,MAAM,GAAE,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAE7D,EACkB,IAAI,GAAE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,eAAe,CAEzD;IAGG,OAAO,CAAC,EAAE,EAAE,MAAM;IAIlB,KAAK,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,oBAAoB,GAAG,SAAS,CAAC;IAI5D,GAAG,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC;IAI5C,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,GAAG,SAAS,CAAC;CAG/D"}
@@ -24,7 +24,13 @@ export const DEFAULT_SESSIONS = {
24
24
  sessionId: 'sess-restricted',
25
25
  state: 'running',
26
26
  pid: 4243,
27
- creationTimeStamp: '2026-11-07T09:05:00.000Z'
27
+ creationTimeStamp: '2026-11-07T09:05:00.000Z',
28
+ // the document makes both stamps required, and a real session carries
29
+ // the death stamp from the moment it is created: sasjs/server writes
30
+ // creation + its default lifetime, which is what a poller reads to know
31
+ // when the folder will be gone. A running session without one is a shape
32
+ // no host produces.
33
+ deathTimeStamp: '2026-11-07T09:20:00.000Z'
28
34
  }
29
35
  },
30
36
  'sess-silent': {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sasjs/api",
3
- "version": "0.17.3",
3
+ "version": "0.17.4",
4
4
  "description": "The SASjs Server API, described once - a generated route table, the services behind it, and the conformance corpus both hosts run",
5
5
  "license": "MIT",
6
6
  "author": "SASjs",