Skip to content

system.query_views_log Introspection

The Query Views Log Introspection tool provides insights into all query view executions on your ClickHouse cluster. It tracks how materialized views, live views, and other view types are being executed and their performance metrics.

It provides multiple filters and more dashboards on the metrics of views for better intropsection.

Prerequisites

Note: Read access to the system.query_views_log table is required to use this introspection tool. Ensure your user has the necessary system table privileges.

UI

Query Views Log Use Cases

View Performance Analysis

  1. Monitor View Duration: Track average view execution times to identify slow views
  2. Analyze Read Patterns: Use read rows/bytes charts to understand data consumption
  3. Track Write Patterns: Monitor written rows/bytes to see view output volume
  4. Compare Views: Filter by view_name to compare performance across different views

Error Debugging

  1. Filter by Exception: Use exception_code filter to focus on failed view executions
  2. View Error Details: Expand rows to see full error messages
  3. Track Error Frequency: Use distribution chart to see error spikes
  4. Identify Problematic Views: Filter by view_name and exception to find views with issues

View Optimization

  1. Identify Slow Views: Sort by view_duration_ms to find views that need optimization
  2. Monitor Resource Usage: Track peak_memory_usage and read/write patterns
  3. Compare Time Periods: Use time range selector to compare performance over time
  4. Node Comparison: Filter by hostname to compare view performance across nodes

Materialized View Monitoring

  1. Track Materialization: Monitor written_rows and written_bytes to see materialization activity
  2. Monitor Lag: Check event times to identify delays in materialized view updates
  3. Resource Planning: Use read/write metrics for capacity planning
  4. View Health: Track exception rates to ensure views are functioning correctly

Next Steps

Released under the Apache License 2.0