From e4c531b7d132c910cb288ac2a56071ef8624b145 Mon Sep 17 00:00:00 2001 From: Neil Alexander Date: Fri, 30 Jul 2021 11:19:29 +0100 Subject: [PATCH] Logging --- keyserver/internal/cross_signing.go | 2 +- keyserver/internal/internal.go | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/keyserver/internal/cross_signing.go b/keyserver/internal/cross_signing.go index 2873dafd..2864417e 100644 --- a/keyserver/internal/cross_signing.go +++ b/keyserver/internal/cross_signing.go @@ -239,7 +239,7 @@ func (a *KeyInternalAPI) processOtherSignatures( return nil } -func (a *KeyInternalAPI) crossSigningKeys( +func (a *KeyInternalAPI) crossSigningKeysFromDatabase( ctx context.Context, req *api.QueryKeysRequest, res *api.QueryKeysResponse, ) { for userID := range req.UserToDevices { diff --git a/keyserver/internal/internal.go b/keyserver/internal/internal.go index 6c709c5a..b04b077e 100644 --- a/keyserver/internal/internal.go +++ b/keyserver/internal/internal.go @@ -227,7 +227,7 @@ func (a *KeyInternalAPI) QueryKeys(ctx context.Context, req *api.QueryKeysReques res.Failures = make(map[string]interface{}) // get cross-signing keys from the database - a.crossSigningKeys(ctx, req, res) + a.crossSigningKeysFromDatabase(ctx, req, res) // make a map from domain to device keys domainToDeviceKeys := make(map[string]map[string][]string) @@ -448,6 +448,7 @@ func (a *KeyInternalAPI) queryRemoteKeysOnServer( } } queryKeysResp, err := a.FedClient.QueryKeys(fedCtx, gomatrixserverlib.ServerName(serverName), devKeys) + util.GetLogger(fedCtx).Infof("Query keys response: %+v", queryKeysResp) if err == nil { resultCh <- &queryKeysResp return