mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-07-31 13:22:46 +00:00
Fix slow querying of cross-signing signatures
This commit is contained in:
parent
0843bd776e
commit
a553fe7705
4 changed files with 12 additions and 7 deletions
|
@ -99,7 +99,11 @@ func (r *queryKeysRequest) GetTimeout() time.Duration {
|
|||
if r.Timeout == 0 {
|
||||
return 10 * time.Second
|
||||
}
|
||||
return time.Duration(r.Timeout) * time.Millisecond
|
||||
timeout := time.Duration(r.Timeout) * time.Millisecond
|
||||
if timeout > time.Second*20 {
|
||||
timeout = time.Second * 20
|
||||
}
|
||||
return timeout
|
||||
}
|
||||
|
||||
func QueryKeys(req *http.Request, keyAPI api.ClientKeyAPI, device *userapi.Device) util.JSONResponse {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue