xds: add type url to log

This commit is contained in:
Denis Mishin 2023-11-01 12:40:27 -04:00
parent 53573dc046
commit df9f814bc1

View file

@ -108,6 +108,7 @@ func (mgr *Manager) DeltaAggregatedResources(
// neither an ACK or a NACK
case req.GetErrorDetail() != nil:
log.Info(ctx).
Str("type-url", req.GetTypeUrl()).
Any("error-detail", req.GetErrorDetail()).
Msg("xdsmgr: nack")
// a NACK
@ -118,6 +119,7 @@ func (mgr *Manager) DeltaAggregatedResources(
}
case req.GetResponseNonce() == mgr.nonce:
log.Info(ctx).
Str("type-url", req.GetTypeUrl()).
Msg("xdsmgr: ack")
// an ACK for the last response
// - set the client resource versions to the current resource versions
@ -128,6 +130,7 @@ func (mgr *Manager) DeltaAggregatedResources(
default:
// an ACK for a response that's not the last response
log.Info(ctx).
Str("type-url", req.GetTypeUrl()).
Msg("xdsmgr: ack")
}
@ -209,6 +212,7 @@ func (mgr *Manager) DeltaAggregatedResources(
return ctx.Err()
case res := <-outgoing:
log.Info(ctx).
Str("type-url", res.GetTypeUrl()).
Int("resource-count", len(res.GetResources())).
Int("removed-resource-count", len(res.GetRemovedResources())).
Msg("xdsmgr: sending resources")