You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Merge branch 'main' into lb/resolve-pipelining-deprecation-warnings
* main:
Bump version for 1.2.0
Use pipeline for migration too
Ensure to pass the pipeline to super
Use block parameter to pipeline in Redis#multi (#68)
Note tested / supported versions of Redis in the Readme (#79)
Return counter value after incrementing/decrementing
Enum Bang setter (#82)
Add reset to Cycle after_change callbacks
Add example in Readme.md
Support configuring custom keys via method invocation
Use bundle add instead (#81)
kredis_enum :morning, values:%w[ bright blue black ], default:"bright"
174
177
kredis_counter :steps, expires_in:1.hour
178
+
179
+
private
180
+
defgenerate_names_key
181
+
"key-generated-from-private-method"
182
+
end
175
183
end
176
184
177
185
person =Person.find(5)
@@ -195,14 +203,17 @@ end
195
203
196
204
## Installation
197
205
198
-
1. Add the `kredis` gem to your Gemfile: `gem 'kredis'`
199
-
2. Run `./bin/bundle install`
200
-
3. Run `./bin/rails kredis:install` to add a default configuration at [`config/redis/shared.yml`](lib/install/shared.yml)
206
+
1. Run `./bin/bundle add kredis`
207
+
2. Run `./bin/rails kredis:install` to add a default configuration at [`config/redis/shared.yml`](lib/install/shared.yml)
201
208
202
209
Additional configurations can be added under `config/redis/*.yml` and referenced when a type is created. For example, `Kredis.string("mystring", config: :strings)` would lookup `config/redis/strings.yml`.
203
210
204
211
Kredis passes the configuration to `Redis.new` to establish the connection. See the [Redis documentation](https://github.com/redis/redis-rb) for other configuration options.
205
212
213
+
### Redis support
214
+
215
+
Kredis works with Redis server 4.0+, with the [Redis Ruby](https://github.com/redis/redis-rb) client version 4.2+.
216
+
206
217
### Setting SSL options on Redis Connections
207
218
208
219
If you need to connect to Redis with SSL, the recommended approach is to set your Redis instance manually by adding an entry to the `Kredis::Connections.connections` hash. Below an example showing how to connect to Redis using Client Authentication:
0 commit comments