feat(catalog): queue furniture imports with history and matching file attachments
This commit is contained in:
1 parent
775d14f861
commit
2619bec165
16 files changed
+1016
-232
No files matched your search
@@ -20,3 +20,18 @@ export const onRequestError: Instrumentation.onRequestError = async (
|
||||
: null,
|
||||
});
|
||||
};
|
||||
|
||||
export async function register() {
|
||||
if (
|
||||
process.env.NEXT_RUNTIME !== "nodejs" ||
|
||||
process.env.NEXT_PHASE === "phase-production-build"
|
||||
)
|
||||
return;
|
||||
const { drainFurnitureImports } = await import(
|
||||
"@/lib/services/furni-job-worker"
|
||||
);
|
||||
const timer = setInterval(() => {
|
||||
void drainFurnitureImports();
|
||||
}, 30000);
|
||||
timer.unref();
|
||||
}
|
||||
Reference in new issue
Block a user