Skip to content
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

Feature Request: include mirror stats in /debug/querylogz output #17697

Open
maxenglander opened this issue Feb 4, 2025 · 0 comments · May be fixed by #17698
Open

Feature Request: include mirror stats in /debug/querylogz output #17697

maxenglander opened this issue Feb 4, 2025 · 0 comments · May be fixed by #17698
Assignees
Labels
Component: Query Serving Type: Enhancement Logical improvement (somewhere between a bug and feature)

Comments

@maxenglander
Copy link
Collaborator

Feature Description

Mirror query stats are included in Logstats.

MirrorSourceExecuteTime time.Duration
MirrorTargetExecuteTime time.Duration
MirrorTargetError error

However, they do not appear in /debug/querylogz output:

querylogzTmpl = template.Must(template.New("example").Funcs(querylogzFuncMap).Parse(`
<tr class="{{.ColorLevel}}">
<td>{{.Method}}</td>
<td>{{.ContextHTML}}</td>
<td>{{.EffectiveCaller}}</td>
<td>{{.ImmediateCaller}}</td>
<td>{{.SessionUUID}}</td>
<td>{{.StartTime | stampMicro}}</td>
<td>{{.EndTime | stampMicro}}</td>
<td>{{.TotalTime.Seconds}}</td>
<td>{{.PlanTime.Seconds}}</td>
<td>{{.ExecuteTime.Seconds}}</td>
<td>{{.CommitTime.Seconds}}</td>
<td>{{.StmtType}}</td>
<td>{{.SQL | .Parser.TruncateForUI | unquote | cssWrappable}}</td>
<td>{{.ShardQueries}}</td>
<td>{{.RowsAffected}}</td>
<td>{{.ErrorStr}}</td>
</tr>
`))

Add them to query log output.

Use Case(s)

This is useful for being able to see how query mirroring is performing.

@maxenglander maxenglander added the Needs Triage This issue needs to be correctly labelled and triaged label Feb 4, 2025
@mattlord mattlord added Type: Enhancement Logical improvement (somewhere between a bug and feature) Component: Query Serving and removed Needs Triage This issue needs to be correctly labelled and triaged labels Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Query Serving Type: Enhancement Logical improvement (somewhere between a bug and feature)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants