evt-consumer 2.3.0.0 → 2.3.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/consumer/consumer.rb +13 -3
- data/lib/consumer/controls.rb +3 -1
- data/lib/consumer/controls/consumer.rb +8 -0
- data/lib/consumer/controls/handle/settings.rb +7 -0
- data/lib/consumer/controls/settings.rb +13 -0
- data/lib/consumer/position_store/substitute.rb +2 -0
- data/lib/consumer/postgres +1 -0
- data/lib/consumer/postgres.rb +1 -0
- metadata +9 -6
- data/lib/consumer/controls/stream_name.rb +0 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cf9c47da47df09523d2007d47a2bd92aa8463924f327261c0e5a1215efb16a81
|
4
|
+
data.tar.gz: 3ce5caed62500286a552af1940b6892e45c2c60ac235acb11bea52ab0ccbd79e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f3e8b9b68405943aec82c4d2ebc5d6de35419fd8715bee00fab9476e833ec2521e18f3f208c14f3d81dd4038faf255c66b21a1ed8f7f717dd9b0e5c0bc2cdd2d
|
7
|
+
data.tar.gz: cde3e28a744e3eefde6367eb7f4425d2faacff56b7b65ccd237d0144079a5b8de1c4b554a7e763e091a38dacb1f0e2c554735add6fa602b135ecefa76f793a90
|
data/lib/consumer/consumer.rb
CHANGED
@@ -37,6 +37,8 @@ module Consumer
|
|
37
37
|
|
38
38
|
attr_accessor :session
|
39
39
|
|
40
|
+
attr_accessor :supplemental_settings
|
41
|
+
|
40
42
|
dependency :get, MessageStore::Get
|
41
43
|
dependency :position_store, PositionStore
|
42
44
|
dependency :subscription, Subscription
|
@@ -119,7 +121,7 @@ module Consumer
|
|
119
121
|
logger.trace(tags: [:consumer, :dispatch, :message]) { "Dispatching message (#{LogText.message_data(message_data)})" }
|
120
122
|
|
121
123
|
self.class.handler_registry.each do |handler|
|
122
|
-
handler.(message_data, session: session)
|
124
|
+
handler.(message_data, session: session, settings: supplemental_settings)
|
123
125
|
end
|
124
126
|
|
125
127
|
update_position(message_data.global_position)
|
@@ -172,13 +174,21 @@ module Consumer
|
|
172
174
|
end
|
173
175
|
|
174
176
|
module Build
|
175
|
-
def build(category, position_update_interval: nil, poll_interval_milliseconds: nil, identifier: nil, **arguments)
|
177
|
+
def build(category, position_update_interval: nil, poll_interval_milliseconds: nil, identifier: nil, supplemental_settings: nil, **arguments)
|
176
178
|
instance = new(category)
|
177
179
|
|
178
|
-
|
180
|
+
if not identifier.nil?
|
179
181
|
instance.identifier = identifier
|
180
182
|
end
|
181
183
|
|
184
|
+
if not supplemental_settings.nil?
|
185
|
+
if not supplemental_settings.is_a?(::Settings)
|
186
|
+
supplemental_settings = ::Settings.build(supplemental_settings)
|
187
|
+
end
|
188
|
+
|
189
|
+
instance.supplemental_settings = supplemental_settings
|
190
|
+
end
|
191
|
+
|
182
192
|
instance.position_update_interval = position_update_interval
|
183
193
|
instance.poll_interval_milliseconds = poll_interval_milliseconds
|
184
194
|
|
data/lib/consumer/controls.rb
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
require 'settings/controls'
|
1
2
|
require 'messaging/controls'
|
2
3
|
|
3
4
|
require 'consumer/controls/category'
|
@@ -11,7 +12,7 @@ require 'consumer/controls/id'
|
|
11
12
|
require 'consumer/controls/identifier'
|
12
13
|
require 'consumer/controls/position'
|
13
14
|
require 'consumer/controls/session'
|
14
|
-
require 'consumer/controls/
|
15
|
+
require 'consumer/controls/settings'
|
15
16
|
|
16
17
|
require 'consumer/controls/position_store'
|
17
18
|
require 'consumer/controls/position_store/file'
|
@@ -19,6 +20,7 @@ require 'consumer/controls/subscription'
|
|
19
20
|
|
20
21
|
require 'consumer/controls/handle'
|
21
22
|
require 'consumer/controls/handle/raise_error'
|
23
|
+
require 'consumer/controls/handle/settings'
|
22
24
|
|
23
25
|
require 'consumer/controls/actor'
|
24
26
|
|
@@ -0,0 +1 @@
|
|
1
|
+
lib/consumer/Users/sbellware/projects/eventide/consumer-postgres/lib/consumer/postgres
|
@@ -0,0 +1 @@
|
|
1
|
+
lib/consumer/Users/sbellware/projects/eventide/consumer-postgres/lib/consumer/postgres.rb
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: evt-consumer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.3.
|
4
|
+
version: 2.3.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- The Eventide Project
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-12-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ntl-actor
|
@@ -114,6 +114,7 @@ files:
|
|
114
114
|
- lib/consumer/controls/get/incrementing.rb
|
115
115
|
- lib/consumer/controls/handle.rb
|
116
116
|
- lib/consumer/controls/handle/raise_error.rb
|
117
|
+
- lib/consumer/controls/handle/settings.rb
|
117
118
|
- lib/consumer/controls/id.rb
|
118
119
|
- lib/consumer/controls/identifier.rb
|
119
120
|
- lib/consumer/controls/message_data.rb
|
@@ -123,7 +124,7 @@ files:
|
|
123
124
|
- lib/consumer/controls/position_store.rb
|
124
125
|
- lib/consumer/controls/position_store/file.rb
|
125
126
|
- lib/consumer/controls/session.rb
|
126
|
-
- lib/consumer/controls/
|
127
|
+
- lib/consumer/controls/settings.rb
|
127
128
|
- lib/consumer/controls/subscription.rb
|
128
129
|
- lib/consumer/defaults.rb
|
129
130
|
- lib/consumer/handler_registry.rb
|
@@ -132,6 +133,8 @@ files:
|
|
132
133
|
- lib/consumer/position_store.rb
|
133
134
|
- lib/consumer/position_store/substitute.rb
|
134
135
|
- lib/consumer/position_store/telemetry.rb
|
136
|
+
- lib/consumer/postgres
|
137
|
+
- lib/consumer/postgres.rb
|
135
138
|
- lib/consumer/subscription.rb
|
136
139
|
- lib/consumer/subscription/defaults.rb
|
137
140
|
- lib/consumer/subscription/get_batch.rb
|
@@ -140,7 +143,7 @@ homepage: https://github.com/eventide-project/consumer
|
|
140
143
|
licenses:
|
141
144
|
- MIT
|
142
145
|
metadata: {}
|
143
|
-
post_install_message:
|
146
|
+
post_install_message:
|
144
147
|
rdoc_options: []
|
145
148
|
require_paths:
|
146
149
|
- lib
|
@@ -156,7 +159,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
156
159
|
version: '0'
|
157
160
|
requirements: []
|
158
161
|
rubygems_version: 3.1.2
|
159
|
-
signing_key:
|
162
|
+
signing_key:
|
160
163
|
specification_version: 4
|
161
164
|
summary: Continuous subscription to a category and message dispatching to handlers
|
162
165
|
test_files: []
|