bc-lightstep-ruby 1.1.6 → 1.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 402c34ffb90db4b5f068099b70c80cc933dc8f4f5f4914de05bd2c09398842a7
|
4
|
+
data.tar.gz: af092007c4a9a2ceca3bebd200e332e38c2539e8438a3ec9a840a7c03aaf66e5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1adafe2e08b065730025e548b6711b6c6ec673f0c92e022d7b6cd9bf2cef8547ca0867efb3b9b692eccb3f929f2277c8338700ca22c38ef68653fc5ba1c2951b
|
7
|
+
data.tar.gz: dd4ebff9ddbc843051745e3762a1bc0d8ac2790b5341483192e22dee990718221191c6f20850cec6f68f38ce1e8f914df3b99c0e85e6d056ef8d2c0f795a67a5
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,12 @@ Changelog for the bc-lightstep-ruby gem.
|
|
2
2
|
|
3
3
|
h3. Pending Release
|
4
4
|
|
5
|
+
h3. 1.1.7
|
6
|
+
|
7
|
+
- Better handling of exceptions and tagged errors
|
8
|
+
- Lower timeouts for collector connections to reduce impact if collector is down/unreachable
|
9
|
+
- Always ensure spans are reported even in the case of exceptional failure
|
10
|
+
|
5
11
|
h3. 1.1.6
|
6
12
|
|
7
13
|
- First OSS release
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# bc-lightstep-ruby - LightStep distributed tracing
|
2
2
|
|
3
|
-
[](https://travis-ci.com/bigcommerce/bc-lightstep-ruby)
|
3
|
+
[](https://travis-ci.com/bigcommerce/bc-lightstep-ruby) [](https://badge.fury.io/rb/bc-lightstep-ruby) [](http://inch-ci.org/github/bigcommerce/bc-lightstep-ruby)
|
4
4
|
|
5
5
|
Adds [LightStep](https://lightstep.com) tracing support for Ruby. This is an extension of the
|
6
6
|
[LightStep ruby gem](https://github.com/lightstep/lightstep-tracer-ruby) and adds extra functionality and resiliency.
|
@@ -8,7 +8,7 @@ Adds [LightStep](https://lightstep.com) tracing support for Ruby. This is an ext
|
|
8
8
|
## Installation
|
9
9
|
|
10
10
|
```ruby
|
11
|
-
gem 'bc-lightstep-ruby'
|
11
|
+
gem 'bc-lightstep-ruby'
|
12
12
|
```
|
13
13
|
|
14
14
|
Then in an initializer or before use:
|
@@ -48,7 +48,7 @@ bc-lightstep-ruby can be automatically configured from these ENV vars, if you'd
|
|
48
48
|
| LIGHTSTEP_SSL_VERIFY_PEER | If using 443 as the port, toggle SSL verification. Defaults to true. |
|
49
49
|
| LIGHTSTEP_VERBOSITY | The verbosity level of lightstep logs. Defaults to 1. |
|
50
50
|
|
51
|
-
Most
|
51
|
+
Most systems will only need to customize the component name.
|
52
52
|
|
53
53
|
### Instrumenting Rails Controllers
|
54
54
|
|
@@ -70,7 +70,7 @@ end
|
|
70
70
|
|
71
71
|
Spans will be built with the external service name. It's generally _not_ a good idea to use the Faraday adapter
|
72
72
|
with internal services that are also instrumented with LightStep - use the Faraday adapter on external services
|
73
|
-
or systems outside of
|
73
|
+
or systems outside of your instrumenting control.
|
74
74
|
|
75
75
|
## License
|
76
76
|
|
@@ -58,13 +58,18 @@ module Bigcommerce
|
|
58
58
|
self.active_span = span
|
59
59
|
|
60
60
|
# run the process
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
61
|
+
begin
|
62
|
+
result = yield span
|
63
|
+
rescue StandardError
|
64
|
+
span.set_tag('error', true)
|
65
|
+
raise
|
66
|
+
ensure
|
67
|
+
# finish this span if the reporter is initialized
|
68
|
+
span.finish if reporter_initialized?
|
69
|
+
|
70
|
+
# now set back the parent as the active span
|
71
|
+
self.active_span = last_active_span
|
72
|
+
end
|
68
73
|
|
69
74
|
# return result
|
70
75
|
result
|
@@ -47,8 +47,8 @@ module Bigcommerce
|
|
47
47
|
verbose: 0,
|
48
48
|
encryption: ENCRYPTION_TLS,
|
49
49
|
ssl_verify_peer: true,
|
50
|
-
open_timeout:
|
51
|
-
read_timeout:
|
50
|
+
open_timeout: 2,
|
51
|
+
read_timeout: 2,
|
52
52
|
continue_timeout: nil,
|
53
53
|
keep_alive_timeout: 2,
|
54
54
|
logger: nil
|
@@ -64,7 +64,9 @@ module Bigcommerce
|
|
64
64
|
@keep_alive_timeout = keep_alive_timeout.to_i
|
65
65
|
|
66
66
|
raise ::Bigcommerce::Lightstep::Errors::InvalidAccessToken, 'access_token must be a string' unless access_token.is_a?(String)
|
67
|
+
|
67
68
|
raise ::Bigcommerce::Lightstep::Errors::InvalidAccessToken, 'access_token cannot be blank' if access_token.empty?
|
69
|
+
|
68
70
|
@access_token = access_token.to_s
|
69
71
|
@logger = logger || ::Logger.new(STDOUT)
|
70
72
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bc-lightstep-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shaun McCormick
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-09-
|
11
|
+
date: 2018-09-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|