@platforma-sdk/workflow-tengo 2.14.0 → 2.15.1

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.
Files changed (80) hide show
  1. package/README.md +17 -1
  2. package/dist/index.d.ts +1 -1
  3. package/dist/index.js +3 -1
  4. package/dist/index.mjs +3 -1
  5. package/dist/tengo/lib/assets.lib.tengo +28 -28
  6. package/dist/tengo/lib/assets.swinfo.lib.tengo +24 -24
  7. package/dist/tengo/lib/constants.lib.tengo +6 -3
  8. package/dist/tengo/lib/exec.R.internal.lib.tengo +2 -2
  9. package/dist/tengo/lib/exec.R.lib.tengo +41 -41
  10. package/dist/tengo/lib/exec.descriptor.lib.tengo +3 -3
  11. package/dist/tengo/lib/exec.internal.lib.tengo +41 -41
  12. package/dist/tengo/lib/exec.lib.tengo +289 -289
  13. package/dist/tengo/lib/exec.limits.lib.tengo +49 -49
  14. package/dist/tengo/lib/exec.monetization.lib.tengo +1 -1
  15. package/dist/tengo/lib/exec.monetization_internal.lib.tengo +38 -38
  16. package/dist/tengo/lib/exec.package.lib.tengo +53 -53
  17. package/dist/tengo/lib/exec.python.internal.lib.tengo +1 -1
  18. package/dist/tengo/lib/exec.python.lib.tengo +37 -37
  19. package/dist/tengo/lib/exec.runcmd.lib.tengo +138 -138
  20. package/dist/tengo/lib/exec.runenv.lib.tengo +18 -18
  21. package/dist/tengo/lib/exec.stream.lib.tengo +25 -25
  22. package/dist/tengo/lib/feats.lib.tengo +3 -3
  23. package/dist/tengo/lib/file.internal.lib.tengo +31 -31
  24. package/dist/tengo/lib/file.lib.tengo +29 -29
  25. package/dist/tengo/lib/ll.get-future-field-default.lib.tengo +137 -0
  26. package/dist/tengo/lib/ll.lib.tengo +129 -129
  27. package/dist/tengo/lib/maps.lib.tengo +38 -38
  28. package/dist/tengo/lib/objects.lib.tengo +6 -6
  29. package/dist/tengo/lib/oop.lib.tengo +11 -11
  30. package/dist/tengo/lib/path.lib.tengo +60 -60
  31. package/dist/tengo/lib/pframes.builder.lib.tengo +3 -3
  32. package/dist/tengo/lib/pframes.constants.lib.tengo +20 -20
  33. package/dist/tengo/lib/pframes.export-pcolumn.lib.tengo +5 -5
  34. package/dist/tengo/lib/pframes.lib.tengo +206 -198
  35. package/dist/tengo/lib/pframes.ll.lib.tengo +59 -59
  36. package/dist/tengo/lib/pframes.pcolumn.lib.tengo +18 -18
  37. package/dist/tengo/lib/pframes.remove-nulls.lib.tengo +36 -0
  38. package/dist/tengo/lib/pframes.spec.lib.tengo +83 -83
  39. package/dist/tengo/lib/pframes.util.lib.tengo +176 -176
  40. package/dist/tengo/lib/pframes.xsv-import-file.lib.tengo +160 -0
  41. package/dist/tengo/lib/pframes.xsv.lib.tengo +84 -167
  42. package/dist/tengo/lib/render.lib.tengo +100 -45
  43. package/dist/tengo/lib/sets.lib.tengo +44 -44
  44. package/dist/tengo/lib/slices.lib.tengo +126 -126
  45. package/dist/tengo/lib/smart.lib.tengo +654 -507
  46. package/dist/tengo/lib/test.lib.tengo +120 -120
  47. package/dist/tengo/lib/tpl.lib.tengo +206 -170
  48. package/dist/tengo/lib/tpl.state-await.lib.tengo +17 -17
  49. package/dist/tengo/lib/tpl.util.lib.tengo +5 -5
  50. package/dist/tengo/lib/units.lib.tengo +2 -2
  51. package/dist/tengo/lib/validation.lib.tengo +130 -130
  52. package/dist/tengo/lib/waiter.lib.tengo +13 -13
  53. package/dist/tengo/lib/workdir.lib.tengo +126 -126
  54. package/dist/tengo/lib/workdir.proc.lib.tengo +47 -47
  55. package/dist/tengo/lib/workdir.save.lib.tengo +53 -53
  56. package/dist/tengo/lib/workflow.bobject.lib.tengo +11 -11
  57. package/dist/tengo/lib/workflow.bquery.lib.tengo +40 -40
  58. package/dist/tengo/lib/workflow.constants.lib.tengo +1 -1
  59. package/dist/tengo/lib/workflow.context.lib.tengo +16 -16
  60. package/dist/tengo/lib/workflow.lib.tengo +76 -76
  61. package/dist/tengo/tpl/exec.R.create-renv.plj.gz +0 -0
  62. package/dist/tengo/tpl/exec.exec.plj.gz +0 -0
  63. package/dist/tengo/tpl/exec.monetization_to_json.plj.gz +0 -0
  64. package/dist/tengo/tpl/exec.python.create-venv.plj.gz +0 -0
  65. package/dist/tengo/tpl/exec.python.install-deps.plj.gz +0 -0
  66. package/dist/tengo/tpl/ll.get-field.plj.gz +0 -0
  67. package/dist/tengo/tpl/pframes.export-multiple-pcolumns.plj.gz +0 -0
  68. package/dist/tengo/tpl/pframes.export-pframe.plj.gz +0 -0
  69. package/dist/tengo/tpl/pframes.export-single-pcolumn.plj.gz +0 -0
  70. package/dist/tengo/tpl/pframes.import-dir.plj.gz +0 -0
  71. package/dist/tengo/tpl/pframes.process-pcolumn-data.plj.gz +0 -0
  72. package/dist/tengo/tpl/pframes.remove-nulls.plj.gz +0 -0
  73. package/dist/tengo/tpl/pframes.xsv-export-pframe.plj.gz +0 -0
  74. package/dist/tengo/tpl/pframes.xsv-import-if-not-null.plj.gz +0 -0
  75. package/dist/tengo/tpl/pframes.xsv-import-map.plj.gz +0 -0
  76. package/dist/tengo/tpl/waiter.waiter.plj.gz +0 -0
  77. package/dist/tengo/tpl/workdir.save.plj.gz +0 -0
  78. package/dist/tengo/tpl/workflow.build-ctx.plj.gz +0 -0
  79. package/package.json +2 -2
  80. package/dist/tengo/tpl/pframes.map-pframe.plj.gz +0 -0
@@ -1,6 +1,6 @@
1
- /**
2
- * A library that creates RunCommand resource.
3
- */
1
+
2
+
3
+
4
4
 
5
5
  ll := import("@platforma-sdk/workflow-tengo:ll")
6
6
  feats := import("@platforma-sdk/workflow-tengo:feats")
@@ -21,11 +21,11 @@ _RTYPE_RUN_COMMAND_REFS := { Name: "RunCommandRefs", Version: "1" }
21
21
  _FIELD_WORKDIR_IN := "workdirIn"
22
22
  _FIELD_WORKDIR_OUT := "workdirOut"
23
23
 
24
- /**
25
- * Creates a simple argument for the command.
26
- *
27
- * @param argument: string - the argument to create.
28
- */
24
+
25
+
26
+
27
+
28
+
29
29
  _createSimpleArg := func(argument) {
30
30
  return {
31
31
  type: constants.ARG_TYPE_STRING,
@@ -33,11 +33,11 @@ _createSimpleArg := func(argument) {
33
33
  }
34
34
  }
35
35
 
36
- /**
37
- * @deprecated, use _createRenderedArg
38
- * Creates 'variableRef' argument.
39
- * @param argTpl: string - argument value in any form with variables inside (e.g. "file://{pkg}/some-file" or "o-{java}-o")
40
- */
36
+
37
+
38
+
39
+
40
+
41
41
  _createVariableArg := func(argTpl) {
42
42
  return {
43
43
  type: constants.ARG_TYPE_VAR,
@@ -45,13 +45,13 @@ _createVariableArg := func(argTpl) {
45
45
  }
46
46
  }
47
47
 
48
- /**
49
- * Creates 'expressionRef' arguments
50
- * @param argTpl: string - arguments value in any form with expressions inside, e.g.:
51
- * - `–Xms{env.PL_EXEC_HARD_MEMORY_LIMIT_MB * 80 / 100}m`
52
- * - `file://{pkg}/some-file`
53
- * - `o-{java}-o`
54
- */
48
+
49
+
50
+
51
+
52
+
53
+
54
+
55
55
  _createExpressionArg := func(argTpl) {
56
56
  return {
57
57
  type: constants.ARG_TYPE_EXPRESSION,
@@ -59,12 +59,12 @@ _createExpressionArg := func(argTpl) {
59
59
  }
60
60
  }
61
61
 
62
- /**
63
- * Builder function for creating a RunCommand resource.
64
- *
65
- * @param workdir: string - the working directory for the command.
66
- * @return builder - the builder object with methods for configuring and building the RunCommand resource.
67
- */
62
+
63
+
64
+
65
+
66
+
67
+
68
68
  builder := func(workdir) {
69
69
  res := smart.ephemeralBuilder(_RTYPE_RUN_COMMAND)
70
70
  res.getField(_FIELD_WORKDIR_IN).set(workdir)
@@ -87,38 +87,38 @@ builder := func(workdir) {
87
87
  nErrorLines := 200
88
88
 
89
89
  self = ll.toStrict(oop.inherit(res, {
90
- /**
91
- * Sets the command, e.g. /usr/bin/env or sh.
92
- *
93
- * @param commandName: string - the name of the command.
94
- */
90
+
91
+
92
+
93
+
94
+
95
95
  cmd: func(commandName) {
96
96
  cmd = _createSimpleArg(commandName)
97
97
  return self
98
98
  },
99
99
 
100
- /**
101
- * Sets the command with variables inside to be rendered using rules
102
- * from .substitutionRules().
103
- *
104
- * @param commandTpl: string - string with '{varName}' substitutions to be replaced with
105
- * software paths. Replace rules are defined by .substitutionRule()
106
- * and .substitutionRules(),
107
- */
100
+
101
+
102
+
103
+
104
+
105
+
106
+
107
+
108
108
  cmdVar: func(commandTpl) {
109
109
  cmd = _createVariableArg(commandTpl)
110
110
  hasPatternArgs = true
111
111
  return self
112
112
  },
113
113
 
114
- /**
115
- * Sets the command with expressions inside to be rendered using rules
116
- * from .substitutionRules().
117
- *
118
- * @param commandTpl: string - string with '{any expression}' substitutions to be replaced with
119
- * software paths. Replace rules are defined by .substitutionRule()
120
- * and .substitutionRules(),
121
- */
114
+
115
+
116
+
117
+
118
+
119
+
120
+
121
+
122
122
  cmdExpression: func(commandTpl) {
123
123
  cmd = _createExpressionArg(commandTpl)
124
124
  hasExpressionArgs = true
@@ -140,38 +140,38 @@ builder := func(workdir) {
140
140
  ll.panic("runcmd.builder().cmdTyped: unknown type %s, expect: %v", type, constants.ARG_TYPES)
141
141
  },
142
142
 
143
- /**
144
- * Adds an argument to the command.
145
- *
146
- * @param arg: string - the argument to add.
147
- */
143
+
144
+
145
+
146
+
147
+
148
148
  arg: func(arg) {
149
149
  args = append(args, _createSimpleArg(arg))
150
150
  return self
151
151
  },
152
152
 
153
- /**
154
- * Adds an argument with variables inside to be rendered using rules
155
- * from .substitutionRules().
156
- *
157
- * @param argTpl: string - string with '{varName}' substitutions to be replaced with
158
- * software paths. Replace rules are defined by .substitutionRule()
159
- * and .substitutionRules(),
160
- */
153
+
154
+
155
+
156
+
157
+
158
+
159
+
160
+
161
161
  argVar: func(argTpl) {
162
162
  args = append(args, _createVariableArg(argTpl))
163
163
  hasPatternArgs = true
164
164
  return self
165
165
  },
166
166
 
167
- /**
168
- * Adds an argument with variables inside to be rendered using rules
169
- * from .substitutionRules().
170
- *
171
- * @param argTpl: string - string with '{expression}' substitutions to be replaced with
172
- * expression value. Replace rules are defined by .substitutionRule()
173
- * and .substitutionRules(),
174
- */
167
+
168
+
169
+
170
+
171
+
172
+
173
+
174
+
175
175
  argExpression: func(argTpl) {
176
176
  args = append(args, _createExpressionArg(argTpl))
177
177
  hasExpressionArgs = true
@@ -193,12 +193,12 @@ builder := func(workdir) {
193
193
  ll.panic("runcmd.builder().argTyped: unknown type %s, expect: %v", type, constants.ARG_TYPES)
194
194
  },
195
195
 
196
- /**
197
- * Adds a reference for using it in expressions next.
198
- *
199
- * @param refKey: string - the name of the ref
200
- * @param ref: reference - a reference to the valid field or resource
201
- */
196
+
197
+
198
+
199
+
200
+
201
+
202
202
  ref: func(refKey, ref) {
203
203
  ll.assert(smart.isReference(ref),
204
204
  "runcmd.builder().ref() must be a reference (valid field or resource)")
@@ -210,37 +210,37 @@ builder := func(workdir) {
210
210
  return self
211
211
  },
212
212
 
213
- /**
214
- * Sets an environment variable for the command.
215
- *
216
- * @param name: string - the name of the environment variable.
217
- * @param value: string - the value of the environment variable.
218
- */
213
+
214
+
215
+
216
+
217
+
218
+
219
219
  env: func(name, value) {
220
220
  envs[name] = value
221
221
  return self
222
222
  },
223
223
 
224
- /**
225
- * Sets environment variable with substitution inside value, to be rendered
226
- * using rules from .substitutionRules().
227
- *
228
- * @param name: string - the name of the environment variable.
229
- * @param valueTpl: string - the value of the environment variable.
230
- */
224
+
225
+
226
+
227
+
228
+
229
+
230
+
231
231
  envVar: func(name, valueTpl) {
232
232
  envs[name] = _createVariableArg(valueTpl)
233
233
  hasPatternArgs = true
234
234
  return self
235
235
  },
236
236
 
237
- /**
238
- * Sets environment variable with substitution inside value, to be rendered
239
- * using rules from .substitutionRules().
240
- *
241
- * @param name: string - the name of the environment variable.
242
- * @param valueTpl: string - the value of the environment variable.
243
- */
237
+
238
+
239
+
240
+
241
+
242
+
243
+
244
244
  envExpression: func(name, valueTpl) {
245
245
  envs[name] = _createExpressionArg(valueTpl)
246
246
  hasExpressionArgs = true
@@ -262,12 +262,12 @@ builder := func(workdir) {
262
262
  ll.panic("runcmd.builder().envTyped: unknown type %s, expect: %v", type, constants.ARG_TYPES)
263
263
  },
264
264
 
265
- /*
266
- * Patch 'PATH' environment variable, adding software path to it.
267
- *
268
- * @param type: constants.ARG_TYPES - whether Platforma Backend should try to substitute variables or expressions inside <value> on server side
269
- * @param value: string - the value of the environment variable with variables to be replaced to software path.
270
- */
265
+
266
+
267
+
268
+
269
+
270
+
271
271
  addToPath: func(type, value) {
272
272
  ll.assert(slices.hasElement(constants.ARG_TYPES, type),
273
273
  "runcmd.builder().addToPath: unknown type %s, expect: %v", type, constants.ARG_TYPES)
@@ -287,23 +287,23 @@ builder := func(workdir) {
287
287
  return self
288
288
  },
289
289
 
290
- /**
291
- * Define substitution variable for software args.
292
- *
293
- * @param varName: string - variable to be substituted in arg value ("var1" would be
294
- * substituted in place of {var1} of arg value)
295
- * @param refKey: string - key of ref (added with .ref()) that points to installed software.
296
- */
290
+
291
+
292
+
293
+
294
+
295
+
296
+
297
297
  substitutionRule: func(varName, refKey) {
298
298
  substRules[varName] = refKey
299
299
  return self
300
300
  },
301
301
 
302
- /**
303
- * Batched .substitutionRule() call (add several rules in single call)
304
- *
305
- * @param rules: map[string]string - <var name> -> <ref key> pairs to be added to substitution rules.
306
- */
302
+
303
+
304
+
305
+
306
+
307
307
  substitutionRules: func(rules) {
308
308
  for k, v in rules {
309
309
  substRules[k] = v
@@ -311,53 +311,53 @@ builder := func(workdir) {
311
311
  return self
312
312
  },
313
313
 
314
- /**
315
- * Sets the queue name for the command.
316
- *
317
- * @param queueName: string - the name of the queue.
318
- */
314
+
315
+
316
+
317
+
318
+
319
319
  inQueue: func(queueName) {
320
320
  queue = queueName
321
321
  return self
322
322
  },
323
323
 
324
- /**
325
- * Sets the stdout file name for the command.
326
- *
327
- * @param fileName: string - the name of the stdout file.
328
- */
324
+
325
+
326
+
327
+
328
+
329
329
  stdout: func(fileName) {
330
330
  stdout = fileName
331
331
  return self
332
332
  },
333
333
 
334
- /**
335
- * Sets the stderr file name for the command.
336
- *
337
- * @param fileName: string - the name of the stderr file.
338
- */
334
+
335
+
336
+
337
+
338
+
339
339
  stderr: func(fileName) {
340
340
  stderr = fileName
341
341
  return self
342
342
  },
343
343
 
344
- /**
345
- * Sets the number of error lines for the command.
346
- *
347
- * @param number: int - the number of error lines.
348
- */
344
+
345
+
346
+
347
+
348
+
349
349
  nErrorLines: func(number) {
350
350
  nErrorLines = number
351
351
  return self
352
352
  },
353
353
 
354
- /**
355
- * Builds the RunCommand resource.
356
- *
357
- * @return object - the built RunCommand resource.
358
- */
354
+
355
+
356
+
357
+
358
+
359
359
  build: func() {
360
- // TODO: add assertions about the state
360
+
361
361
 
362
362
  ll.assert(!hasPatternArgs || len(substRules) != 0,
363
363
  "found pattern argument, but no substitution rules were set: hasPatternArgs: %v, substRules: %v, cmd: %v, args: %v, envs: %v",
@@ -1,6 +1,6 @@
1
- /**
2
- * A library for run environments creation and bootstrapping.
3
- */
1
+
2
+
3
+
4
4
 
5
5
  ll := import("@platforma-sdk/workflow-tengo:ll")
6
6
  smart := import("@platforma-sdk/workflow-tengo:smart")
@@ -40,9 +40,9 @@ saveBuilder := func(wd) {
40
40
  return self
41
41
  },
42
42
 
43
- /**
44
- * Bind package to created run environment, holding it as long as run environment exists.
45
- */
43
+
44
+
45
+
46
46
  addPackage: func(key, pkgRef) {
47
47
  ll.assert(!maps.containsKey(packagesMap, key), "runenv.saveBuilder.addPackage: package %q was already added to SaveRunEnv builder", key)
48
48
  validation.assertType(pkgRef, validation.reference, "runenv.saveBuilder.addPackage: <pkgRef> must be reference")
@@ -68,22 +68,22 @@ saveBuilder := func(wd) {
68
68
  set(smart.createMapResource(packagesMap))
69
69
 
70
70
  return oop.inherit(envSaver.lockAndBuild(), {
71
- /**
72
- * Run environment reference
73
- *
74
- * @return runEnv: smart.field - field where run environment appears
75
- * after operation is done
76
- */
71
+
72
+
73
+
74
+
75
+
76
+
77
77
  runEnv: func() {
78
78
  return envSaver.getField(_OUTPUT_RUN_ENV)
79
79
  },
80
80
 
81
- /**
82
- * Working directory reference after operation is complete
83
- *
84
- * @return wd: smart.field - field where workdir appears after
85
- * operation is done
86
- */
81
+
82
+
83
+
84
+
85
+
86
+
87
87
  workdir: func() {
88
88
  return envSaver.getField(_OUTPUT_WD_OUT)
89
89
  }
@@ -1,6 +1,6 @@
1
- /**
2
- * A library for working with streams.
3
- */
1
+
2
+
3
+
4
4
 
5
5
  ll := import("@platforma-sdk/workflow-tengo:ll")
6
6
  smart := import("@platforma-sdk/workflow-tengo:smart")
@@ -10,13 +10,13 @@ file := import("@platforma-sdk/workflow-tengo:file")
10
10
  _RTYPE_CREATE_STREAM := { Name: "CreateStream", Version: "2" }
11
11
  _RTYPE_STREAM_MANAGER := { Name: "StreamManager", Version: "2" }
12
12
 
13
- /**
14
- * Creates a stream in the specified workdir for the given file path.
15
- *
16
- * @param workdir: reference - a reference to the workdir.
17
- * @param filePath: string - the path of the file in the workdir.
18
- * @return stream: resource - a smart.resource to the created stream with an output field.
19
- */
13
+
14
+
15
+
16
+
17
+
18
+
19
+
20
20
  _create := func(workdir, filePath) {
21
21
  stream := smart.ephemeralBuilder(_RTYPE_CREATE_STREAM)
22
22
  stream.getField("workdir").set(workdir)
@@ -27,13 +27,13 @@ _create := func(workdir, filePath) {
27
27
  }))
28
28
  }
29
29
 
30
- /**
31
- * Creates a special manager resource that has either a blob or a stream in the `stream` field.
32
- *
33
- * @param stream: reference - a reference to the stream.
34
- * @param downloadableRef: reference - a reference to the downloadable content.
35
- * @return manager: reference - a reference to the stream manager.
36
- */
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
37
  _manager := func(stream, downloadableRef) {
38
38
  res := smart.structBuilder(_RTYPE_STREAM_MANAGER)
39
39
 
@@ -43,14 +43,14 @@ _manager := func(stream, downloadableRef) {
43
43
  return res.lockAndBuild()
44
44
  }
45
45
 
46
- /**
47
- * Creates a stream and manages its downloadable content.
48
- *
49
- * @param workdirBefore: reference - a reference to the workdir before RunCommand were executed.
50
- * @param workdirAfter: reference - a reference to the resulted workdir field of RunCommand.
51
- * @param filePath: string - the path of the file in the workdir.
52
- * @return manager: reference - a reference to the stream manager.
53
- */
46
+
47
+
48
+
49
+
50
+
51
+
52
+
53
+
54
54
  create := func(workdirBefore, workdirAfter, filePath) {
55
55
  stream := _create(workdirBefore, filePath)
56
56
  fileFuture := workdirAfter.files.getFutureInputField(filePath)
@@ -1,6 +1,6 @@
1
- /**
2
- * Catalogue of features available in current execution context.
3
- */
1
+
2
+
3
+
4
4
  plapi := import("plapi")
5
5
  ll := import("@platforma-sdk/workflow-tengo:ll")
6
6
 
@@ -1,13 +1,13 @@
1
- /**
2
- * Internal functions to work with blobs.
3
- *
4
- * This file contains functions intended for use only within workflow tengo SDK.
5
- * Their parameters list, results and other parts of the interface may change from
6
- * vertion to version without prior notice.
7
- *
8
- * DO NOT USE them in workflows or templates directly.
9
- *
10
- */
1
+
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
11
 
12
12
  ll := import("@platforma-sdk/workflow-tengo:ll")
13
13
  smart := import("@platforma-sdk/workflow-tengo:smart")
@@ -15,21 +15,21 @@ validation := import("@platforma-sdk/workflow-tengo:validation")
15
15
 
16
16
  json := import("json")
17
17
 
18
- //
19
- // Resource types:
20
- //
18
+
19
+
20
+
21
21
 
22
22
  RTYPE_BLOB_IMPORT_EXTERNAL := { Name: "BlobImportExternal", Version: "1" }
23
23
  RTYPE_BLOB_IMPORT_INTERNAL := { Name: "BlobImportInternal", Version: "1" }
24
24
  RTYPE_BLOB_UPLOAD := { Name: "BlobUpload", Version: "1" }
25
25
  RTYPE_BLOB_DOWNLOAD := { Name: "BlobDownload", Version: "2" }
26
26
 
27
- /**
28
- * Create a task for importing blob from external service by URL
29
- * Produces 2 fields:
30
- * 'file' - reference to blob to appear once import gets finished.
31
- * 'handle' - reference to resource with 'progress' API.
32
- */
27
+
28
+
29
+
30
+
31
+
32
+
33
33
  createBlobImportExternal := func(settings) {
34
34
  validation.assertType(settings, {
35
35
  "dataURL": "string",
@@ -45,12 +45,12 @@ createBlobImportExternal := func(settings) {
45
45
  })
46
46
  }
47
47
 
48
- /**
49
- * Create a task for importing blob from one of preconfigured storages.
50
- * Produces 2 fields:
51
- * 'file' - reference to blob to appear once import gets finished.
52
- * 'handle' - reference to resource with 'progress' API.
53
- */
48
+
49
+
50
+
51
+
52
+
53
+
54
54
  createBlobImportInternal := func(settings) {
55
55
  validation.assertType(settings, {
56
56
  "path": "string",
@@ -67,12 +67,12 @@ createBlobImportInternal := func(settings) {
67
67
  })
68
68
  }
69
69
 
70
- /**
71
- * Create a task for getting a blob directly from the user via 'upload' procedure.
72
- * Produces 2 fields:
73
- * 'file' - reference to blob to appear once upload gets finished.
74
- * 'handle' - reference to resource with 'progress' and 'upload' APIs.
75
- */
70
+
71
+
72
+
73
+
74
+
75
+
76
76
  createBlobUpload := func(settings) {
77
77
  validation.assertType(settings, {
78
78
  "modificationTime": "string",