@isomorph.ai/app-sdk 1.19.0 → 1.21.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 +111 -0
- package/dist/index.d.ts +770 -4
- package/dist/index.js +4 -4
- package/dist/integration-execute-input-rules.d.ts +1195 -1
- package/dist/integration-execute-input-rules.js +393 -1
- package/dist/integration-operations.d.ts +315 -0
- package/dist/integration-operations.js +405 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -31,15 +31,15 @@ function warehouseReadProblem({ columns, aggregates }) {
|
|
|
31
31
|
return undefined;
|
|
32
32
|
}
|
|
33
33
|
const UUID_PATTERN = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
34
|
-
// The append rules governance states in prose: 1 to
|
|
34
|
+
// The append rules governance states in prose: 1 to 5000 rows per call (a
|
|
35
35
|
// larger report is several calls) and a UUID idempotency key per call.
|
|
36
36
|
// Governance checks the columns and the value types against the catalog.
|
|
37
37
|
function warehouseAppendProblem({ input, idempotencyKey }) {
|
|
38
38
|
const rows = input?.rows;
|
|
39
39
|
if (!Array.isArray(rows) || rows.length === 0)
|
|
40
|
-
return { field: 'rows', message: 'a warehouse append needs 1 to
|
|
41
|
-
if (rows.length >
|
|
42
|
-
return { field: 'rows', message: 'a warehouse append takes at most
|
|
40
|
+
return { field: 'rows', message: 'a warehouse append needs 1 to 5000 rows' };
|
|
41
|
+
if (rows.length > 5000)
|
|
42
|
+
return { field: 'rows', message: 'a warehouse append takes at most 5000 rows per call; send a larger report as several calls, each with its own idempotencyKey' };
|
|
43
43
|
if (typeof idempotencyKey !== 'string' || !UUID_PATTERN.test(idempotencyKey))
|
|
44
44
|
return { field: 'idempotencyKey', message: 'a warehouse append needs a fresh UUID idempotencyKey per call' };
|
|
45
45
|
return undefined;
|