ldclient-rb 0.1.3 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 90bab32e29619fe24b31a74ddfa23ec825b68d2a
4
- data.tar.gz: 3fd83f272000a6313895eb8ae02f1d089b35bd36
3
+ metadata.gz: 9e44a1aa86a1b8486920b0798f25160481a8fd06
4
+ data.tar.gz: 0ecdeb68b3479534fc148dc277181fd4d98d94c3
5
5
  SHA512:
6
- metadata.gz: cf202515c0ba433d8c04d714502686ec21b2d620c7e3b2cac0d2f7c1984b5c163e75799874c7764ab1ec00e16a379a8b549db317f9c8ac3e4ace251ee34e2c15
7
- data.tar.gz: 2ffbbfe89474a7d91f6d085aa009197e2c2c4fb5bcfcde4addf194069ac906b879a1aabc56f39834ef052147288f01914ae15f75109fc7d8c22f9e91a5f0f668
6
+ metadata.gz: 47fa2c0003a580ce85eb90a235a1405723fd891bef78bfff21cfa9cc84933b1f0d24dc228ccda1dd1a97d973426754bc246e2b0d80f26f0272b2e0c2d589f127
7
+ data.tar.gz: e4dbca380db1a33754d595b98a17969981876c0d04ea36d275c8aec95f0de9d2abe519a3ac1d443964f4c399ad7e7bc3e6eb63f167123f9de347603820d5d3c4
data/README.md CHANGED
@@ -27,4 +27,9 @@ Your first feature flag
27
27
  # application code to show the feature
28
28
  else
29
29
  # the code to run if the feature is off
30
- end
30
+ end
31
+
32
+ Learn more
33
+ -----------
34
+
35
+ Check out our [documentation](http://docs.launchdarkly.com) for in-depth instructions on configuring and using LaunchDarkly. You can also head straight to the [complete reference guide for this SDK](http://docs.launchdarkly.com/v1.0/docs/ruby-sdk-reference).
data/lib/ldclient-rb.rb CHANGED
@@ -1,4 +1,5 @@
1
1
  require "ldclient-rb/version"
2
2
  require "ldclient-rb/ldclient"
3
3
  require "ldclient-rb/store"
4
- require "ldclient-rb/config"
4
+ require "ldclient-rb/config"
5
+ require "ldclient-rb/newrelic"
@@ -126,6 +126,7 @@ module LaunchDarkly
126
126
 
127
127
  value = get_flag_int(key, user, default)
128
128
  add_event({:kind => 'feature', :key => key, :user => user, :value => value})
129
+ LDNewRelic.annotate_transaction(key, value)
129
130
  return value
130
131
  rescue StandardError => error
131
132
  @config.logger.error("[LDClient] Unhandled exception in get_flag: (#{error.class.name}) #{error.to_s}\n\t#{error.backtrace.join("\n\t")}")
@@ -0,0 +1,19 @@
1
+ module LaunchDarkly
2
+
3
+ class LDNewRelic
4
+ begin
5
+ require 'newrelic_rpm'
6
+ NR_ENABLED = defined?(::NewRelic::Agent.add_custom_parameters)
7
+ rescue Exception
8
+ NR_ENABLED = false
9
+ end
10
+
11
+ def self.annotate_transaction(key, value)
12
+ if NR_ENABLED
13
+ ::NewRelic::Agent.add_custom_parameters({key.to_s => value.to_s})
14
+ end
15
+ end
16
+ end
17
+
18
+
19
+ end
@@ -1,3 +1,3 @@
1
1
  module LaunchDarkly
2
- VERSION = "0.1.3"
2
+ VERSION = "0.2.0"
3
3
  end
metadata CHANGED
@@ -1,111 +1,111 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ldclient-rb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Catamorphic Co
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-04-28 00:00:00.000000000 Z
11
+ date: 2015-05-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.7'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.7'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '10.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ~>
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '10.0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: json
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ~>
45
+ - - "~>"
46
46
  - !ruby/object:Gem::Version
47
47
  version: '1.8'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ~>
52
+ - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '1.8'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: faraday
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - ~>
59
+ - - "~>"
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0.9'
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - ~>
66
+ - - "~>"
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0.9'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: faraday-http-cache
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - ~>
73
+ - - "~>"
74
74
  - !ruby/object:Gem::Version
75
75
  version: '0.4'
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - ~>
80
+ - - "~>"
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0.4'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: thread_safe
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - ~>
87
+ - - "~>"
88
88
  - !ruby/object:Gem::Version
89
89
  version: '0.3'
90
90
  type: :runtime
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - ~>
94
+ - - "~>"
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0.3'
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: net-http-persistent
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
- - - ~>
101
+ - - "~>"
102
102
  - !ruby/object:Gem::Version
103
103
  version: 2.9.4
104
104
  type: :runtime
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
- - - ~>
108
+ - - "~>"
109
109
  - !ruby/object:Gem::Version
110
110
  version: 2.9.4
111
111
  description: Official LaunchDarkly SDK for Ruby
@@ -115,7 +115,7 @@ executables: []
115
115
  extensions: []
116
116
  extra_rdoc_files: []
117
117
  files:
118
- - .gitignore
118
+ - ".gitignore"
119
119
  - Gemfile
120
120
  - Gemfile.lock
121
121
  - LICENSE.txt
@@ -125,6 +125,7 @@ files:
125
125
  - lib/ldclient-rb.rb
126
126
  - lib/ldclient-rb/config.rb
127
127
  - lib/ldclient-rb/ldclient.rb
128
+ - lib/ldclient-rb/newrelic.rb
128
129
  - lib/ldclient-rb/store.rb
129
130
  - lib/ldclient-rb/version.rb
130
131
  homepage: ''
@@ -137,18 +138,19 @@ require_paths:
137
138
  - lib
138
139
  required_ruby_version: !ruby/object:Gem::Requirement
139
140
  requirements:
140
- - - '>='
141
+ - - ">="
141
142
  - !ruby/object:Gem::Version
142
143
  version: '0'
143
144
  required_rubygems_version: !ruby/object:Gem::Requirement
144
145
  requirements:
145
- - - '>='
146
+ - - ">="
146
147
  - !ruby/object:Gem::Version
147
148
  version: '0'
148
149
  requirements: []
149
150
  rubyforge_project:
150
- rubygems_version: 2.0.14
151
+ rubygems_version: 2.2.2
151
152
  signing_key:
152
153
  specification_version: 4
153
154
  summary: LaunchDarkly SDK for Ruby
154
155
  test_files: []
156
+ has_rdoc: