mirror of
https://github.com/matrix-org/dendrite.git
synced 2026-01-10 15:43:09 -06:00
Add timeout back with longer value
This commit is contained in:
parent
c1f3c0789e
commit
19875b7a42
|
|
@ -29,6 +29,8 @@ func (a *FederationInternalAPI) MakeJoin(
|
||||||
func (a *FederationInternalAPI) SendJoin(
|
func (a *FederationInternalAPI) SendJoin(
|
||||||
ctx context.Context, origin, s spec.ServerName, event gomatrixserverlib.PDU,
|
ctx context.Context, origin, s spec.ServerName, event gomatrixserverlib.PDU,
|
||||||
) (res gomatrixserverlib.SendJoinResponse, err error) {
|
) (res gomatrixserverlib.SendJoinResponse, err error) {
|
||||||
|
ctx, cancel := context.WithTimeout(ctx, time.Minute*5)
|
||||||
|
defer cancel()
|
||||||
ires, err := a.federation.SendJoin(ctx, origin, s, event)
|
ires, err := a.federation.SendJoin(ctx, origin, s, event)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return &fclient.RespSendJoin{}, err
|
return &fclient.RespSendJoin{}, err
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue