0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-05-29 08:13:46 +02:00

modules/s_fetch: Add conf item for auth timeout; tweak event timeout default.

This commit is contained in:
Jason Volk 2019-04-26 05:28:18 -07:00
parent 10b8e1d08b
commit 0b8ebf8d09
2 changed files with 10 additions and 2 deletions

View file

@ -27,7 +27,14 @@ decltype(ircd::m::fetch::timeout)
ircd::m::fetch::timeout
{
{ "name", "ircd.m.fetch.timeout" },
{ "default", 10L },
{ "default", 5L },
};
decltype(ircd::m::fetch::auth_timeout)
ircd::m::fetch::auth_timeout
{
{ "name", "ircd.m.fetch.auth.timeout" },
{ "default", 15L },
};
decltype(ircd::m::fetch::hook)
@ -453,7 +460,7 @@ ircd::m::fetch::auth_chain(const room &room,
room.room_id, room.event_id, buf, std::move(opts)
};
request.wait(seconds(20)); //TODO: conf
request.wait(seconds(auth_timeout)); //TODO: conf
request.get();
const json::array &array
{

View file

@ -24,6 +24,7 @@ namespace ircd::m::fetch
extern ctx::context eval_context;
extern ctx::context request_context;
extern hookfn<vm::eval &> hook;
extern conf::item<seconds> auth_timeout;
extern conf::item<seconds> timeout;
extern conf::item<bool> enable;