@sasjs/api 0.49.1 → 0.51.0
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/README.md +15 -0
- package/build/browser.js +453 -17
- package/build/cjs/viya/appSurface.js +241 -0
- package/build/cjs/viya/compute.js +127 -4
- package/build/cjs/viya/declared.js +107 -0
- package/build/cjs/viya/dispatch.js +3 -0
- package/build/cjs/viya/identity.js +191 -0
- package/build/cjs/viya/overlay.js +15 -6
- package/build/cjs/viya/service.js +3 -1
- package/build/esm/viya/appSurface.d.ts +51 -0
- package/build/esm/viya/appSurface.d.ts.map +1 -0
- package/build/esm/viya/appSurface.js +238 -0
- package/build/esm/viya/compute.d.ts.map +1 -1
- package/build/esm/viya/compute.js +128 -5
- package/build/esm/viya/declared.d.ts.map +1 -1
- package/build/esm/viya/declared.js +107 -0
- package/build/esm/viya/dispatch.d.ts.map +1 -1
- package/build/esm/viya/dispatch.js +4 -1
- package/build/esm/viya/identity.d.ts +34 -0
- package/build/esm/viya/identity.d.ts.map +1 -0
- package/build/esm/viya/identity.js +187 -0
- package/build/esm/viya/overlay.d.ts +1 -0
- package/build/esm/viya/overlay.d.ts.map +1 -1
- package/build/esm/viya/overlay.js +14 -5
- package/build/esm/viya/seed.d.ts +8 -4
- package/build/esm/viya/seed.d.ts.map +1 -1
- package/build/esm/viya/service.d.ts.map +1 -1
- package/build/esm/viya/service.js +3 -1
- package/build/esm/viya/sessions.d.ts +3 -1
- package/build/esm/viya/sessions.d.ts.map +1 -1
- package/package.json +4 -1
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.IDENTITY_HANDLERS = exports.requireRecords = void 0;
|
|
4
|
+
const types_js_1 = require("../types.js");
|
|
5
|
+
const ids_js_1 = require("./ids.js");
|
|
6
|
+
/** The port these handlers read, or the capability the host did not supply. */
|
|
7
|
+
const requireRecords = (services) => {
|
|
8
|
+
if (!services.records)
|
|
9
|
+
throw new types_js_1.ApiError(501, 'The emulated identity answers from the records service, which this host does not supply.');
|
|
10
|
+
return services.records;
|
|
11
|
+
};
|
|
12
|
+
exports.requireRecords = requireRecords;
|
|
13
|
+
/**
|
|
14
|
+
* The caller, from the subject a host resolved or from the token it forwarded.
|
|
15
|
+
*
|
|
16
|
+
* A host that already knows its caller passes `subject`; one that hands the
|
|
17
|
+
* emulator a bearer token (the server's Viya router does) gets the token read
|
|
18
|
+
* here, exactly as `GET /identities/users/@currentUser` reads it. Neither is
|
|
19
|
+
* optional in effect: an unauthenticated caller has no identity to answer about.
|
|
20
|
+
*/
|
|
21
|
+
const callerOf = async (services, request) => request.subject ?? (await services.identity?.authenticate(request.token));
|
|
22
|
+
/**
|
|
23
|
+
* The `{}` a membership or avatar read was addressed to, as a uid.
|
|
24
|
+
*
|
|
25
|
+
* `@currentUser` is where Viya puts the caller's own account, and a client asks
|
|
26
|
+
* for it by that spelling. It is resolved here rather than given its own row so
|
|
27
|
+
* the handler has one shape to answer.
|
|
28
|
+
*/
|
|
29
|
+
const userIdFrom = (segment, caller) => {
|
|
30
|
+
if (segment.toLowerCase() !== '@currentuser')
|
|
31
|
+
return segment;
|
|
32
|
+
const id = caller?.userId;
|
|
33
|
+
if (!id)
|
|
34
|
+
throw new types_js_1.ApiError(401, 'No caller is signed in.');
|
|
35
|
+
return id;
|
|
36
|
+
};
|
|
37
|
+
/** The paging fields every collection answer carries, as the captured ones do. */
|
|
38
|
+
const collection = (name, items, limit, uri, type) => {
|
|
39
|
+
const page = limit > 0 ? items.slice(0, limit) : items;
|
|
40
|
+
return {
|
|
41
|
+
accept: 'application/json',
|
|
42
|
+
name,
|
|
43
|
+
start: 0,
|
|
44
|
+
// the value asked for is echoed, as the folder answers echo it: a caller
|
|
45
|
+
// that asked for five and is told zero cannot tell what happened
|
|
46
|
+
limit: limit || page.length,
|
|
47
|
+
count: page.length,
|
|
48
|
+
version: 2,
|
|
49
|
+
items: page,
|
|
50
|
+
links: [
|
|
51
|
+
{
|
|
52
|
+
href: uri,
|
|
53
|
+
uri,
|
|
54
|
+
rel: 'self',
|
|
55
|
+
method: 'GET',
|
|
56
|
+
type: 'application/vnd.sas.collection',
|
|
57
|
+
itemType: type
|
|
58
|
+
}
|
|
59
|
+
]
|
|
60
|
+
};
|
|
61
|
+
};
|
|
62
|
+
const identityLinks = (uri, type) => [
|
|
63
|
+
{ href: uri, uri, rel: 'self', method: 'GET', type }
|
|
64
|
+
];
|
|
65
|
+
const GROUP_TYPE = 'application/vnd.sas.identity.group';
|
|
66
|
+
const USER_TYPE = 'application/vnd.sas.identity.user';
|
|
67
|
+
/** A group as Viya represents one, from the store's record. */
|
|
68
|
+
const groupBody = (group, memberCount) => ({
|
|
69
|
+
id: group.uid,
|
|
70
|
+
name: group.name,
|
|
71
|
+
description: group.description,
|
|
72
|
+
providerId: 'sas',
|
|
73
|
+
state: 'active',
|
|
74
|
+
memberCount,
|
|
75
|
+
creationTimeStamp: ids_js_1.EMULATED_NOW,
|
|
76
|
+
modifiedTimeStamp: ids_js_1.EMULATED_NOW,
|
|
77
|
+
version: 1,
|
|
78
|
+
links: identityLinks(`/identities/groups/${group.uid}`, GROUP_TYPE)
|
|
79
|
+
});
|
|
80
|
+
/** A user as Viya represents one. */
|
|
81
|
+
const userBody = (user) => ({
|
|
82
|
+
id: user.uid,
|
|
83
|
+
// Viya's `name` is the identifier a person signs in with; the display name is
|
|
84
|
+
// a separate field, and this is the one a member list shows
|
|
85
|
+
name: user.username,
|
|
86
|
+
displayName: user.displayName,
|
|
87
|
+
providerId: 'sas',
|
|
88
|
+
state: 'active',
|
|
89
|
+
version: 1,
|
|
90
|
+
links: identityLinks(`/identities/users/${user.uid}`, USER_TYPE)
|
|
91
|
+
});
|
|
92
|
+
/** The groups a user is a member of, as Viya's memberships route answers them. */
|
|
93
|
+
const membershipsOf = async (records, caller, uid) => {
|
|
94
|
+
const users = await records.listUsers(caller);
|
|
95
|
+
// Viya clients may address a user by login name; prefer an exact uid when a
|
|
96
|
+
// login happens to equal another user's uid.
|
|
97
|
+
const user = users.find((item) => item.uid === uid) ??
|
|
98
|
+
users.find((item) => item.username === uid);
|
|
99
|
+
const resolvedUid = user?.uid ?? uid;
|
|
100
|
+
const groups = await records.listGroups(caller);
|
|
101
|
+
const found = [];
|
|
102
|
+
for (const group of groups) {
|
|
103
|
+
const details = await records.getGroup(caller, { uid: group.uid });
|
|
104
|
+
if (details.users.some((member) => member.uid === resolvedUid))
|
|
105
|
+
found.push(groupBody(group, details.users.length));
|
|
106
|
+
}
|
|
107
|
+
return found;
|
|
108
|
+
};
|
|
109
|
+
exports.IDENTITY_HANDLERS = {
|
|
110
|
+
'GET /identities/groups': async ({ services, request }) => {
|
|
111
|
+
const records = (0, exports.requireRecords)(services);
|
|
112
|
+
const caller = await callerOf(services, request);
|
|
113
|
+
const limit = Number(request.query?.limit ?? 0) || 0;
|
|
114
|
+
const sortBy = request.query?.sortBy;
|
|
115
|
+
const groups = await records.listGroups(caller);
|
|
116
|
+
const items = [];
|
|
117
|
+
for (const group of groups) {
|
|
118
|
+
const details = await records.getGroup(caller, { uid: group.uid });
|
|
119
|
+
items.push(groupBody(group, details.users.length));
|
|
120
|
+
}
|
|
121
|
+
// `sortBy=name` is what the application asks for, and the store's order is
|
|
122
|
+
// not one: a screen that lists groups alphabetically asks the service for it
|
|
123
|
+
const ordered = sortBy && sortBy.toLowerCase() === 'name'
|
|
124
|
+
? [...items].sort((left, right) => left.name.localeCompare(right.name))
|
|
125
|
+
: items;
|
|
126
|
+
return {
|
|
127
|
+
status: 200,
|
|
128
|
+
body: collection('groups', ordered, limit, '/identities/groups', GROUP_TYPE)
|
|
129
|
+
};
|
|
130
|
+
},
|
|
131
|
+
'GET /identities/groups/{}/members': async ({ services, request, params }) => {
|
|
132
|
+
const records = (0, exports.requireRecords)(services);
|
|
133
|
+
const caller = await callerOf(services, request);
|
|
134
|
+
const limit = Number(request.query?.limit ?? 0) || 0;
|
|
135
|
+
const details = await records.getGroup(caller, { uid: params.id });
|
|
136
|
+
const items = details.users.map((user) => userBody(user));
|
|
137
|
+
return {
|
|
138
|
+
status: 200,
|
|
139
|
+
body: collection('members', items, limit, `/identities/groups/${details.uid}/members`, USER_TYPE)
|
|
140
|
+
};
|
|
141
|
+
},
|
|
142
|
+
'GET /identities/users': async ({ services, request }) => {
|
|
143
|
+
const records = (0, exports.requireRecords)(services);
|
|
144
|
+
const caller = await callerOf(services, request);
|
|
145
|
+
const limit = Number(request.query?.limit ?? 0) || 0;
|
|
146
|
+
const users = await records.listUsers(caller);
|
|
147
|
+
return {
|
|
148
|
+
status: 200,
|
|
149
|
+
body: collection('users', users.map((user) => userBody(user)), limit, '/identities/users', USER_TYPE)
|
|
150
|
+
};
|
|
151
|
+
},
|
|
152
|
+
'GET /identities/users/{}': async ({ services, request, params }) => {
|
|
153
|
+
const records = (0, exports.requireRecords)(services);
|
|
154
|
+
const caller = await callerOf(services, request);
|
|
155
|
+
const uid = userIdFrom(params.id, caller);
|
|
156
|
+
const user = await records.getUser(caller, { uid });
|
|
157
|
+
return { status: 200, body: userBody(user) };
|
|
158
|
+
},
|
|
159
|
+
'GET /identities/users/@currentUser/memberships': async ({ services, request }) => {
|
|
160
|
+
const records = (0, exports.requireRecords)(services);
|
|
161
|
+
const caller = await callerOf(services, request);
|
|
162
|
+
const limit = Number(request.query?.limit ?? 0) || 0;
|
|
163
|
+
const uid = userIdFrom('@currentUser', caller);
|
|
164
|
+
const items = await membershipsOf(records, caller, uid);
|
|
165
|
+
return {
|
|
166
|
+
status: 200,
|
|
167
|
+
body: collection('memberships', items, limit, '/identities/users/@currentUser/memberships', GROUP_TYPE)
|
|
168
|
+
};
|
|
169
|
+
},
|
|
170
|
+
'GET /identities/users/{}/memberships': async ({ services, request, params }) => {
|
|
171
|
+
const records = (0, exports.requireRecords)(services);
|
|
172
|
+
const caller = await callerOf(services, request);
|
|
173
|
+
const limit = Number(request.query?.limit ?? 0) || 0;
|
|
174
|
+
const uid = userIdFrom(params.id, caller);
|
|
175
|
+
// the address the client used is the address echoed back, as the other
|
|
176
|
+
// answers do: a client that followed a rel is never told about another one
|
|
177
|
+
const items = await membershipsOf(records, caller, uid);
|
|
178
|
+
return {
|
|
179
|
+
status: 200,
|
|
180
|
+
body: collection('memberships', items, limit, `/identities/users/${params.id}/memberships`, GROUP_TYPE)
|
|
181
|
+
};
|
|
182
|
+
},
|
|
183
|
+
'GET /identities/users/{}/avatar/content': async ({ services, request, params }) => {
|
|
184
|
+
const caller = await callerOf(services, request);
|
|
185
|
+
const uid = userIdFrom(params.id, caller);
|
|
186
|
+
// the estate's identity carries no avatar, and Viya answers a 404 for an
|
|
187
|
+
// account that has none - so a client's fallback image is what a real
|
|
188
|
+
// estate with none would show it
|
|
189
|
+
throw new types_js_1.ApiError(404, `No avatar is recorded for the user ${uid}.`);
|
|
190
|
+
}
|
|
191
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.assertOverlayEntries = exports.VIYA_OVERLAY = void 0;
|
|
3
|
+
exports.assertOverlayEntries = exports.VIYA_OVERLAY = exports.SESSION_VARIABLE_REFUSAL = void 0;
|
|
4
4
|
/**
|
|
5
5
|
* What this package answers of the Viya table, and what it declines.
|
|
6
6
|
*
|
|
@@ -32,6 +32,7 @@ const NEEDS_AUTH = 'The token endpoint is answered by the host that mounts the e
|
|
|
32
32
|
* what is missing and a client learning nothing.
|
|
33
33
|
*/
|
|
34
34
|
const NEEDS_JOBS = 'The emulator answers the compute and content families; the job definitions a deploy creates and the executions a run submits are not modelled yet.';
|
|
35
|
+
exports.SESSION_VARIABLE_REFUSAL = 'GET /compute/sessions/{}/variables/{} is not emulated. The emulator does not model session variables; the client reads these only to log the pid of a job it is about to submit (SYSJOBID), and any name it asks for is refused here rather than answered with a value the emulator did not run.';
|
|
35
36
|
exports.VIYA_OVERLAY = {
|
|
36
37
|
// answered here
|
|
37
38
|
'POST /folders/folders': { implemented: true },
|
|
@@ -41,13 +42,24 @@ exports.VIYA_OVERLAY = {
|
|
|
41
42
|
'GET /folders/folders/@item': { implemented: true },
|
|
42
43
|
'GET /folders/folders/@myRecycleBin': { implemented: true },
|
|
43
44
|
'GET /identities/users/@currentUser': { implemented: true },
|
|
45
|
+
// answered here: the application's own identity reads, declared rather than
|
|
46
|
+
// captured - see src/viya/appSurface.ts for the scope they belong to
|
|
47
|
+
'GET /identities/groups': { implemented: true },
|
|
48
|
+
'GET /identities/groups/{}/members': { implemented: true },
|
|
49
|
+
'GET /identities/users': { implemented: true },
|
|
50
|
+
'GET /identities/users/{}': { implemented: true },
|
|
51
|
+
'GET /identities/users/@currentUser/memberships': { implemented: true },
|
|
52
|
+
'GET /identities/users/{}/memberships': { implemented: true },
|
|
53
|
+
'GET /identities/users/{}/avatar/content': { implemented: true },
|
|
44
54
|
'GET /types/types': { implemented: true },
|
|
45
55
|
// answered here: compute
|
|
46
56
|
'GET /compute/contexts': { implemented: true },
|
|
57
|
+
'GET /compute/contexts/{}': { implemented: true },
|
|
47
58
|
'POST /compute/contexts/{}/sessions': { implemented: true },
|
|
48
59
|
'DELETE /compute/sessions/{}': { implemented: true },
|
|
49
60
|
'POST /compute/sessions/{}/jobs': { implemented: true },
|
|
50
61
|
'GET /compute/sessions/{}/jobs/{}': { implemented: true },
|
|
62
|
+
'GET /compute/sessions/{}/jobs/{}/log': { implemented: true },
|
|
51
63
|
'GET /compute/sessions/{}/jobs/{}/log/content': { implemented: true },
|
|
52
64
|
'GET /compute/sessions/{}/jobs/{}/state': { implemented: true },
|
|
53
65
|
'GET /compute/sessions/{}/state': { implemented: true },
|
|
@@ -78,11 +90,8 @@ exports.VIYA_OVERLAY = {
|
|
|
78
90
|
implemented: false,
|
|
79
91
|
reason: 'The emulator answers compute contexts from its seed; the launcher list a client falls back to is not modelled, and nothing on the emulated path asks for it.'
|
|
80
92
|
},
|
|
81
|
-
//
|
|
82
|
-
'GET /compute/sessions/{}/variables/{}': {
|
|
83
|
-
implemented: false,
|
|
84
|
-
reason: 'The emulator does not model session variables; the client reads these only to log the pid of a job it is about to submit (SYSJOBID), and any name it asks for is refused here rather than answered with a value the emulator did not run.'
|
|
85
|
-
},
|
|
93
|
+
// Default refusal, with an explicit host opt-in for a synthetic SYSJOBID.
|
|
94
|
+
'GET /compute/sessions/{}/variables/{}': { implemented: true },
|
|
86
95
|
// declined: the host owns the token port
|
|
87
96
|
'POST /SASLogon/oauth/token': { implemented: false, reason: NEEDS_AUTH },
|
|
88
97
|
// declared, not captured: the webout an application's service returns
|
|
@@ -5,6 +5,7 @@ const types_js_1 = require("../types.js");
|
|
|
5
5
|
const ports_js_1 = require("./ports.js");
|
|
6
6
|
const compute_js_1 = require("./compute.js");
|
|
7
7
|
const files_js_1 = require("./files.js");
|
|
8
|
+
const identity_js_1 = require("./identity.js");
|
|
8
9
|
const ids_js_1 = require("./ids.js");
|
|
9
10
|
const linksFor = (uri, collection = false) => {
|
|
10
11
|
const self = {
|
|
@@ -339,5 +340,6 @@ exports.VIYA_HANDLERS = {
|
|
|
339
340
|
};
|
|
340
341
|
},
|
|
341
342
|
...compute_js_1.COMPUTE_HANDLERS,
|
|
342
|
-
...files_js_1.FILE_HANDLERS
|
|
343
|
+
...files_js_1.FILE_HANDLERS,
|
|
344
|
+
...identity_js_1.IDENTITY_HANDLERS
|
|
343
345
|
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The application's call surface, and what this package decides about each entry.
|
|
3
|
+
*
|
|
4
|
+
* `src/viya/surface.ts` is the adapter's surface: what `@sasjs/adapter` measured
|
|
5
|
+
* to build. It is not the whole story, because an application can call the
|
|
6
|
+
* platform itself. Data Controller does exactly that - its group, user and deploy
|
|
7
|
+
* screens speak Viya REST directly for the calls the adapter does not offer -
|
|
8
|
+
* and the emulator answered those paths with the 404 that says "the emulated
|
|
9
|
+
* estate answers the client's call surface and nothing else". A capture pass
|
|
10
|
+
* driven by the adapter can never see them, so they were outside a scope that
|
|
11
|
+
* was measured from the adapter alone, and the screens they carry were dead on
|
|
12
|
+
* an emulated estate.
|
|
13
|
+
*
|
|
14
|
+
* This file is the second measurement. `spec/viya/app-paths.json` is what Data
|
|
15
|
+
* Controller's client was measured to build (`scripts/viya-app-scope.mjs` re-runs
|
|
16
|
+
* the extraction from a checkout), and every path in it is classified here. The
|
|
17
|
+
* two are held together in both directions, the way the adapter's inventory and
|
|
18
|
+
* `surface.ts` are: a path nobody classified is scope creep nobody chose, and a
|
|
19
|
+
* classification for a path the application no longer builds is a stale claim
|
|
20
|
+
* about what a host has to answer.
|
|
21
|
+
*
|
|
22
|
+
* `decision: 'in'` means a host must answer it. That is a promise the table keeps
|
|
23
|
+
* - `spec/viyaTable.spec.ts` refuses an answered operation no in-scope entry
|
|
24
|
+
* covers - so an `in` entry with no operation is a gap the table spec does not
|
|
25
|
+
* catch. Read the two together: `src/viya/declared.ts` is where an `in` path
|
|
26
|
+
* becomes an operation.
|
|
27
|
+
*/
|
|
28
|
+
import type { SurfaceFamily } from './surface.js';
|
|
29
|
+
export interface AppSurfaceEntry {
|
|
30
|
+
/** Where the application sends it; `{}` is one path segment. */
|
|
31
|
+
path: string;
|
|
32
|
+
family: SurfaceFamily;
|
|
33
|
+
decision: 'in' | 'declined';
|
|
34
|
+
/** What the emulator answers, or why it does not answer this at all. */
|
|
35
|
+
reason: string;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* The application the inventory was measured from.
|
|
39
|
+
*
|
|
40
|
+
* Named rather than assumed: the inventory describes one application's calls,
|
|
41
|
+
* and a second application running on an emulated estate is a second inventory -
|
|
42
|
+
* not an edit to this one, whose rows would then be a claim about a client
|
|
43
|
+
* nobody measured.
|
|
44
|
+
*/
|
|
45
|
+
export declare const APP_SURFACE_APPLICATION: {
|
|
46
|
+
name: string;
|
|
47
|
+
repository: string;
|
|
48
|
+
measuredFrom: string;
|
|
49
|
+
};
|
|
50
|
+
export declare const APP_SURFACE: AppSurfaceEntry[];
|
|
51
|
+
//# sourceMappingURL=appSurface.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"appSurface.d.ts","sourceRoot":"","sources":["../../../src/viya/appSurface.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AAEjD,MAAM,WAAW,eAAe;IAC9B,gEAAgE;IAChE,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,EAAE,aAAa,CAAA;IACrB,QAAQ,EAAE,IAAI,GAAG,UAAU,CAAA;IAC3B,wEAAwE;IACxE,MAAM,EAAE,MAAM,CAAA;CACf;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,uBAAuB;;;;CAInC,CAAA;AAMD,eAAO,MAAM,WAAW,EAAE,eAAe,EAkPxC,CAAA"}
|
|
@@ -0,0 +1,238 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The application the inventory was measured from.
|
|
3
|
+
*
|
|
4
|
+
* Named rather than assumed: the inventory describes one application's calls,
|
|
5
|
+
* and a second application running on an emulated estate is a second inventory -
|
|
6
|
+
* not an edit to this one, whose rows would then be a claim about a client
|
|
7
|
+
* nobody measured.
|
|
8
|
+
*/
|
|
9
|
+
export const APP_SURFACE_APPLICATION = {
|
|
10
|
+
name: 'Data Controller for SAS',
|
|
11
|
+
repository: 'https://git.datacontroller.io/dc/dc',
|
|
12
|
+
measuredFrom: 'client/src'
|
|
13
|
+
};
|
|
14
|
+
/** Why a namespace the API-explorer page lists is not an answered operation. */
|
|
15
|
+
const EXPLORER_ONLY = 'The application names this namespace in its Viya API map, which its API-explorer page reads; no product screen calls it, so the emulated estate does not answer it.';
|
|
16
|
+
export const APP_SURFACE = [
|
|
17
|
+
// the auth flow the client shares with the adapter
|
|
18
|
+
{
|
|
19
|
+
path: '/SASLogon',
|
|
20
|
+
family: 'viya-auth',
|
|
21
|
+
decision: 'in',
|
|
22
|
+
reason: 'the auth flow, named by the application as well as the adapter, and the reason the emulated paths cannot be renamed'
|
|
23
|
+
},
|
|
24
|
+
// compute: the list, and the read of one context a deploy screen makes
|
|
25
|
+
{
|
|
26
|
+
path: '/compute/contexts',
|
|
27
|
+
family: 'viya-compute',
|
|
28
|
+
decision: 'in',
|
|
29
|
+
reason: 'the deploy screen lists the contexts it may run a session in, and picks the one the wizard will use'
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
path: '/compute/contexts/{}',
|
|
33
|
+
family: 'viya-compute',
|
|
34
|
+
decision: 'in',
|
|
35
|
+
reason: 'the deploy screen reads each context in full for its batch identity and reuse setting, which the list view does not carry'
|
|
36
|
+
},
|
|
37
|
+
// folders: the two reads an application makes of a deployment folder
|
|
38
|
+
{
|
|
39
|
+
path: '/folders/folders/@item',
|
|
40
|
+
family: 'viya-folders',
|
|
41
|
+
decision: 'in',
|
|
42
|
+
reason: 'the application resolves its own appLoc by path to find the services it will run'
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
path: '/folders/folders/{}/members',
|
|
46
|
+
family: 'viya-folders',
|
|
47
|
+
decision: 'in',
|
|
48
|
+
reason: 'the application lists the members of the folder it resolved, to find a deployed service'
|
|
49
|
+
},
|
|
50
|
+
// identities: the family the adapter asks one question of and an app asks six
|
|
51
|
+
{
|
|
52
|
+
path: '/identities/groups',
|
|
53
|
+
family: 'viya-identity',
|
|
54
|
+
decision: 'in',
|
|
55
|
+
reason: 'the deploy screen fetches the group list to offer the admin-group dropdown, and its failure aborts the wizard'
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
path: '/identities/groups/{}',
|
|
59
|
+
family: 'viya-identity',
|
|
60
|
+
decision: 'in',
|
|
61
|
+
reason: 'the group screen appends the group id and a member list to this fragment, to show who holds a group'
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
path: '/identities/users',
|
|
65
|
+
family: 'viya-identity',
|
|
66
|
+
decision: 'in',
|
|
67
|
+
reason: 'the user screen lists the accounts the estate holds'
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
path: '/identities/users/@currentUser',
|
|
71
|
+
family: 'viya-identity',
|
|
72
|
+
decision: 'in',
|
|
73
|
+
reason: 'the caller, which the application reads for its own profile as the adapter does'
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
path: '/identities/users/@currentUser/memberships',
|
|
77
|
+
family: 'viya-identity',
|
|
78
|
+
decision: 'in',
|
|
79
|
+
reason: 'the deploy screen filters the group list to the caller own groups, and falls back to all groups when this read fails'
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
path: '/identities/users/{}',
|
|
83
|
+
family: 'viya-identity',
|
|
84
|
+
decision: 'in',
|
|
85
|
+
reason: 'the user screen appends an account id to this fragment for a profile and its memberships'
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
path: '/identities/users/{}/avatar/content',
|
|
89
|
+
family: 'viya-identity',
|
|
90
|
+
decision: 'in',
|
|
91
|
+
reason: 'the header renders the caller avatar from this URL, and an account with none answers the 404 an estate would'
|
|
92
|
+
},
|
|
93
|
+
// the API roots and the explorer-only namespaces: named, never called
|
|
94
|
+
{
|
|
95
|
+
path: '/identities',
|
|
96
|
+
family: 'viya-identity',
|
|
97
|
+
decision: 'declined',
|
|
98
|
+
reason: 'the service root the application API map lists for its explorer page, not an endpoint any screen calls'
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
path: '/folders',
|
|
102
|
+
family: 'viya-folders',
|
|
103
|
+
decision: 'declined',
|
|
104
|
+
reason: 'the service root the application API map lists for its explorer page, not an endpoint any screen calls'
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
path: '/files',
|
|
108
|
+
family: 'viya-files',
|
|
109
|
+
decision: 'declined',
|
|
110
|
+
reason: 'the service root the application API map lists for its explorer page, not an endpoint any screen calls'
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
path: '/jobDefinitions',
|
|
114
|
+
family: 'viya-jobs',
|
|
115
|
+
decision: 'declined',
|
|
116
|
+
reason: 'the service root the application API map lists for its explorer page, not an endpoint any screen calls'
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
path: '/jobExecution',
|
|
120
|
+
family: 'viya-jobs',
|
|
121
|
+
decision: 'declined',
|
|
122
|
+
reason: 'the service root the application API map lists for its explorer page, not an endpoint any screen calls'
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
path: '/annotations',
|
|
126
|
+
family: 'viya-files',
|
|
127
|
+
decision: 'declined',
|
|
128
|
+
reason: EXPLORER_ONLY
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
path: '/authorization',
|
|
132
|
+
family: 'viya-identity',
|
|
133
|
+
decision: 'declined',
|
|
134
|
+
reason: EXPLORER_ONLY
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
path: '/businessRules',
|
|
138
|
+
family: 'viya-jobs',
|
|
139
|
+
decision: 'declined',
|
|
140
|
+
reason: EXPLORER_ONLY
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
path: '/dataMining',
|
|
144
|
+
family: 'viya-jobs',
|
|
145
|
+
decision: 'declined',
|
|
146
|
+
reason: EXPLORER_ONLY
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
path: '/decisionsRuntimeBuilder',
|
|
150
|
+
family: 'viya-jobs',
|
|
151
|
+
decision: 'declined',
|
|
152
|
+
reason: EXPLORER_ONLY
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
path: '/insights',
|
|
156
|
+
family: 'viya-jobs',
|
|
157
|
+
decision: 'declined',
|
|
158
|
+
reason: EXPLORER_ONLY
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
path: '/microanalyticScore',
|
|
162
|
+
family: 'viya-jobs',
|
|
163
|
+
decision: 'declined',
|
|
164
|
+
reason: EXPLORER_ONLY
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
path: '/mlPipelineAutomation',
|
|
168
|
+
family: 'viya-jobs',
|
|
169
|
+
decision: 'declined',
|
|
170
|
+
reason: EXPLORER_ONLY
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
path: '/modelManagement',
|
|
174
|
+
family: 'viya-jobs',
|
|
175
|
+
decision: 'declined',
|
|
176
|
+
reason: EXPLORER_ONLY
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
path: '/modelPublish',
|
|
180
|
+
family: 'viya-jobs',
|
|
181
|
+
decision: 'declined',
|
|
182
|
+
reason: EXPLORER_ONLY
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
path: '/modelRepository',
|
|
186
|
+
family: 'viya-jobs',
|
|
187
|
+
decision: 'declined',
|
|
188
|
+
reason: EXPLORER_ONLY
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
path: '/referenceData',
|
|
192
|
+
family: 'viya-jobs',
|
|
193
|
+
decision: 'declined',
|
|
194
|
+
reason: EXPLORER_ONLY
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
path: '/relationships',
|
|
198
|
+
family: 'viya-folders',
|
|
199
|
+
decision: 'declined',
|
|
200
|
+
reason: EXPLORER_ONLY
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
path: '/reportImages',
|
|
204
|
+
family: 'viya-jobs',
|
|
205
|
+
decision: 'declined',
|
|
206
|
+
reason: EXPLORER_ONLY
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
path: '/reportTransforms',
|
|
210
|
+
family: 'viya-jobs',
|
|
211
|
+
decision: 'declined',
|
|
212
|
+
reason: EXPLORER_ONLY
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
path: '/reports',
|
|
216
|
+
family: 'viya-jobs',
|
|
217
|
+
decision: 'declined',
|
|
218
|
+
reason: EXPLORER_ONLY
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
path: '/subjectContacts',
|
|
222
|
+
family: 'viya-jobs',
|
|
223
|
+
decision: 'declined',
|
|
224
|
+
reason: EXPLORER_ONLY
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
path: '/treatmentDefinitions',
|
|
228
|
+
family: 'viya-jobs',
|
|
229
|
+
decision: 'declined',
|
|
230
|
+
reason: EXPLORER_ONLY
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
path: '/visualAnalytics',
|
|
234
|
+
family: 'viya-jobs',
|
|
235
|
+
decision: 'declined',
|
|
236
|
+
reason: EXPLORER_ONLY
|
|
237
|
+
}
|
|
238
|
+
];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compute.d.ts","sourceRoot":"","sources":["../../../src/viya/compute.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAA;AAChE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;
|
|
1
|
+
{"version":3,"file":"compute.d.ts","sourceRoot":"","sources":["../../../src/viya/compute.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAA;AAChE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AAOnD;;;;;;;;;GASG;AACH,eAAO,MAAM,oBAAoB,sCAAsC,CAAA;AAEvE,2EAA2E;AAC3E,eAAO,MAAM,mBAAmB,QAAuC,CAAA;AAgDvE;;;;;;;GAOG;AACH,eAAO,MAAM,eAAe,GAAI,QAAQ,MAAM,GAAG,SAAS,KAAG,MAM5D,CAAA;AA0KD,eAAO,MAAM,gBAAgB,EAAE,MAAM,CACnC,MAAM,EACN,CAAC,OAAO,EAAE;IACR,QAAQ,EAAE,QAAQ,CAAA;IAClB,OAAO,EAAE;QACP,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAA;QAC1C,IAAI,CAAC,EAAE,OAAO,CAAA;QACd,KAAK,CAAC,EAAE,MAAM,CAAA;QACd,OAAO,CAAC,EAAE,OAAO,CAAA;KAClB,CAAA;IACD,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CAC/B,KAAK,OAAO,CAAC,WAAW,CAAC,CAwU3B,CAAA"}
|