N
Nuxt4d ago
Equinox

set idleTimeout when using bun preset

how do i set the idleTimeout parameter used by the Bun.serve server underneath when using nitro preset bun I cannot use other preset than bun, otherwise i get a weird error about ofetch missing as a package and if I use bun, I'm building a software with analytical queries which are supposed to take a longtime, but they end up 502 Gateawaiting because of idleTimeout so if anyone has any clues I'm interested
2 Replies
kapa.ai
kapa.ai4d ago
Hi @Equinox. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- The provided knowledge sources don’t mention any way to configure idleTimeout (or other Bun.serve options) through Nitro’s bun preset, nor an escape hatch to pass custom options directly to Bun.serve. Nitro / Nuxt docs and issues in the sources only touch Bun in terms of: - Using the Bun runtime and commands like bun --bun run dev -o. [Bun dev docs] - Recognising Bun lockfiles (bun.lock, bun.lockb). [bun.lock PR; bun.lock docs] There is no documented nitro config key (in these sources) that maps to Bun’s idleTimeout, nor any Bun‑specific server options. Given that, based only on the available information: - I’m not able to point to a supported way (in these docs) to change idleTimeout when using preset: 'bun'. - The sources also don’t document a recommended workaround for long‑running analytical requests on Bun (e.g. switching preset, custom entry, or configuration in Nitro). If you need this today, the next step would be to raise this upstream in Nitro’s issue tracker, as Nuxt maintainers already direct runtime/server‑side behaviour questions there in similar cases. [Netlify rate limit issue] ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai4d ago
<@76841662445256704> Kapa.ai is still learning and improving, please let me know how I did by reacting below.

Did you find this page helpful?