@wenlarge/communication 1.1.6 → 1.1.7
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/generated/workflow.d.ts +29 -0
- package/dist/generated/workflow.js +2 -0
- package/dist/helpers/structToJson.d.ts +1 -0
- package/dist/helpers/structToJson.js +7 -0
- package/package.json +1 -1
- package/proto/executor-core.proto +1 -0
- package/proto/workflow.proto +25 -0
- package/src/generated/workflow.ts +42 -0
|
@@ -148,6 +148,31 @@ export interface UpdateWorkflowStatusRequest {
|
|
|
148
148
|
workflowId: string;
|
|
149
149
|
status: WorkflowStatus;
|
|
150
150
|
}
|
|
151
|
+
export interface GetNodeExecutionLogRequest {
|
|
152
|
+
nodeId: string;
|
|
153
|
+
workflowId: string;
|
|
154
|
+
}
|
|
155
|
+
export interface GetExecutionLogResponse {
|
|
156
|
+
logs: ExecutionLogEntry[];
|
|
157
|
+
}
|
|
158
|
+
export interface GetWorkflowExecutionLogRequest {
|
|
159
|
+
workflowId: string;
|
|
160
|
+
}
|
|
161
|
+
export interface ExecutionLogEntry {
|
|
162
|
+
nodeId: string;
|
|
163
|
+
status: string;
|
|
164
|
+
inputSchema?: {
|
|
165
|
+
[key: string]: any;
|
|
166
|
+
} | undefined;
|
|
167
|
+
outputSchema?: {
|
|
168
|
+
[key: string]: any;
|
|
169
|
+
} | undefined;
|
|
170
|
+
config?: {
|
|
171
|
+
[key: string]: any;
|
|
172
|
+
} | undefined;
|
|
173
|
+
startedAt: string;
|
|
174
|
+
finishedAt: string;
|
|
175
|
+
}
|
|
151
176
|
export declare const WORKFLOW_PACKAGE_NAME = "workflow";
|
|
152
177
|
export interface WorkflowServiceClient {
|
|
153
178
|
create(request: CreateWorkflowRequest, metadata?: Metadata): Observable<WorkflowResponse>;
|
|
@@ -165,6 +190,8 @@ export interface WorkflowServiceClient {
|
|
|
165
190
|
findWorkflowNodeTypes(request: Empty, metadata?: Metadata): Observable<FindManyWorkflowNodeTypeResponse>;
|
|
166
191
|
findConnections(request: FindConnectionsRequest, metadata?: Metadata): Observable<FindConnectionsResponse>;
|
|
167
192
|
updateWorkflowStatus(request: UpdateWorkflowStatusRequest, metadata?: Metadata): Observable<Empty>;
|
|
193
|
+
getNodeExecutionLog(request: GetNodeExecutionLogRequest, metadata?: Metadata): Observable<GetExecutionLogResponse>;
|
|
194
|
+
getWorkflowExecutionLog(request: GetWorkflowExecutionLogRequest, metadata?: Metadata): Observable<GetExecutionLogResponse>;
|
|
168
195
|
}
|
|
169
196
|
export interface WorkflowServiceController {
|
|
170
197
|
create(request: CreateWorkflowRequest, metadata?: Metadata): Promise<WorkflowResponse> | Observable<WorkflowResponse> | WorkflowResponse;
|
|
@@ -182,6 +209,8 @@ export interface WorkflowServiceController {
|
|
|
182
209
|
findWorkflowNodeTypes(request: Empty, metadata?: Metadata): Promise<FindManyWorkflowNodeTypeResponse> | Observable<FindManyWorkflowNodeTypeResponse> | FindManyWorkflowNodeTypeResponse;
|
|
183
210
|
findConnections(request: FindConnectionsRequest, metadata?: Metadata): Promise<FindConnectionsResponse> | Observable<FindConnectionsResponse> | FindConnectionsResponse;
|
|
184
211
|
updateWorkflowStatus(request: UpdateWorkflowStatusRequest, metadata?: Metadata): void;
|
|
212
|
+
getNodeExecutionLog(request: GetNodeExecutionLogRequest, metadata?: Metadata): Promise<GetExecutionLogResponse> | Observable<GetExecutionLogResponse> | GetExecutionLogResponse;
|
|
213
|
+
getWorkflowExecutionLog(request: GetWorkflowExecutionLogRequest, metadata?: Metadata): Promise<GetExecutionLogResponse> | Observable<GetExecutionLogResponse> | GetExecutionLogResponse;
|
|
185
214
|
}
|
|
186
215
|
export declare function WorkflowServiceControllerMethods(): (constructor: Function) => void;
|
|
187
216
|
export declare const WORKFLOW_SERVICE_NAME = "WorkflowService";
|
|
@@ -37,6 +37,8 @@ function WorkflowServiceControllerMethods() {
|
|
|
37
37
|
"findWorkflowNodeTypes",
|
|
38
38
|
"findConnections",
|
|
39
39
|
"updateWorkflowStatus",
|
|
40
|
+
"getNodeExecutionLog",
|
|
41
|
+
"getWorkflowExecutionLog",
|
|
40
42
|
];
|
|
41
43
|
for (const method of grpcMethods) {
|
|
42
44
|
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.unwrapStruct = unwrapStruct;
|
|
4
|
+
exports.wrapStruct = wrapStruct;
|
|
5
|
+
const struct_1 = require("../generated/google/protobuf/struct");
|
|
4
6
|
function unwrapStruct(fields) {
|
|
5
7
|
var _a, _b;
|
|
6
8
|
const result = {};
|
|
@@ -21,3 +23,8 @@ function unwrapStruct(fields) {
|
|
|
21
23
|
}
|
|
22
24
|
return result;
|
|
23
25
|
}
|
|
26
|
+
function wrapStruct(obj) {
|
|
27
|
+
if (!obj)
|
|
28
|
+
return undefined;
|
|
29
|
+
return struct_1.Struct.wrap(obj);
|
|
30
|
+
}
|
package/package.json
CHANGED
package/proto/workflow.proto
CHANGED
|
@@ -21,6 +21,8 @@ service WorkflowService {
|
|
|
21
21
|
rpc FindWorkflowNodeTypes (google.protobuf.Empty) returns (FindManyWorkflowNodeTypeResponse);
|
|
22
22
|
rpc FindConnections (FindConnectionsRequest) returns (FindConnectionsResponse);
|
|
23
23
|
rpc UpdateWorkflowStatus (UpdateWorkflowStatusRequest) returns (google.protobuf.Empty);
|
|
24
|
+
rpc GetNodeExecutionLog(GetNodeExecutionLogRequest) returns (GetExecutionLogResponse);
|
|
25
|
+
rpc GetWorkflowExecutionLog(GetWorkflowExecutionLogRequest) returns (GetExecutionLogResponse);
|
|
24
26
|
}
|
|
25
27
|
|
|
26
28
|
message CreateWorkflowRequest {
|
|
@@ -171,4 +173,27 @@ enum WorkflowStatus {
|
|
|
171
173
|
message UpdateWorkflowStatusRequest {
|
|
172
174
|
string workflowId = 1;
|
|
173
175
|
WorkflowStatus status = 2;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
message GetNodeExecutionLogRequest {
|
|
179
|
+
string nodeId = 1;
|
|
180
|
+
string workflowId =2;
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
message GetExecutionLogResponse {
|
|
184
|
+
repeated ExecutionLogEntry logs = 1;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
message GetWorkflowExecutionLogRequest{
|
|
188
|
+
string workflowId = 1;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
message ExecutionLogEntry {
|
|
192
|
+
string nodeId = 1;
|
|
193
|
+
string status = 2;
|
|
194
|
+
google.protobuf.Struct inputSchema = 3;
|
|
195
|
+
google.protobuf.Struct outputSchema = 4;
|
|
196
|
+
google.protobuf.Struct config = 5;
|
|
197
|
+
string startedAt = 6;
|
|
198
|
+
string finishedAt = 7;
|
|
174
199
|
}
|
|
@@ -165,6 +165,29 @@ export interface UpdateWorkflowStatusRequest {
|
|
|
165
165
|
status: WorkflowStatus;
|
|
166
166
|
}
|
|
167
167
|
|
|
168
|
+
export interface GetNodeExecutionLogRequest {
|
|
169
|
+
nodeId: string;
|
|
170
|
+
workflowId: string;
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
export interface GetExecutionLogResponse {
|
|
174
|
+
logs: ExecutionLogEntry[];
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export interface GetWorkflowExecutionLogRequest {
|
|
178
|
+
workflowId: string;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
export interface ExecutionLogEntry {
|
|
182
|
+
nodeId: string;
|
|
183
|
+
status: string;
|
|
184
|
+
inputSchema?: { [key: string]: any } | undefined;
|
|
185
|
+
outputSchema?: { [key: string]: any } | undefined;
|
|
186
|
+
config?: { [key: string]: any } | undefined;
|
|
187
|
+
startedAt: string;
|
|
188
|
+
finishedAt: string;
|
|
189
|
+
}
|
|
190
|
+
|
|
168
191
|
export const WORKFLOW_PACKAGE_NAME = "workflow";
|
|
169
192
|
|
|
170
193
|
wrappers[".google.protobuf.Struct"] = { fromObject: Struct.wrap, toObject: Struct.unwrap } as any;
|
|
@@ -205,6 +228,13 @@ export interface WorkflowServiceClient {
|
|
|
205
228
|
findConnections(request: FindConnectionsRequest, metadata?: Metadata): Observable<FindConnectionsResponse>;
|
|
206
229
|
|
|
207
230
|
updateWorkflowStatus(request: UpdateWorkflowStatusRequest, metadata?: Metadata): Observable<Empty>;
|
|
231
|
+
|
|
232
|
+
getNodeExecutionLog(request: GetNodeExecutionLogRequest, metadata?: Metadata): Observable<GetExecutionLogResponse>;
|
|
233
|
+
|
|
234
|
+
getWorkflowExecutionLog(
|
|
235
|
+
request: GetWorkflowExecutionLogRequest,
|
|
236
|
+
metadata?: Metadata,
|
|
237
|
+
): Observable<GetExecutionLogResponse>;
|
|
208
238
|
}
|
|
209
239
|
|
|
210
240
|
export interface WorkflowServiceController {
|
|
@@ -267,6 +297,16 @@ export interface WorkflowServiceController {
|
|
|
267
297
|
): Promise<FindConnectionsResponse> | Observable<FindConnectionsResponse> | FindConnectionsResponse;
|
|
268
298
|
|
|
269
299
|
updateWorkflowStatus(request: UpdateWorkflowStatusRequest, metadata?: Metadata): void;
|
|
300
|
+
|
|
301
|
+
getNodeExecutionLog(
|
|
302
|
+
request: GetNodeExecutionLogRequest,
|
|
303
|
+
metadata?: Metadata,
|
|
304
|
+
): Promise<GetExecutionLogResponse> | Observable<GetExecutionLogResponse> | GetExecutionLogResponse;
|
|
305
|
+
|
|
306
|
+
getWorkflowExecutionLog(
|
|
307
|
+
request: GetWorkflowExecutionLogRequest,
|
|
308
|
+
metadata?: Metadata,
|
|
309
|
+
): Promise<GetExecutionLogResponse> | Observable<GetExecutionLogResponse> | GetExecutionLogResponse;
|
|
270
310
|
}
|
|
271
311
|
|
|
272
312
|
export function WorkflowServiceControllerMethods() {
|
|
@@ -287,6 +327,8 @@ export function WorkflowServiceControllerMethods() {
|
|
|
287
327
|
"findWorkflowNodeTypes",
|
|
288
328
|
"findConnections",
|
|
289
329
|
"updateWorkflowStatus",
|
|
330
|
+
"getNodeExecutionLog",
|
|
331
|
+
"getWorkflowExecutionLog",
|
|
290
332
|
];
|
|
291
333
|
for (const method of grpcMethods) {
|
|
292
334
|
const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|