evt-consumer-postgres 0.4.0.1 → 0.5.0.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/postgres/controls/consumer.rb +9 -3
- data/lib/consumer/postgres/postgres.rb +11 -8
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 60844427514a24b8c5c53ac8dea4e183443454ccbda024a5f44b0af8175531f5
|
4
|
+
data.tar.gz: 4259b520f7ba2f6d02bda3752178086caca48cc795a490a58402a26fe3d42b90
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 00e4a2ad356b11879796662ea0d1247476d528806099a75d5600fca79957d6b266c2ec8ce905b110ca303ecb7a39ba01e5713112582ce6e4700b57722aed1322
|
7
|
+
data.tar.gz: 6b7104ff34ee17baaf9a19c7d5f4999917de3843aca8e850a3a91a47b37ecd78950e00c462ad04a33221da3b4d8c8fcde2ca6b6f22f1c00fe5e44d6fd5fe9383
|
@@ -9,10 +9,16 @@ module Consumer
|
|
9
9
|
class Incrementing
|
10
10
|
include ::Consumer::Postgres
|
11
11
|
|
12
|
-
|
13
|
-
|
14
|
-
|
12
|
+
class Handler
|
13
|
+
include Messaging::Handle
|
14
|
+
include Log::Dependency
|
15
|
+
|
16
|
+
def handle(message_data)
|
17
|
+
logger.info { "Handled message (StreamName: #{message_data.stream_name}, GlobalPosition: #{message_data.global_position})" }
|
18
|
+
logger.debug { message_data.data.pretty_inspect }
|
19
|
+
end
|
15
20
|
end
|
21
|
+
handler Handler
|
16
22
|
end
|
17
23
|
|
18
24
|
class Identifier
|
@@ -6,21 +6,24 @@ module Consumer
|
|
6
6
|
end
|
7
7
|
end
|
8
8
|
|
9
|
-
def configure(batch_size: nil,
|
10
|
-
MessageStore::Postgres::
|
11
|
-
self,
|
12
|
-
batch_size: batch_size,
|
13
|
-
condition: condition,
|
14
|
-
session: session
|
15
|
-
)
|
9
|
+
def configure(batch_size: nil, settings: nil, condition: nil)
|
10
|
+
MessageStore::Postgres::Session.configure(self, settings: settings)
|
16
11
|
|
12
|
+
session = self.session
|
17
13
|
PositionStore.configure(
|
18
14
|
self,
|
19
15
|
stream_name,
|
20
|
-
position_store: position_store,
|
21
16
|
consumer_identifier: identifier,
|
22
17
|
session: session
|
23
18
|
)
|
19
|
+
|
20
|
+
get_session = MessageStore::Postgres::Session.build(settings: settings)
|
21
|
+
MessageStore::Postgres::Get.configure(
|
22
|
+
self,
|
23
|
+
batch_size: batch_size,
|
24
|
+
condition: condition,
|
25
|
+
session: get_session
|
26
|
+
)
|
24
27
|
end
|
25
28
|
end
|
26
29
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: evt-consumer-postgres
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- The Eventide Project
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-10-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: evt-consumer
|
@@ -93,7 +93,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
93
93
|
version: '0'
|
94
94
|
requirements: []
|
95
95
|
rubyforge_project:
|
96
|
-
rubygems_version: 2.7.
|
96
|
+
rubygems_version: 2.7.6
|
97
97
|
signing_key:
|
98
98
|
specification_version: 4
|
99
99
|
summary: Postgres implementation of continuous subscription to a stream and message
|