@lcap/nasl 4.1.0-beta.4 → 4.1.0-beta.5
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/out/generator/release-body/body.d.ts +1 -1
- package/out/generator/release-body/body.d.ts.map +1 -1
- package/out/generator/release-body/body.js +387 -385
- package/out/generator/release-body/body.js.map +1 -1
- package/out/generator/release-body/data.d.ts.map +1 -1
- package/out/generator/release-body/data.js +51 -34
- package/out/generator/release-body/data.js.map +1 -1
- package/out/generator/release-body/index.d.ts +1 -0
- package/out/generator/release-body/index.d.ts.map +1 -1
- package/out/generator/release-body/index.js +1 -0
- package/out/generator/release-body/index.js.map +1 -1
- package/out/generator/release-body/memory-optimization.d.ts +47 -0
- package/out/generator/release-body/memory-optimization.d.ts.map +1 -0
- package/out/generator/release-body/memory-optimization.js +266 -0
- package/out/generator/release-body/memory-optimization.js.map +1 -0
- package/out/generator/release-body/utils.d.ts +11 -4
- package/out/generator/release-body/utils.d.ts.map +1 -1
- package/out/generator/release-body/utils.js +52 -20
- package/out/generator/release-body/utils.js.map +1 -1
- package/out/server/extendBaseNode.js +1 -1
- package/out/server/extendBaseNode.js.map +1 -1
- package/out/server/findReference.d.ts.map +1 -1
- package/out/server/findReference.js +5 -1
- package/out/server/findReference.js.map +1 -1
- package/out/server/index.d.ts +0 -1
- package/out/server/index.d.ts.map +1 -1
- package/out/server/index.js +1 -2
- package/out/server/index.js.map +1 -1
- package/out/server/naslServer.d.ts +4 -11
- package/out/server/naslServer.d.ts.map +1 -1
- package/out/server/naslServer.js +21 -56
- package/out/server/naslServer.js.map +1 -1
- package/out/templator/utils.d.ts.map +1 -1
- package/out/templator/utils.js +1 -0
- package/out/templator/utils.js.map +1 -1
- package/package.json +11 -12
- package/sandbox/stdlib/nasl.util.ts +18 -4
|
@@ -23,13 +23,14 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.replaceAssetsPrefix = exports.genReleaseBodyForParallel = exports.genReleaseBody = exports.getFrontendBundleFiles = exports.getNaslAnnotatedJSONFile = exports.
|
|
26
|
+
exports.replaceAssetsPrefix = exports.genReleaseBodyForParallel = exports.genReleaseBody = exports.getFrontendBundleFiles = exports.getNaslAnnotatedJSONFile = exports.addEntityToDefaultDS = exports.__getNaslAnnotatedJSON = exports.replaceAssets = exports.replaceFrontendTypesAssets = void 0;
|
|
27
27
|
const concepts_1 = require("../../concepts");
|
|
28
28
|
const genBundleFiles_1 = require("../genBundleFiles");
|
|
29
29
|
const is_view_logic_1 = require("../../service/instruct-ruler/rules/is-view-logic");
|
|
30
30
|
const utils_1 = require("./utils");
|
|
31
31
|
const permission_1 = require("../permission");
|
|
32
32
|
const validation_1 = require("./validation");
|
|
33
|
+
const memory_optimization_1 = require("./memory-optimization");
|
|
33
34
|
const utils = __importStar(require("../../utils"));
|
|
34
35
|
const config_1 = require("../../config");
|
|
35
36
|
const share_content_1 = require("./share-content");
|
|
@@ -118,13 +119,16 @@ function replaceAssets(app, json, opt) {
|
|
|
118
119
|
exports.replaceAssets = replaceAssets;
|
|
119
120
|
/** 获取全量标注数据 */
|
|
120
121
|
async function __getNaslAnnotatedJSON(app, opt) {
|
|
121
|
-
let
|
|
122
|
+
let json;
|
|
122
123
|
try {
|
|
123
|
-
|
|
124
|
+
json = await app.naslServer.fastGetNaslAnnotatedJSON(app);
|
|
124
125
|
await opt?.logPublishFunc?.('语言', '获取全量类型标注成功');
|
|
126
|
+
// Memory optimization is now integrated into the annotation process
|
|
127
|
+
// No need for separate compaction step - saves memory and time
|
|
128
|
+
await opt?.logPublishFunc?.('优化', '内存优化已集成到标注过程');
|
|
125
129
|
// 打印传给服务端的 nasl,为了服务端排查问题方便
|
|
126
130
|
if (utils.isDebugMode) {
|
|
127
|
-
console.dir(
|
|
131
|
+
console.dir(json, '标注后的nasl');
|
|
128
132
|
}
|
|
129
133
|
}
|
|
130
134
|
catch (err) {
|
|
@@ -132,403 +136,400 @@ async function __getNaslAnnotatedJSON(app, opt) {
|
|
|
132
136
|
throw err;
|
|
133
137
|
}
|
|
134
138
|
app.curDeployEnv = opt?.env;
|
|
135
|
-
replaceAssets(app,
|
|
139
|
+
replaceAssets(app, json, opt);
|
|
136
140
|
await opt?.logPublishFunc?.('资源', '前端静态资源替换完成');
|
|
137
|
-
return
|
|
141
|
+
return json;
|
|
138
142
|
}
|
|
139
143
|
exports.__getNaslAnnotatedJSON = __getNaslAnnotatedJSON;
|
|
140
144
|
// 暂时发布的时候加一个实体
|
|
141
145
|
// 为了服务端发布,使用文件系统,标注的nasl 强制增加一个
|
|
142
146
|
// 服务端承诺 2024年10月份会挪走, @钟春燕 @杨剑飞
|
|
143
|
-
function
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
"
|
|
169
|
-
"
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
"inForm": false,
|
|
173
|
-
"inDetail": false
|
|
174
|
-
},
|
|
175
|
-
"rules": [],
|
|
176
|
-
"generationRule": "auto",
|
|
177
|
-
"sequence": "Entity11299220825",
|
|
178
|
-
"composedBy": null,
|
|
179
|
-
"typeAnnotation": {
|
|
180
|
-
"concept": "TypeAnnotation",
|
|
181
|
-
"typeKind": "primitive",
|
|
182
|
-
"typeNamespace": "nasl.core",
|
|
183
|
-
"typeName": "Long"
|
|
184
|
-
},
|
|
185
|
-
"databaseTypeAnnotation": null,
|
|
186
|
-
"defaultValue": null
|
|
147
|
+
function addEntityToDefaultDS(app, defaultDS) {
|
|
148
|
+
const tableName = 'lcap_async_task_' + (app.id || '').slice(0, 6);
|
|
149
|
+
defaultDS.entities.push({
|
|
150
|
+
"concept": "Entity",
|
|
151
|
+
"name": "LCAPAsyncTask",
|
|
152
|
+
"uuid": "fe2cef1efd9c4189951b1f0bb6eacf11",
|
|
153
|
+
"tableName": tableName,
|
|
154
|
+
"description": null,
|
|
155
|
+
"origin": "ide",
|
|
156
|
+
"composedBy": null,
|
|
157
|
+
"properties": [
|
|
158
|
+
{
|
|
159
|
+
"concept": "EntityProperty",
|
|
160
|
+
"name": "id",
|
|
161
|
+
"uuid": "af657c05c1e545769887cfd2104257bb",
|
|
162
|
+
"columnName": "id",
|
|
163
|
+
"label": "主键",
|
|
164
|
+
"description": "主键",
|
|
165
|
+
"required": true,
|
|
166
|
+
"primaryKey": true,
|
|
167
|
+
"relationNamespace": null,
|
|
168
|
+
"relationEntity": null,
|
|
169
|
+
"relationProperty": null,
|
|
170
|
+
"deleteRule": null,
|
|
171
|
+
"display": {
|
|
172
|
+
"inTable": false,
|
|
173
|
+
"inFilter": false,
|
|
174
|
+
"inForm": false,
|
|
175
|
+
"inDetail": false
|
|
187
176
|
},
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
"
|
|
194
|
-
"
|
|
195
|
-
"
|
|
196
|
-
"
|
|
197
|
-
"relationNamespace": null,
|
|
198
|
-
"relationEntity": null,
|
|
199
|
-
"relationProperty": null,
|
|
200
|
-
"deleteRule": null,
|
|
201
|
-
"display": {
|
|
202
|
-
"inTable": true,
|
|
203
|
-
"inFilter": true,
|
|
204
|
-
"inForm": true,
|
|
205
|
-
"inDetail": true
|
|
206
|
-
},
|
|
207
|
-
"rules": [],
|
|
208
|
-
"generationRule": "manual",
|
|
209
|
-
"sequence": null,
|
|
210
|
-
"composedBy": null,
|
|
211
|
-
"typeAnnotation": {
|
|
212
|
-
"concept": "TypeAnnotation",
|
|
213
|
-
"typeKind": "primitive",
|
|
214
|
-
"typeNamespace": "nasl.core",
|
|
215
|
-
"typeName": "String"
|
|
216
|
-
},
|
|
217
|
-
"databaseTypeAnnotation": null,
|
|
218
|
-
"defaultValue": null
|
|
177
|
+
"rules": [],
|
|
178
|
+
"generationRule": "auto",
|
|
179
|
+
"sequence": "Entity11299220825",
|
|
180
|
+
"composedBy": null,
|
|
181
|
+
"typeAnnotation": {
|
|
182
|
+
"concept": "TypeAnnotation",
|
|
183
|
+
"typeKind": "primitive",
|
|
184
|
+
"typeNamespace": "nasl.core",
|
|
185
|
+
"typeName": "Long"
|
|
219
186
|
},
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
"
|
|
240
|
-
"
|
|
241
|
-
"sequence": null,
|
|
242
|
-
"composedBy": null,
|
|
243
|
-
"typeAnnotation": {
|
|
244
|
-
"concept": "TypeAnnotation",
|
|
245
|
-
"typeKind": "primitive",
|
|
246
|
-
"typeNamespace": "nasl.core",
|
|
247
|
-
"typeName": "String"
|
|
248
|
-
},
|
|
249
|
-
"databaseTypeAnnotation": null,
|
|
250
|
-
"defaultValue": null
|
|
187
|
+
"databaseTypeAnnotation": null,
|
|
188
|
+
"defaultValue": null
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
"concept": "EntityProperty",
|
|
192
|
+
"name": "task_id",
|
|
193
|
+
"uuid": "1ee6f95909b34416bc091775766e9733",
|
|
194
|
+
"columnName": "task_id",
|
|
195
|
+
"label": "任务id",
|
|
196
|
+
"description": null,
|
|
197
|
+
"required": true,
|
|
198
|
+
"primaryKey": false,
|
|
199
|
+
"relationNamespace": null,
|
|
200
|
+
"relationEntity": null,
|
|
201
|
+
"relationProperty": null,
|
|
202
|
+
"deleteRule": null,
|
|
203
|
+
"display": {
|
|
204
|
+
"inTable": true,
|
|
205
|
+
"inFilter": true,
|
|
206
|
+
"inForm": true,
|
|
207
|
+
"inDetail": true
|
|
251
208
|
},
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
"
|
|
258
|
-
"
|
|
259
|
-
"
|
|
260
|
-
"
|
|
261
|
-
"relationNamespace": null,
|
|
262
|
-
"relationEntity": null,
|
|
263
|
-
"relationProperty": null,
|
|
264
|
-
"deleteRule": null,
|
|
265
|
-
"display": {
|
|
266
|
-
"inTable": true,
|
|
267
|
-
"inFilter": true,
|
|
268
|
-
"inForm": true,
|
|
269
|
-
"inDetail": true
|
|
270
|
-
},
|
|
271
|
-
"rules": [],
|
|
272
|
-
"generationRule": "manual",
|
|
273
|
-
"sequence": null,
|
|
274
|
-
"composedBy": null,
|
|
275
|
-
"typeAnnotation": {
|
|
276
|
-
"concept": "TypeAnnotation",
|
|
277
|
-
"typeKind": "primitive",
|
|
278
|
-
"typeNamespace": "nasl.core",
|
|
279
|
-
"typeName": "String"
|
|
280
|
-
},
|
|
281
|
-
"databaseTypeAnnotation": null,
|
|
282
|
-
"defaultValue": null
|
|
209
|
+
"rules": [],
|
|
210
|
+
"generationRule": "manual",
|
|
211
|
+
"sequence": null,
|
|
212
|
+
"composedBy": null,
|
|
213
|
+
"typeAnnotation": {
|
|
214
|
+
"concept": "TypeAnnotation",
|
|
215
|
+
"typeKind": "primitive",
|
|
216
|
+
"typeNamespace": "nasl.core",
|
|
217
|
+
"typeName": "String"
|
|
283
218
|
},
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
"
|
|
304
|
-
|
|
305
|
-
],
|
|
306
|
-
"generationRule": "manual",
|
|
307
|
-
"sequence": null,
|
|
308
|
-
"composedBy": null,
|
|
309
|
-
"typeAnnotation": {
|
|
310
|
-
"concept": "TypeAnnotation",
|
|
311
|
-
"typeKind": "primitive",
|
|
312
|
-
"typeNamespace": "nasl.core",
|
|
313
|
-
"typeName": "String"
|
|
314
|
-
},
|
|
315
|
-
"databaseTypeAnnotation": null,
|
|
316
|
-
"defaultValue": null
|
|
219
|
+
"databaseTypeAnnotation": null,
|
|
220
|
+
"defaultValue": null
|
|
221
|
+
},
|
|
222
|
+
{
|
|
223
|
+
"concept": "EntityProperty",
|
|
224
|
+
"name": "task_status",
|
|
225
|
+
"uuid": "4b11c717968d43e7a5dccb329d444cc1",
|
|
226
|
+
"columnName": "task_status",
|
|
227
|
+
"label": "任务状态",
|
|
228
|
+
"description": null,
|
|
229
|
+
"required": true,
|
|
230
|
+
"primaryKey": false,
|
|
231
|
+
"relationNamespace": null,
|
|
232
|
+
"relationEntity": null,
|
|
233
|
+
"relationProperty": null,
|
|
234
|
+
"deleteRule": null,
|
|
235
|
+
"display": {
|
|
236
|
+
"inTable": true,
|
|
237
|
+
"inFilter": true,
|
|
238
|
+
"inForm": true,
|
|
239
|
+
"inDetail": true
|
|
317
240
|
},
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
"
|
|
324
|
-
"
|
|
325
|
-
"
|
|
326
|
-
"
|
|
327
|
-
"relationNamespace": null,
|
|
328
|
-
"relationEntity": null,
|
|
329
|
-
"relationProperty": null,
|
|
330
|
-
"deleteRule": null,
|
|
331
|
-
"display": {
|
|
332
|
-
"inTable": true,
|
|
333
|
-
"inFilter": true,
|
|
334
|
-
"inForm": true,
|
|
335
|
-
"inDetail": true
|
|
336
|
-
},
|
|
337
|
-
"rules": [
|
|
338
|
-
"maxLength(16777215)"
|
|
339
|
-
],
|
|
340
|
-
"generationRule": "manual",
|
|
341
|
-
"sequence": null,
|
|
342
|
-
"composedBy": null,
|
|
343
|
-
"typeAnnotation": {
|
|
344
|
-
"concept": "TypeAnnotation",
|
|
345
|
-
"typeKind": "primitive",
|
|
346
|
-
"typeNamespace": "nasl.core",
|
|
347
|
-
"typeName": "String"
|
|
348
|
-
},
|
|
349
|
-
"databaseTypeAnnotation": null,
|
|
350
|
-
"defaultValue": null
|
|
241
|
+
"rules": [],
|
|
242
|
+
"generationRule": "manual",
|
|
243
|
+
"sequence": null,
|
|
244
|
+
"composedBy": null,
|
|
245
|
+
"typeAnnotation": {
|
|
246
|
+
"concept": "TypeAnnotation",
|
|
247
|
+
"typeKind": "primitive",
|
|
248
|
+
"typeNamespace": "nasl.core",
|
|
249
|
+
"typeName": "String"
|
|
351
250
|
},
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
"
|
|
372
|
-
|
|
373
|
-
],
|
|
374
|
-
"generationRule": "manual",
|
|
375
|
-
"sequence": null,
|
|
376
|
-
"composedBy": null,
|
|
377
|
-
"typeAnnotation": {
|
|
378
|
-
"concept": "TypeAnnotation",
|
|
379
|
-
"typeKind": "primitive",
|
|
380
|
-
"typeNamespace": "nasl.core",
|
|
381
|
-
"typeName": "String"
|
|
382
|
-
},
|
|
383
|
-
"databaseTypeAnnotation": null,
|
|
384
|
-
"defaultValue": null
|
|
251
|
+
"databaseTypeAnnotation": null,
|
|
252
|
+
"defaultValue": null
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
"concept": "EntityProperty",
|
|
256
|
+
"name": "task_name",
|
|
257
|
+
"uuid": "e069c6541835457483a37df8c0cdafc0",
|
|
258
|
+
"columnName": "task_name",
|
|
259
|
+
"label": "任务名称",
|
|
260
|
+
"description": null,
|
|
261
|
+
"required": true,
|
|
262
|
+
"primaryKey": false,
|
|
263
|
+
"relationNamespace": null,
|
|
264
|
+
"relationEntity": null,
|
|
265
|
+
"relationProperty": null,
|
|
266
|
+
"deleteRule": null,
|
|
267
|
+
"display": {
|
|
268
|
+
"inTable": true,
|
|
269
|
+
"inFilter": true,
|
|
270
|
+
"inForm": true,
|
|
271
|
+
"inDetail": true
|
|
385
272
|
},
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
"
|
|
392
|
-
"
|
|
393
|
-
"
|
|
394
|
-
"
|
|
395
|
-
"relationNamespace": null,
|
|
396
|
-
"relationEntity": null,
|
|
397
|
-
"relationProperty": null,
|
|
398
|
-
"deleteRule": null,
|
|
399
|
-
"display": {
|
|
400
|
-
"inTable": true,
|
|
401
|
-
"inFilter": true,
|
|
402
|
-
"inForm": true,
|
|
403
|
-
"inDetail": true
|
|
404
|
-
},
|
|
405
|
-
"rules": [],
|
|
406
|
-
"generationRule": "manual",
|
|
407
|
-
"sequence": null,
|
|
408
|
-
"composedBy": null,
|
|
409
|
-
"typeAnnotation": {
|
|
410
|
-
"concept": "TypeAnnotation",
|
|
411
|
-
"typeKind": "primitive",
|
|
412
|
-
"typeNamespace": "nasl.core",
|
|
413
|
-
"typeName": "String"
|
|
414
|
-
},
|
|
415
|
-
"databaseTypeAnnotation": null,
|
|
416
|
-
"defaultValue": null
|
|
273
|
+
"rules": [],
|
|
274
|
+
"generationRule": "manual",
|
|
275
|
+
"sequence": null,
|
|
276
|
+
"composedBy": null,
|
|
277
|
+
"typeAnnotation": {
|
|
278
|
+
"concept": "TypeAnnotation",
|
|
279
|
+
"typeKind": "primitive",
|
|
280
|
+
"typeNamespace": "nasl.core",
|
|
281
|
+
"typeName": "String"
|
|
417
282
|
},
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
"
|
|
438
|
-
"
|
|
439
|
-
"sequence": null,
|
|
440
|
-
"composedBy": null,
|
|
441
|
-
"typeAnnotation": {
|
|
442
|
-
"concept": "TypeAnnotation",
|
|
443
|
-
"typeKind": "primitive",
|
|
444
|
-
"typeNamespace": "nasl.core",
|
|
445
|
-
"typeName": "String"
|
|
446
|
-
},
|
|
447
|
-
"databaseTypeAnnotation": null,
|
|
448
|
-
"defaultValue": null
|
|
283
|
+
"databaseTypeAnnotation": null,
|
|
284
|
+
"defaultValue": null
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
"concept": "EntityProperty",
|
|
288
|
+
"name": "result",
|
|
289
|
+
"uuid": "6a6a3b70e5d04831a1da89e6d72b445c",
|
|
290
|
+
"columnName": "result",
|
|
291
|
+
"label": "任务结果",
|
|
292
|
+
"description": null,
|
|
293
|
+
"required": false,
|
|
294
|
+
"primaryKey": false,
|
|
295
|
+
"relationNamespace": null,
|
|
296
|
+
"relationEntity": null,
|
|
297
|
+
"relationProperty": null,
|
|
298
|
+
"deleteRule": null,
|
|
299
|
+
"display": {
|
|
300
|
+
"inTable": true,
|
|
301
|
+
"inFilter": true,
|
|
302
|
+
"inForm": true,
|
|
303
|
+
"inDetail": true
|
|
449
304
|
},
|
|
450
|
-
|
|
451
|
-
"
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
"
|
|
458
|
-
"
|
|
459
|
-
"
|
|
460
|
-
"
|
|
461
|
-
"relationProperty": null,
|
|
462
|
-
"deleteRule": null,
|
|
463
|
-
"display": {
|
|
464
|
-
"inTable": true,
|
|
465
|
-
"inFilter": false,
|
|
466
|
-
"inForm": false,
|
|
467
|
-
"inDetail": false
|
|
468
|
-
},
|
|
469
|
-
"rules": [],
|
|
470
|
-
"generationRule": "auto",
|
|
471
|
-
"sequence": null,
|
|
472
|
-
"composedBy": null,
|
|
473
|
-
"typeAnnotation": {
|
|
474
|
-
"concept": "TypeAnnotation",
|
|
475
|
-
"typeKind": "primitive",
|
|
476
|
-
"typeNamespace": "nasl.core",
|
|
477
|
-
"typeName": "DateTime"
|
|
478
|
-
},
|
|
479
|
-
"databaseTypeAnnotation": null,
|
|
480
|
-
"defaultValue": null
|
|
305
|
+
"rules": [
|
|
306
|
+
"maxLength(16777215)"
|
|
307
|
+
],
|
|
308
|
+
"generationRule": "manual",
|
|
309
|
+
"sequence": null,
|
|
310
|
+
"composedBy": null,
|
|
311
|
+
"typeAnnotation": {
|
|
312
|
+
"concept": "TypeAnnotation",
|
|
313
|
+
"typeKind": "primitive",
|
|
314
|
+
"typeNamespace": "nasl.core",
|
|
315
|
+
"typeName": "String"
|
|
481
316
|
},
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
"
|
|
502
|
-
"
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
"
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
"
|
|
512
|
-
"
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
317
|
+
"databaseTypeAnnotation": null,
|
|
318
|
+
"defaultValue": null
|
|
319
|
+
},
|
|
320
|
+
{
|
|
321
|
+
"concept": "EntityProperty",
|
|
322
|
+
"name": "error_msg",
|
|
323
|
+
"uuid": "7c1c143003784277882b044aa88224d9",
|
|
324
|
+
"columnName": "error_msg",
|
|
325
|
+
"label": "任务异常信息",
|
|
326
|
+
"description": null,
|
|
327
|
+
"required": false,
|
|
328
|
+
"primaryKey": false,
|
|
329
|
+
"relationNamespace": null,
|
|
330
|
+
"relationEntity": null,
|
|
331
|
+
"relationProperty": null,
|
|
332
|
+
"deleteRule": null,
|
|
333
|
+
"display": {
|
|
334
|
+
"inTable": true,
|
|
335
|
+
"inFilter": true,
|
|
336
|
+
"inForm": true,
|
|
337
|
+
"inDetail": true
|
|
338
|
+
},
|
|
339
|
+
"rules": [
|
|
340
|
+
"maxLength(16777215)"
|
|
341
|
+
],
|
|
342
|
+
"generationRule": "manual",
|
|
343
|
+
"sequence": null,
|
|
344
|
+
"composedBy": null,
|
|
345
|
+
"typeAnnotation": {
|
|
346
|
+
"concept": "TypeAnnotation",
|
|
347
|
+
"typeKind": "primitive",
|
|
348
|
+
"typeNamespace": "nasl.core",
|
|
349
|
+
"typeName": "String"
|
|
350
|
+
},
|
|
351
|
+
"databaseTypeAnnotation": null,
|
|
352
|
+
"defaultValue": null
|
|
353
|
+
},
|
|
354
|
+
{
|
|
355
|
+
"concept": "EntityProperty",
|
|
356
|
+
"name": "job_parameters",
|
|
357
|
+
"uuid": "82f83a95684642568701562d9d91571c",
|
|
358
|
+
"columnName": "job_parameters",
|
|
359
|
+
"label": "任务参数",
|
|
360
|
+
"description": null,
|
|
361
|
+
"required": false,
|
|
362
|
+
"primaryKey": false,
|
|
363
|
+
"relationNamespace": null,
|
|
364
|
+
"relationEntity": null,
|
|
365
|
+
"relationProperty": null,
|
|
366
|
+
"deleteRule": null,
|
|
367
|
+
"display": {
|
|
368
|
+
"inTable": true,
|
|
369
|
+
"inFilter": true,
|
|
370
|
+
"inForm": true,
|
|
371
|
+
"inDetail": true
|
|
372
|
+
},
|
|
373
|
+
"rules": [
|
|
374
|
+
"maxLength(16777215)"
|
|
375
|
+
],
|
|
376
|
+
"generationRule": "manual",
|
|
377
|
+
"sequence": null,
|
|
378
|
+
"composedBy": null,
|
|
379
|
+
"typeAnnotation": {
|
|
380
|
+
"concept": "TypeAnnotation",
|
|
381
|
+
"typeKind": "primitive",
|
|
382
|
+
"typeNamespace": "nasl.core",
|
|
383
|
+
"typeName": "String"
|
|
384
|
+
},
|
|
385
|
+
"databaseTypeAnnotation": null,
|
|
386
|
+
"defaultValue": null
|
|
387
|
+
},
|
|
388
|
+
{
|
|
389
|
+
"concept": "EntityProperty",
|
|
390
|
+
"name": "file_plugin_code",
|
|
391
|
+
"uuid": "f05f15779bd84edb8f358ef8483acc23",
|
|
392
|
+
"columnName": "file_plugin_code",
|
|
393
|
+
"label": "文件插件唯一标识",
|
|
394
|
+
"description": "文件插件唯一标识",
|
|
395
|
+
"required": false,
|
|
396
|
+
"primaryKey": false,
|
|
397
|
+
"relationNamespace": null,
|
|
398
|
+
"relationEntity": null,
|
|
399
|
+
"relationProperty": null,
|
|
400
|
+
"deleteRule": null,
|
|
401
|
+
"display": {
|
|
402
|
+
"inTable": true,
|
|
403
|
+
"inFilter": true,
|
|
404
|
+
"inForm": true,
|
|
405
|
+
"inDetail": true
|
|
406
|
+
},
|
|
407
|
+
"rules": [],
|
|
408
|
+
"generationRule": "manual",
|
|
409
|
+
"sequence": null,
|
|
410
|
+
"composedBy": null,
|
|
411
|
+
"typeAnnotation": {
|
|
412
|
+
"concept": "TypeAnnotation",
|
|
413
|
+
"typeKind": "primitive",
|
|
414
|
+
"typeNamespace": "nasl.core",
|
|
415
|
+
"typeName": "String"
|
|
416
|
+
},
|
|
417
|
+
"databaseTypeAnnotation": null,
|
|
418
|
+
"defaultValue": null
|
|
419
|
+
},
|
|
420
|
+
{
|
|
421
|
+
"concept": "EntityProperty",
|
|
422
|
+
"name": "file_type",
|
|
423
|
+
"uuid": "79355d76950a48609b123417e08f85bc",
|
|
424
|
+
"columnName": "file_type",
|
|
425
|
+
"label": "需要生成的文件类型",
|
|
426
|
+
"description": null,
|
|
427
|
+
"required": false,
|
|
428
|
+
"primaryKey": false,
|
|
429
|
+
"relationNamespace": null,
|
|
430
|
+
"relationEntity": null,
|
|
431
|
+
"relationProperty": null,
|
|
432
|
+
"deleteRule": null,
|
|
433
|
+
"display": {
|
|
434
|
+
"inTable": true,
|
|
435
|
+
"inFilter": true,
|
|
436
|
+
"inForm": true,
|
|
437
|
+
"inDetail": true
|
|
438
|
+
},
|
|
439
|
+
"rules": [],
|
|
440
|
+
"generationRule": "manual",
|
|
441
|
+
"sequence": null,
|
|
442
|
+
"composedBy": null,
|
|
443
|
+
"typeAnnotation": {
|
|
444
|
+
"concept": "TypeAnnotation",
|
|
445
|
+
"typeKind": "primitive",
|
|
446
|
+
"typeNamespace": "nasl.core",
|
|
447
|
+
"typeName": "String"
|
|
448
|
+
},
|
|
449
|
+
"databaseTypeAnnotation": null,
|
|
450
|
+
"defaultValue": null
|
|
451
|
+
},
|
|
452
|
+
{
|
|
453
|
+
"concept": "EntityProperty",
|
|
454
|
+
"name": "createdTime",
|
|
455
|
+
"uuid": "273fa6230d8b4c068b57a76f7b08bdfa",
|
|
456
|
+
"columnName": "created_time",
|
|
457
|
+
"label": "创建时间",
|
|
458
|
+
"description": "创建时间",
|
|
459
|
+
"required": false,
|
|
460
|
+
"primaryKey": false,
|
|
461
|
+
"relationNamespace": null,
|
|
462
|
+
"relationEntity": null,
|
|
463
|
+
"relationProperty": null,
|
|
464
|
+
"deleteRule": null,
|
|
465
|
+
"display": {
|
|
466
|
+
"inTable": true,
|
|
467
|
+
"inFilter": false,
|
|
468
|
+
"inForm": false,
|
|
469
|
+
"inDetail": false
|
|
470
|
+
},
|
|
471
|
+
"rules": [],
|
|
472
|
+
"generationRule": "auto",
|
|
473
|
+
"sequence": null,
|
|
474
|
+
"composedBy": null,
|
|
475
|
+
"typeAnnotation": {
|
|
476
|
+
"concept": "TypeAnnotation",
|
|
477
|
+
"typeKind": "primitive",
|
|
478
|
+
"typeNamespace": "nasl.core",
|
|
479
|
+
"typeName": "DateTime"
|
|
480
|
+
},
|
|
481
|
+
"databaseTypeAnnotation": null,
|
|
482
|
+
"defaultValue": null
|
|
483
|
+
},
|
|
484
|
+
{
|
|
485
|
+
"concept": "EntityProperty",
|
|
486
|
+
"name": "updatedTime",
|
|
487
|
+
"uuid": "7d2ec9616309424fbd37830b1e8f1a9d",
|
|
488
|
+
"columnName": "updated_time",
|
|
489
|
+
"label": "更新时间",
|
|
490
|
+
"description": "更新时间",
|
|
491
|
+
"required": false,
|
|
492
|
+
"primaryKey": false,
|
|
493
|
+
"relationNamespace": null,
|
|
494
|
+
"relationEntity": null,
|
|
495
|
+
"relationProperty": null,
|
|
496
|
+
"deleteRule": null,
|
|
497
|
+
"display": {
|
|
498
|
+
"inTable": true,
|
|
499
|
+
"inFilter": false,
|
|
500
|
+
"inForm": false,
|
|
501
|
+
"inDetail": false
|
|
502
|
+
},
|
|
503
|
+
"rules": [],
|
|
504
|
+
"generationRule": "auto",
|
|
505
|
+
"sequence": null,
|
|
506
|
+
"composedBy": null,
|
|
507
|
+
"typeAnnotation": {
|
|
508
|
+
"concept": "TypeAnnotation",
|
|
509
|
+
"typeKind": "primitive",
|
|
510
|
+
"typeNamespace": "nasl.core",
|
|
511
|
+
"typeName": "DateTime"
|
|
512
|
+
},
|
|
513
|
+
"databaseTypeAnnotation": null,
|
|
514
|
+
"defaultValue": null
|
|
515
|
+
}
|
|
516
|
+
],
|
|
517
|
+
"indexes": [
|
|
518
|
+
{
|
|
519
|
+
"concept": "EntityIndex",
|
|
520
|
+
"name": "uni_task_id",
|
|
521
|
+
"indexName": null,
|
|
522
|
+
"propertyNames": [
|
|
523
|
+
"task_id"
|
|
524
|
+
],
|
|
525
|
+
"unique": true,
|
|
526
|
+
"description": null
|
|
527
|
+
}
|
|
528
|
+
],
|
|
529
|
+
"applyAnnotations": null
|
|
530
|
+
});
|
|
530
531
|
}
|
|
531
|
-
exports.
|
|
532
|
+
exports.addEntityToDefaultDS = addEntityToDefaultDS;
|
|
532
533
|
/**
|
|
533
534
|
* 获取全量标注文件
|
|
534
535
|
* @description 数据将会被 stringify
|
|
@@ -642,10 +643,11 @@ async function genReleaseBody(_app, opt) {
|
|
|
642
643
|
file.name = encodeURIComponent(file.name);
|
|
643
644
|
});
|
|
644
645
|
}
|
|
645
|
-
body.files = files;
|
|
646
646
|
if (!opt?.isBackendValidation) {
|
|
647
647
|
body.callLogicValidations = callLogicValidations;
|
|
648
648
|
}
|
|
649
|
+
// Add memory-aware delay to allow GC
|
|
650
|
+
await (0, memory_optimization_1.smartDelay)(50);
|
|
649
651
|
const exportShareContent = (0, share_content_1.genShareContent)(app);
|
|
650
652
|
Object.assign(body, {
|
|
651
653
|
exportShareContent: Object.keys(exportShareContent.dependOn).length ? exportShareContent : null,
|