You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Snowflake and Databricks connectors both classify each statement.execute tracing span's statement.kind / rocky.statement.kind attribute as query / dml / ddl, via a classify_statement_kind(sql) matcher. BigQuery is the lone warehouse-adapter holdout: it hardcodes statement.kind = "query" and carries an explicit TODO.
This is a cross-adapter parity / observability-consistency task, not a bug fix: with BigQuery classifying like the others, dashboards can filter ddl/dml/query traffic uniformly across every warehouse adapter. (The existing TODO hedges "if downstream consumers need to filter" — the justification is span-attribute consistency across adapters.)
Mirror the merged Snowflake work in PR #540 (closed issue #481) — it's the template; this issue is the BigQuery twin.
Scope
Port a classify_statement_kind(sql) -> &'static str matcher into rocky-bigquery and use it for both the statement.kind and rocky.statement.kind span attributes in run_query, replacing the hardcoded "query".
Code refs
engine/crates/rocky-bigquery/src/connector.rs around line 287 — the // TODO: classify via rocky-sql marker and the hardcoded statement.kind = "query" in run_query
engine/crates/rocky-snowflake/src/connector.rs:623 — fn classify_statement_kind to mirror
engine/crates/rocky-snowflake/src/connector.rs:788+ — the query/dml/ddl unit tests to mirror
engine/crates/rocky-databricks/src/connector.rs:1211 — second in-repo reference implementation
The Snowflake and Databricks connectors both classify each
statement.executetracing span'sstatement.kind/rocky.statement.kindattribute asquery/dml/ddl, via aclassify_statement_kind(sql)matcher. BigQuery is the lone warehouse-adapter holdout: it hardcodesstatement.kind = "query"and carries an explicitTODO.This is a cross-adapter parity / observability-consistency task, not a bug fix: with BigQuery classifying like the others, dashboards can filter ddl/dml/query traffic uniformly across every warehouse adapter. (The existing TODO hedges "if downstream consumers need to filter" — the justification is span-attribute consistency across adapters.)
Scope
Port a
classify_statement_kind(sql) -> &'static strmatcher intorocky-bigqueryand use it for both thestatement.kindandrocky.statement.kindspan attributes inrun_query, replacing the hardcoded"query".Code refs
engine/crates/rocky-bigquery/src/connector.rsaround line 287 — the// TODO: classify via rocky-sqlmarker and the hardcodedstatement.kind = "query"inrun_queryengine/crates/rocky-snowflake/src/connector.rs:623—fn classify_statement_kindto mirrorengine/crates/rocky-snowflake/src/connector.rs:788+— the query/dml/ddl unit tests to mirrorengine/crates/rocky-databricks/src/connector.rs:1211— second in-repo reference implementationAcceptance criteria
statement.kindandrocky.statement.kindon the BigQuerystatement.executespan reflect the classified kind (query/dml/ddl)cargo test -p rocky-bigqueryis greenEffort
2 hours.