govuk_app_config 1.9.1 → 1.9.2

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: eeb71c2a0cf389772afcd12b204fc215abc594b7588b21425ec8d537bc71b14b
4
- data.tar.gz: 8da06a31b69b1f02627ac855ef11dbcf963dd606b2940ac0f4f87a879505dbf8
3
+ metadata.gz: 1fa3464663f494716d02cd33731746cfa6b1ed7afbccd0557df14d17b712e3be
4
+ data.tar.gz: 02cf9e2b20c433003594329ae6d260fbb3401943e584e50d81587cd8f15d3489
5
5
  SHA512:
6
- metadata.gz: 372eaa1dcc16a8ce7cb2bc2f9014a51c7c7cd5398386d896c24ca780df9e93e35af1dc01223e4e35b037ecf7a4d9eb7e61a86504a58a3e9a138fc7c0d38af9fc
7
- data.tar.gz: 18ca93f12d376d3bb601a16782346b9b93d63bc3e25e4417ae0800fcad0bcda724f347677cac8ff1527d7e139e9fd7c45a7608f342c20d3070c7fc1237c5bbdd
6
+ metadata.gz: c5ad9f2482074fd4676028b5545fa9d7a2a3221de0f2658f8d0082e85a46015acd53e70d0f087b81075f4ffd0bbfa8278b93ec9a368c73f950d7bce9d78f1bde
7
+ data.tar.gz: c8f88e3334ff137fc78b8d1daf3feddc7fc0cf26e841425329c33a7a51698b1e2e3173f9c7eb3e2b8f2fa4dae72ac3a473d7132e7b0f144bdb2d612e28a23adb
data/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
+ # 1.9.2
2
+
3
+ * Set a default segment name for XRay if the `GOVUK_APP_NAME`
4
+ environment variable is missing, rather than throwing an exception.
5
+
1
6
  # 1.9.1
2
7
 
3
8
  * Make XRay log missing segments (such as when executing rake tasks)
@@ -12,8 +12,13 @@ module GovukXRay
12
12
  patch = Gem.loaded_specs.has_key?('aws-sdk-core') ?
13
13
  %I[aws_sdk net_http] : %I[net_http]
14
14
 
15
+ # if there isn't a name set, attempting to record a segment will
16
+ # throw an error
17
+ govuk_app_name = ENV['GOVUK_APP_NAME']
18
+ name = govuk_app_name.blank? ? 'xray' : govuk_app_name
19
+
15
20
  XRay.recorder.configure(
16
- name: ENV['GOVUK_APP_NAME'].to_s,
21
+ name: name,
17
22
  patch: patch,
18
23
  context_missing: 'LOG_ERROR',
19
24
  sampling_rules: {
@@ -1,3 +1,3 @@
1
1
  module GovukAppConfig
2
- VERSION = "1.9.1"
2
+ VERSION = "1.9.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: govuk_app_config
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.1
4
+ version: 1.9.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - GOV.UK Dev
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-09-24 00:00:00.000000000 Z
11
+ date: 2018-09-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-xray-sdk