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
Copy file name to clipboardExpand all lines: helpers/sql/README.md
+16-9Lines changed: 16 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,20 +1,28 @@
1
1
# OpenTelemetry Sql Helpers
2
2
3
-
Todo: Add a description.
3
+
This gem is intended to be used by the instrumentation libraries to provide a common set of helpers for SQL-related spans. It is not intended to be used directly by applications.
4
+
5
+
## Installation
6
+
7
+
Add a line similar to this in your `gemspec`:
4
8
5
-
## How do I get started?
9
+
```ruby
6
10
7
-
Install the gem using:
11
+
spec.add_dependency 'opentelemetry-helpers-sql', '~> 0.3'# Use the approprite version
8
12
9
-
```console
10
-
gem install opentelemetry-helpers-sql
11
13
```
12
14
13
-
Or, if you use [bundler][bundler-home], include `opentelemetry-helpers-sql`in your `Gemfile`.
15
+
Update your `Gemfile` to use the latest version of the gem in the contrib, e.g.
14
16
15
-
## Usage
17
+
```ruby
16
18
17
-
This gem is intended to be used by the instrumentation libraries to provide a common set of helpers for SQL-related spans. It is not intended to be used directly by applications.
19
+
group :testdo
20
+
gem 'opentelemetry-helpers-sql', path:'../../helpers/sql'# Use the approprite path
21
+
end
22
+
23
+
```
24
+
25
+
## Usage
18
26
19
27
Some database libraries do not have enough context to add sufficient details to client spans. In these cases, you can use the `OpenTelemetry::Helpers::Sql.with_attributes` to create a set of shared attributes to amend to a database span.
20
28
@@ -44,7 +52,6 @@ The OpenTelemetry Ruby gems are maintained by the OpenTelemetry Ruby special int
44
52
45
53
The `opentelemetry-helpers-sql` gem is distributed under the Apache 2.0 license. See [LICENSE][license-github] for more information.
0 commit comments