@remotion/lambda 3.2.9 → 3.2.10
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/api/render-media-on-lambda.d.ts +1 -0
- package/dist/api/render-media-on-lambda.js +7 -0
- package/dist/api/render-still-on-lambda.d.ts +1 -0
- package/dist/api/render-still-on-lambda.js +7 -0
- package/dist/cli/commands/render/render.js +1 -7
- package/dist/cli/commands/still.js +1 -7
- package/dist/functions/chunk-optimization/plan-frame-ranges.d.ts +1 -4
- package/dist/shared/get-cloudwatch-stream-url.d.ts +8 -0
- package/dist/shared/get-cloudwatch-stream-url.js +7 -0
- package/package.json +6 -6
- package/remotionlambda.zip +0 -0
- package/dist/shared/chunk.d.ts +0 -1
- package/dist/shared/chunk.js +0 -11
|
@@ -34,6 +34,7 @@ export declare type RenderMediaOnLambdaInput = {
|
|
|
34
34
|
export declare type RenderMediaOnLambdaOutput = {
|
|
35
35
|
renderId: string;
|
|
36
36
|
bucketName: string;
|
|
37
|
+
cloudWatchLogs: string;
|
|
37
38
|
};
|
|
38
39
|
/**
|
|
39
40
|
* @description Triggers a render on a lambda given a composition and a lambda function.
|
|
@@ -5,6 +5,7 @@ const version_1 = require("remotion/version");
|
|
|
5
5
|
const call_lambda_1 = require("../shared/call-lambda");
|
|
6
6
|
const constants_1 = require("../shared/constants");
|
|
7
7
|
const convert_to_serve_url_1 = require("../shared/convert-to-serve-url");
|
|
8
|
+
const get_cloudwatch_stream_url_1 = require("../shared/get-cloudwatch-stream-url");
|
|
8
9
|
const validate_download_behavior_1 = require("../shared/validate-download-behavior");
|
|
9
10
|
const validate_frames_per_lambda_1 = require("../shared/validate-frames-per-lambda");
|
|
10
11
|
const validate_lambda_codec_1 = require("../shared/validate-lambda-codec");
|
|
@@ -70,6 +71,12 @@ const renderMediaOnLambda = async ({ functionName, serveUrl, inputProps, codec,
|
|
|
70
71
|
return {
|
|
71
72
|
renderId: res.renderId,
|
|
72
73
|
bucketName: res.bucketName,
|
|
74
|
+
cloudWatchLogs: (0, get_cloudwatch_stream_url_1.getCloudwatchStreamUrl)({
|
|
75
|
+
functionName,
|
|
76
|
+
method: constants_1.LambdaRoutines.renderer,
|
|
77
|
+
region,
|
|
78
|
+
renderId: res.renderId,
|
|
79
|
+
}),
|
|
73
80
|
};
|
|
74
81
|
}
|
|
75
82
|
catch (err) {
|
|
@@ -5,6 +5,7 @@ const version_1 = require("remotion/version");
|
|
|
5
5
|
const call_lambda_1 = require("../shared/call-lambda");
|
|
6
6
|
const constants_1 = require("../shared/constants");
|
|
7
7
|
const convert_to_serve_url_1 = require("../shared/convert-to-serve-url");
|
|
8
|
+
const get_cloudwatch_stream_url_1 = require("../shared/get-cloudwatch-stream-url");
|
|
8
9
|
/**
|
|
9
10
|
* @description Renders a still frame on Lambda
|
|
10
11
|
* @link https://remotion.dev/docs/lambda/renderstillonlambda
|
|
@@ -55,6 +56,12 @@ const renderStillOnLambda = async ({ functionName, serveUrl, inputProps, imageFo
|
|
|
55
56
|
sizeInBytes: res.size,
|
|
56
57
|
bucketName: res.bucketName,
|
|
57
58
|
renderId: res.renderId,
|
|
59
|
+
cloudWatchLogs: (0, get_cloudwatch_stream_url_1.getCloudwatchStreamUrl)({
|
|
60
|
+
functionName,
|
|
61
|
+
method: constants_1.LambdaRoutines.still,
|
|
62
|
+
region,
|
|
63
|
+
renderId: res.renderId,
|
|
64
|
+
}),
|
|
58
65
|
};
|
|
59
66
|
}
|
|
60
67
|
catch (err) {
|
|
@@ -14,7 +14,6 @@ const validate_retries_1 = require("../../../shared/validate-retries");
|
|
|
14
14
|
const args_1 = require("../../args");
|
|
15
15
|
const get_aws_region_1 = require("../../get-aws-region");
|
|
16
16
|
const find_function_name_1 = require("../../helpers/find-function-name");
|
|
17
|
-
const get_cloudwatch_stream_url_1 = require("../../helpers/get-cloudwatch-stream-url");
|
|
18
17
|
const quit_1 = require("../../helpers/quit");
|
|
19
18
|
const log_1 = require("../../log");
|
|
20
19
|
const progress_1 = require("./progress");
|
|
@@ -80,12 +79,7 @@ const renderCommand = async (args) => {
|
|
|
80
79
|
const totalSteps = outName ? 5 : 4;
|
|
81
80
|
const progressBar = cli_1.CliInternals.createOverwriteableCliOutput(cli_1.CliInternals.quietFlagProvided());
|
|
82
81
|
log_1.Log.info(cli_1.CliInternals.chalk.gray(`Bucket = ${res.bucketName}, renderId = ${res.renderId}, functionName = ${functionName}`));
|
|
83
|
-
log_1.Log.verbose(`CloudWatch logs (if enabled): ${
|
|
84
|
-
functionName,
|
|
85
|
-
region,
|
|
86
|
-
renderId: res.renderId,
|
|
87
|
-
method: constants_1.LambdaRoutines.renderer,
|
|
88
|
-
})}`);
|
|
82
|
+
log_1.Log.verbose(`CloudWatch logs (if enabled): ${res.cloudWatchLogs}`);
|
|
89
83
|
const status = await (0, get_render_progress_1.getRenderProgress)({
|
|
90
84
|
functionName,
|
|
91
85
|
bucketName: res.bucketName,
|
|
@@ -11,7 +11,6 @@ const validate_retries_1 = require("../../shared/validate-retries");
|
|
|
11
11
|
const args_1 = require("../args");
|
|
12
12
|
const get_aws_region_1 = require("../get-aws-region");
|
|
13
13
|
const find_function_name_1 = require("../helpers/find-function-name");
|
|
14
|
-
const get_cloudwatch_stream_url_1 = require("../helpers/get-cloudwatch-stream-url");
|
|
15
14
|
const quit_1 = require("../helpers/quit");
|
|
16
15
|
const log_1 = require("../log");
|
|
17
16
|
exports.STILL_COMMAND = 'still';
|
|
@@ -63,12 +62,7 @@ const stillCommand = async (args) => {
|
|
|
63
62
|
scale,
|
|
64
63
|
});
|
|
65
64
|
log_1.Log.verbose(cli_1.CliInternals.chalk.gray(`Bucket = ${res.bucketName}, renderId = ${res.renderId}, functionName = ${functionName}`));
|
|
66
|
-
log_1.Log.verbose(`CloudWatch logs (if enabled): ${
|
|
67
|
-
functionName,
|
|
68
|
-
region: (0, get_aws_region_1.getAwsRegion)(),
|
|
69
|
-
renderId: res.renderId,
|
|
70
|
-
method: constants_1.LambdaRoutines.still,
|
|
71
|
-
})}`);
|
|
65
|
+
log_1.Log.verbose(`CloudWatch logs (if enabled): ${res.cloudWatchLogs}`);
|
|
72
66
|
if (outName) {
|
|
73
67
|
log_1.Log.info('Finished rendering. Downloading...');
|
|
74
68
|
const { outputPath, sizeInBytes } = await (0, download_media_1.downloadMedia)({
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { AwsRegion } from '../client';
|
|
2
|
+
import type { LambdaRoutines } from './constants';
|
|
3
|
+
export declare const getCloudwatchStreamUrl: ({ region, functionName, method, renderId, }: {
|
|
4
|
+
region: AwsRegion;
|
|
5
|
+
functionName: string;
|
|
6
|
+
method: LambdaRoutines;
|
|
7
|
+
renderId: string;
|
|
8
|
+
}) => string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getCloudwatchStreamUrl = void 0;
|
|
4
|
+
const getCloudwatchStreamUrl = ({ region, functionName, method, renderId, }) => {
|
|
5
|
+
return `https://${region}.console.aws.amazon.com/cloudwatch/home?region=${region}#logsV2:log-groups/log-group/$252Faws$252Flambda$252F${functionName}/log-events$3FfilterPattern$3D$2522method$253D${method}$252CrenderId$253D${renderId}$2522`;
|
|
6
|
+
};
|
|
7
|
+
exports.getCloudwatchStreamUrl = getCloudwatchStreamUrl;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@remotion/lambda",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.10",
|
|
4
4
|
"description": "Distributed renderer for Remotion based on AWS Lambda",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -32,12 +32,12 @@
|
|
|
32
32
|
"@aws-sdk/client-service-quotas": "3.58.0",
|
|
33
33
|
"@aws-sdk/lib-storage": "3.58.0",
|
|
34
34
|
"@aws-sdk/s3-request-presigner": "3.58.0",
|
|
35
|
-
"@remotion/bundler": "3.2.
|
|
36
|
-
"@remotion/cli": "3.2.
|
|
37
|
-
"@remotion/renderer": "3.2.
|
|
35
|
+
"@remotion/bundler": "3.2.10",
|
|
36
|
+
"@remotion/cli": "3.2.10",
|
|
37
|
+
"@remotion/renderer": "3.2.10",
|
|
38
38
|
"aws-policies": "^1.0.1",
|
|
39
39
|
"mime-types": "2.1.34",
|
|
40
|
-
"remotion": "3.2.
|
|
40
|
+
"remotion": "3.2.10"
|
|
41
41
|
},
|
|
42
42
|
"peerDependencies": {
|
|
43
43
|
"react": ">=16.8.0",
|
|
@@ -62,5 +62,5 @@
|
|
|
62
62
|
"publishConfig": {
|
|
63
63
|
"access": "public"
|
|
64
64
|
},
|
|
65
|
-
"gitHead": "
|
|
65
|
+
"gitHead": "66ad527dc06a14b7d6d5aab8ff8e736e67db8154"
|
|
66
66
|
}
|
package/remotionlambda.zip
CHANGED
|
Binary file
|
package/dist/shared/chunk.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const chunk: <T>(input: T[], size: number) => T[][];
|
package/dist/shared/chunk.js
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.chunk = void 0;
|
|
4
|
-
const chunk = (input, size) => {
|
|
5
|
-
return input.reduce((arr, item, idx) => {
|
|
6
|
-
return idx % size === 0
|
|
7
|
-
? [...arr, [item]]
|
|
8
|
-
: [...arr.slice(0, -1), [...arr.slice(-1)[0], item]];
|
|
9
|
-
}, []);
|
|
10
|
-
};
|
|
11
|
-
exports.chunk = chunk;
|