aparavi-client 1.0.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.
- package/LICENSE +21 -0
- package/README.md +523 -0
- package/dist/aparavi-client-typescript-1.0.0.tgz +0 -0
- package/dist/aparavi-client-typescript-1.0.1.tgz +0 -0
- package/dist/cjs/client.js +1002 -0
- package/dist/cjs/client.js.map +1 -0
- package/dist/cjs/constants.js +37 -0
- package/dist/cjs/constants.js.map +1 -0
- package/dist/cjs/core/DAPBase.js +313 -0
- package/dist/cjs/core/DAPBase.js.map +1 -0
- package/dist/cjs/core/DAPClient.js +173 -0
- package/dist/cjs/core/DAPClient.js.map +1 -0
- package/dist/cjs/core/TransportBase.js +131 -0
- package/dist/cjs/core/TransportBase.js.map +1 -0
- package/dist/cjs/core/TransportWebSocket.js +492 -0
- package/dist/cjs/core/TransportWebSocket.js.map +1 -0
- package/dist/cjs/exceptions/index.js +109 -0
- package/dist/cjs/exceptions/index.js.map +1 -0
- package/dist/cjs/index.js +56 -0
- package/dist/cjs/index.js.map +1 -0
- package/dist/cjs/package.json +3 -0
- package/dist/cjs/schema/Doc.js +79 -0
- package/dist/cjs/schema/Doc.js.map +1 -0
- package/dist/cjs/schema/DocFilter.js +133 -0
- package/dist/cjs/schema/DocFilter.js.map +1 -0
- package/dist/cjs/schema/DocGroup.js +235 -0
- package/dist/cjs/schema/DocGroup.js.map +1 -0
- package/dist/cjs/schema/DocMetadata.js +57 -0
- package/dist/cjs/schema/DocMetadata.js.map +1 -0
- package/dist/cjs/schema/Question.js +414 -0
- package/dist/cjs/schema/Question.js.map +1 -0
- package/dist/cjs/schema/index.js +50 -0
- package/dist/cjs/schema/index.js.map +1 -0
- package/dist/cjs/types/client.js +26 -0
- package/dist/cjs/types/client.js.map +1 -0
- package/dist/cjs/types/data.js +26 -0
- package/dist/cjs/types/data.js.map +1 -0
- package/dist/cjs/types/events.js +119 -0
- package/dist/cjs/types/events.js.map +1 -0
- package/dist/cjs/types/index.js +50 -0
- package/dist/cjs/types/index.js.map +1 -0
- package/dist/cjs/types/pipeline.js +26 -0
- package/dist/cjs/types/pipeline.js.map +1 -0
- package/dist/cjs/types/task.js +115 -0
- package/dist/cjs/types/task.js.map +1 -0
- package/dist/cli/cli/aparavi.js +1401 -0
- package/dist/cli/cli/aparavi.js.map +1 -0
- package/dist/cli/src/client.js +1002 -0
- package/dist/cli/src/client.js.map +1 -0
- package/dist/cli/src/constants.js +37 -0
- package/dist/cli/src/constants.js.map +1 -0
- package/dist/cli/src/core/DAPBase.js +313 -0
- package/dist/cli/src/core/DAPBase.js.map +1 -0
- package/dist/cli/src/core/DAPClient.js +173 -0
- package/dist/cli/src/core/DAPClient.js.map +1 -0
- package/dist/cli/src/core/TransportBase.js +131 -0
- package/dist/cli/src/core/TransportBase.js.map +1 -0
- package/dist/cli/src/core/TransportWebSocket.js +492 -0
- package/dist/cli/src/core/TransportWebSocket.js.map +1 -0
- package/dist/cli/src/exceptions/index.js +109 -0
- package/dist/cli/src/exceptions/index.js.map +1 -0
- package/dist/cli/src/index.js +56 -0
- package/dist/cli/src/index.js.map +1 -0
- package/dist/cli/src/schema/Doc.js +79 -0
- package/dist/cli/src/schema/Doc.js.map +1 -0
- package/dist/cli/src/schema/DocFilter.js +133 -0
- package/dist/cli/src/schema/DocFilter.js.map +1 -0
- package/dist/cli/src/schema/DocGroup.js +235 -0
- package/dist/cli/src/schema/DocGroup.js.map +1 -0
- package/dist/cli/src/schema/DocMetadata.js +57 -0
- package/dist/cli/src/schema/DocMetadata.js.map +1 -0
- package/dist/cli/src/schema/Question.js +414 -0
- package/dist/cli/src/schema/Question.js.map +1 -0
- package/dist/cli/src/schema/index.js +50 -0
- package/dist/cli/src/schema/index.js.map +1 -0
- package/dist/cli/src/types/client.js +26 -0
- package/dist/cli/src/types/client.js.map +1 -0
- package/dist/cli/src/types/data.js +26 -0
- package/dist/cli/src/types/data.js.map +1 -0
- package/dist/cli/src/types/events.js +119 -0
- package/dist/cli/src/types/events.js.map +1 -0
- package/dist/cli/src/types/index.js +50 -0
- package/dist/cli/src/types/index.js.map +1 -0
- package/dist/cli/src/types/pipeline.js +26 -0
- package/dist/cli/src/types/pipeline.js.map +1 -0
- package/dist/cli/src/types/task.js +115 -0
- package/dist/cli/src/types/task.js.map +1 -0
- package/dist/esm/client.js +997 -0
- package/dist/esm/client.js.map +1 -0
- package/dist/esm/constants.js +34 -0
- package/dist/esm/constants.js.map +1 -0
- package/dist/esm/core/DAPBase.js +309 -0
- package/dist/esm/core/DAPBase.js.map +1 -0
- package/dist/esm/core/DAPClient.js +169 -0
- package/dist/esm/core/DAPClient.js.map +1 -0
- package/dist/esm/core/TransportBase.js +127 -0
- package/dist/esm/core/TransportBase.js.map +1 -0
- package/dist/esm/core/TransportWebSocket.js +488 -0
- package/dist/esm/core/TransportWebSocket.js.map +1 -0
- package/dist/esm/exceptions/index.js +100 -0
- package/dist/esm/exceptions/index.js.map +1 -0
- package/dist/esm/index.js +40 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/package.json +3 -0
- package/dist/esm/schema/Doc.js +75 -0
- package/dist/esm/schema/Doc.js.map +1 -0
- package/dist/esm/schema/DocFilter.js +129 -0
- package/dist/esm/schema/DocFilter.js.map +1 -0
- package/dist/esm/schema/DocGroup.js +231 -0
- package/dist/esm/schema/DocGroup.js.map +1 -0
- package/dist/esm/schema/DocMetadata.js +53 -0
- package/dist/esm/schema/DocMetadata.js.map +1 -0
- package/dist/esm/schema/Question.js +409 -0
- package/dist/esm/schema/Question.js.map +1 -0
- package/dist/esm/schema/index.js +34 -0
- package/dist/esm/schema/index.js.map +1 -0
- package/dist/esm/types/client.js +25 -0
- package/dist/esm/types/client.js.map +1 -0
- package/dist/esm/types/data.js +25 -0
- package/dist/esm/types/data.js.map +1 -0
- package/dist/esm/types/events.js +116 -0
- package/dist/esm/types/events.js.map +1 -0
- package/dist/esm/types/index.js +34 -0
- package/dist/esm/types/index.js.map +1 -0
- package/dist/esm/types/pipeline.js +25 -0
- package/dist/esm/types/pipeline.js.map +1 -0
- package/dist/esm/types/task.js +112 -0
- package/dist/esm/types/task.js.map +1 -0
- package/dist/types/client.d.ts +395 -0
- package/dist/types/client.d.ts.map +1 -0
- package/dist/types/constants.d.ts +34 -0
- package/dist/types/constants.d.ts.map +1 -0
- package/dist/types/core/DAPBase.d.ts +140 -0
- package/dist/types/core/DAPBase.d.ts.map +1 -0
- package/dist/types/core/DAPClient.d.ts +83 -0
- package/dist/types/core/DAPClient.d.ts.map +1 -0
- package/dist/types/core/TransportBase.d.ts +94 -0
- package/dist/types/core/TransportBase.d.ts.map +1 -0
- package/dist/types/core/TransportWebSocket.d.ts +78 -0
- package/dist/types/core/TransportWebSocket.d.ts.map +1 -0
- package/dist/types/exceptions/index.d.ts +81 -0
- package/dist/types/exceptions/index.d.ts.map +1 -0
- package/dist/types/index.d.ts +36 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/schema/Doc.d.ts +69 -0
- package/dist/types/schema/Doc.d.ts.map +1 -0
- package/dist/types/schema/DocFilter.d.ts +101 -0
- package/dist/types/schema/DocFilter.d.ts.map +1 -0
- package/dist/types/schema/DocGroup.d.ts +113 -0
- package/dist/types/schema/DocGroup.d.ts.map +1 -0
- package/dist/types/schema/DocMetadata.d.ts +61 -0
- package/dist/types/schema/DocMetadata.d.ts.map +1 -0
- package/dist/types/schema/Question.d.ts +163 -0
- package/dist/types/schema/Question.d.ts.map +1 -0
- package/dist/types/schema/index.d.ts +34 -0
- package/dist/types/schema/index.d.ts.map +1 -0
- package/dist/types/types/client.d.ts +140 -0
- package/dist/types/types/client.d.ts.map +1 -0
- package/dist/types/types/data.d.ts +95 -0
- package/dist/types/types/data.d.ts.map +1 -0
- package/dist/types/types/events.d.ts +246 -0
- package/dist/types/types/events.d.ts.map +1 -0
- package/dist/types/types/index.d.ts +34 -0
- package/dist/types/types/index.d.ts.map +1 -0
- package/dist/types/types/pipeline.d.ts +61 -0
- package/dist/types/types/pipeline.d.ts.map +1 -0
- package/dist/types/types/task.d.ts +265 -0
- package/dist/types/types/task.d.ts.map +1 -0
- package/package.json +75 -0
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* MIT License
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) 2024 Aparavi Development Team
|
|
6
|
+
*
|
|
7
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
8
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
9
|
+
* in the Software without restriction, including without limitation the rights
|
|
10
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
11
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
12
|
+
* furnished to do so, subject to the following conditions:
|
|
13
|
+
*
|
|
14
|
+
* The above copyright notice and this permission notice shall be included in all
|
|
15
|
+
* copies or substantial portions of the Software.
|
|
16
|
+
*
|
|
17
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
18
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
19
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
20
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
21
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
22
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
23
|
+
* SOFTWARE.
|
|
24
|
+
*/
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.EVENT_TYPE = void 0;
|
|
27
|
+
/**
|
|
28
|
+
* Event type enumeration for sophisticated client subscription and event routing.
|
|
29
|
+
*
|
|
30
|
+
* This enumeration defines event categories used for intelligent event filtering
|
|
31
|
+
* and routing in multi-client environments. It enables clients to subscribe
|
|
32
|
+
* to specific types of events based on their needs and capabilities, reducing
|
|
33
|
+
* network traffic and improving system performance.
|
|
34
|
+
*
|
|
35
|
+
* Event Categories:
|
|
36
|
+
* ----------------
|
|
37
|
+
* NONE: Unsubscribe from all events (cleanup and disconnection)
|
|
38
|
+
* ALL: Subscribe to all events regardless of category (comprehensive monitoring)
|
|
39
|
+
* DEBUGGER: Debug-specific events for debugging protocol communication
|
|
40
|
+
* DETAIL: Real-time processing events requiring immediate client attention
|
|
41
|
+
* SUMMARY: Periodic status summaries suitable for dashboard monitoring
|
|
42
|
+
* OUTPUT: Standard output and logging messages
|
|
43
|
+
* FLOW: Pipeline flow events - component execution tracking
|
|
44
|
+
* TASK: Task lifecycle events - start, stop, state changes
|
|
45
|
+
*
|
|
46
|
+
* Subscription Strategies:
|
|
47
|
+
* -----------------------
|
|
48
|
+
* NONE: Used during client disconnection to stop all event delivery
|
|
49
|
+
* and perform cleanup of monitoring subscriptions.
|
|
50
|
+
*
|
|
51
|
+
* ALL: Comprehensive monitoring for administrative clients that need
|
|
52
|
+
* complete visibility into task execution and debugging activities.
|
|
53
|
+
*
|
|
54
|
+
* DEBUGGER: Debug protocol events including breakpoint hits, variable
|
|
55
|
+
* changes, stack traces, and debugging session management.
|
|
56
|
+
*
|
|
57
|
+
* DETAIL: Real-time processing events including object processing updates,
|
|
58
|
+
* error/warning messages, metrics updates, and immediate status
|
|
59
|
+
* changes requiring client response or display updates.
|
|
60
|
+
*
|
|
61
|
+
* SUMMARY: Periodic status summaries sent at CONST_STATUS_UPDATE_FREQ
|
|
62
|
+
* intervals containing complete task status, suitable for
|
|
63
|
+
* monitoring dashboards and periodic client updates.
|
|
64
|
+
*
|
|
65
|
+
* OUTPUT: Standard output and logging messages from task execution.
|
|
66
|
+
*
|
|
67
|
+
* FLOW: Pipeline flow events tracking component execution, data flow
|
|
68
|
+
* between pipeline stages, and processing pipeline status.
|
|
69
|
+
*
|
|
70
|
+
* TASK: Task lifecycle events including task start, stop, pause, resume,
|
|
71
|
+
* and state changes for task management interfaces.
|
|
72
|
+
*
|
|
73
|
+
* Network Optimization:
|
|
74
|
+
* --------------------
|
|
75
|
+
* Event filtering reduces network traffic by sending only relevant events
|
|
76
|
+
* to interested clients. SUMMARY subscriptions receive consolidated status
|
|
77
|
+
* updates rather than individual processing events, significantly reducing
|
|
78
|
+
* bandwidth usage for monitoring applications.
|
|
79
|
+
*
|
|
80
|
+
* Multi-Client Support:
|
|
81
|
+
* --------------------
|
|
82
|
+
* Different clients can subscribe to different event types simultaneously:
|
|
83
|
+
* - Debugging clients: DEBUGGER + DETAIL for comprehensive debugging
|
|
84
|
+
* - Monitoring dashboards: SUMMARY for efficient status tracking
|
|
85
|
+
* - Administrative tools: ALL for complete system visibility
|
|
86
|
+
* - Log viewers: OUTPUT for message monitoring
|
|
87
|
+
* - Pipeline managers: FLOW + TASK for execution tracking
|
|
88
|
+
*
|
|
89
|
+
* @example
|
|
90
|
+
* ```typescript
|
|
91
|
+
* // Subscribe to debugging and detail events
|
|
92
|
+
* const subscription = EVENT_TYPE.DEBUGGER | EVENT_TYPE.DETAIL;
|
|
93
|
+
*
|
|
94
|
+
* // Check if client wants specific events
|
|
95
|
+
* if (clientSubscription & EVENT_TYPE.SUMMARY) {
|
|
96
|
+
* sendSummaryUpdate(client, taskStatus);
|
|
97
|
+
* }
|
|
98
|
+
* ```
|
|
99
|
+
*/
|
|
100
|
+
var EVENT_TYPE;
|
|
101
|
+
(function (EVENT_TYPE) {
|
|
102
|
+
/** No events - unsubscribe from all event types */
|
|
103
|
+
EVENT_TYPE[EVENT_TYPE["NONE"] = 0] = "NONE";
|
|
104
|
+
/** Debug protocol events - DAP and debugging-specific events like breakpoints, stack traces */
|
|
105
|
+
EVENT_TYPE[EVENT_TYPE["DEBUGGER"] = 1] = "DEBUGGER";
|
|
106
|
+
/** Real-time processing events - immediate updates for live monitoring */
|
|
107
|
+
EVENT_TYPE[EVENT_TYPE["DETAIL"] = 2] = "DETAIL";
|
|
108
|
+
/** Periodic status summaries - dashboard monitoring with reduced frequency */
|
|
109
|
+
EVENT_TYPE[EVENT_TYPE["SUMMARY"] = 4] = "SUMMARY";
|
|
110
|
+
/** Standard output and logging messages from task execution */
|
|
111
|
+
EVENT_TYPE[EVENT_TYPE["OUTPUT"] = 8] = "OUTPUT";
|
|
112
|
+
/** Pipeline flow events - component execution tracking and data flow visualization */
|
|
113
|
+
EVENT_TYPE[EVENT_TYPE["FLOW"] = 16] = "FLOW";
|
|
114
|
+
/** Task lifecycle events - start, stop, state changes, and task management */
|
|
115
|
+
EVENT_TYPE[EVENT_TYPE["TASK"] = 32] = "TASK";
|
|
116
|
+
/** Convenience combination - ALL events except NONE for comprehensive monitoring */
|
|
117
|
+
EVENT_TYPE[EVENT_TYPE["ALL"] = 63] = "ALL"; // Binary: 111111
|
|
118
|
+
})(EVENT_TYPE || (exports.EVENT_TYPE = EVENT_TYPE = {}));
|
|
119
|
+
//# sourceMappingURL=events.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.js","sourceRoot":"","sources":["../../../../aparavi-client/src/types/events.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;;;AAIH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwEG;AACH,IAAY,UAwBX;AAxBD,WAAY,UAAU;IACrB,mDAAmD;IACnD,2CAAQ,CAAA;IAER,+FAA+F;IAC/F,mDAAiB,CAAA;IAEjB,0EAA0E;IAC1E,+CAAe,CAAA;IAEf,8EAA8E;IAC9E,iDAAgB,CAAA;IAEhB,+DAA+D;IAC/D,+CAAe,CAAA;IAEf,sFAAsF;IACtF,4CAAa,CAAA;IAEb,8EAA8E;IAC9E,4CAAa,CAAA;IAEb,oFAAoF;IACpF,0CAAwD,CAAA,CAAC,iBAAiB;AAC3E,CAAC,EAxBW,UAAU,0BAAV,UAAU,QAwBrB"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* MIT License
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) 2024 Aparavi Development Team
|
|
6
|
+
*
|
|
7
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
8
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
9
|
+
* in the Software without restriction, including without limitation the rights
|
|
10
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
11
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
12
|
+
* furnished to do so, subject to the following conditions:
|
|
13
|
+
*
|
|
14
|
+
* The above copyright notice and this permission notice shall be included in all
|
|
15
|
+
* copies or substantial portions of the Software.
|
|
16
|
+
*
|
|
17
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
18
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
19
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
20
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
21
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
22
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
23
|
+
* SOFTWARE.
|
|
24
|
+
*/
|
|
25
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
26
|
+
if (k2 === undefined) k2 = k;
|
|
27
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
28
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
29
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
30
|
+
}
|
|
31
|
+
Object.defineProperty(o, k2, desc);
|
|
32
|
+
}) : (function(o, m, k, k2) {
|
|
33
|
+
if (k2 === undefined) k2 = k;
|
|
34
|
+
o[k2] = m[k];
|
|
35
|
+
}));
|
|
36
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
37
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
38
|
+
};
|
|
39
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
|
+
/**
|
|
41
|
+
* Type definitions for the Aparavi TypeScript SDK.
|
|
42
|
+
*
|
|
43
|
+
* Re-exports all type definitions from individual modules for convenient imports.
|
|
44
|
+
*/
|
|
45
|
+
__exportStar(require("./client"), exports);
|
|
46
|
+
__exportStar(require("./data"), exports);
|
|
47
|
+
__exportStar(require("./events"), exports);
|
|
48
|
+
__exportStar(require("./pipeline"), exports);
|
|
49
|
+
__exportStar(require("./task"), exports);
|
|
50
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../aparavi-client/src/types/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;;;;;;;;;;;;;;;;AAEH;;;;GAIG;AAEH,2CAAyB;AACzB,yCAAuB;AACvB,2CAAyB;AACzB,6CAA2B;AAC3B,yCAAuB"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* MIT License
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) 2024 Aparavi Development Team
|
|
6
|
+
*
|
|
7
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
8
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
9
|
+
* in the Software without restriction, including without limitation the rights
|
|
10
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
11
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
12
|
+
* furnished to do so, subject to the following conditions:
|
|
13
|
+
*
|
|
14
|
+
* The above copyright notice and this permission notice shall be included in all
|
|
15
|
+
* copies or substantial portions of the Software.
|
|
16
|
+
*
|
|
17
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
18
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
19
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
20
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
21
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
22
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
23
|
+
* SOFTWARE.
|
|
24
|
+
*/
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
//# sourceMappingURL=pipeline.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pipeline.js","sourceRoot":"","sources":["../../../../aparavi-client/src/types/pipeline.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG"}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* MIT License
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) 2024 Aparavi Development Team
|
|
6
|
+
*
|
|
7
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
8
|
+
* of this software and associated documentation files (the "Software"), to deal
|
|
9
|
+
* in the Software without restriction, including without limitation the rights
|
|
10
|
+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
11
|
+
* copies of the Software, and to permit persons to whom the Software is
|
|
12
|
+
* furnished to do so, subject to the following conditions:
|
|
13
|
+
*
|
|
14
|
+
* The above copyright notice and this permission notice shall be included in all
|
|
15
|
+
* copies or substantial portions of the Software.
|
|
16
|
+
*
|
|
17
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
18
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
19
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
20
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
21
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
22
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
23
|
+
* SOFTWARE.
|
|
24
|
+
*/
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.TASK_STATE = void 0;
|
|
27
|
+
/**
|
|
28
|
+
* Task Management Types: Comprehensive Status Tracking and Event Management System.
|
|
29
|
+
*
|
|
30
|
+
* This module defines the complete type system for sophisticated task lifecycle management,
|
|
31
|
+
* real-time status monitoring, and event-driven communication in distributed computational
|
|
32
|
+
* pipeline systems. It provides structured data models for tracking complex task execution
|
|
33
|
+
* states, processing statistics, error management, and pipeline flow visualization.
|
|
34
|
+
*/
|
|
35
|
+
/**
|
|
36
|
+
* Task lifecycle state enumeration for comprehensive state management.
|
|
37
|
+
*
|
|
38
|
+
* This enumeration defines all possible states in the task execution lifecycle,
|
|
39
|
+
* providing clear state transitions and enabling proper resource management,
|
|
40
|
+
* error handling, and client notification. Each state represents a distinct
|
|
41
|
+
* phase with specific characteristics and available operations.
|
|
42
|
+
*
|
|
43
|
+
* Lifecycle Phases:
|
|
44
|
+
* ----------------
|
|
45
|
+
* NONE: Initial state before any resources are allocated or configuration
|
|
46
|
+
* is processed. Tasks in this state can be safely discarded without
|
|
47
|
+
* cleanup operations.
|
|
48
|
+
*
|
|
49
|
+
* STARTING: Resource allocation and initial setup phase. Ports are allocated,
|
|
50
|
+
* temporary files created, and subprocess preparation occurs.
|
|
51
|
+
*
|
|
52
|
+
* INITIALIZING: Subprocess has been created and is performing pipeline
|
|
53
|
+
* initialization. Service interfaces are being established.
|
|
54
|
+
*
|
|
55
|
+
* RUNNING: Task is operational and processing requests. All interfaces
|
|
56
|
+
* are available and the pipeline is actively executing.
|
|
57
|
+
*
|
|
58
|
+
* STOPPING: Graceful shutdown initiated. Subprocess is being terminated
|
|
59
|
+
* and resources are being cleaned up.
|
|
60
|
+
*
|
|
61
|
+
* COMPLETED: Task finished successfully. All resources cleaned up and
|
|
62
|
+
* final status available for client queries.
|
|
63
|
+
*
|
|
64
|
+
* CANCELLED: Task was terminated before completion. Resources cleaned up
|
|
65
|
+
* and termination reason available in status.
|
|
66
|
+
*
|
|
67
|
+
* State Transitions:
|
|
68
|
+
* -----------------
|
|
69
|
+
* Normal execution flow:
|
|
70
|
+
* NONE → STARTING → INITIALIZING → RUNNING → STOPPING → COMPLETED
|
|
71
|
+
*
|
|
72
|
+
* Cancellation flow:
|
|
73
|
+
* Any state → STOPPING → CANCELLED
|
|
74
|
+
*
|
|
75
|
+
* Error handling:
|
|
76
|
+
* Any state → STOPPING → COMPLETED (with error exit code)
|
|
77
|
+
*
|
|
78
|
+
* Resource Management:
|
|
79
|
+
* -------------------
|
|
80
|
+
* - NONE/COMPLETED/CANCELLED: No active resources requiring cleanup
|
|
81
|
+
* - STARTING/INITIALIZING/RUNNING: Active resources requiring cleanup
|
|
82
|
+
* - STOPPING: Cleanup in progress, resources being deallocated
|
|
83
|
+
*
|
|
84
|
+
* Client Operations:
|
|
85
|
+
* -----------------
|
|
86
|
+
* - NONE: Configuration and launch operations available
|
|
87
|
+
* - STARTING/INITIALIZING: Status monitoring available
|
|
88
|
+
* - RUNNING: Full debugging and data processing operations available
|
|
89
|
+
* - STOPPING: Limited status monitoring, operations being rejected
|
|
90
|
+
* - COMPLETED/CANCELLED: Status queries only, task cleanup may be initiated
|
|
91
|
+
*
|
|
92
|
+
* Wait Operations:
|
|
93
|
+
* ---------------
|
|
94
|
+
* Clients can wait for specific state transitions using wait_for_running()
|
|
95
|
+
* and similar methods. State transitions trigger event notifications to
|
|
96
|
+
* all subscribed monitoring clients.
|
|
97
|
+
*/
|
|
98
|
+
var TASK_STATE;
|
|
99
|
+
(function (TASK_STATE) {
|
|
100
|
+
/** Initial state - no resources allocated */
|
|
101
|
+
TASK_STATE[TASK_STATE["NONE"] = 0] = "NONE";
|
|
102
|
+
/** Resource allocation and subprocess preparation */
|
|
103
|
+
TASK_STATE[TASK_STATE["STARTING"] = 1] = "STARTING";
|
|
104
|
+
/** Subprocess initialization and service startup */
|
|
105
|
+
TASK_STATE[TASK_STATE["INITIALIZING"] = 2] = "INITIALIZING";
|
|
106
|
+
/** Operational state - processing requests */
|
|
107
|
+
TASK_STATE[TASK_STATE["RUNNING"] = 3] = "RUNNING";
|
|
108
|
+
/** Graceful shutdown and resource cleanup in progress */
|
|
109
|
+
TASK_STATE[TASK_STATE["STOPPING"] = 4] = "STOPPING";
|
|
110
|
+
/** Successful completion - resources cleaned up */
|
|
111
|
+
TASK_STATE[TASK_STATE["COMPLETED"] = 5] = "COMPLETED";
|
|
112
|
+
/** Terminated before completion - resources cleaned up */
|
|
113
|
+
TASK_STATE[TASK_STATE["CANCELLED"] = 6] = "CANCELLED";
|
|
114
|
+
})(TASK_STATE || (exports.TASK_STATE = TASK_STATE = {}));
|
|
115
|
+
//# sourceMappingURL=task.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"task.js","sourceRoot":"","sources":["../../../../aparavi-client/src/types/task.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;;;AAEH;;;;;;;GAOG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8DG;AACH,IAAY,UAqBX;AArBD,WAAY,UAAU;IACrB,6CAA6C;IAC7C,2CAAQ,CAAA;IAER,qDAAqD;IACrD,mDAAY,CAAA;IAEZ,oDAAoD;IACpD,2DAAgB,CAAA;IAEhB,8CAA8C;IAC9C,iDAAW,CAAA;IAEX,yDAAyD;IACzD,mDAAY,CAAA;IAEZ,mDAAmD;IACnD,qDAAa,CAAA;IAEb,0DAA0D;IAC1D,qDAAa,CAAA;AACd,CAAC,EArBW,UAAU,0BAAV,UAAU,QAqBrB"}
|