@hyperframes/aws-lambda 0.6.80 → 0.6.81
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/events.d.ts +2 -8
- package/dist/events.d.ts.map +1 -1
- package/dist/index.js +10 -229
- package/dist/index.js.map +3 -3
- package/dist/sdk/deploySite.d.ts.map +1 -1
- package/dist/sdk/index.js +10 -229
- package/dist/sdk/index.js.map +3 -3
- package/dist/sdk/validateConfig.d.ts +19 -57
- package/dist/sdk/validateConfig.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -1,56 +1,31 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Client-side validation
|
|
3
|
-
* SDK fails on shape errors with a typed `InvalidConfigError` *before* a
|
|
4
|
-
* Step Functions execution starts.
|
|
2
|
+
* Client-side validation for the AWS Lambda adapter.
|
|
5
3
|
*
|
|
6
|
-
* The
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* throw.
|
|
12
|
-
*
|
|
13
|
-
* The check is deliberately narrow — it covers the *shape* errors any
|
|
14
|
-
* caller could have surfaced with `tsc` if they passed a literal, plus
|
|
15
|
-
* the `force-hdr` rejection (HDR mp4 isn't supported in distributed
|
|
16
|
-
* mode). webm was previously rejected here too; v0.7+ supports it via
|
|
17
|
-
* closed-GOP concat-copy. Anything deeper (font availability, plan
|
|
18
|
-
* size cap, GPU mode at runtime) needs the actual planner.
|
|
19
|
-
*/
|
|
20
|
-
import type { SerializableDistributedRenderConfig } from "../events.js";
|
|
21
|
-
/** Thrown for any client-side `SerializableDistributedRenderConfig` violation. */
|
|
22
|
-
export declare class InvalidConfigError extends Error {
|
|
23
|
-
readonly name = "InvalidConfigError";
|
|
24
|
-
/** Dotted JSON-pointer-ish path to the offending field, e.g. `config.fps`. */
|
|
25
|
-
readonly field: string;
|
|
26
|
-
constructor(field: string, message: string);
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Throw an `InvalidConfigError` if `config` is not a valid
|
|
30
|
-
* `SerializableDistributedRenderConfig`. Returns the same reference on
|
|
31
|
-
* success so the call site reads:
|
|
32
|
-
*
|
|
33
|
-
* const validated = validateDistributedRenderConfig(input);
|
|
4
|
+
* The cloud-agnostic config-shape validation (`validateDistributedRenderConfig`,
|
|
5
|
+
* `validateVariablesPayload`, `InvalidConfigError`) lives in
|
|
6
|
+
* `@hyperframes/producer/distributed` and is shared with the other adapters.
|
|
7
|
+
* This module re-exports those and adds the one piece specific to Step
|
|
8
|
+
* Functions: the 256 KiB Standard-workflow execution-input size cap.
|
|
34
9
|
*/
|
|
35
|
-
export
|
|
10
|
+
export { InvalidConfigError, validateDistributedRenderConfig, validateVariablesPayload, } from "@hyperframes/producer/distributed";
|
|
36
11
|
/**
|
|
37
|
-
* Hard cap on Step Functions Standard workflow execution input — 256 KiB
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
12
|
+
* Hard cap on Step Functions Standard workflow execution input — 256 KiB per
|
|
13
|
+
* the AWS limits page. Express workflows cap at 32 KiB; the render stack runs
|
|
14
|
+
* Standard for execution-history visibility, so the larger limit applies. The
|
|
15
|
+
* cap is on the entire serialized input, not just the variables, because
|
|
16
|
+
* users hit it at the wire boundary regardless of which field caused the
|
|
17
|
+
* bloat.
|
|
43
18
|
*
|
|
44
19
|
* Specific to Step Functions Standard. Other workflow runtimes (Temporal,
|
|
45
|
-
* Express SFN, raw Lambda invoke) have different caps;
|
|
46
|
-
*
|
|
20
|
+
* Express SFN, Cloud Workflows, raw Lambda invoke) have different caps; don't
|
|
21
|
+
* reuse this constant for those without confirming the limit.
|
|
47
22
|
*/
|
|
48
23
|
export declare const MAX_STEP_FUNCTIONS_INPUT_BYTES: number;
|
|
49
24
|
/**
|
|
50
|
-
* Validate that the serialized Step Functions execution input fits inside
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
25
|
+
* Validate that the serialized Step Functions execution input fits inside the
|
|
26
|
+
* 256 KiB Standard-workflow cap. Measured in UTF-8 bytes (the format Step
|
|
27
|
+
* Functions uses on the wire) — JS strings count UTF-16 code units, which
|
|
28
|
+
* under-reports for any multi-byte character.
|
|
54
29
|
*
|
|
55
30
|
* Throws {@link InvalidConfigError} with a clear message naming the actual
|
|
56
31
|
* byte count, the cap, and a pointer to the "working with large variables"
|
|
@@ -59,17 +34,4 @@ export declare const MAX_STEP_FUNCTIONS_INPUT_BYTES: number;
|
|
|
59
34
|
* execution.
|
|
60
35
|
*/
|
|
61
36
|
export declare function validateStepFunctionsInputSize(input: unknown): void;
|
|
62
|
-
/**
|
|
63
|
-
* Validate that `variables` is a plain JSON-safe object — no functions,
|
|
64
|
-
* Symbols, `undefined` leaves, BigInts, non-finite numbers, or non-plain
|
|
65
|
-
* objects (Dates, Maps, Sets, class instances). Rejected values would
|
|
66
|
-
* either round-trip incorrectly through Step Functions (`undefined` is
|
|
67
|
-
* silently dropped by `JSON.stringify`) or throw at the wire boundary
|
|
68
|
-
* (`bigint`), so we surface the offending path synchronously.
|
|
69
|
-
*
|
|
70
|
-
* The check is purely structural — semantic constraints (e.g. "is this
|
|
71
|
-
* variable declared in `data-composition-variables`?") belong to the CLI
|
|
72
|
-
* layer where the project's HTML is on disk.
|
|
73
|
-
*/
|
|
74
|
-
export declare function validateVariablesPayload(value: unknown): void;
|
|
75
37
|
//# sourceMappingURL=validateConfig.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validateConfig.d.ts","sourceRoot":"","sources":["../../src/sdk/validateConfig.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"validateConfig.d.ts","sourceRoot":"","sources":["../../src/sdk/validateConfig.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,OAAO,EACL,kBAAkB,EAClB,+BAA+B,EAC/B,wBAAwB,GACzB,MAAM,mCAAmC,CAAC;AAE3C;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,8BAA8B,QAAa,CAAC;AAMzD;;;;;;;;;;;GAWG;AAEH,wBAAgB,8BAA8B,CAAC,KAAK,EAAE,OAAO,GAAG,IAAI,CA6BnE"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hyperframes/aws-lambda",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.81",
|
|
4
4
|
"description": "AWS Lambda adapter for HyperFrames distributed rendering — handler, client-side SDK, and CDK construct.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"ffprobe-static": "^3.1.0",
|
|
46
46
|
"puppeteer-core": "^24.39.1",
|
|
47
47
|
"tar": "^7.4.3",
|
|
48
|
-
"@hyperframes/producer": "^0.6.
|
|
48
|
+
"@hyperframes/producer": "^0.6.81"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
51
|
"@types/aws-lambda": "^8.10.146",
|