pub fn normalize_db_attributes(annotated_attributes: &mut Annotated<Attributes>)Expand description
Normalizes the following db attributes: db.query.text, db.operation.name, db.collection.name
based on related attributes within DB spans.
This function reads the raw db query from db.query.text, scrubs it if possible, and writes
the normalized query to the sentry.normalized_db_query attribute. After normalizing the query,
the db operation and collection name are updated if needed.
Note: This function assumes that the sentry.op has already been inferred and set in the attributes.