Skip to content

Commit e7f34a6

Browse files
Copilotaegilops
andcommitted
Add CLI arguments for snapshot ingestion delays
Co-authored-by: aegilops <[email protected]>
1 parent 3d5f9ad commit e7f34a6

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/cli.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ async function main() {
5151
.option("submit-languages", { type: "array", describe: "Limit snapshot submission to these languages (e.g., JavaScript,TypeScript,Python,Maven)." })
5252
.option("component-detection-bin", { type: "string", describe: "Path to a local component-detection executable to use for snapshot submission (skips download)." })
5353
.option("force-submission", { type: "boolean", default: false, describe: "Always run Dependency Submission for scanned branches before fetching diffs." })
54+
.option("snapshot-ingestion-delay", { type: "number", default: 1500, describe: "Delay (ms) after snapshot submission to allow ingestion before dependency review (default: 1500ms)" })
55+
.option("retry-ingestion-delay", { type: "number", default: 3000, describe: "Delay (ms) after snapshot submission before retrying dependency review on 404 (default: 3000ms)" })
5456
.option("debug", { type: "boolean", default: false, describe: "Enable debug logging" })
5557
.check(args => {
5658
const syncing = !!args.syncSboms;
@@ -141,6 +143,8 @@ async function main() {
141143
forceSubmission: argv["force-submission"] as boolean,
142144
submitLanguages: (argv["submit-languages"] as string[] | undefined) || undefined,
143145
componentDetectionBinPath: argv["component-detection-bin"] as string | undefined,
146+
snapshotIngestionDelayMs: argv["snapshot-ingestion-delay"] as number | undefined,
147+
retryIngestionDelayMs: argv["retry-ingestion-delay"] as number | undefined,
144148
}) : undefined;
145149

146150
if (collector && (argv.sbomCache || argv.syncSboms)) {

0 commit comments

Comments
 (0)