I'm using a locally-hosted Large Language Model to generate bot replies, and sometimes a few seconds are needed to return a 200 OK to the webhook, which leads to the following error:
** (EXIT) time out
(elixir 1.15.0) lib/gen_server.ex:1074: GenServer.call/3
(ex_gram 0.40.0) lib/ex_gram/updates/webhook.ex:34: ExGram.Updates.Webhook.handle_cast/2
It would be nice to be able to increase the timeout from 5000ms to some longer interval or to return a 200 OK before calling long-running functions: what's the best way to do it?
I'm using a locally-hosted Large Language Model to generate bot replies, and sometimes a few seconds are needed to return a
200 OK
to the webhook, which leads to the following error:It would be nice to be able to increase the timeout from 5000ms to some longer interval or to return a
200 OK
before calling long-running functions: what's the best way to do it?Thanks.