You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
finer grained ability to control values like maxDuration for server actions
Non-Goals
I don't really care about other route segment config than that, but other things might be useful.
Background
according to the docs server actions take the max duration of the page they are used on.
This is kludgy for a few reasons
the actual page the action is used on loads fast, but this action can take a long time, and the loading time of one has nothing to do with the processing time of the other. I don't want to allow that page to have a really long max duration but i cannot apply it to just the action
this action is used in like 6 different pages, which are hard to figure out because the action is called in nested components, so it requires traversing the dependency graph to even figure out what pages need this. i have to increase max duration for all of them, and if it ever gets used elsewhere again, our team will probably forget to propagate that config.
Proposal
allow maxDuration (and potentially other route segment configs as relevant) to be associated directly with a server action
apply it to the server action invocation, have it take precedence over the config on the page/layout itself.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Goals
maxDuration
for server actionsNon-Goals
I don't really care about other route segment config than that, but other things might be useful.
Background
according to the docs server actions take the max duration of the page they are used on.
This is kludgy for a few reasons
Proposal
maxDuration
(and potentially other route segment configs as relevant) to be associated directly with a server actionBeta Was this translation helpful? Give feedback.
All reactions