stockpile_cache 1.3.0 → 1.3.1

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
  SHA256:
3
- metadata.gz: '055681de81947f8bb1934929e2a0467a332c2c7bfaee62e3fe0c0fdac7c51033'
4
- data.tar.gz: 7a38b8765377b2b3df4b7919c0148b543cc5f8465a559b1e08ddc9fb4cf4a1f6
3
+ metadata.gz: 6ad32124765de7dec002510817eba80abf37eb7e42403de931e6c74cc9178842
4
+ data.tar.gz: b0242fe4109a69ce917997181ec76b00b47c0cb8c02794d88edf75276b5d62fc
5
5
  SHA512:
6
- metadata.gz: b917312a5c31ac63518097609ee538a2699f8c629926386cff33c7c3ab9cf1ed6161a1486ac0b708cd9055d21d424c00c4e4945a315d3237db6c33440b9d65e2
7
- data.tar.gz: 19f55f2f2b072d4a11f3af6c2fd6596068c6c31a5745eff056548c196ef3d2cda58af8dcaa00cf93a07355cf8b9e8f1fad43e9e8cf5ce1e4db6eaaefbe0e46db
6
+ metadata.gz: 1540e626290d9209a0820c8a8f9830f9bc14cf8d10569bf6279b4369a0da35843d0a19ef99f90e0ab21de31c3653a24d5658285e410085aeda4e2d7209658cc6
7
+ data.tar.gz: 7bf019df445a2a1acd3a70d1400a65d06b09056a35ea287ea3b469fd7fb65753530d47cf2105a93f8f6b7dc1348409ba5ba5680464ce46b3d897fd55c7a00503
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.3.1
4
+ - Parsing ERB in YAML configs
5
+ - Fill in missing README about cache expiration
6
+
3
7
  ## 1.3.0
4
8
  - Allowing optional compression of cached content
5
9
 
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- stockpile_cache (1.3.0)
4
+ stockpile_cache (1.3.1)
5
5
  connection_pool
6
6
  oj
7
7
  rake
data/README.md CHANGED
@@ -91,6 +91,12 @@ end
91
91
  | `db` | (optional) Name of the Redis database to cache value in. Defaults to `:default` |
92
92
  | `&block` | Block of code to execute; it's return value will be stored in cache. |
93
93
 
94
+ To expire your cache immediately run:
95
+
96
+ ```
97
+ Stockpile.expire_cached(key: 'meaning_of_life')
98
+ ```
99
+
94
100
  ### Multiple Database
95
101
  Stockpile comes with a support for multiple databases. A word of caution: unless
96
102
  you have very good reason to run multiple databases within single instance of
@@ -23,5 +23,5 @@ module Stockpile
23
23
  DEFAULT_TTL = 60 * 5
24
24
  LOCK_PREFIX = 'stockpile_lock::'
25
25
  SLUMBER_COOLDOWN = 0.05
26
- VERSION = '1.3.0'
26
+ VERSION = '1.3.1'
27
27
  end
@@ -58,7 +58,11 @@ module Stockpile
58
58
  end
59
59
 
60
60
  def parsed_configuration
61
- YAML.safe_load(raw_configuration)
61
+ YAML.safe_load(
62
+ ERB.new(
63
+ raw_configuration
64
+ ).result
65
+ )
62
66
  end
63
67
 
64
68
  def raw_configuration
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stockpile_cache
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.0
4
+ version: 1.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - ConvertKit, LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-05-20 00:00:00.000000000 Z
11
+ date: 2020-06-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: connection_pool