mankai-cache 0.1.0

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,53 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Mankai
4
+ class Cache
5
+ module Stores
6
+ # Keeps nothing: every read misses, and fetch always runs its block. For tests, and for
7
+ # turning caching off without changing code.
8
+ #
9
+ # @api public
10
+ # @since 0.1.0
11
+ class Null
12
+ include Store
13
+
14
+ # @api public
15
+ # @since 0.1.0
16
+ def read(_key)
17
+ nil
18
+ end
19
+
20
+ # @api public
21
+ # @since 0.1.0
22
+ def write(_key, _data, expires_at:)
23
+ true
24
+ end
25
+
26
+ # @api public
27
+ # @since 0.1.0
28
+ def delete(_key)
29
+ false
30
+ end
31
+
32
+ # @api public
33
+ # @since 0.1.0
34
+ def update(_key)
35
+ yield(nil)
36
+ nil
37
+ end
38
+
39
+ # @api public
40
+ # @since 0.1.0
41
+ def clear
42
+ true
43
+ end
44
+
45
+ # @api public
46
+ # @since 0.1.0
47
+ def cleanup(_now)
48
+ 0
49
+ end
50
+ end
51
+ end
52
+ end
53
+ end
@@ -0,0 +1,69 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Shared examples for the Store contract, for store specs:
4
+ #
5
+ # require "mankai/cache/testing/store_examples"
6
+ #
7
+ # RSpec.describe MyStore do
8
+ # subject(:store) { MyStore.new }
9
+ #
10
+ # it_behaves_like "a mankai-cache store"
11
+ # end
12
+ #
13
+ # Pass `cleanup: false` for stores whose cleanup does not delete entries by their expiry time.
14
+ #
15
+ # @api public
16
+ # @since 0.1.0
17
+ RSpec.shared_examples "a mankai-cache store" do |cleanup: true|
18
+ it "writes, reads and deletes entries" do
19
+ expect(store.read("a")).to be_nil
20
+ expect(store.write("a", "one".b, expires_at: nil)).to be(true)
21
+ expect(store.read("a")).to eq("one".b)
22
+
23
+ store.write("a", "two".b, expires_at: nil)
24
+ expect(store.read("a")).to eq("two".b)
25
+
26
+ expect(store.delete("a")).to be(true)
27
+ expect(store.delete("a")).to be(false)
28
+ expect(store.read("a")).to be_nil
29
+ end
30
+
31
+ it "keeps binary data intact" do
32
+ data = (0..255).map(&:chr).join.b
33
+ store.write("bin", data, expires_at: nil)
34
+ expect(store.read("bin")).to eq(data)
35
+ end
36
+
37
+ it "reads, writes and deletes several entries" do
38
+ store.write_multi({"a" => "1", "b" => "2"}, expires_at: nil)
39
+ expect(store.read_multi(%w[a b c])).to eq("a" => "1", "b" => "2")
40
+ expect(store.delete_multi(%w[a c])).to eq(1)
41
+ expect(store.read_multi(%w[a b])).to eq("b" => "2")
42
+ end
43
+
44
+ it "updates an entry with the block's result" do
45
+ store.update("counter") do |data|
46
+ expect(data).to be_nil
47
+ ["1", nil]
48
+ end
49
+ store.update("counter") { |data| [(Integer(data) + 1).to_s, nil] }
50
+ expect(store.read("counter")).to eq("2")
51
+ end
52
+
53
+ it "clears every entry" do
54
+ store.write("a", "1", expires_at: nil)
55
+ store.clear
56
+ expect(store.read("a")).to be_nil
57
+ end
58
+
59
+ it "deletes expired entries on cleanup", if: cleanup do
60
+ now = Time.now.to_f
61
+ store.write("old", "1", expires_at: now - 1)
62
+ store.write("new", "2", expires_at: now + 60)
63
+ store.write("forever", "3", expires_at: nil)
64
+ store.cleanup(now)
65
+ expect(store.read("old")).to be_nil
66
+ expect(store.read("new")).to eq("2")
67
+ expect(store.read("forever")).to eq("3")
68
+ end
69
+ end
@@ -0,0 +1,9 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Mankai
4
+ class Cache
5
+ # @api public
6
+ # @since 0.1.0
7
+ VERSION = "0.1.0"
8
+ end
9
+ end
@@ -0,0 +1,54 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Mankai
4
+ class Cache
5
+ # A template helper that caches part of a page.
6
+ #
7
+ # # app/views/helpers.rb
8
+ # module Bookshelf
9
+ # module Views
10
+ # module Helpers
11
+ # include Mankai::Cache::ViewHelpers
12
+ # end
13
+ # end
14
+ # end
15
+ #
16
+ # # app/views/context.rb: the helper reads the cache from the view context
17
+ # class Context < Hanami::View::Context
18
+ # include Deps["cache"]
19
+ # end
20
+ #
21
+ # <%= cache ["books", book.id, book.updated_at] do %>
22
+ # <%= render "books/card", book: book %>
23
+ # <% end %>
24
+ #
25
+ # The key must change whenever the cached HTML should: include the records it shows and
26
+ # their update times (a record can be a key part itself only if it has `cache_key`, and
27
+ # then `cache_version` versions it), and anything else the HTML
28
+ # depends on, such as the locale or the current user's role. Changing the template does not
29
+ # change the key, so add a version to it, e.g. `cache ["v2", book]`, when you change markup.
30
+ #
31
+ # Keys are stored under "views/", apart from your own keys.
32
+ #
33
+ # @api public
34
+ # @since 0.1.0
35
+ module ViewHelpers
36
+ # @param key [Object] see Key.expand
37
+ # @param options see Cache#fetch (expires_in:, version:, race_condition_ttl:, ...)
38
+ # @return [String] the HTML, marked safe
39
+ #
40
+ # @api public
41
+ # @since 0.1.0
42
+ def cache(key, **options)
43
+ unless _context.respond_to?(:cache)
44
+ raise ConfigurationError, "the cache helper needs the view context to have the cache: add " \
45
+ "include Deps[\"cache\"] to your view context class"
46
+ end
47
+
48
+ # A plain String, so the cached copy does not depend on the view library's string class.
49
+ html = _context.cache.fetch(["views", key], **options) { String.new(yield.to_s) }
50
+ html.html_safe
51
+ end
52
+ end
53
+ end
54
+ end
@@ -0,0 +1,348 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "digest"
4
+ require "dry/system"
5
+ require "zeitwerk"
6
+
7
+ module Mankai
8
+ # Caching for Hanami apps. See README.md.
9
+ #
10
+ # A cache turns keys into strings, encodes values with their expiry and version, and keeps them
11
+ # in a store. Inject it as the "cache" component (see ProviderSource), or build one directly:
12
+ #
13
+ # cache = Mankai::Cache.new(store: Mankai::Cache::Stores::Memory.new, expires_in: 300)
14
+ # cache.fetch(["book", id]) { book_repo.find(id).to_h }
15
+ #
16
+ # @api public
17
+ # @since 0.1.0
18
+ class Cache
19
+ # Longer keys are shortened and given a digest suffix, so every store can hold them.
20
+ #
21
+ # @api public
22
+ # @since 0.1.0
23
+ DEFAULT_MAX_KEY_SIZE = 250
24
+
25
+ # @api private
26
+ # @since 0.1.0
27
+ def self.gem_loader
28
+ @gem_loader ||= Zeitwerk::Loader.new.tap do |loader|
29
+ root = File.expand_path("..", __dir__)
30
+ loader.tag = "mankai-cache"
31
+ loader.inflector = Zeitwerk::GemInflector.new("#{root}/mankai-cache.rb")
32
+ loader.push_dir(root)
33
+ loader.ignore(
34
+ "#{root}/mankai-cache.rb",
35
+ "#{root}/mankai/cache/{errors,version}.rb",
36
+ # Required by test suites.
37
+ "#{root}/mankai/cache/testing"
38
+ )
39
+ loader.inflector.inflect("json" => "JSON")
40
+ end
41
+ end
42
+
43
+ gem_loader.setup
44
+ require_relative "cache/errors"
45
+ require_relative "cache/version"
46
+
47
+ Dry::System.register_provider_source(:cache, group: :mankai_cache, source: ProviderSource)
48
+
49
+ # @api public
50
+ # @since 0.1.0
51
+ attr_reader :store, :namespace, :expires_in, :coder, :max_key_size, :clock, :instrumenter
52
+
53
+ # @param store [#read, #write, #delete, #update, #clear, #cleanup] where entries are kept
54
+ # (see Store)
55
+ # @param namespace [String, nil] prefixed to every key, e.g. to share a store between apps
56
+ # @param expires_in [Numeric, nil] default lifetime of written entries, in seconds; nil keeps
57
+ # them until the store evicts them
58
+ # @param coder [Coder] encodes entries (serializer and compression)
59
+ # @param clock [#call] returns the current Time
60
+ # @param instrumenter [Instrumenter]
61
+ #
62
+ # @api public
63
+ # @since 0.1.0
64
+ def initialize(
65
+ store: Stores::Memory.new,
66
+ namespace: nil,
67
+ expires_in: nil,
68
+ coder: Coder.new,
69
+ max_key_size: DEFAULT_MAX_KEY_SIZE,
70
+ clock: -> { Time.now },
71
+ instrumenter: Instrumenter::NULL
72
+ )
73
+ @store = store
74
+ @namespace = namespace&.to_s
75
+ @expires_in = expires_in
76
+ @coder = coder
77
+ @max_key_size = max_key_size
78
+ @clock = clock
79
+ @instrumenter = instrumenter
80
+ end
81
+
82
+ # @param key [Object] see Key.expand
83
+ # @param version [#to_s, nil] the entry is a miss unless written with this version (compared
84
+ # as a String, so 3 and "3" match); taken from the key's `cache_version` when not given
85
+ # @return [Object, nil] the value, or nil on a miss
86
+ #
87
+ # @api public
88
+ # @since 0.1.0
89
+ def read(key, version: nil)
90
+ name = key_for(key)
91
+ instrument(:read, key: name) do |payload|
92
+ entry = read_entry(name)
93
+ payload[:hit] = usable?(entry, version_for(key, version))
94
+ payload[:hit] ? entry.value : nil
95
+ end
96
+ end
97
+
98
+ # @return [Hash{Object => Object}] the values found, by the keys given (misses are left out)
99
+ #
100
+ # @api public
101
+ # @since 0.1.0
102
+ def read_multi(*keys, version: nil)
103
+ names = keys.to_h { |key| [key_for(key), key] }
104
+ instrument(:read_multi, keys: names.keys) do |payload|
105
+ found = {}
106
+ store.read_multi(names.keys).each do |name, data|
107
+ key = names.fetch(name)
108
+ entry = coder.load(data)
109
+ found[key] = entry.value if usable?(entry, version_for(key, version))
110
+ end
111
+ payload[:hits] = found.keys.map { |key| key_for(key) }
112
+ found
113
+ end
114
+ end
115
+
116
+ # @param expires_in [Numeric, nil] seconds until the entry expires
117
+ # @param expires_at [Time, nil] when the entry expires (instead of expires_in)
118
+ # @param version [String, nil] see #read
119
+ # @return [true]
120
+ #
121
+ # @api public
122
+ # @since 0.1.0
123
+ def write(key, value, expires_in: self.expires_in, expires_at: nil, version: nil)
124
+ name = key_for(key)
125
+ instrument(:write, key: name) do
126
+ expires_at = expiry(expires_in, expires_at)
127
+ entry = Entry.new(value: value, expires_at: expires_at, version: version_for(key, version))
128
+ store.write(name, coder.dump(entry), expires_at: entry.expires_at)
129
+ true
130
+ end
131
+ end
132
+
133
+ # @param values [Hash{Object => Object}]
134
+ # @return [true]
135
+ #
136
+ # @api public
137
+ # @since 0.1.0
138
+ def write_multi(values, expires_in: self.expires_in, expires_at: nil, version: nil)
139
+ expires_at = expiry(expires_in, expires_at)
140
+ entries = values.to_h do |key, value|
141
+ entry = Entry.new(value: value, expires_at: expires_at, version: version_for(key, version))
142
+ [key_for(key), coder.dump(entry)]
143
+ end
144
+ instrument(:write_multi, keys: entries.keys) do
145
+ store.write_multi(entries, expires_at: expires_at)
146
+ true
147
+ end
148
+ end
149
+
150
+ # Returns the cached value, or runs the block, stores its result and returns it.
151
+ #
152
+ # @param force [Boolean] run the block even on a hit
153
+ # @param skip_nil [Boolean] do not store a nil result
154
+ # @param race_condition_ttl [Numeric, nil] when the entry has expired, keep serving it to
155
+ # other callers for this many seconds while this one runs the block, so that a popular
156
+ # key's value is recomputed once rather than by every caller at the same time
157
+ # @param write_options see #write
158
+ # @yieldparam key [Object] the key given
159
+ #
160
+ # @api public
161
+ # @since 0.1.0
162
+ def fetch(key, force: false, skip_nil: false, race_condition_ttl: nil, **write_options)
163
+ raise ArgumentError, "fetch needs a block to compute missing values" unless block_given?
164
+
165
+ name = key_for(key)
166
+ version = version_for(key, write_options[:version])
167
+ instrument(:fetch, key: name) do |payload|
168
+ entry = force ? nil : read_entry(name)
169
+ payload[:hit] = usable?(entry, version)
170
+ if payload[:hit]
171
+ entry.value
172
+ else
173
+ extend_stale(name, entry, version, race_condition_ttl)
174
+ value = yield(key)
175
+ write(key, value, **write_options) unless skip_nil && value.nil?
176
+ value
177
+ end
178
+ end
179
+ end
180
+
181
+ # Like #fetch, for several keys: the block runs once for each missing key.
182
+ #
183
+ # @return [Hash{Object => Object}] values by key, in the order given
184
+ #
185
+ # @api public
186
+ # @since 0.1.0
187
+ def fetch_multi(*keys, skip_nil: false, **write_options)
188
+ raise ArgumentError, "fetch_multi needs a block to compute missing values" unless block_given?
189
+
190
+ found = read_multi(*keys, version: write_options[:version])
191
+ computed = (keys - found.keys).to_h { |key| [key, yield(key)] }
192
+ to_write = skip_nil ? computed.compact : computed
193
+ write_multi(to_write, **write_options) if to_write.any?
194
+ keys.to_h { |key| [key, found.fetch(key) { computed[key] }] }
195
+ end
196
+
197
+ # @api public
198
+ # @since 0.1.0
199
+ def exist?(key, version: nil)
200
+ usable?(read_entry(key_for(key)), version_for(key, version))
201
+ end
202
+
203
+ # @return [Boolean] whether there was an entry
204
+ #
205
+ # @api public
206
+ # @since 0.1.0
207
+ def delete(key)
208
+ name = key_for(key)
209
+ instrument(:delete, key: name) { store.delete(name) }
210
+ end
211
+
212
+ # @return [Integer] how many entries were deleted
213
+ #
214
+ # @api public
215
+ # @since 0.1.0
216
+ def delete_multi(keys)
217
+ names = keys.map { |key| key_for(key) }
218
+ instrument(:delete_multi, keys: names) { store.delete_multi(names) }
219
+ end
220
+
221
+ # Adds to an Integer value atomically, starting from 0. The entry keeps its expiry, or gets
222
+ # `expires_in` when it is new.
223
+ #
224
+ # @return [Integer] the new value
225
+ #
226
+ # @api public
227
+ # @since 0.1.0
228
+ def increment(key, amount = 1, expires_in: self.expires_in)
229
+ name = key_for(key)
230
+ instrument(:increment, key: name, amount: amount) do
231
+ value = nil
232
+ store.update(name) do |data|
233
+ entry = data && coder.load(data)
234
+ entry = nil unless usable?(entry, nil)
235
+ value = Integer(entry&.value || 0) + amount
236
+ expires_at = entry ? entry.expires_at : expiry(expires_in, nil)
237
+ [coder.dump(Entry.new(value: value, expires_at: expires_at, version: nil)), expires_at]
238
+ end
239
+ value
240
+ end
241
+ end
242
+
243
+ # @return [Integer] the new value
244
+ #
245
+ # @api public
246
+ # @since 0.1.0
247
+ def decrement(key, amount = 1, **options)
248
+ increment(key, -amount, **options)
249
+ end
250
+
251
+ # Deletes every entry in the store, including other namespaces' entries.
252
+ #
253
+ # @api public
254
+ # @since 0.1.0
255
+ def clear
256
+ instrument(:clear) { store.clear }
257
+ end
258
+
259
+ # Deletes expired entries, for stores that keep them until asked.
260
+ #
261
+ # @api public
262
+ # @since 0.1.0
263
+ def cleanup
264
+ instrument(:cleanup) { store.cleanup(now) }
265
+ end
266
+
267
+ # Releases the store's resources (e.g. a background thread or a connection pool).
268
+ #
269
+ # @api public
270
+ # @since 0.1.0
271
+ def close
272
+ store.close
273
+ end
274
+
275
+ # The string a key is stored under: expanded, namespaced, and shortened when too long.
276
+ #
277
+ # @api public
278
+ # @since 0.1.0
279
+ def key_for(key)
280
+ name = Key.expand(key)
281
+ name = "#{namespace}:#{name}" if namespace
282
+ return name if name.bytesize <= max_key_size
283
+
284
+ digest = Digest::SHA256.hexdigest(name)
285
+ "#{name.byteslice(0, max_key_size - digest.size - 8).scrub("")}:sha256:#{digest}"
286
+ end
287
+
288
+ private
289
+
290
+ # @api private
291
+ # @since 0.1.0
292
+ def read_entry(name)
293
+ data = store.read(name)
294
+ data && coder.load(data)
295
+ end
296
+
297
+ # The version as stored: a String, or nil for none. Versions are compared as Strings, so 3
298
+ # and "3" are the same version.
299
+ #
300
+ # @api private
301
+ # @since 0.1.0
302
+ def version_for(key, version)
303
+ version = version.nil? ? Key.version(key) : version.to_s
304
+ version unless version.nil? || version.empty?
305
+ end
306
+
307
+ # @api private
308
+ # @since 0.1.0
309
+ def usable?(entry, version)
310
+ !entry.nil? && !entry.expired?(now) && entry.version == version
311
+ end
312
+
313
+ # Writes an expired entry back for a little longer, so other callers keep using it while
314
+ # this one computes the new value.
315
+ #
316
+ # @api private
317
+ # @since 0.1.0
318
+ def extend_stale(name, entry, version, race_condition_ttl)
319
+ return unless race_condition_ttl && entry&.expired?(now) && entry.version == version
320
+
321
+ stale = entry.with(expires_at: now + race_condition_ttl)
322
+ store.write(name, coder.dump(stale), expires_at: stale.expires_at)
323
+ end
324
+
325
+ # @return [Float, nil] seconds since the epoch
326
+ #
327
+ # @api private
328
+ # @since 0.1.0
329
+ def expiry(expires_in, expires_at)
330
+ return expires_at.to_f if expires_at
331
+ return unless expires_in
332
+
333
+ now + expires_in.to_f
334
+ end
335
+
336
+ # @api private
337
+ # @since 0.1.0
338
+ def now
339
+ clock.call.to_f
340
+ end
341
+
342
+ # @api private
343
+ # @since 0.1.0
344
+ def instrument(event, payload = {}, &)
345
+ instrumenter.instrument(event, payload, &)
346
+ end
347
+ end
348
+ end
@@ -0,0 +1,3 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative "mankai/cache"
@@ -0,0 +1,34 @@
1
+ # frozen_string_literal: true
2
+
3
+ lib = File.expand_path("lib", __dir__)
4
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
5
+ require "mankai/cache/version"
6
+
7
+ Gem::Specification.new do |spec|
8
+ spec.name = "mankai-cache"
9
+ spec.authors = ["Ibrahim Diallo"]
10
+ spec.email = ["thisis@ibrahimd.com"]
11
+ spec.license = "MIT"
12
+ spec.version = Mankai::Cache::VERSION.dup
13
+ spec.homepage = "https://github.com/thisisibrahimd/mankai"
14
+ spec.metadata["github_repo"] = "https://github.com/thisisibrahimd/mankai"
15
+ spec.metadata["source_code_uri"] = "https://github.com/thisisibrahimd/mankai/tree/main/gems/mankai-cache"
16
+ spec.metadata["changelog_uri"] = "https://github.com/thisisibrahimd/mankai/blob/main/gems/mankai-cache/CHANGELOG.md"
17
+ spec.metadata["rubygems_mfa_required"] = "true"
18
+
19
+ spec.summary = "Caching for Hanami apps, with swappable stores"
20
+ spec.description = <<~TEXT
21
+ A cache component you inject: read, write and fetch values with expiry and versions, backed by
22
+ a store (memory, file, or an adapter gem such as mankai-cache-sql), plus a template helper for
23
+ caching parts of a page.
24
+ TEXT
25
+ spec.files = Dir["CHANGELOG.md", "LICENSE", "README.md", "mankai-cache.gemspec", "lib/**/*"]
26
+ spec.require_paths = ["lib"]
27
+
28
+ spec.extra_rdoc_files = ["README.md", "CHANGELOG.md", "LICENSE"]
29
+
30
+ spec.required_ruby_version = ">= 3.3"
31
+
32
+ spec.add_runtime_dependency "dry-system", "~> 1.1"
33
+ spec.add_runtime_dependency "zeitwerk", "~> 2.6"
34
+ end
metadata ADDED
@@ -0,0 +1,100 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: mankai-cache
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Ibrahim Diallo
8
+ bindir: bin
9
+ cert_chain: []
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
+ dependencies:
12
+ - !ruby/object:Gem::Dependency
13
+ name: dry-system
14
+ requirement: !ruby/object:Gem::Requirement
15
+ requirements:
16
+ - - "~>"
17
+ - !ruby/object:Gem::Version
18
+ version: '1.1'
19
+ type: :runtime
20
+ prerelease: false
21
+ version_requirements: !ruby/object:Gem::Requirement
22
+ requirements:
23
+ - - "~>"
24
+ - !ruby/object:Gem::Version
25
+ version: '1.1'
26
+ - !ruby/object:Gem::Dependency
27
+ name: zeitwerk
28
+ requirement: !ruby/object:Gem::Requirement
29
+ requirements:
30
+ - - "~>"
31
+ - !ruby/object:Gem::Version
32
+ version: '2.6'
33
+ type: :runtime
34
+ prerelease: false
35
+ version_requirements: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: '2.6'
40
+ description: |
41
+ A cache component you inject: read, write and fetch values with expiry and versions, backed by
42
+ a store (memory, file, or an adapter gem such as mankai-cache-sql), plus a template helper for
43
+ caching parts of a page.
44
+ email:
45
+ - thisis@ibrahimd.com
46
+ executables: []
47
+ extensions: []
48
+ extra_rdoc_files:
49
+ - CHANGELOG.md
50
+ - LICENSE
51
+ - README.md
52
+ files:
53
+ - CHANGELOG.md
54
+ - LICENSE
55
+ - README.md
56
+ - lib/mankai-cache.rb
57
+ - lib/mankai/cache.rb
58
+ - lib/mankai/cache/coder.rb
59
+ - lib/mankai/cache/entry.rb
60
+ - lib/mankai/cache/errors.rb
61
+ - lib/mankai/cache/instrumenter.rb
62
+ - lib/mankai/cache/key.rb
63
+ - lib/mankai/cache/provider_source.rb
64
+ - lib/mankai/cache/serializers.rb
65
+ - lib/mankai/cache/serializers/json.rb
66
+ - lib/mankai/cache/serializers/marshal.rb
67
+ - lib/mankai/cache/store.rb
68
+ - lib/mankai/cache/stores/file.rb
69
+ - lib/mankai/cache/stores/memory.rb
70
+ - lib/mankai/cache/stores/null.rb
71
+ - lib/mankai/cache/testing/store_examples.rb
72
+ - lib/mankai/cache/version.rb
73
+ - lib/mankai/cache/view_helpers.rb
74
+ - mankai-cache.gemspec
75
+ homepage: https://github.com/thisisibrahimd/mankai
76
+ licenses:
77
+ - MIT
78
+ metadata:
79
+ github_repo: https://github.com/thisisibrahimd/mankai
80
+ source_code_uri: https://github.com/thisisibrahimd/mankai/tree/main/gems/mankai-cache
81
+ changelog_uri: https://github.com/thisisibrahimd/mankai/blob/main/gems/mankai-cache/CHANGELOG.md
82
+ rubygems_mfa_required: 'true'
83
+ rdoc_options: []
84
+ require_paths:
85
+ - lib
86
+ required_ruby_version: !ruby/object:Gem::Requirement
87
+ requirements:
88
+ - - ">="
89
+ - !ruby/object:Gem::Version
90
+ version: '3.3'
91
+ required_rubygems_version: !ruby/object:Gem::Requirement
92
+ requirements:
93
+ - - ">="
94
+ - !ruby/object:Gem::Version
95
+ version: '0'
96
+ requirements: []
97
+ rubygems_version: 4.0.20
98
+ specification_version: 4
99
+ summary: Caching for Hanami apps, with swappable stores
100
+ test_files: []