sql: add randomized testing for gist decoding #117634
Labels
C-enhancement
Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)
E-quick-win
Likely to be a quick win for someone experienced.
P-2
Issues/test failures with a fix SLA of 3 months
T-sql-queries
SQL Queries Team
Is your feature request related to a problem? Please describe.
We have found that there are cases where decoding a gist can cause panics when the encoded format doesn't exactly match what is expected by the code. For example, see #113900. This is especially likely when decoding a gist that was encoded by a different version of CockroachDB.
The DB console performs gist decoding of sampled queries, making it likely that a customer might run into this issue in production.
Describe the solution you'd like
We'd like to discover cases where gist decoding can cause panics so they can be fixed before customers run into them in production. One idea is to randomly generate queries using sqlsmith, encode them as a gist, and then make sure they can be decoded without a panic. We could also write this as a mixed version roach test.
Jira issue: CRDB-35283
The text was updated successfully, but these errors were encountered: