esse-redis_storage 0.1.1 → 0.1.2

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: ad734caa5a5772b8d7ba66bd2f40a031203b96edade5aa0547e5bf574c228094
4
- data.tar.gz: 4efb7b6b025a32e69819f12902e97abc0fac887aaee7cf34082b8e6bcc77b50f
3
+ metadata.gz: dbe607977885ccd2e85b297251b0b2412ecb0cd36658a812db840d575dfb3207
4
+ data.tar.gz: f02f2eb3d65897a7630b128ecd5150a3c4d9c247617158a85445aa44a0ee6b07
5
5
  SHA512:
6
- metadata.gz: 5e66697c37188316303ca3e9ce7466a3ae4a46255d33a75f6b4ed15c28b060cb7a3e1094b6bc2648238341becd6abb080175bcc0edf15d57e04b6fa8fcfd7ef6
7
- data.tar.gz: 2e0991b872d1c15f07fd76398c0d52c01a934efada5a6b26ba1e04cfb7ecc3e66eb4e6362e011cfb39d8a3a385131a0d031ac7faeff5de2a83f28ea2493944e8
6
+ metadata.gz: b26d864ec031ae339b177df8e3f2bf0e6ad3b7c9c08a6dc46b6ba085fbdd9f9e618d5351910a621d64ce6d9151a79b04a316c7958570ff447992aeb3fc61a397
7
+ data.tar.gz: 13404ce338c0603630713cf7f4429557a0580de4640509852924b6cb6a6291403247ad622c8c07e8e4cab28ffc19d53baadb1ae770dd86d79db98a2883caa82c
data/CHANGELOG.md CHANGED
@@ -4,6 +4,9 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## 0.1.2 - 2024-08-08
8
+ * Add `redis_queue_ttl` configuration option to the `Esse::Config` class.
9
+
7
10
  ## 0.1.1 - 2024-08-06
8
11
  * Add TTL to the enqueued items in the queue.
9
12
  * Included current time in the rand batch id to be more human readable.
data/Gemfile.lock CHANGED
@@ -10,7 +10,7 @@ GIT
10
10
  PATH
11
11
  remote: .
12
12
  specs:
13
- esse-redis_storage (0.1.1)
13
+ esse-redis_storage (0.1.2)
14
14
  esse (>= 0.3.2)
15
15
  multi_json (>= 1.0.0)
16
16
  redis (>= 4.0.0)
@@ -8,7 +8,7 @@ module Esse
8
8
  end
9
9
 
10
10
  module InstanceMethods
11
- attr_accessor :redis
11
+ attr_accessor :redis, :redis_queue_ttl
12
12
 
13
13
  def redis_pool
14
14
  @redis_pool ||= Esse::RedisStorage::Pool.new(redis)
@@ -31,6 +31,7 @@ module Esse
31
31
  def enqueue(id: nil, values: [], ttl: nil)
32
32
  return if values.nil? || values.empty?
33
33
 
34
+ ttl ||= Esse.config.redis_queue_ttl
34
35
  values = ::Esse::ArrayUtils.wrap(values)
35
36
  batch_id = id || self.class.batch_id
36
37
  with do |conn|
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Esse
4
4
  module RedisStorage
5
- VERSION = "0.1.1"
5
+ VERSION = "0.1.2"
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: esse-redis_storage
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marcos G. Zimmermann
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-08-06 00:00:00.000000000 Z
11
+ date: 2024-08-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: esse