-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
backupccl: hookup tracing aggregator events from the restore job #108359
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM overall
msg, ok := event.(protoutil.Message) | ||
if !ok { | ||
// This should never happen but if it does skip the aggregated event. | ||
log.Warningf(ctx, "event is not a protoutil.Message: %T", event) | ||
return | ||
} | ||
data := make([]byte, msg.Size()) | ||
if _, err := msg.MarshalTo(data); err != nil { | ||
// This should never happen but if it does skip the aggregated event. | ||
log.Warningf(ctx, "failed to unmarshal aggregated event: %v", err.Error()) | ||
return | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps this could be a method on bulkutil.TracingAggregatorEvent so that it can be shared?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i made it a util method instead of putting it on the interface since all events would have the same impl
This change builds on top of cockroachdb#107994 and wires up each restore data processor to emit TracingAggregatorEvents to the job coordinator. These events are periodically flushed to files in the `job_info` table and are consumable via the DBConsole Job Details page. Fixes: cockroachdb#100126 Release note: None
b0a7126
to
e89c74f
Compare
It looks like your PR touches production code but doesn't add or edit any test code. Did you consider adding tests to your PR? 🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf. |
TFTR! bors r=stevendanna |
Build succeeded: |
This change builds on top of #107994 and wires up each restore
data processor to emit TracingAggregatorEvents to the job coordinator.
These events are periodically flushed to files in the
job_info
table and are consumable via the DBConsole Job Details page.
Fixes: #100126
Release note: None