From de30ef10f49e5a38069397476ba365a6008b4b46 Mon Sep 17 00:00:00 2001 From: Neil Alexander Date: Tue, 29 Jun 2021 15:00:56 +0100 Subject: [PATCH] Remove mutex --- federationapi/routing/send.go | 5 ----- 1 file changed, 5 deletions(-) diff --git a/federationapi/routing/send.go b/federationapi/routing/send.go index 1ff15173..0a20d87b 100644 --- a/federationapi/routing/send.go +++ b/federationapi/routing/send.go @@ -618,14 +618,9 @@ func checkAllowedByState(e *gomatrixserverlib.Event, stateEvents []*gomatrixserv return gomatrixserverlib.Allowed(e, &authUsingState) } -var processEventWithMissingStateMutexes = internal.NewMutexByRoom() - func (t *txnReq) processEventWithMissingState( ctx context.Context, e *gomatrixserverlib.Event, roomVersion gomatrixserverlib.RoomVersion, ) error { - processEventWithMissingStateMutexes.Lock(e.RoomID()) - defer processEventWithMissingStateMutexes.Unlock(e.RoomID()) - // Do this with a fresh context, so that we keep working even if the // original request times out. With any luck, by the time the remote // side retries, we'll have fetched the missing state.