mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
fix: EXR/HDR decode failures and batch network timeout
EXR: add ffmpeg fallback when ImageMagick lacks the OpenEXR delegate (common on macOS Homebrew installs). HDR: force 8-bit depth output to prevent CLAHE crash (hist_local requires VIPS_FORMAT_UCHAR). Batch: disable socket timeout and increase server requestTimeout to 30 min so large AI batches don't get killed by Node.js defaults.
This commit is contained in:
@@ -86,6 +86,12 @@ const app = Fastify({
|
||||
routerOptions: { maxParamLength: 500 },
|
||||
});
|
||||
|
||||
// Image processing (especially AI batch) can run for tens of minutes.
|
||||
// Node.js defaults to a 5-minute requestTimeout which kills long-running
|
||||
// connections. Set a generous default; per-route overrides disable it entirely.
|
||||
app.server.requestTimeout = 30 * 60 * 1000;
|
||||
app.server.headersTimeout = 60 * 1000;
|
||||
|
||||
app.removeContentTypeParser("application/json");
|
||||
app.addContentTypeParser("application/json", { parseAs: "string" }, (_request, body, done) => {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user