Skip to content

Commit 3b1001d

Browse files
committed
refactor: reduce query text truncation to 150 chars
1 parent b5b0e9b commit 3b1001d

2 files changed

Lines changed: 4 additions & 11 deletions

File tree

config/grafana/dashboards/Dashboard_2_Aggregated_query_analysis.json

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -172,14 +172,7 @@
172172
"properties": [
173173
{
174174
"id": "custom.width",
175-
"value": 400
176-
},
177-
{
178-
"id": "custom.cellOptions",
179-
"value": {
180-
"type": "auto",
181-
"wrapText": true
182-
}
175+
"value": 300
183176
}
184177
]
185178
}

monitoring_flask_backend/app.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,9 @@ def get_query_texts_from_sink(db_name: str = None) -> dict:
8888
queryid = row['queryid']
8989
query_text = row['query']
9090
if queryid:
91-
# Truncate very long queries for display
92-
if query_text and len(query_text) > 500:
93-
query_text = query_text[:500] + '...'
91+
# Truncate long queries for display (150 chars)
92+
if query_text and len(query_text) > 150:
93+
query_text = query_text[:150] + '...'
9494
query_texts[queryid] = query_text or ''
9595

9696
conn.close()

0 commit comments

Comments
 (0)