Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Only make one sql table method call
  • Loading branch information
hannahramadan committed Nov 8, 2024
commit 68f42ec3074b90bb5baa14fadb8b9541bcb60cbb
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ def _otel_span_attributes(sql)
attributes = _otel_client_attributes(sql)

if sql
attributes[SemanticConventions::Trace::DB_SQL_TABLE] = db_sql_table_name(sql) if db_sql_table_name(sql) && config[:db_sql_table] == :include
sql_table_name = db_sql_table_name(sql)
attributes[SemanticConventions::Trace::DB_SQL_TABLE] = sql_table_name if sql_table_name && config[:db_sql_table] == :include

case config[:db_statement]
when :include
Expand Down