Skip to content

Commit

Permalink
stats/opencensus: Handle PickerUpdated to avoid "Received unexpected …
Browse files Browse the repository at this point in the history
…stats" error (#7153)
  • Loading branch information
townba authored Apr 22, 2024
1 parent 34c7675 commit 34de5cf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions stats/opencensus/stats.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,9 @@ func recordRPCData(ctx context.Context, s stats.RPCStats, mi *metricsInfo) {
return
}
switch st := s.(type) {
case *stats.InHeader, *stats.OutHeader, *stats.InTrailer, *stats.OutTrailer:
// Headers and Trailers are not relevant to the measures, as the
// measures concern number of messages and bytes for messages. This
case *stats.InHeader, *stats.OutHeader, *stats.InTrailer, *stats.OutTrailer, *stats.PickerUpdated:
// Headers, Trailers, and picker updates are not relevant to the measures,
// as the measures concern number of messages and bytes for messages. This
// aligns with flow control.
case *stats.Begin:
recordDataBegin(ctx, mi, st)
Expand Down

0 comments on commit 34de5cf

Please sign in to comment.