message_bus_client_worker 1.1.1 → 1.2.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0c751fde3915093c67772d2c32d1677f823477b6c52bd63a5b5c708bc29c26c9
4
- data.tar.gz: 4c1c9be014e9854fc82a8b16cceb6cdb7c983179bf9c458b88715f339b374dc3
3
+ metadata.gz: 0e11858a4762c2a446881b531dc10c0f5d74490a01b61697a3fe9100bf399553
4
+ data.tar.gz: 364a0bbdcc1f7a3906ac4a3d2343ab16b7c518afe8fde6a408b6b0b4651f2f73
5
5
  SHA512:
6
- metadata.gz: 24cb0a4ff8c18e1189e465c6c793cb383e41a97cf935832db61ae5f682329efeba70c63e44ac9c92db3778834aaac187b3cf9ddc95ffcb6e1ddf08b2c1f32985
7
- data.tar.gz: 5684faff9b328389beb6700a7eabe448cee8ded1b69f20bfa44e07cd1cd0ebaef8756724e6bed23bd688c3af8d96fd9b3e05b6ffd98c39300d75214ed9d0d6e2
6
+ metadata.gz: 511394ec3c064c50e616625b2ba1baf0b7b05bf047eb75b66110ef9e5132ebb398bffa0cf7f34a308965dca583cd8e2e9bc0fc78db99a8a7df94801337b3928f
7
+ data.tar.gz: 65c0a9f3eec5b469fec84450fac71db37d011d261b06ba934bb1ddcc8013579a485d6f5bb801eae6ed43889fb91035117e3813999d16e8186af95f95ffed67a0
data/CHANGELOG.md CHANGED
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
4
4
  The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
5
5
  and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [1.2.0] - 2018-02-24
8
+ ### Added
9
+ - Add ability to customise client_id
10
+
7
11
  ## [1.1.1] - 2018-02-18
8
12
  ### Fixed
9
13
  - Log channels correctly when `SubscriptionWorker` is performed.
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- message_bus_client_worker (1.1.1)
4
+ message_bus_client_worker (1.2.0)
5
5
  activesupport
6
6
  addressable
7
7
  excon
@@ -4,6 +4,7 @@ require "gem_config"
4
4
  require "light-service"
5
5
  require "securerandom"
6
6
  require "sidekiq"
7
+ require "securerandom"
7
8
  require "active_support/core_ext/hash/indifferent_access"
8
9
  require "active_support/core_ext/string/inflections"
9
10
  require "message_bus_client_worker/version"
@@ -25,6 +26,7 @@ module MessageBusClientWorker
25
26
 
26
27
  with_configuration do
27
28
  has :subscriptions, classes: Hash
29
+ has :client_id, classes: [Proc, String], default: -> {SecureRandom.uuid}
28
30
  end
29
31
 
30
32
  end
@@ -6,7 +6,8 @@ module MessageBusClientWorker
6
6
  promises :client_id
7
7
 
8
8
  executed do |c|
9
- c.client_id = SecureRandom.uuid
9
+ c.client_id = client_id = MessageBusClientWorker.configuration.client_id
10
+ c.client_id = client_id.() if client_id.respond_to?(:call)
10
11
  end
11
12
  end
12
13
  end
@@ -1,3 +1,3 @@
1
1
  module MessageBusClientWorker
2
- VERSION = "1.1.1"
2
+ VERSION = "1.2.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: message_bus_client_worker
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ramon Tayag
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-02-19 00:00:00.000000000 Z
11
+ date: 2019-02-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gem_config
@@ -221,7 +221,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
221
221
  version: '0'
222
222
  requirements: []
223
223
  rubyforge_project:
224
- rubygems_version: 2.7.7
224
+ rubygems_version: 2.7.8
225
225
  signing_key:
226
226
  specification_version: 4
227
227
  summary: Subscribe to MessageBus using Sidekiq workers