safe_memoize 0.8.0 → 1.0.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.
- checksums.yaml +4 -4
- data/.yardopts +10 -0
- data/CHANGELOG.md +23 -0
- data/README.md +555 -8
- data/ROADMAP.md +7 -22
- data/Rakefile +5 -0
- data/UPGRADING.md +197 -0
- data/benchmarks/README.md +68 -0
- data/benchmarks/benchmark.rb +225 -0
- data/codecov.yml +17 -0
- data/lib/safe_memoize/adapters/opentelemetry.rb +44 -0
- data/lib/safe_memoize/adapters/statsd.rb +56 -0
- data/lib/safe_memoize/cache_metrics_methods.rb +1 -0
- data/lib/safe_memoize/cache_record_methods.rb +1 -0
- data/lib/safe_memoize/cache_store_methods.rb +1 -0
- data/lib/safe_memoize/class_methods.rb +106 -21
- data/lib/safe_memoize/configuration.rb +43 -1
- data/lib/safe_memoize/custom_key_methods.rb +1 -0
- data/lib/safe_memoize/hooks_methods.rb +31 -0
- data/lib/safe_memoize/inspection_methods.rb +2 -1
- data/lib/safe_memoize/instance_methods.rb +1 -0
- data/lib/safe_memoize/lru_methods.rb +1 -0
- data/lib/safe_memoize/public_custom_key_methods.rb +23 -0
- data/lib/safe_memoize/public_methods.rb +162 -5
- data/lib/safe_memoize/public_metrics_methods.rb +20 -0
- data/lib/safe_memoize/rails/middleware.rb +25 -0
- data/lib/safe_memoize/rails/request_scoped.rb +40 -0
- data/lib/safe_memoize/rails.rb +28 -0
- data/lib/safe_memoize/release_tooling.rb +1 -0
- data/lib/safe_memoize/version.rb +2 -1
- data/lib/safe_memoize.rb +56 -0
- data/rbi/safe_memoize.rbi +245 -0
- data/sig/safe_memoize.rbs +41 -5
- metadata +12 -1
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
# typed: true
|
|
2
|
+
|
|
3
|
+
# Sorbet type stubs for the safe_memoize gem.
|
|
4
|
+
#
|
|
5
|
+
# These stubs cover every symbol listed in the public API guarantee
|
|
6
|
+
# (see README "Public API and versioning guarantee"). Opt-in extensions
|
|
7
|
+
# (SafeMemoize::Rails, SafeMemoize::Adapters::*) are included as well,
|
|
8
|
+
# but they are not part of the v1.0.0 semver guarantee.
|
|
9
|
+
#
|
|
10
|
+
# Usage: add `require "safe_memoize"` to your Sorbet ignore list if you
|
|
11
|
+
# use tapioca, or copy this file into sorbet/rbi/shims/ for manual setups.
|
|
12
|
+
|
|
13
|
+
module SafeMemoize
|
|
14
|
+
VERSION = T.let(T.unsafe(nil), String)
|
|
15
|
+
|
|
16
|
+
class Error < StandardError; end
|
|
17
|
+
|
|
18
|
+
sig { params(base: T::Class[T.anything]).void }
|
|
19
|
+
def self.prepended(base); end
|
|
20
|
+
|
|
21
|
+
sig { params(blk: T.proc.params(config: SafeMemoize::Configuration).void).void }
|
|
22
|
+
def self.configure(&blk); end
|
|
23
|
+
|
|
24
|
+
sig { returns(SafeMemoize::Configuration) }
|
|
25
|
+
def self.configuration; end
|
|
26
|
+
|
|
27
|
+
sig { returns(SafeMemoize::Configuration) }
|
|
28
|
+
def self.reset_configuration!; end
|
|
29
|
+
|
|
30
|
+
sig { params(subject: String, message: String, horizon: String).void }
|
|
31
|
+
def self.deprecate(subject, message:, horizon:); end
|
|
32
|
+
|
|
33
|
+
class Configuration
|
|
34
|
+
sig { returns(T.nilable(Numeric)) }
|
|
35
|
+
attr_accessor :default_ttl
|
|
36
|
+
|
|
37
|
+
sig { returns(T.nilable(Integer)) }
|
|
38
|
+
attr_accessor :default_max_size
|
|
39
|
+
|
|
40
|
+
sig { returns(T.nilable(T.proc.params(message: String).void)) }
|
|
41
|
+
attr_accessor :on_deprecation
|
|
42
|
+
|
|
43
|
+
sig { returns(T.nilable(T.proc.params(error: Exception, hook_type: Symbol, cache_key: T.untyped).void)) }
|
|
44
|
+
attr_accessor :on_hook_error
|
|
45
|
+
|
|
46
|
+
sig { returns(T::Boolean) }
|
|
47
|
+
attr_accessor :active_support_notifications
|
|
48
|
+
|
|
49
|
+
sig { returns(T.untyped) }
|
|
50
|
+
attr_accessor :statsd_client
|
|
51
|
+
|
|
52
|
+
sig { returns(T.untyped) }
|
|
53
|
+
attr_accessor :opentelemetry_tracer
|
|
54
|
+
|
|
55
|
+
sig { void }
|
|
56
|
+
def initialize; end
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
module ClassMethods
|
|
60
|
+
sig do
|
|
61
|
+
params(
|
|
62
|
+
method_name: T.any(Symbol, String),
|
|
63
|
+
ttl: T.nilable(Numeric),
|
|
64
|
+
max_size: T.nilable(Integer),
|
|
65
|
+
ttl_refresh: T::Boolean,
|
|
66
|
+
if: T.nilable(T.proc.params(result: T.untyped).returns(T.untyped)),
|
|
67
|
+
unless: T.nilable(T.proc.params(result: T.untyped).returns(T.untyped)),
|
|
68
|
+
shared: T::Boolean,
|
|
69
|
+
key: T.nilable(T.proc.params(args: T.untyped).returns(T.untyped))
|
|
70
|
+
).void
|
|
71
|
+
end
|
|
72
|
+
def memoize(method_name, ttl: nil, max_size: nil, ttl_refresh: false, if: nil, unless: nil, shared: false, key: nil); end
|
|
73
|
+
|
|
74
|
+
sig do
|
|
75
|
+
params(
|
|
76
|
+
except: T::Array[T.any(Symbol, String)],
|
|
77
|
+
only: T::Array[T.any(Symbol, String)],
|
|
78
|
+
include_protected: T::Boolean,
|
|
79
|
+
include_private: T::Boolean,
|
|
80
|
+
ttl: T.nilable(Numeric),
|
|
81
|
+
max_size: T.nilable(Integer),
|
|
82
|
+
ttl_refresh: T::Boolean,
|
|
83
|
+
if: T.nilable(T.proc.params(result: T.untyped).returns(T.untyped)),
|
|
84
|
+
unless: T.nilable(T.proc.params(result: T.untyped).returns(T.untyped)),
|
|
85
|
+
shared: T::Boolean,
|
|
86
|
+
key: T.nilable(T.proc.params(args: T.untyped).returns(T.untyped))
|
|
87
|
+
).void
|
|
88
|
+
end
|
|
89
|
+
def memoize_all(except: [], only: [], include_protected: false, include_private: false, ttl: nil, max_size: nil, ttl_refresh: false, if: nil, unless: nil, shared: false, key: nil); end
|
|
90
|
+
|
|
91
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).void }
|
|
92
|
+
def reset_shared_memo(method_name, *args, **kwargs); end
|
|
93
|
+
|
|
94
|
+
sig { void }
|
|
95
|
+
def reset_all_shared_memos; end
|
|
96
|
+
|
|
97
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).returns(T::Boolean) }
|
|
98
|
+
def shared_memoized?(method_name, *args, **kwargs); end
|
|
99
|
+
|
|
100
|
+
sig { params(method_name: T.nilable(T.any(Symbol, String))).returns(Integer) }
|
|
101
|
+
def shared_memo_count(method_name = nil); end
|
|
102
|
+
|
|
103
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).returns(T.nilable(Float)) }
|
|
104
|
+
def shared_memo_age(method_name, *args, **kwargs); end
|
|
105
|
+
|
|
106
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).returns(T::Boolean) }
|
|
107
|
+
def shared_memo_stale?(method_name, *args, **kwargs); end
|
|
108
|
+
end
|
|
109
|
+
|
|
110
|
+
module PublicMethods
|
|
111
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped, blk: T.nilable(T.proc.returns(T.untyped))).returns(T::Boolean) }
|
|
112
|
+
def memoized?(method_name, *args, **kwargs, &blk); end
|
|
113
|
+
|
|
114
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).returns(T.nilable(T.any(Float, Integer))) }
|
|
115
|
+
def memo_ttl_remaining(method_name, *args, **kwargs); end
|
|
116
|
+
|
|
117
|
+
sig { params(method_name: T.nilable(T.any(Symbol, String))).returns(Integer) }
|
|
118
|
+
def memo_count(method_name = nil); end
|
|
119
|
+
|
|
120
|
+
sig { params(method_name: T.nilable(T.any(Symbol, String))).returns(T::Array[T.untyped]) }
|
|
121
|
+
def memo_keys(method_name = nil); end
|
|
122
|
+
|
|
123
|
+
sig { params(method_name: T.nilable(T.any(Symbol, String))).returns(T::Array[T.untyped]) }
|
|
124
|
+
def memo_values(method_name = nil); end
|
|
125
|
+
|
|
126
|
+
sig { params(blk: T.proc.params(cache_key: T.untyped, record: T::Hash[Symbol, T.untyped]).returns(T.untyped)).void }
|
|
127
|
+
def on_memo_expire(&blk); end
|
|
128
|
+
|
|
129
|
+
sig { params(blk: T.proc.params(cache_key: T.untyped, record: T::Hash[Symbol, T.untyped]).returns(T.untyped)).void }
|
|
130
|
+
def on_memo_evict(&blk); end
|
|
131
|
+
|
|
132
|
+
sig { params(blk: T.proc.params(cache_key: T.untyped, record: T::Hash[Symbol, T.untyped]).returns(T.untyped)).void }
|
|
133
|
+
def on_memo_hit(&blk); end
|
|
134
|
+
|
|
135
|
+
sig { params(blk: T.proc.params(cache_key: T.untyped, record: T::Hash[Symbol, T.untyped]).returns(T.untyped)).void }
|
|
136
|
+
def on_memo_miss(&blk); end
|
|
137
|
+
|
|
138
|
+
sig { params(blk: T.proc.params(cache_key: T.untyped, record: T::Hash[Symbol, T.untyped]).returns(T.untyped)).void }
|
|
139
|
+
def on_memo_store(&blk); end
|
|
140
|
+
|
|
141
|
+
sig { params(hook_type: T.nilable(Symbol)).void }
|
|
142
|
+
def clear_memo_hooks(hook_type = nil); end
|
|
143
|
+
|
|
144
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, ttl: T.nilable(Numeric), kwargs: T.untyped, blk: T.proc.returns(T.untyped)).returns(T.untyped) }
|
|
145
|
+
def warm_memo(method_name, *args, ttl: nil, **kwargs, &blk); end
|
|
146
|
+
|
|
147
|
+
sig { params(method_name: T.any(Symbol, String), arg_sets: T::Array[T.untyped]).returns(T::Array[T.untyped]) }
|
|
148
|
+
def memo_preload(method_name, *arg_sets); end
|
|
149
|
+
|
|
150
|
+
sig { params(method_name: T.nilable(T.any(Symbol, String))).returns(T::Hash[T.untyped, T.untyped]) }
|
|
151
|
+
def dump_memo(method_name = nil); end
|
|
152
|
+
|
|
153
|
+
sig { params(snapshot: T::Hash[T.untyped, T.untyped]).void }
|
|
154
|
+
def load_memo(snapshot); end
|
|
155
|
+
|
|
156
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, ttl: T.nilable(Numeric), kwargs: T.untyped).returns(T::Boolean) }
|
|
157
|
+
def memo_touch(method_name, *args, ttl: nil, **kwargs); end
|
|
158
|
+
|
|
159
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).returns(T.untyped) }
|
|
160
|
+
def memo_refresh(method_name, *args, **kwargs); end
|
|
161
|
+
|
|
162
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).returns(T.nilable(Float)) }
|
|
163
|
+
def memo_age(method_name, *args, **kwargs); end
|
|
164
|
+
|
|
165
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).returns(T::Boolean) }
|
|
166
|
+
def memo_stale?(method_name, *args, **kwargs); end
|
|
167
|
+
|
|
168
|
+
sig { params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped).void }
|
|
169
|
+
def reset_memo(method_name, *args, **kwargs); end
|
|
170
|
+
|
|
171
|
+
sig { void }
|
|
172
|
+
def reset_all_memos; end
|
|
173
|
+
|
|
174
|
+
sig do
|
|
175
|
+
params(method_name: T.any(Symbol, String), args: T.untyped, kwargs: T.untyped)
|
|
176
|
+
.returns(T.nilable(T::Hash[Symbol, T.untyped]))
|
|
177
|
+
end
|
|
178
|
+
def memo_inspect(method_name, *args, **kwargs); end
|
|
179
|
+
end
|
|
180
|
+
|
|
181
|
+
module PublicMetricsMethods
|
|
182
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
183
|
+
def cache_stats; end
|
|
184
|
+
|
|
185
|
+
sig { params(method_name: T.any(Symbol, String)).returns(T::Hash[Symbol, T.untyped]) }
|
|
186
|
+
def cache_stats_for(method_name); end
|
|
187
|
+
|
|
188
|
+
sig { returns(Float) }
|
|
189
|
+
def cache_hit_rate; end
|
|
190
|
+
|
|
191
|
+
sig { returns(Float) }
|
|
192
|
+
def cache_miss_rate; end
|
|
193
|
+
|
|
194
|
+
sig { params(method_name: T.nilable(T.any(Symbol, String))).void }
|
|
195
|
+
def cache_metrics_reset(method_name = nil); end
|
|
196
|
+
end
|
|
197
|
+
|
|
198
|
+
module PublicCustomKeyMethods
|
|
199
|
+
sig { params(method_name: T.any(Symbol, String), blk: T.proc.params(args: T.untyped).returns(T.untyped)).void }
|
|
200
|
+
def memoize_with_custom_key(method_name, &blk); end
|
|
201
|
+
|
|
202
|
+
sig { params(method_name: T.nilable(T.any(Symbol, String))).void }
|
|
203
|
+
def clear_custom_keys(method_name = nil); end
|
|
204
|
+
end
|
|
205
|
+
|
|
206
|
+
module Adapters
|
|
207
|
+
module StatsD
|
|
208
|
+
METRIC_NAMES = T.let(T.unsafe(nil), T::Hash[Symbol, String])
|
|
209
|
+
|
|
210
|
+
sig { params(client: T.untyped, hook_type: Symbol, cache_key: T.untyped, class_name: T.nilable(String)).void }
|
|
211
|
+
def self.dispatch(client, hook_type, cache_key, class_name); end
|
|
212
|
+
end
|
|
213
|
+
|
|
214
|
+
module OpenTelemetry
|
|
215
|
+
SPAN_NAME = T.let(T.unsafe(nil), String)
|
|
216
|
+
|
|
217
|
+
sig { params(tracer: T.untyped, method_name: T.any(Symbol, String), class_name: T.nilable(String), blk: T.proc.returns(T.untyped)).returns(T.untyped) }
|
|
218
|
+
def self.trace(tracer, method_name, class_name, &blk); end
|
|
219
|
+
end
|
|
220
|
+
end
|
|
221
|
+
|
|
222
|
+
module Rails
|
|
223
|
+
sig { params(instance: T.untyped).void }
|
|
224
|
+
def self.track(instance); end
|
|
225
|
+
|
|
226
|
+
sig { void }
|
|
227
|
+
def self.reset_tracked!; end
|
|
228
|
+
|
|
229
|
+
module RequestScoped
|
|
230
|
+
sig { params(base: Module).void }
|
|
231
|
+
def self.included(base); end
|
|
232
|
+
|
|
233
|
+
sig { void }
|
|
234
|
+
def reset_request_memos; end
|
|
235
|
+
end
|
|
236
|
+
|
|
237
|
+
class Middleware
|
|
238
|
+
sig { params(app: T.untyped).void }
|
|
239
|
+
def initialize(app); end
|
|
240
|
+
|
|
241
|
+
sig { params(env: T.untyped).returns(T.untyped) }
|
|
242
|
+
def call(env); end
|
|
243
|
+
end
|
|
244
|
+
end
|
|
245
|
+
end
|
data/sig/safe_memoize.rbs
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
module SafeMemoize
|
|
2
2
|
VERSION: String
|
|
3
|
+
|
|
4
|
+
class Error < StandardError
|
|
5
|
+
end
|
|
6
|
+
|
|
3
7
|
include InstanceMethods
|
|
4
8
|
|
|
5
9
|
type default_memo_key = [Symbol, Array[untyped], Hash[Symbol, untyped]]
|
|
@@ -7,6 +11,7 @@ module SafeMemoize
|
|
|
7
11
|
type memo_key = default_memo_key | custom_memo_key
|
|
8
12
|
type memo_record = { value: untyped, expires_at: Float?, cached_at: Float }
|
|
9
13
|
|
|
14
|
+
@configuration: Configuration?
|
|
10
15
|
@__safe_memo_cache__: Hash[memo_key, memo_record]?
|
|
11
16
|
@__safe_memo_mutex__: Mutex?
|
|
12
17
|
@__safe_memo_shared_cache__: Hash[memo_key, memo_record]?
|
|
@@ -24,6 +29,9 @@ module SafeMemoize
|
|
|
24
29
|
attr_accessor default_max_size: Integer?
|
|
25
30
|
attr_accessor on_deprecation: (^(String message) -> void)?
|
|
26
31
|
attr_accessor on_hook_error: (^(Exception error, Symbol hook_type, untyped cache_key) -> void)?
|
|
32
|
+
attr_accessor active_support_notifications: bool
|
|
33
|
+
attr_accessor statsd_client: untyped
|
|
34
|
+
attr_accessor opentelemetry_tracer: untyped
|
|
27
35
|
|
|
28
36
|
def initialize: () -> void
|
|
29
37
|
end
|
|
@@ -52,15 +60,15 @@ module SafeMemoize
|
|
|
52
60
|
|
|
53
61
|
def memoized?: (Symbol | String method_name, *untyped args, **untyped kwargs) ?{ () -> untyped } -> bool
|
|
54
62
|
def memo_ttl_remaining: (Symbol | String method_name, *untyped args, **untyped kwargs) -> (Float | Integer | nil)
|
|
55
|
-
def memo_count: (
|
|
56
|
-
def memo_keys: (
|
|
57
|
-
def memo_values: (
|
|
63
|
+
def memo_count: (?(Symbol | String) method_name) -> Integer
|
|
64
|
+
def memo_keys: (?(Symbol | String) method_name) -> Array[untyped]
|
|
65
|
+
def memo_values: (?(Symbol | String) method_name) -> Array[untyped]
|
|
58
66
|
def on_memo_expire: { (memo_key cache_key, memo_record record) -> untyped } -> void
|
|
59
67
|
def on_memo_evict: { (memo_key cache_key, memo_record record) -> untyped } -> void
|
|
60
68
|
def on_memo_hit: { (memo_key cache_key, memo_record record) -> untyped } -> void
|
|
61
69
|
def on_memo_miss: { (memo_key cache_key, memo_record record) -> untyped } -> void
|
|
62
70
|
def on_memo_store: { (memo_key cache_key, memo_record record) -> untyped } -> void
|
|
63
|
-
def clear_memo_hooks: (Symbol
|
|
71
|
+
def clear_memo_hooks: (?Symbol hook_type) -> void
|
|
64
72
|
def warm_memo: (Symbol | String method_name, *untyped args, ?ttl: Numeric?, **untyped kwargs) { () -> untyped } -> untyped
|
|
65
73
|
def memo_preload: (Symbol | String method_name, *Array[untyped] arg_sets) -> Array[untyped]
|
|
66
74
|
def dump_memo: (?Symbol | String method_name) -> Hash[memo_key, untyped]
|
|
@@ -163,7 +171,7 @@ module SafeMemoize
|
|
|
163
171
|
|
|
164
172
|
module PublicCustomKeyMethods
|
|
165
173
|
def memoize_with_custom_key: (Symbol | String method_name) { (*untyped args, **untyped kwargs) -> untyped } -> void
|
|
166
|
-
def clear_custom_keys: (Symbol | String
|
|
174
|
+
def clear_custom_keys: (?(Symbol | String) method_name) -> void
|
|
167
175
|
end
|
|
168
176
|
|
|
169
177
|
module LruMethods
|
|
@@ -190,5 +198,33 @@ module SafeMemoize
|
|
|
190
198
|
include PublicCustomKeyMethods
|
|
191
199
|
include LruMethods
|
|
192
200
|
end
|
|
201
|
+
|
|
202
|
+
module Adapters
|
|
203
|
+
module StatsD
|
|
204
|
+
METRIC_NAMES: Hash[Symbol, String]
|
|
205
|
+
|
|
206
|
+
def self.dispatch: (untyped client, Symbol hook_type, memo_key cache_key, String? class_name) -> void
|
|
207
|
+
end
|
|
208
|
+
|
|
209
|
+
module OpenTelemetry
|
|
210
|
+
SPAN_NAME: String
|
|
211
|
+
def self.trace: (untyped tracer, Symbol | String method_name, String? class_name) { () -> untyped } -> untyped
|
|
212
|
+
end
|
|
213
|
+
end
|
|
214
|
+
|
|
215
|
+
module Rails
|
|
216
|
+
def self.track: (untyped instance) -> void
|
|
217
|
+
def self.reset_tracked!: () -> void
|
|
218
|
+
|
|
219
|
+
module RequestScoped
|
|
220
|
+
def self.included: (Module base) -> void
|
|
221
|
+
def reset_request_memos: () -> void
|
|
222
|
+
end
|
|
223
|
+
|
|
224
|
+
class Middleware
|
|
225
|
+
def initialize: (untyped app) -> void
|
|
226
|
+
def call: (untyped env) -> untyped
|
|
227
|
+
end
|
|
228
|
+
end
|
|
193
229
|
end
|
|
194
230
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: safe_memoize
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 1.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Chuck Smith
|
|
@@ -41,12 +41,19 @@ extra_rdoc_files: []
|
|
|
41
41
|
files:
|
|
42
42
|
- ".github/workflows/ci.yml"
|
|
43
43
|
- ".github/workflows/release.yml"
|
|
44
|
+
- ".yardopts"
|
|
44
45
|
- CHANGELOG.md
|
|
45
46
|
- LICENSE.txt
|
|
46
47
|
- README.md
|
|
47
48
|
- ROADMAP.md
|
|
48
49
|
- Rakefile
|
|
50
|
+
- UPGRADING.md
|
|
51
|
+
- benchmarks/README.md
|
|
52
|
+
- benchmarks/benchmark.rb
|
|
53
|
+
- codecov.yml
|
|
49
54
|
- lib/safe_memoize.rb
|
|
55
|
+
- lib/safe_memoize/adapters/opentelemetry.rb
|
|
56
|
+
- lib/safe_memoize/adapters/statsd.rb
|
|
50
57
|
- lib/safe_memoize/cache_metrics_methods.rb
|
|
51
58
|
- lib/safe_memoize/cache_record_methods.rb
|
|
52
59
|
- lib/safe_memoize/cache_store_methods.rb
|
|
@@ -60,8 +67,12 @@ files:
|
|
|
60
67
|
- lib/safe_memoize/public_custom_key_methods.rb
|
|
61
68
|
- lib/safe_memoize/public_methods.rb
|
|
62
69
|
- lib/safe_memoize/public_metrics_methods.rb
|
|
70
|
+
- lib/safe_memoize/rails.rb
|
|
71
|
+
- lib/safe_memoize/rails/middleware.rb
|
|
72
|
+
- lib/safe_memoize/rails/request_scoped.rb
|
|
63
73
|
- lib/safe_memoize/release_tooling.rb
|
|
64
74
|
- lib/safe_memoize/version.rb
|
|
75
|
+
- rbi/safe_memoize.rbi
|
|
65
76
|
- sig/safe_memoize.rbs
|
|
66
77
|
homepage: https://github.com/eclectic-coding/safe_memoize
|
|
67
78
|
licenses:
|