mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-11-03 20:37:30 +00:00
* perf(engine): a remote source's tail decodes run many at a time, not one per half-core * perf(producer): the plan logs where its extract stage spends its time * perf(engine): a window that ends inside its source takes its frame count without a decode * test(engine): pin the tail-decode slot test to the windows that decode * style(engine): format the tail-probe window check * test(engine): deferred counts match extraction on a B-frame NTSC source; VFR is not deferred * style(engine): format the tail-probe tests * perf(aws-lambda): a site stores each video's ffprobe JSON, and the plan reads it instead of probing * test(aws-lambda): a site stores and hands out each video's probe * style(aws-lambda): format the probe-facts upload and tests * perf(engine): a site's stored probe also holds the final-frame timestamp the plan would probe for * test(engine): drop an unused import * test(aws-lambda): the stored probe holds the ffprobe JSON and the final frame * test(aws-lambda): the stored probe holds the ffprobe JSON and the final frame * perf(producer): a distributed chunk encodes while it captures * perf(producer): the audio task logs where its mix spends its time One line per audio stage: prepare, groups, mix, master, encode and the peak check, in ms. * perf(engine): locked warmup ticks stop sleeping once the page is ready * perf(engine): a window reaching a stored video's end takes its frame count from stored facts * fix(producer): the cloud audio task logs its phases * perf(engine): stored facts keep the last packet length so late-start windows skip the tail decode * fix(engine): a probe spawns without waiting when no stored facts are declared * chore(aws-lambda): shorten comments over the line limit * fix(engine): warmup keeps pacing after a failed tick; stored final frames check ffprobe major * test(engine): the recorded ffprobe major matches the build's own banner * test(engine): the version-banner probes go through a named binary like the other spawns
24 lines
941 B
TypeScript
24 lines
941 B
TypeScript
// Shared by every render: project files and plan-v2 artifacts by SHA-256. Dependency-free for CDK.
|
|
|
|
export const CONTENT_STORE_PREFIX = "cas/sha256";
|
|
export const CONTENT_STORE_RETENTION_DAYS = 30;
|
|
/** Reusing an object at least this old rewrites it, so a plan's objects outlive it by 23+ days. */
|
|
export const CONTENT_STORE_REFRESH_AFTER_DAYS = 7;
|
|
|
|
export function contentStoreUri(bucket: string, sha256: string): string {
|
|
if (!/^[a-f0-9]{64}$/.test(sha256)) {
|
|
throw new Error(
|
|
`[contentStore] expected lowercase SHA-256 digest, got ${JSON.stringify(sha256)}`,
|
|
);
|
|
}
|
|
return `s3://${bucket}/${CONTENT_STORE_PREFIX}/${sha256.slice(0, 2)}/${sha256}`;
|
|
}
|
|
|
|
export function probeFactsUri(bucket: string, sha256: string): string {
|
|
return `${contentStoreUri(bucket, sha256)}.probe.v2.json`;
|
|
}
|
|
|
|
export function audioSidecarUri(bucket: string, sha256: string): string {
|
|
return `${contentStoreUri(bucket, sha256)}.audio.m4a`;
|
|
}
|