aboutsummaryrefslogtreecommitdiff
path: root/federationapi/api
diff options
context:
space:
mode:
authorNeil Alexander <neilalexander@users.noreply.github.com>2021-06-30 12:05:58 +0100
committerGitHub <noreply@github.com>2021-06-30 12:05:58 +0100
commitb7a2d369c0b4c18208db5f44a29a4829dd7e39f3 (patch)
treeade8b0e87d696491fb613d6415b4b0fade2f7c69 /federationapi/api
parent0e69212206d7abbe5d3e4c65b4ae369a0067bdc9 (diff)
Change how servers are selected for missing auth/prev events (#1892)
* Change how servers are selected for missing auth/prev events * Shuffle order * Move ServersInRoomProvider into api package
Diffstat (limited to 'federationapi/api')
-rw-r--r--federationapi/api/servers.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/federationapi/api/servers.go b/federationapi/api/servers.go
new file mode 100644
index 00000000..6bb15763
--- /dev/null
+++ b/federationapi/api/servers.go
@@ -0,0 +1,11 @@
+package api
+
+import (
+ "context"
+
+ "github.com/matrix-org/gomatrixserverlib"
+)
+
+type ServersInRoomProvider interface {
+ GetServersForRoom(ctx context.Context, roomID string, event *gomatrixserverlib.Event) []gomatrixserverlib.ServerName
+}