mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-08-01 22:02:46 +00:00
Logging
This commit is contained in:
parent
8630960141
commit
3939d54cc2
1 changed files with 5 additions and 6 deletions
|
@ -288,19 +288,15 @@ func (a *KeyInternalAPI) QueryKeys(ctx context.Context, req *api.QueryKeysReques
|
||||||
if _, ok := domainToCrossSigningKeys[domain]; !ok {
|
if _, ok := domainToCrossSigningKeys[domain]; !ok {
|
||||||
domainToCrossSigningKeys[domain] = make(map[string]struct{})
|
domainToCrossSigningKeys[domain] = make(map[string]struct{})
|
||||||
}
|
}
|
||||||
if _, ok := domainToCrossSigningKeys[domain][userID]; !ok {
|
|
||||||
domainToCrossSigningKeys[domain][userID] = struct{}{}
|
domainToCrossSigningKeys[domain][userID] = struct{}{}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if _, ok := res.SelfSigningKeys[userID]; !ok {
|
if _, ok := res.SelfSigningKeys[userID]; !ok {
|
||||||
if _, ok := domainToCrossSigningKeys[domain]; !ok {
|
if _, ok := domainToCrossSigningKeys[domain]; !ok {
|
||||||
domainToCrossSigningKeys[domain] = make(map[string]struct{})
|
domainToCrossSigningKeys[domain] = make(map[string]struct{})
|
||||||
}
|
}
|
||||||
if _, ok := domainToCrossSigningKeys[domain][userID]; !ok {
|
|
||||||
domainToCrossSigningKeys[domain][userID] = struct{}{}
|
domainToCrossSigningKeys[domain][userID] = struct{}{}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// attempt to satisfy key queries from the local database first as we should get device updates pushed to us
|
// attempt to satisfy key queries from the local database first as we should get device updates pushed to us
|
||||||
domainToDeviceKeys = a.remoteKeysFromDatabase(ctx, res, domainToDeviceKeys)
|
domainToDeviceKeys = a.remoteKeysFromDatabase(ctx, res, domainToDeviceKeys)
|
||||||
|
@ -320,6 +316,9 @@ func (a *KeyInternalAPI) QueryKeys(ctx context.Context, req *api.QueryKeysReques
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
util.GetLogger(ctx).Infof("Domain to cross-signing keys: %+v", domainToCrossSigningKeys)
|
||||||
|
util.GetLogger(ctx).Infof("Domain to device keys: %+v", domainToDeviceKeys)
|
||||||
|
|
||||||
// perform key queries for remote devices
|
// perform key queries for remote devices
|
||||||
a.queryRemoteKeys(ctx, req.Timeout, res, domainToDeviceKeys)
|
a.queryRemoteKeys(ctx, req.Timeout, res, domainToDeviceKeys)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue