-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
feat(sql): table_writer_metrics() and memory_metrics() for better observability #2318
Conversation
…ric-observability
|
I'd say that we should clearly state in the docs that memory tags (and any metrics) are subject to change.
+1 from me for enabling metrics by default.
I'd suggest returning tuples instead of columns. This would make any integration simpler and less coupled with our tags and metrics. WDYT? |
@puzpuzpuz I agree with everything you wrote! I will change the format to return tuples and later send a separate PR to enable metrics by default. |
also: scope metrics table functions in the sys. pseudo-schema to avoid polluting global function namespace.
@puzpuzpuz can you please re-check? |
core/src/main/java/io/questdb/griffin/engine/functions/table/MemoryMetricsFunctionFactory.java
Outdated
Show resolved
Hide resolved
...c/main/java/io/questdb/griffin/engine/functions/table/TableWriterMetricsFunctionFactory.java
Outdated
Show resolved
Hide resolved
core/src/main/java/io/questdb/griffin/engine/table/MemoryMetricsRecordCursorFactory.java
Outdated
Show resolved
Hide resolved
core/src/main/java/io/questdb/griffin/engine/table/StringLongTuplesRecordCursor.java
Outdated
Show resolved
Hide resolved
core/src/test/java/io/questdb/griffin/engine/table/MemoryMetricsRecordCursorFactoryTest.java
Show resolved
Hide resolved
that's more idiomatic for QuestDB
[PR Coverage check]😍 pass : 91 / 94 (96.81%) file detail
|
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'd prefer a function for all prometheus metrics, all in one, not just writer and memory separately.
It allows to query:
table writer metrics expose these: TOTAL_COMMITS, O3_COMMITS, ROLLBACKS, COMMITTED_ROWS, PHYSICALLY_WRITTEN_ROWS
memory utilization metrics: with a breakdown per tag.
For #1 to work metrics have to be enabled in QuestDB configuration. #2 is always enabled.
Questions I'd like reviewers to think about: