Fastify maxParamLength option

Is it possible to set the maxParamLength option in a boot/route plugin? Some of my params are over 100 characters long and I need to be able to adjust it, intellisense isn't providing anything super obvious
5 Replies
airhorns
airhorns8mo ago
sadly no, there isn't a great way to adjust it, but for silly gadget reasons. we preboot the fastify server in order to reduce cold start times, but that means that those server-level configs are set once at the start and fastify doesn't allow them to be changed 😦 that said, i think we can raise the limit we use when we start the server so you aren't stuck, and we have plans for the future to allow much more control over this kind of thing! what's the limit you'd have set?
Dave
DaveOP8mo ago
400 would be a good value, plenty of room for us
airhorns
airhorns8mo ago
ok i will let you know when that is raised!
Dave
DaveOP8mo ago
Thanks Harry 🙂
airhorns
airhorns8mo ago
this change has been rolled out, the platform wide limit is now 500 chars 👍

Did you find this page helpful?