active_remote-cached 0.1.2 → 0.1.3

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: d09ee17c4bc381af4901fdff4db406009ad2c027
4
- data.tar.gz: 38b5d38c0ac4ff0dbd0852b155a6dfb5347f756b
3
+ metadata.gz: 81e9acd882928c8bbbef788810301b195c2400eb
4
+ data.tar.gz: ac45bdd85f22bfa2185451e4bf0bfb2c03410510
5
5
  SHA512:
6
- metadata.gz: faa37b47e9d4df79ac735501d72e562b42e10ef5c4302305d080243382b48420417d56317aade1a7c866bf0275fcf6fc2c31ef0c619804efbf8ad6f58e99e464
7
- data.tar.gz: b205d8e1b41052fa887efcc28ede71fb3ebaef907d05d4a40c18e4f9848713937e3b47d526e32eb5d057d06a3a93b6b464bece96bddd08720074231366ca1484
6
+ metadata.gz: e24999c6d62259b1f88f625cc8ae7bdb96d2ae0c5bd3d0beca2418729823d3d8b2fbdd4581b17a27ecf82ca7ed5831975b67167639b158d24986f36d1a2f3497
7
+ data.tar.gz: b699749dbd2d7d77cf9b4851d460c9d76b7bb2ac96374b9874001c950a7d45550ce4b3efd49a0e0e956592ef8780bcd507bf7e7e13cfebe5f8a7e3c59428476e
@@ -139,9 +139,9 @@ module ActiveRemote
139
139
  # def self.cached_delete_by_user_guid(user_guid, options = {})
140
140
  # ::ActiveRemote::Cached.cache.delete([name, user_guid])
141
141
  # end
142
- def self.#{method_name}(#{expanded_method_args}, options = {})
143
- options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(options)
144
- namespace = options.delete(:namespace)
142
+ def self.#{method_name}(#{expanded_method_args}, __active_remote_cached_options = {})
143
+ __active_remote_cached_options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(__active_remote_cached_options)
144
+ namespace = __active_remote_cached_options.delete(:namespace)
145
145
  find_cache_key = [namespace, name, "#find", #{sorted_method_args}].compact
146
146
  search_cache_key = [namespace, name, "#search", #{sorted_method_args}].compact
147
147
 
@@ -160,9 +160,9 @@ module ActiveRemote
160
160
  # def self.cached_exist_find_by_user_guid(user_guid, options = {})
161
161
  # ::ActiveRemote::Cached.cache.exist?([name, user_guid])
162
162
  # end
163
- def self.#{method_name}(#{expanded_method_args}, options = {})
164
- options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(options)
165
- namespace = options.delete(:namespace)
163
+ def self.#{method_name}(#{expanded_method_args}, __active_remote_cached_options = {})
164
+ __active_remote_cached_options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(__active_remote_cached_options)
165
+ namespace = __active_remote_cached_options.delete(:namespace)
166
166
  cache_key = [namespace, name, "#find", #{sorted_method_args}].compact
167
167
 
168
168
  ::ActiveRemote::Cached.cache.exist?(cache_key)
@@ -181,9 +181,9 @@ module ActiveRemote
181
181
  # def self.cached_exist_search_by_user_guid(user_guid, options = {})
182
182
  # ::ActiveRemote::Cached.cache.exist?([namespace, name, "#search", user_guid])
183
183
  # end
184
- def self.#{method_name}(#{expanded_method_args}, options = {})
185
- options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(options)
186
- namespace = options.delete(:namespace)
184
+ def self.#{method_name}(#{expanded_method_args}, __active_remote_cached_options = {})
185
+ __active_remote_cached_options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(__active_remote_cached_options)
186
+ namespace = __active_remote_cached_options.delete(:namespace)
187
187
  cache_key = [namespace, name, "#search", #{sorted_method_args}].compact
188
188
 
189
189
  ::ActiveRemote::Cached.cache.exist?(cache_key)
@@ -215,12 +215,12 @@ module ActiveRemote
215
215
  # If a block is given, it is incumbent on the caller to make sure the expectation
216
216
  # of the result object is maintained for requests/responses
217
217
  #
218
- def self.#{method_name}(#{expanded_method_args}, options = {})
219
- options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(options)
220
- namespace = options.delete(:namespace)
218
+ def self.#{method_name}(#{expanded_method_args}, __active_remote_cached_options = {})
219
+ __active_remote_cached_options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(__active_remote_cached_options)
220
+ namespace = __active_remote_cached_options.delete(:namespace)
221
221
  cache_key = [namespace, name, "#find", #{sorted_method_args}].compact
222
222
 
223
- ::ActiveRemote::Cached.cache.fetch(cache_key, options) do
223
+ ::ActiveRemote::Cached.cache.fetch(cache_key, __active_remote_cached_options) do
224
224
  if block_given?
225
225
  yield
226
226
  else
@@ -257,12 +257,12 @@ module ActiveRemote
257
257
  # If a block is given, it is incumbent on the caller to make sure the expectation
258
258
  # of the result object is maintained for requests/responses
259
259
  #
260
- def self.#{method_name}(#{expanded_method_args}, options = {})
261
- options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(options)
262
- namespace = options.delete(:namespace)
260
+ def self.#{method_name}(#{expanded_method_args}, __active_remote_cached_options = {})
261
+ __active_remote_cached_options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(__active_remote_cached_options)
262
+ namespace = __active_remote_cached_options.delete(:namespace)
263
263
  cache_key = [namespace, name, "#search", #{sorted_method_args}].compact
264
264
 
265
- ::ActiveRemote::Cached.cache.fetch(cache_key, options) do
265
+ ::ActiveRemote::Cached.cache.fetch(cache_key, __active_remote_cached_options) do
266
266
  if block_given?
267
267
  yield
268
268
  else
@@ -304,12 +304,12 @@ module ActiveRemote
304
304
  # If a block is given, it is incumbent on the caller to make sure the expectation
305
305
  # of the result object is maintained for requests/responses
306
306
  #
307
- def self.#{method_name}(#{expanded_method_args}, options = {})
308
- options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(options)
309
- namespace = options.delete(:namespace)
307
+ def self.#{method_name}(#{expanded_method_args}, __active_remote_cached_options = {})
308
+ __active_remote_cached_options = ::ActiveRemote::Cached.default_options.merge(#{cached_finder_options}).merge(__active_remote_cached_options)
309
+ namespace = __active_remote_cached_options.delete(:namespace)
310
310
  cache_key = [namespace, name, "#search", #{sorted_method_args}].compact
311
311
 
312
- ::ActiveRemote::Cached.cache.fetch(cache_key, options) do
312
+ ::ActiveRemote::Cached.cache.fetch(cache_key, __active_remote_cached_options) do
313
313
  results = []
314
314
 
315
315
  if block_given?
@@ -1,5 +1,5 @@
1
1
  module ActiveRemote
2
2
  module Cached
3
- VERSION = "0.1.2"
3
+ VERSION = "0.1.3"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_remote-cached
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Dewitt
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-04 00:00:00.000000000 Z
11
+ date: 2017-03-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: active_remote
@@ -138,7 +138,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
138
138
  version: '0'
139
139
  requirements: []
140
140
  rubyforge_project:
141
- rubygems_version: 2.5.1
141
+ rubygems_version: 2.6.10
142
142
  signing_key:
143
143
  specification_version: 4
144
144
  summary: Provides a configuration for caching mechanisms and finders on ActiveRemote