eventhub-processor2 1.18.0 → 1.20.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 +4 -4
- data/.github/dependabot.yml +2 -2
- data/.github/workflows/cd.yml +2 -2
- data/.github/workflows/ci.yml +3 -3
- data/.gitignore +1 -0
- data/.tool-versions +1 -1
- data/CHANGELOG.md +10 -0
- data/README.md +2 -1
- data/eventhub-processor2.gemspec +3 -2
- data/lib/eventhub/configuration.rb +7 -1
- data/lib/eventhub/logger.rb +7 -4
- data/lib/eventhub/message.rb +2 -2
- data/lib/eventhub/version.rb +1 -1
- metadata +21 -8
- data/Gemfile.lock +0 -99
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 81ac3772f42a5064c4adec4b688a3c67be1c77cdc687dad104fcd818da41fd22
|
4
|
+
data.tar.gz: 197ccdbe4e559c6f5111b4c085159a48af4bc741f4f3e0003d28e3b78bd30f61
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 230c1ae1e50dcead275b6394b0cd3817ad412dead817d0efd3337199444cdb8ed8f5648035f30b29cbd3c575f5aaa2281fbe3d2c8b050d6dded187713b8987d5
|
7
|
+
data.tar.gz: 7993add1980e3b8dc57be6eb9b86b0048fe43dd64abca332fbe048d7fe065bf07974ea8284cf9b04ac05db5932a9aea19da2bb72a04536cfc131b89f33242883
|
data/.github/dependabot.yml
CHANGED
@@ -5,7 +5,7 @@ updates:
|
|
5
5
|
schedule:
|
6
6
|
interval: "weekly"
|
7
7
|
day: "saturday"
|
8
|
-
time: "04:
|
8
|
+
time: "04:05"
|
9
9
|
timezone: "Europe/Zurich"
|
10
10
|
|
11
11
|
- package-ecosystem: "github-actions"
|
@@ -13,5 +13,5 @@ updates:
|
|
13
13
|
schedule:
|
14
14
|
interval: "weekly"
|
15
15
|
day: "saturday"
|
16
|
-
time: "04:
|
16
|
+
time: "04:05"
|
17
17
|
timezone: "Europe/Zurich"
|
data/.github/workflows/cd.yml
CHANGED
@@ -10,12 +10,12 @@ jobs:
|
|
10
10
|
|
11
11
|
steps:
|
12
12
|
- name: Checkout current code
|
13
|
-
uses: actions/checkout@
|
13
|
+
uses: actions/checkout@v4
|
14
14
|
|
15
15
|
- name: Set up Ruby
|
16
16
|
uses: ruby/setup-ruby@v1
|
17
17
|
with:
|
18
|
-
ruby-version: '3.
|
18
|
+
ruby-version: '3.3'
|
19
19
|
bundler-cache: true
|
20
20
|
cache-version: 1
|
21
21
|
|
data/.github/workflows/ci.yml
CHANGED
@@ -10,7 +10,7 @@ on:
|
|
10
10
|
- "*"
|
11
11
|
|
12
12
|
schedule:
|
13
|
-
- cron: 0 2 * *
|
13
|
+
- cron: 0 2 * * 3,6
|
14
14
|
|
15
15
|
# Allows you to run this workflow manually from the Actions tab
|
16
16
|
workflow_dispatch:
|
@@ -23,11 +23,11 @@ jobs:
|
|
23
23
|
strategy:
|
24
24
|
fail-fast: false
|
25
25
|
matrix:
|
26
|
-
ruby: [ '3.2', '3.1', '3.0', '2.7', '2.6']
|
26
|
+
ruby: [ '3.3', '3.2', '3.1', '3.0', '2.7', '2.6']
|
27
27
|
|
28
28
|
name: Ruby ${{ matrix.ruby }}
|
29
29
|
steps:
|
30
|
-
- uses: actions/checkout@
|
30
|
+
- uses: actions/checkout@v4
|
31
31
|
|
32
32
|
- name: Set up Ruby
|
33
33
|
uses: ruby/setup-ruby@v1
|
data/.gitignore
CHANGED
data/.tool-versions
CHANGED
@@ -1 +1 @@
|
|
1
|
-
ruby 3.
|
1
|
+
ruby 3.3.0
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,15 @@
|
|
1
1
|
# Changelog of EventHub::Processor2
|
2
2
|
|
3
|
+
## 1.20.0 / 2023-12-28
|
4
|
+
|
5
|
+
* Update dependencies
|
6
|
+
* Support Ruby 3.3.0
|
7
|
+
* Have a console log only option
|
8
|
+
|
9
|
+
## 1.19.0 / 2023-04-23
|
10
|
+
|
11
|
+
* Update dependencies
|
12
|
+
|
3
13
|
## 1.18.0 / 2023-01-30
|
4
14
|
|
5
15
|
* Update dependencies
|
data/README.md
CHANGED
@@ -19,6 +19,7 @@ Processor2 is using Bunny http://rubybunny.info a feature complete RabbitMQ Clie
|
|
19
19
|
|
20
20
|
Currently supported and tested ruby versions are:
|
21
21
|
|
22
|
+
- 3.3
|
22
23
|
- 3.2
|
23
24
|
- 3.1
|
24
25
|
- 3.0
|
@@ -101,7 +102,7 @@ Usage: example [options]
|
|
101
102
|
-e, --environment ENVIRONMENT Define environment (default development)
|
102
103
|
-d, --detached Run processor detached as a daemon
|
103
104
|
-c, --config CONFIG Define configuration file
|
104
|
-
|
105
|
+
--console-log-only Logs to console only (E.g. containers)
|
105
106
|
|
106
107
|
bundle exec ruby example.rb
|
107
108
|
I, [2018-02-09T15:22:35.649646 #37966] INFO -- : example (1.1.0): has been started
|
data/eventhub-processor2.gemspec
CHANGED
@@ -26,10 +26,11 @@ Gem::Specification.new do |spec|
|
|
26
26
|
spec.add_dependency "bunny", "~> 2.20"
|
27
27
|
spec.add_dependency "eventhub-components", "~> 0.2"
|
28
28
|
spec.add_dependency "uuidtools", "~> 2.1"
|
29
|
+
spec.add_dependency "base64", "~> 0.2.0"
|
29
30
|
|
30
31
|
spec.add_development_dependency "bundler", "~> 2.3"
|
31
32
|
spec.add_development_dependency "rake", "~> 13.0"
|
32
|
-
spec.add_development_dependency "rspec", "~> 3.
|
33
|
+
spec.add_development_dependency "rspec", "~> 3.12"
|
33
34
|
spec.add_development_dependency "simplecov", "~> 0.21"
|
34
|
-
spec.add_development_dependency "standard", "~> 1.
|
35
|
+
spec.add_development_dependency "standard", "~> 1.28"
|
35
36
|
end
|
@@ -10,6 +10,7 @@ module EventHub
|
|
10
10
|
attr_reader :environment # environment the processor is running
|
11
11
|
attr_reader :detached # run processor run as a daemon
|
12
12
|
attr_reader :config_file # name of configuration file
|
13
|
+
attr_reader :console_log_only # only log to console
|
13
14
|
attr_reader :config_data # data from configuration file
|
14
15
|
|
15
16
|
@name = "undefined"
|
@@ -29,6 +30,7 @@ module EventHub
|
|
29
30
|
@detached = false
|
30
31
|
@config_file = File.join(Dir.getwd, "config", "#{@name}.json")
|
31
32
|
@config_data = {}
|
33
|
+
@console_log_only = false
|
32
34
|
end
|
33
35
|
|
34
36
|
# parse options from argument list
|
@@ -45,6 +47,10 @@ module EventHub
|
|
45
47
|
@detached = true
|
46
48
|
end
|
47
49
|
|
50
|
+
opts.on(nil, "--console-log-only", "Only log to console (containers)") do
|
51
|
+
@console_log_only = true
|
52
|
+
end
|
53
|
+
|
48
54
|
note = "Define configuration file"
|
49
55
|
opts.on("-c", "--config CONFIG", note) do |config|
|
50
56
|
@config_file = config
|
@@ -83,7 +89,7 @@ module EventHub
|
|
83
89
|
def load_more!(args = {})
|
84
90
|
return unless args[:pattern]
|
85
91
|
|
86
|
-
Dir.glob(args[:pattern]).each do |name|
|
92
|
+
Dir.glob(args[:pattern]).sort.each do |name|
|
87
93
|
next if File.directory?(name)
|
88
94
|
|
89
95
|
begin
|
data/lib/eventhub/logger.rb
CHANGED
@@ -4,10 +4,13 @@ module EventHub
|
|
4
4
|
unless defined?(@logger)
|
5
5
|
@logger = ::EventHub::Components::MultiLogger.new
|
6
6
|
@logger.add_device(Logger.new($stdout))
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
7
|
+
|
8
|
+
unless Configuration.console_log_only
|
9
|
+
@logger.add_device(
|
10
|
+
EventHub::Components::Logger.logstash(Configuration.name,
|
11
|
+
Configuration.environment)
|
12
|
+
)
|
13
|
+
end
|
11
14
|
end
|
12
15
|
@logger
|
13
16
|
end
|
data/lib/eventhub/message.rb
CHANGED
@@ -32,7 +32,7 @@ module EventHub
|
|
32
32
|
self.header.get(header)
|
33
33
|
end
|
34
34
|
|
35
|
-
define_method("#{name}=") do |value|
|
35
|
+
define_method(:"#{name}=") do |value|
|
36
36
|
self.header.set(header, value)
|
37
37
|
end
|
38
38
|
end
|
@@ -145,7 +145,7 @@ module EventHub
|
|
145
145
|
end
|
146
146
|
|
147
147
|
def append_to_execution_history(processor_name)
|
148
|
-
header.set("execution_history", []) unless
|
148
|
+
header.set("execution_history", []) unless
|
149
149
|
header.get("execution_history")
|
150
150
|
header.get("execution_history") << \
|
151
151
|
{"processor" => processor_name, "timestamp" => now_stamp}
|
data/lib/eventhub/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: eventhub-processor2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.20.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Steiner, Thomas
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-12-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: celluloid
|
@@ -66,6 +66,20 @@ dependencies:
|
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '2.1'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: base64
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 0.2.0
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 0.2.0
|
69
83
|
- !ruby/object:Gem::Dependency
|
70
84
|
name: bundler
|
71
85
|
requirement: !ruby/object:Gem::Requirement
|
@@ -100,14 +114,14 @@ dependencies:
|
|
100
114
|
requirements:
|
101
115
|
- - "~>"
|
102
116
|
- !ruby/object:Gem::Version
|
103
|
-
version: '3.
|
117
|
+
version: '3.12'
|
104
118
|
type: :development
|
105
119
|
prerelease: false
|
106
120
|
version_requirements: !ruby/object:Gem::Requirement
|
107
121
|
requirements:
|
108
122
|
- - "~>"
|
109
123
|
- !ruby/object:Gem::Version
|
110
|
-
version: '3.
|
124
|
+
version: '3.12'
|
111
125
|
- !ruby/object:Gem::Dependency
|
112
126
|
name: simplecov
|
113
127
|
requirement: !ruby/object:Gem::Requirement
|
@@ -128,14 +142,14 @@ dependencies:
|
|
128
142
|
requirements:
|
129
143
|
- - "~>"
|
130
144
|
- !ruby/object:Gem::Version
|
131
|
-
version: '1.
|
145
|
+
version: '1.28'
|
132
146
|
type: :development
|
133
147
|
prerelease: false
|
134
148
|
version_requirements: !ruby/object:Gem::Requirement
|
135
149
|
requirements:
|
136
150
|
- - "~>"
|
137
151
|
- !ruby/object:Gem::Version
|
138
|
-
version: '1.
|
152
|
+
version: '1.28'
|
139
153
|
description: Next generation gem to build ruby based eventhub processor
|
140
154
|
email:
|
141
155
|
- thomas.steiner@ikey.ch
|
@@ -151,7 +165,6 @@ files:
|
|
151
165
|
- ".tool-versions"
|
152
166
|
- CHANGELOG.md
|
153
167
|
- Gemfile
|
154
|
-
- Gemfile.lock
|
155
168
|
- LICENSE.txt
|
156
169
|
- README.md
|
157
170
|
- Rakefile
|
@@ -207,7 +220,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
207
220
|
- !ruby/object:Gem::Version
|
208
221
|
version: '0'
|
209
222
|
requirements: []
|
210
|
-
rubygems_version: 3.3
|
223
|
+
rubygems_version: 3.5.3
|
211
224
|
signing_key:
|
212
225
|
specification_version: 4
|
213
226
|
summary: Next generation gem to build ruby based eventhub processor
|
data/Gemfile.lock
DELETED
@@ -1,99 +0,0 @@
|
|
1
|
-
PATH
|
2
|
-
remote: .
|
3
|
-
specs:
|
4
|
-
eventhub-processor2 (1.18.0)
|
5
|
-
bunny (~> 2.20)
|
6
|
-
celluloid (~> 0.18)
|
7
|
-
eventhub-components (~> 0.2)
|
8
|
-
uuidtools (~> 2.1)
|
9
|
-
|
10
|
-
GEM
|
11
|
-
remote: https://rubygems.org/
|
12
|
-
specs:
|
13
|
-
amq-protocol (2.3.2)
|
14
|
-
ast (2.4.2)
|
15
|
-
bunny (2.20.3)
|
16
|
-
amq-protocol (~> 2.3, >= 2.3.1)
|
17
|
-
sorted_set (~> 1, >= 1.0.2)
|
18
|
-
celluloid (0.18.0)
|
19
|
-
timers (~> 4)
|
20
|
-
diff-lcs (1.5.0)
|
21
|
-
docile (1.4.0)
|
22
|
-
eventhub-components (0.3.1)
|
23
|
-
logstash-logger (~> 0.26)
|
24
|
-
json (2.6.3)
|
25
|
-
language_server-protocol (3.17.0.2)
|
26
|
-
logstash-event (1.2.02)
|
27
|
-
logstash-logger (0.26.1)
|
28
|
-
logstash-event (~> 1.2)
|
29
|
-
parallel (1.22.1)
|
30
|
-
parser (3.2.0.0)
|
31
|
-
ast (~> 2.4.1)
|
32
|
-
rainbow (3.1.1)
|
33
|
-
rake (13.0.6)
|
34
|
-
rbtree (0.4.6)
|
35
|
-
regexp_parser (2.6.2)
|
36
|
-
rexml (3.2.5)
|
37
|
-
rspec (3.12.0)
|
38
|
-
rspec-core (~> 3.12.0)
|
39
|
-
rspec-expectations (~> 3.12.0)
|
40
|
-
rspec-mocks (~> 3.12.0)
|
41
|
-
rspec-core (3.12.0)
|
42
|
-
rspec-support (~> 3.12.0)
|
43
|
-
rspec-expectations (3.12.2)
|
44
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
45
|
-
rspec-support (~> 3.12.0)
|
46
|
-
rspec-mocks (3.12.3)
|
47
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
48
|
-
rspec-support (~> 3.12.0)
|
49
|
-
rspec-support (3.12.0)
|
50
|
-
rubocop (1.42.0)
|
51
|
-
json (~> 2.3)
|
52
|
-
parallel (~> 1.10)
|
53
|
-
parser (>= 3.1.2.1)
|
54
|
-
rainbow (>= 2.2.2, < 4.0)
|
55
|
-
regexp_parser (>= 1.8, < 3.0)
|
56
|
-
rexml (>= 3.2.5, < 4.0)
|
57
|
-
rubocop-ast (>= 1.24.1, < 2.0)
|
58
|
-
ruby-progressbar (~> 1.7)
|
59
|
-
unicode-display_width (>= 1.4.0, < 3.0)
|
60
|
-
rubocop-ast (1.24.1)
|
61
|
-
parser (>= 3.1.1.0)
|
62
|
-
rubocop-performance (1.15.2)
|
63
|
-
rubocop (>= 1.7.0, < 2.0)
|
64
|
-
rubocop-ast (>= 0.4.0)
|
65
|
-
ruby-progressbar (1.11.0)
|
66
|
-
set (1.0.3)
|
67
|
-
simplecov (0.22.0)
|
68
|
-
docile (~> 1.1)
|
69
|
-
simplecov-html (~> 0.11)
|
70
|
-
simplecov_json_formatter (~> 0.1)
|
71
|
-
simplecov-html (0.12.3)
|
72
|
-
simplecov_json_formatter (0.1.4)
|
73
|
-
sorted_set (1.0.3)
|
74
|
-
rbtree
|
75
|
-
set (~> 1.0)
|
76
|
-
standard (1.22.1)
|
77
|
-
language_server-protocol (~> 3.17.0.2)
|
78
|
-
rubocop (= 1.42.0)
|
79
|
-
rubocop-performance (= 1.15.2)
|
80
|
-
timers (4.3.5)
|
81
|
-
unicode-display_width (2.4.2)
|
82
|
-
uuidtools (2.2.0)
|
83
|
-
|
84
|
-
PLATFORMS
|
85
|
-
arm64-darwin-21
|
86
|
-
ruby
|
87
|
-
x86_64-darwin-18
|
88
|
-
x86_64-linux
|
89
|
-
|
90
|
-
DEPENDENCIES
|
91
|
-
bundler (~> 2.3)
|
92
|
-
eventhub-processor2!
|
93
|
-
rake (~> 13.0)
|
94
|
-
rspec (~> 3.11)
|
95
|
-
simplecov (~> 0.21)
|
96
|
-
standard (~> 1.20)
|
97
|
-
|
98
|
-
BUNDLED WITH
|
99
|
-
2.3.26
|