Commit Graph

7 Commits

Author SHA1 Message Date
Kyle Brandt 4583402ba9
SQL Expressions: Instrumentation fix and extra testing (#110778) 2025-09-15 13:00:22 -04:00
Kyle Brandt dd4ffc9918
SQL Expressions: Add setting to limit length of query (#110165)
sql_expression_query_length_limit

Set the maximum length of a SQL query that can be used in a SQL expression. Default is 10000 characters. A setting of 0 means no limit.
2025-08-27 12:08:25 -04:00
Kyle Brandt 4f0cb47d3c
SQL Expressions: Rework backend errors and error instrumentation (#109633)
* Capture error_type label on metrics/traces
* Make error messages more helpful to user
* Use errutil, categorized errors, and tie them to error_type (category in code)
* Misc trace fixes
* Add metric to track SQL input conversion
2025-08-25 11:13:42 -04:00
Kyle Brandt 466aa70179
Sql Expressions: (Chore) Dedicated logger for expr.sql, and pass context (#109549) 2025-08-13 11:20:14 -04:00
Sam Jewell 0eafd0641f
SQL Expressions: Simplify test code (#101718)
Simplify, by retaining quotes when escaping query

We also don't need to convert to string when passing to fmt.Sprintf
a slice of Bytes is accepted by Sprintf instead.
2025-03-06 17:02:31 +00:00
Kyle Brandt c291ec7ba9
SQL Expressions: Include SQL Parser/Syntax error in the public message (#100725)
fixes #100721
2025-02-14 09:09:21 -05:00
Kyle Brandt d64f41afdc
SQL Expressions: Re-implement feature using go-mysql-server (#99521)
* Under feature flag `sqlExpressions` and is experimental
* Excluded from arm32
* Will not work with the Query Service yet
* Does not have limits in place yet
* Does not working with alerting yet
* Currently requires "prepare time series" Transform for time series viz
 
---------

Co-authored-by: Sam Jewell <sam.jewell@grafana.com>
2025-02-06 07:27:28 -05:00