cockroachdb / cockroach

CockroachDB — the cloud native, distributed SQL database designed for high availability, effortless scale, and control over data placement.
https://www.cockroachlabs.com
Other
30.16k stars 3.82k forks source link

observability, jobs: multiple progress phases #67665

Open shermanCRL opened 3 years ago

shermanCRL commented 3 years ago

Problem

When observing progress of a job, we only have a facility for one “percent complete”. Jobs often have multiple phases, but they are lumped under one number. The user might see rapid progress to (say) 80% and then the last 20% goes more slowly -- because it’s different work!

Desired solution

A facility to record & display multiple (arbitrarily labelled) progress metrics. In the case of restore, it might be the various phases:

It would be great to let the user see which ones are how far along, and which are upcoming.

Each phase could have its own definition of progress:

Jira issue: CRDB-8697

Epic CRDB-32144

shermanCRL commented 3 years ago

Some similarity in spirit to https://pkg.go.dev/testing#B.ReportMetric

amruss commented 3 years ago

Here is how we currently show progress:

Screen Shot 2021-10-25 at 12 37 32 PM

Some points from discussion: