A self-hostable bookmark-everything app (links, notes and images) with AI-based automatic tagging and full text search
feat: make asset preprocessing worker timeout configurable
Claude91784cd20cc2
diff --git a/apps/workers/workers/assetPreprocessingWorker.ts b/apps/workers/workers/assetPreprocessingWorker.tsindex ff16906d..b585a15e 100644--- a/apps/workers/workers/assetPreprocessingWorker.ts+++ b/apps/workers/workers/assetPreprocessingWorker.ts@@ -62,7 +62,7 @@ export class AssetPreprocessingWorker {{concurrency: serverConfig.assetPreprocessing.numWorkers,pollIntervalMs: 1000,- timeoutSecs: 30,+ timeoutSecs: serverConfig.assetPreprocessing.jobTimeoutSec,},);diff --git a/docs/docs/03-configuration.md b/docs/docs/03-configuration.mdindex 0975f1a7..b89460e6 100644--- a/docs/docs/03-configuration.md+++ b/docs/docs/03-configuration.md@@ -27,6 +27,7 @@ The app is mainly configured by environment variables. All the used environment| SEARCH_JOB_TIMEOUT_SEC | No | 30 | How long to wait for a search indexing job to finish before timing out. Increase this if you have large bookmarks with extensive content that takes longer to index. || WEBHOOK_NUM_WORKERS | No | 1 | Number of concurrent workers for webhook delivery. Increase this if you have multiple webhook endpoints or high webhook traffic. || ASSET_PREPROCESSING_NUM_WORKERS | No | 1 | Number of concurrent workers for asset preprocessing tasks (image processing, OCR, etc.). Increase this if you have many images or documents that need processing. |+| ASSET_PREPROCESSING_JOB_TIMEOUT_SEC | No | 60 | How long to wait for an asset preprocessing job to finish before timing out. Increase this if you have large images or PDFs that take longer to process. || RULE_ENGINE_NUM_WORKERS | No | 1 | Number of concurrent workers for rule engine processing. Increase this if you have complex automation rules that need to be processed quickly. |## Asset Storagediff --git a/packages/shared/config.ts b/packages/shared/config.tsindex 60beae1e..1bc8f19d 100644--- a/packages/shared/config.ts+++ b/packages/shared/config.ts@@ -93,6 +93,7 @@ const allEnv = z.object({SEARCH_JOB_TIMEOUT_SEC: z.coerce.number().default(30),WEBHOOK_NUM_WORKERS: z.coerce.number().default(1),ASSET_PREPROCESSING_NUM_WORKERS: z.coerce.number().default(1),+ ASSET_PREPROCESSING_JOB_TIMEOUT_SEC: z.coerce.number().default(60),RULE_ENGINE_NUM_WORKERS: z.coerce.number().default(1),CRAWLER_DOWNLOAD_BANNER_IMAGE: stringBool("true"),CRAWLER_STORE_SCREENSHOT: stringBool("true"),@@ -353,6 +354,7 @@ const serverConfigSchema = allEnv.transform((val, ctx) => {allowedInternalHostnames: val.CRAWLER_ALLOWED_INTERNAL_HOSTNAMES,assetPreprocessing: {numWorkers: val.ASSET_PREPROCESSING_NUM_WORKERS,+ jobTimeoutSec: val.ASSET_PREPROCESSING_JOB_TIMEOUT_SEC,},ruleEngine: {numWorkers: val.RULE_ENGINE_NUM_WORKERS,