scoped_storage 0.0.1

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.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 0e9d2aa981a0b722aef4599d173c7152365dfc4c
4
+ data.tar.gz: 28ba1676de3d3185a714ee30062c2c92e95cd544
5
+ SHA512:
6
+ metadata.gz: 2072a85cd3b348f95d3322d18eaafab1555ec72b4b3acddfc85b53075c224b47b95e511b2eb0e3b29e8ff4addb0be3e1f50494cf31d4e3b10eb0618e3c1becd3
7
+ data.tar.gz: 7bf3f5f5c983b38cec9064ed07c25da5e725eeb70a9ffe16315df2067814fd68cb246a8228c33fa39c78d7e59aad736df2ea8413df5484227335be4f42aec781
@@ -0,0 +1,19 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ .version.conf
7
+ Gemfile.lock
8
+ InstalledFiles
9
+ _yardoc
10
+ coverage
11
+ doc/
12
+ lib/bundler/man
13
+ pkg
14
+ rdoc
15
+ spec/reports
16
+ test/tmp
17
+ test/version_tmp
18
+ tmp
19
+ coverage
@@ -0,0 +1,6 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.1.0
4
+ notifications:
5
+ recipients:
6
+ - shad0wrunner@gmx.de
data/Gemfile ADDED
@@ -0,0 +1,8 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in scoped_storage.gemspec
4
+ gemspec
5
+
6
+
7
+ gem 'simplecov', require: false, group: :test
8
+ gem 'coveralls', require: false
@@ -0,0 +1,25 @@
1
+ # A sample Guardfile
2
+ # More info at https://github.com/guard/guard#readme
3
+
4
+ guard :rspec, all_after_pass: true ,
5
+ all_on_start: true do
6
+
7
+ watch(%r{^spec/.+_spec\.rb$})
8
+
9
+ watch('lib/yaoc.rb') { "spec" }
10
+
11
+ watch(%r{^lib/(.+)\.rb$}) { |m| "spec/unit/lib/#{m[1]}_spec.rb" }
12
+ watch(%r{^lib/(.+)\.rb$}) { |m| "spec/integration/lib/#{m[1]}_spec.rb" }
13
+
14
+ watch('spec/spec_helper.rb') { "spec" }
15
+
16
+ watch(%r{^spec/support/(.+)\.rb$}) { "spec" }
17
+
18
+ end
19
+
20
+
21
+ guard :bundler do
22
+ watch('Gemfile')
23
+ # Uncomment next line if your Gemfile contains the `gemspec' command.
24
+ watch(/^.+\.gemspec/)
25
+ end
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2014 Dieter Späth
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,41 @@
1
+ # ScopedStorage
2
+
3
+ With scoped storage you can save values in a thread local or thread global storage with
4
+ a hash like accessor. Different scopes can be distinguished with a scope name.
5
+
6
+ ## Installation
7
+
8
+ Add this line to your application's Gemfile:
9
+
10
+ gem 'scoped_storage'
11
+
12
+ And then execute:
13
+
14
+ $ bundle
15
+
16
+ Or install it yourself as:
17
+
18
+ $ gem install scoped_storage
19
+
20
+ ## Usage
21
+
22
+ ```ruby
23
+
24
+ scope_storage = ScopedStorage::ThreadGlobalStorage # or ScopedStorage::ThreadLocalStorage
25
+ scope = ScopedStorage::Scope.new('policy_infos', scope_storage)
26
+
27
+ scope['my_key'] = 'my_value'
28
+ scope.fetch('my_key'){...}
29
+
30
+ scope.clear!
31
+
32
+
33
+ ```
34
+
35
+ ## Contributing
36
+
37
+ 1. Fork it ( http://github.com/slowjack2k/scoped_storage/fork )
38
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
39
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
40
+ 4. Push to the branch (`git push origin my-new-feature`)
41
+ 5. Create new Pull Request
@@ -0,0 +1,13 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ RSpec::Core::RakeTask.new
5
+
6
+ task :default => :spec
7
+ task :test => :spec
8
+
9
+ desc "Run RSpec with code coverage"
10
+ task :coverage do
11
+ ENV['SIMPLE_COVERAGE'] = "true"
12
+ Rake::Task["spec"].execute
13
+ end
@@ -0,0 +1,8 @@
1
+ require 'scoped_storage/version'
2
+ require 'scoped_storage/thread_local_storage'
3
+ require 'scoped_storage/thread_global_storage'
4
+ require 'scoped_storage/scope'
5
+
6
+ module ScopedStorage
7
+
8
+ end
@@ -0,0 +1,32 @@
1
+ module ScopedStorage
2
+ class Scope
3
+
4
+ attr_accessor :scope_name, :storage_source
5
+
6
+ def initialize(scope_name="default", storage_source=ThreadGlobalStorage)
7
+ self.scope_name = scope_name
8
+ self.storage_source = storage_source
9
+ end
10
+
11
+ def storage
12
+ storage_source.for(scope_name)
13
+ end
14
+
15
+ def []=(key, value)
16
+ self.storage[key]=value
17
+ end
18
+
19
+ def [](key)
20
+ self.storage[key]
21
+ end
22
+
23
+ def clear!
24
+ self.storage.clear
25
+ end
26
+
27
+ def fetch(*args, &block)
28
+ self.storage.fetch(*args, &block)
29
+ end
30
+
31
+ end
32
+ end
@@ -0,0 +1,54 @@
1
+ module ScopedStorage
2
+ require 'thread'
3
+
4
+ class ThreadGlobalStorage
5
+ class << self
6
+ private :new
7
+ end
8
+
9
+ attr_accessor :data
10
+
11
+ @mutex = Mutex.new
12
+
13
+ def self.mutex
14
+ @mutex
15
+ end
16
+
17
+ def self.for(scope_name="default")
18
+ mutex.synchronize {
19
+ @storage ||= {}
20
+ @storage[scope_name] ||= new
21
+ }
22
+ end
23
+
24
+ def initialize
25
+ self.data||={}
26
+ end
27
+
28
+ def []=(key, value)
29
+ mutex.synchronize {
30
+ self.data[key]=value
31
+ }
32
+ end
33
+
34
+ def [](key)
35
+ self.data[key]
36
+ end
37
+
38
+ def clear!
39
+ mutex.synchronize {
40
+ self.data.clear
41
+ }
42
+ end
43
+
44
+ def fetch(*args, &block)
45
+ self.data.fetch(*args, &block)
46
+ end
47
+
48
+ def mutex
49
+ self.class.mutex
50
+ end
51
+
52
+ end
53
+ end
54
+
@@ -0,0 +1,35 @@
1
+ module ScopedStorage
2
+ class ThreadLocalStorage
3
+ class << self
4
+ private :new
5
+ end
6
+
7
+ attr_accessor :data
8
+
9
+ def self.for(scope_name="default")
10
+ Thread.current["_#{name}_#{scope_name}"] ||= new
11
+ end
12
+
13
+ def initialize
14
+ self.data||={}
15
+ end
16
+
17
+ def []=(key, value)
18
+ self.data[key]=value
19
+ end
20
+
21
+ def [](key)
22
+ self.data[key]
23
+ end
24
+
25
+ def clear!
26
+ self.data.clear
27
+ end
28
+
29
+ def fetch(*args, &block)
30
+ self.data.fetch(*args, &block)
31
+ end
32
+
33
+ end
34
+ end
35
+
@@ -0,0 +1,3 @@
1
+ module ScopedStorage
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,41 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'scoped_storage/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "scoped_storage"
8
+ spec.version = ScopedStorage::VERSION
9
+ spec.authors = ["Dieter Späth"]
10
+ spec.email = ["shad0wrunner@gmx.de"]
11
+ spec.summary = %q{Stores values in a thread local or thread global storage}
12
+ spec.description = %q{Stores values in a thread local or thread global storage}
13
+ spec.homepage = ""
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0")
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_development_dependency "bundler", "~> 1.5"
22
+ spec.add_development_dependency "rake"
23
+
24
+ spec.add_development_dependency "rspec", "2.99.0.beta1"
25
+ # show nicely how many specs have to be run
26
+ spec.add_development_dependency "fuubar"
27
+ # extended console
28
+ spec.add_development_dependency "pry"
29
+ spec.add_development_dependency 'pry-remote'
30
+
31
+ # automatic execute tasks on file changes
32
+ spec.add_development_dependency 'guard'
33
+ spec.add_development_dependency 'guard-rspec'
34
+ spec.add_development_dependency 'guard-bundler'
35
+ spec.add_development_dependency 'rb-fsevent'
36
+
37
+ # https://github.com/pry/pry-stack_explorer
38
+ spec.add_development_dependency 'pry-stack_explorer'
39
+ # https://github.com/nixme/pry-debugger
40
+ spec.add_development_dependency 'pry-debugger'
41
+ end
@@ -0,0 +1,14 @@
1
+ require 'spec_helper'
2
+
3
+ describe ScopedStorage::Scope do
4
+
5
+ subject{
6
+ ScopedStorage::Scope.new("default")
7
+ }
8
+
9
+ it 'works with the default storage' do
10
+ subject['new_value'] = 123
11
+ expect(subject.fetch('new_value')).to eq 123
12
+ end
13
+
14
+ end
@@ -0,0 +1,42 @@
1
+ require 'bundler/setup'
2
+ Bundler.require(:development)
3
+
4
+ require 'coveralls'
5
+ Coveralls.wear! unless ENV["SIMPLE_COVERAGE"]
6
+
7
+ begin
8
+ if ENV["SIMPLE_COVERAGE"]
9
+ require 'simplecov'
10
+ SimpleCov.start do
11
+ add_group "Lib", "lib"
12
+
13
+ add_filter "/spec/"
14
+ end
15
+ end
16
+ rescue LoadError
17
+ warn "=" * 80
18
+ warn 'simplecov not installed. No coverage report'
19
+ warn "=" * 80
20
+ end
21
+
22
+ require 'scoped_storage'
23
+
24
+ Dir[File.join(File.expand_path(__dir__ ), "support/**/*.rb")].each { |f| require f }
25
+
26
+ # This file was generated by the `rspec --init` command. Conventionally, all
27
+ # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
28
+ # Require this file using `require "spec_helper"` to ensure that it is only
29
+ # loaded once.
30
+ #
31
+ # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
32
+ RSpec.configure do |config|
33
+ config.treat_symbols_as_metadata_keys_with_true_values = true
34
+ config.run_all_when_everything_filtered = true
35
+ config.filter_run :focus
36
+
37
+ # Run specs in random order to surface order dependencies. If you find an
38
+ # order dependency and want to debug it, you can fix the order by providing
39
+ # the seed, which is printed after each run.
40
+ # --seed 1234
41
+ config.order = 'random'
42
+ end
@@ -0,0 +1,57 @@
1
+ require 'spec_helper'
2
+
3
+ describe ScopedStorage::Scope do
4
+ class DummyStorage
5
+ def initialize(new_data)
6
+ @data = new_data
7
+ end
8
+
9
+ def for(*args)
10
+ data
11
+ end
12
+
13
+ def data
14
+ @data
15
+ end
16
+
17
+ end
18
+
19
+ subject{
20
+ ScopedStorage::Scope.new("default", DummyStorage.new(data_double))
21
+ }
22
+
23
+ let(:data_double){
24
+ {}
25
+ }
26
+
27
+ describe '#[]=' do
28
+ it 'let me set values' do
29
+ subject['new_value'] = 123
30
+ expect(subject.fetch('new_value')).to eq 123
31
+ end
32
+ end
33
+
34
+ describe '#[]' do
35
+ it 'let me fetch values' do
36
+ subject['new_value'] = 123
37
+ expect(subject['new_value']).to eq 123
38
+ end
39
+ end
40
+
41
+ describe '#clear!' do
42
+ it 'let me fetch values' do
43
+ subject['new_value'] = 123
44
+ subject.clear!
45
+ expect(subject['new_value']).to be_nil
46
+ end
47
+ end
48
+
49
+ describe '#fetch' do
50
+ it 'works like hash fetch' do
51
+ fetched_value = subject.fetch('some_key'){|*args| args}
52
+
53
+ expect(fetched_value).to eq ['some_key']
54
+ end
55
+ end
56
+
57
+ end
@@ -0,0 +1,49 @@
1
+ require 'spec_helper'
2
+
3
+ describe ScopedStorage::ThreadGlobalStorage do
4
+ subject{
5
+ ScopedStorage::ThreadGlobalStorage
6
+ }
7
+
8
+ let(:storage){
9
+ subject.for
10
+ }
11
+
12
+ describe '.for' do
13
+ it 'creates a new object for all threads' do
14
+ subject.for
15
+
16
+ threat_one_object_id = nil
17
+ threat_two_object_id = nil
18
+ threats = []
19
+
20
+ threats << Thread.new{
21
+ threat_one_object_id = ScopedStorage::ThreadLocalStorage.for
22
+ }
23
+
24
+ threats << Thread.new{
25
+ threat_two_object_id = ScopedStorage::ThreadLocalStorage.for
26
+ }
27
+
28
+ threats.each &:join
29
+
30
+ expect(threat_one_object_id).not_to eq threat_two_object_id
31
+ end
32
+
33
+ it 'supports naming different scopes' do
34
+ second_scope = subject.for 'the second scope'
35
+ expect(second_scope.object_id).not_to be subject.for.object_id
36
+ end
37
+ end
38
+
39
+ it 'supports hash like accessors' do
40
+ storage['key'] = 1
41
+ expect(storage['key']).to eq 1
42
+ expect(storage.fetch 'key').to eq 1
43
+
44
+ storage.clear!
45
+
46
+ expect(storage['key']).to be_nil
47
+ end
48
+
49
+ end
@@ -0,0 +1,50 @@
1
+ require 'spec_helper'
2
+
3
+ describe ScopedStorage::ThreadLocalStorage do
4
+ subject{
5
+ ScopedStorage::ThreadLocalStorage
6
+ }
7
+
8
+ let(:storage){
9
+ subject.for
10
+ }
11
+
12
+ describe '.for' do
13
+ it 'creates a new object for every thread' do
14
+ subject.for
15
+
16
+ threat_one_object_id = nil
17
+ threat_two_object_id = nil
18
+ threats = []
19
+
20
+ threats << Thread.new{
21
+ threat_one_object_id = ScopedStorage::ThreadLocalStorage.for
22
+ }
23
+
24
+ threats << Thread.new{
25
+ threat_two_object_id = ScopedStorage::ThreadLocalStorage.for
26
+ }
27
+
28
+ threats.each &:join
29
+
30
+ expect(threat_one_object_id).not_to eq threat_two_object_id
31
+ end
32
+
33
+ it 'supports naming different scopes' do
34
+ second_scope = subject.for 'the second scope'
35
+ expect(second_scope.object_id).not_to be subject.for.object_id
36
+ end
37
+ end
38
+
39
+ it 'supports hash like accessors' do
40
+ storage['key'] = 1
41
+ expect(storage['key']).to eq 1
42
+ expect(storage.fetch 'key').to eq 1
43
+
44
+ storage.clear!
45
+
46
+ expect(storage['key']).to be_nil
47
+
48
+ end
49
+
50
+ end
metadata ADDED
@@ -0,0 +1,235 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: scoped_storage
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Dieter Späth
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-02-10 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.5'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.5'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - '='
46
+ - !ruby/object:Gem::Version
47
+ version: 2.99.0.beta1
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - '='
53
+ - !ruby/object:Gem::Version
54
+ version: 2.99.0.beta1
55
+ - !ruby/object:Gem::Dependency
56
+ name: fuubar
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: pry
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: pry-remote
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: guard
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: guard-rspec
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
125
+ - !ruby/object:Gem::Dependency
126
+ name: guard-bundler
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ version: '0'
132
+ type: :development
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
139
+ - !ruby/object:Gem::Dependency
140
+ name: rb-fsevent
141
+ requirement: !ruby/object:Gem::Requirement
142
+ requirements:
143
+ - - ">="
144
+ - !ruby/object:Gem::Version
145
+ version: '0'
146
+ type: :development
147
+ prerelease: false
148
+ version_requirements: !ruby/object:Gem::Requirement
149
+ requirements:
150
+ - - ">="
151
+ - !ruby/object:Gem::Version
152
+ version: '0'
153
+ - !ruby/object:Gem::Dependency
154
+ name: pry-stack_explorer
155
+ requirement: !ruby/object:Gem::Requirement
156
+ requirements:
157
+ - - ">="
158
+ - !ruby/object:Gem::Version
159
+ version: '0'
160
+ type: :development
161
+ prerelease: false
162
+ version_requirements: !ruby/object:Gem::Requirement
163
+ requirements:
164
+ - - ">="
165
+ - !ruby/object:Gem::Version
166
+ version: '0'
167
+ - !ruby/object:Gem::Dependency
168
+ name: pry-debugger
169
+ requirement: !ruby/object:Gem::Requirement
170
+ requirements:
171
+ - - ">="
172
+ - !ruby/object:Gem::Version
173
+ version: '0'
174
+ type: :development
175
+ prerelease: false
176
+ version_requirements: !ruby/object:Gem::Requirement
177
+ requirements:
178
+ - - ">="
179
+ - !ruby/object:Gem::Version
180
+ version: '0'
181
+ description: Stores values in a thread local or thread global storage
182
+ email:
183
+ - shad0wrunner@gmx.de
184
+ executables: []
185
+ extensions: []
186
+ extra_rdoc_files: []
187
+ files:
188
+ - ".gitignore"
189
+ - ".travis.yml"
190
+ - Gemfile
191
+ - Guardfile
192
+ - LICENSE.txt
193
+ - README.md
194
+ - Rakefile
195
+ - lib/scoped_storage.rb
196
+ - lib/scoped_storage/scope.rb
197
+ - lib/scoped_storage/thread_global_storage.rb
198
+ - lib/scoped_storage/thread_local_storage.rb
199
+ - lib/scoped_storage/version.rb
200
+ - scoped_storage.gemspec
201
+ - spec/integration/lib/scoped_storage/scope_spec.rb
202
+ - spec/spec_helper.rb
203
+ - spec/unit/lib/scoped_storage/scope_spec.rb
204
+ - spec/unit/lib/scoped_storage/thread_global_storage_spec.rb
205
+ - spec/unit/lib/scoped_storage/thread_local_storage_spec.rb
206
+ homepage: ''
207
+ licenses:
208
+ - MIT
209
+ metadata: {}
210
+ post_install_message:
211
+ rdoc_options: []
212
+ require_paths:
213
+ - lib
214
+ required_ruby_version: !ruby/object:Gem::Requirement
215
+ requirements:
216
+ - - ">="
217
+ - !ruby/object:Gem::Version
218
+ version: '0'
219
+ required_rubygems_version: !ruby/object:Gem::Requirement
220
+ requirements:
221
+ - - ">="
222
+ - !ruby/object:Gem::Version
223
+ version: '0'
224
+ requirements: []
225
+ rubyforge_project:
226
+ rubygems_version: 2.2.1
227
+ signing_key:
228
+ specification_version: 4
229
+ summary: Stores values in a thread local or thread global storage
230
+ test_files:
231
+ - spec/integration/lib/scoped_storage/scope_spec.rb
232
+ - spec/spec_helper.rb
233
+ - spec/unit/lib/scoped_storage/scope_spec.rb
234
+ - spec/unit/lib/scoped_storage/thread_global_storage_spec.rb
235
+ - spec/unit/lib/scoped_storage/thread_local_storage_spec.rb