Common -> internal

This commit is contained in:
Neil Alexander 2020-05-21 15:11:50 +01:00
parent f19109a45c
commit 8121ff929b
9 changed files with 9 additions and 25 deletions

View file

@ -15,7 +15,7 @@
package main
import (
"github.com/matrix-org/dendrite/common/basecomponent"
"github.com/matrix-org/dendrite/internal/basecomponent"
"github.com/matrix-org/dendrite/serverkeyapi"
)

View file

@ -4,12 +4,7 @@ import (
"context"
"errors"
<<<<<<< HEAD:serverkeyapi/storage/cache/keydb.go
"github.com/matrix-org/dendrite/common/caching"
=======
"github.com/matrix-org/dendrite/internal/caching"
"github.com/matrix-org/dendrite/internal/keydb"
>>>>>>> master:internal/keydb/cache/keydb.go
"github.com/matrix-org/gomatrixserverlib"
)

View file

@ -21,15 +21,9 @@ import (
"golang.org/x/crypto/ed25519"
<<<<<<< HEAD:serverkeyapi/storage/keydb.go
"github.com/matrix-org/dendrite/common"
"github.com/matrix-org/dendrite/serverkeyapi/storage/postgres"
"github.com/matrix-org/dendrite/serverkeyapi/storage/sqlite3"
=======
"github.com/matrix-org/dendrite/internal"
"github.com/matrix-org/dendrite/internal/keydb/postgres"
"github.com/matrix-org/dendrite/internal/keydb/sqlite3"
>>>>>>> master:internal/keydb/keydb.go
"github.com/matrix-org/gomatrixserverlib"
)

View file

@ -22,13 +22,8 @@ import (
"golang.org/x/crypto/ed25519"
<<<<<<< HEAD:serverkeyapi/storage/keydb_wasm.go
"github.com/matrix-org/dendrite/common"
"github.com/matrix-org/dendrite/serverkeyapi/storage/sqlite3"
=======
"github.com/matrix-org/dendrite/internal"
"github.com/matrix-org/dendrite/internal/keydb/sqlite3"
>>>>>>> master:internal/keydb/keydb_wasm.go
"github.com/matrix-org/gomatrixserverlib"
)

View file

@ -5,7 +5,7 @@ import (
"errors"
"net/http"
"github.com/matrix-org/dendrite/common/caching"
"github.com/matrix-org/dendrite/internal/caching"
"github.com/matrix-org/gomatrixserverlib"
)

View file

@ -3,7 +3,7 @@ package api
import (
"context"
commonHTTP "github.com/matrix-org/dendrite/common/http"
commonHTTP "github.com/matrix-org/dendrite/internal/http"
"github.com/matrix-org/gomatrixserverlib"
"github.com/opentracing/opentracing-go"

View file

@ -3,8 +3,8 @@ package internal
import (
"context"
"github.com/matrix-org/dendrite/common/caching"
"github.com/matrix-org/dendrite/common/config"
"github.com/matrix-org/dendrite/internal/caching"
"github.com/matrix-org/dendrite/internal/config"
"github.com/matrix-org/dendrite/serverkeyapi/api"
"github.com/matrix-org/dendrite/serverkeyapi/storage"
"github.com/matrix-org/gomatrixserverlib"

View file

@ -4,7 +4,7 @@ import (
"encoding/json"
"net/http"
"github.com/matrix-org/dendrite/common"
"github.com/matrix-org/dendrite/internal"
"github.com/matrix-org/dendrite/serverkeyapi/api"
"github.com/matrix-org/gomatrixserverlib"
"github.com/matrix-org/util"
@ -12,7 +12,7 @@ import (
func (s *ServerKeyAPI) SetupHTTP(servMux *http.ServeMux) {
servMux.Handle(api.ServerKeyQueryPublicKeyPath,
common.MakeInternalAPI("queryPublicKeys", func(req *http.Request) util.JSONResponse {
internal.MakeInternalAPI("queryPublicKeys", func(req *http.Request) util.JSONResponse {
result := map[gomatrixserverlib.PublicKeyLookupRequest]gomatrixserverlib.PublicKeyLookupResult{}
request := api.QueryPublicKeysRequest{}
response := api.QueryPublicKeysResponse{}
@ -39,7 +39,7 @@ func (s *ServerKeyAPI) SetupHTTP(servMux *http.ServeMux) {
}),
)
servMux.Handle(api.ServerKeyInputPublicKeyPath,
common.MakeInternalAPI("inputPublicKeys", func(req *http.Request) util.JSONResponse {
internal.MakeInternalAPI("inputPublicKeys", func(req *http.Request) util.JSONResponse {
request := api.InputPublicKeysRequest{}
response := api.InputPublicKeysResponse{}
if err := json.NewDecoder(req.Body).Decode(&request); err != nil {

View file

@ -4,7 +4,7 @@ import (
"crypto/ed25519"
"encoding/base64"
"github.com/matrix-org/dendrite/common/basecomponent"
"github.com/matrix-org/dendrite/internal/basecomponent"
"github.com/matrix-org/dendrite/serverkeyapi/internal"
"github.com/matrix-org/dendrite/serverkeyapi/storage"
"github.com/matrix-org/dendrite/serverkeyapi/storage/cache"