Skip to content

[sql] Support db.operation.batch.size attribute #2240

Description

@alanwest

Refer to the v1.43.0 conventions for attribute descriptions.

Before implementing we need to agree on when and how db.operation.batch.size will be determined.

Few questions/thoughts:

  1. SqlClient has a means to create and execute a batch of commands (see SqlBatch). I'm not certain if SqlBatch can be leveraged nor do I know how a batch is executed. Is each command executed individually, or is the entire batch sent where commands are concatenated together with semi-colons?

  2. Would we need to resort to parsing a SQL query for the presence of semi-colons? Are semi-colons always the character that delimits commands?

  3. If parsing is our only option, we may want to forgo supporting db.operation.batch.size. I'd like to know if there are other languages that are parsing SQL queries to determine db.operation.batch.size.

Metadata

Metadata

Assignees

No one assigned

    Labels

    comp:instrumentation.sqlclientThings related to OpenTelemetry.Instrumentation.SqlClienthelp wantedExtra attention is needed

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions