MCPcopy Create free account
hub / github.com/Openpanel-dev/openpanel / yieldToEventLoop

Function yieldToEventLoop

apps/worker/src/jobs/import.ts:29–33  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

27const BATCH_SIZE = Number.parseInt(process.env.IMPORT_BATCH_SIZE || '5000', 10);
28
29function yieldToEventLoop(): Promise<void> {
30 return new Promise((resolve) => {
31 setTimeout(resolve, 100);
32 });
33}
34
35const RESUMABLE_STEPS = ['creating_sessions', 'moving', 'backfilling_sessions'];
36

Callers 2

flushProfilesFunction · 0.85
importJobFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected