-
-
Notifications
You must be signed in to change notification settings - Fork 579
timeout on request? max post data? #939
Comments
You would have to handle both of those cases yourself. I don’t have any example code on how to do either. Sorry.
…-----------
Mark Bates
On Feb 25, 2018, 12:16 PM -0500, James ***@***.***>, wrote:
hi
is it possible to set time out on every request?
can this be done in a middleware?
example will be highly appreciated :)
and also post form size limit?
thank you
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
i think there should be a default timeout settable in the context. |
I think that’s a great idea! Submit a PR. :)
…-----------
Mark Bates
On Feb 25, 2018, 9:07 PM -0500, James ***@***.***>, wrote:
i think there should be a default timeout settable in the context
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.
|
im glad to help, ive created a middleware , and it works perfect when it does not hit db pool limit. i can see timeout activating in the middleware, but i could not release the db connection. do you have any idea how i could release the db connection?
|
I don't know why you're having connection limit problems. looking at that code snippet I'm guessing you're using websockets, or something based on the Hijack code. It's probably related to that. You might want to stop using the pop transaction middleware, assuming you are, and manage those things by yourself. |
@markbates you are right, the pop middleware causes the problem. no matter if there is transaction or not in any action, it seems to contribute to a new connection request and therefore hang it im wondering how come there are not timeout for transaction request |
It is because statement timeouts need to be set inside postgres? |
The statement timeout will not fix this issue. I had to set idle_in_transaction_session_timeout in order to keep buffalo from eating up all the connections. Also I only have this issue in production. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
This issue was closed because it has been stalled for 5 days with no activity. |
hi
is it possible to set time out on every request?
can this be done in a middleware?
example will be highly appreciated :)
and also post form size limit?
thank you
The text was updated successfully, but these errors were encountered: