mirror of
https://github.com/hoernschen/dendrite.git
synced 2024-12-26 15:08:28 +00:00
Use only origin server to speed things up
This commit is contained in:
parent
57be026e81
commit
f54063a61a
1 changed files with 11 additions and 9 deletions
|
@ -466,13 +466,14 @@ func (t *txnReq) processDeviceListUpdate(ctx context.Context, e gomatrixserverli
|
|||
}
|
||||
}
|
||||
|
||||
func (t *txnReq) getServers(ctx context.Context, roomID string) []gomatrixserverlib.ServerName {
|
||||
func (t *txnReq) getServers(_ context.Context, _ string) []gomatrixserverlib.ServerName {
|
||||
t.serversMutex.Lock()
|
||||
defer t.serversMutex.Unlock()
|
||||
if t.servers != nil {
|
||||
return t.servers
|
||||
}
|
||||
t.servers = []gomatrixserverlib.ServerName{t.Origin}
|
||||
/*
|
||||
serverReq := &api.QueryServerJoinedToRoomRequest{
|
||||
RoomID: roomID,
|
||||
}
|
||||
|
@ -481,6 +482,7 @@ func (t *txnReq) getServers(ctx context.Context, roomID string) []gomatrixserver
|
|||
t.servers = append(t.servers, serverRes.ServerNames...)
|
||||
util.GetLogger(ctx).Infof("Found %d server(s) to query for missing events in %q", len(t.servers), roomID)
|
||||
}
|
||||
*/
|
||||
return t.servers
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue