diff options
author | Kegsay <kegan@matrix.org> | 2020-09-07 14:47:59 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-07 14:47:59 +0100 |
commit | c992f4f1f44b0e43e52010b10bc0a82ddf26848d (patch) | |
tree | 5468390c58377a69f9ae30b6511667e011256e8a /federationapi | |
parent | 8589f8373e627f9229e729186ab800d3116c12da (diff) |
Remove current state server (#1405)
* Remove current state server
Closes #1365 #1272 #1357
* Remove current state server from scripts/docs
Diffstat (limited to 'federationapi')
-rw-r--r-- | federationapi/federationapi.go | 4 | ||||
-rw-r--r-- | federationapi/federationapi_test.go | 2 | ||||
-rw-r--r-- | federationapi/routing/routing.go | 2 |
3 files changed, 2 insertions, 6 deletions
diff --git a/federationapi/federationapi.go b/federationapi/federationapi.go index 9193685a..944e2797 100644 --- a/federationapi/federationapi.go +++ b/federationapi/federationapi.go @@ -16,7 +16,6 @@ package federationapi import ( "github.com/gorilla/mux" - currentstateAPI "github.com/matrix-org/dendrite/currentstateserver/api" eduserverAPI "github.com/matrix-org/dendrite/eduserver/api" federationSenderAPI "github.com/matrix-org/dendrite/federationsender/api" "github.com/matrix-org/dendrite/internal/config" @@ -38,12 +37,11 @@ func AddPublicRoutes( rsAPI roomserverAPI.RoomserverInternalAPI, federationSenderAPI federationSenderAPI.FederationSenderInternalAPI, eduAPI eduserverAPI.EDUServerInputAPI, - stateAPI currentstateAPI.CurrentStateInternalAPI, keyAPI keyserverAPI.KeyInternalAPI, ) { routing.Setup( fedRouter, keyRouter, cfg, rsAPI, eduAPI, federationSenderAPI, keyRing, - federation, userAPI, stateAPI, keyAPI, + federation, userAPI, keyAPI, ) } diff --git a/federationapi/federationapi_test.go b/federationapi/federationapi_test.go index 45346bc0..3c2e5bbb 100644 --- a/federationapi/federationapi_test.go +++ b/federationapi/federationapi_test.go @@ -31,7 +31,7 @@ func TestRoomsV3URLEscapeDoNot404(t *testing.T) { fsAPI := base.FederationSenderHTTPClient() // TODO: This is pretty fragile, as if anything calls anything on these nils this test will break. // Unfortunately, it makes little sense to instantiate these dependencies when we just want to test routing. - federationapi.AddPublicRoutes(base.PublicFederationAPIMux, base.PublicKeyAPIMux, &cfg.FederationAPI, nil, nil, keyRing, nil, fsAPI, nil, nil, nil) + federationapi.AddPublicRoutes(base.PublicFederationAPIMux, base.PublicKeyAPIMux, &cfg.FederationAPI, nil, nil, keyRing, nil, fsAPI, nil, nil) baseURL, cancel := test.ListenAndServe(t, base.PublicFederationAPIMux, true) defer cancel() serverName := gomatrixserverlib.ServerName(strings.TrimPrefix(baseURL, "https://")) diff --git a/federationapi/routing/routing.go b/federationapi/routing/routing.go index 7d60d15e..71a09d42 100644 --- a/federationapi/routing/routing.go +++ b/federationapi/routing/routing.go @@ -19,7 +19,6 @@ import ( "github.com/gorilla/mux" "github.com/matrix-org/dendrite/clientapi/jsonerror" - currentstateAPI "github.com/matrix-org/dendrite/currentstateserver/api" eduserverAPI "github.com/matrix-org/dendrite/eduserver/api" federationSenderAPI "github.com/matrix-org/dendrite/federationsender/api" "github.com/matrix-org/dendrite/internal/config" @@ -48,7 +47,6 @@ func Setup( keys gomatrixserverlib.JSONVerifier, federation *gomatrixserverlib.FederationClient, userAPI userapi.UserInternalAPI, - stateAPI currentstateAPI.CurrentStateInternalAPI, keyAPI keyserverAPI.KeyInternalAPI, ) { v2keysmux := keyMux.PathPrefix("/v2").Subrouter() |