aboutsummaryrefslogtreecommitdiff
path: root/clientapi/routing/membership.go
diff options
context:
space:
mode:
authorNeil Alexander <neilalexander@users.noreply.github.com>2020-09-03 15:22:16 +0100
committerGitHub <noreply@github.com>2020-09-03 15:22:16 +0100
commit6150de6cb3611ffc61ce10ed6714f65e51e38e78 (patch)
tree7c89defb2634b19497f4911e9851f35d8b101af7 /clientapi/routing/membership.go
parent74743ac8ae3cc439862acd15d13ba4123d745598 (diff)
FIFO ordering of input events (#1386)
* Initial FIFOing of roomserver inputs * Remove EventID response from api.InputRoomEventsResponse * Don't send back event ID unnecessarily * Fix ordering hopefully * Reduce copies, use buffered task channel to reduce contention on other rooms * Fix error handling
Diffstat (limited to 'clientapi/routing/membership.go')
-rw-r--r--clientapi/routing/membership.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/clientapi/routing/membership.go b/clientapi/routing/membership.go
index cba19a24..202662ab 100644
--- a/clientapi/routing/membership.go
+++ b/clientapi/routing/membership.go
@@ -75,13 +75,12 @@ func sendMembership(ctx context.Context, accountDB accounts.Database, device *us
return jsonerror.InternalServerError()
}
- _, err = roomserverAPI.SendEvents(
+ if err = roomserverAPI.SendEvents(
ctx, rsAPI,
[]gomatrixserverlib.HeaderedEvent{event.Event.Headered(roomVer)},
cfg.Matrix.ServerName,
nil,
- )
- if err != nil {
+ ); err != nil {
util.GetLogger(ctx).WithError(err).Error("SendEvents failed")
return jsonerror.InternalServerError()
}