omnes 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/test.yml +1 -1
- data/.rubocop.yml +2 -2
- data/CHANGELOG.md +8 -2
- data/README.md +3 -3
- data/lib/omnes/errors.rb +1 -1
- data/lib/omnes/version.rb +1 -1
- data/lib/omnes.rb +6 -1
- data/omnes.gemspec +2 -2
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4d69bcb6ece79550d662ea1ed7cf734cc47940a39d432c58c849f8c15415472a
|
4
|
+
data.tar.gz: 459ff5514f310cc52492bb2fabc6bf8786e3a9119f760288aeef6329b609b4d3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f395f3f775f8c44d54e17ad8502b0bf40c201edd861170242ac1ab29db90c2ace38273aceea5a257ed5e2910dcaca43370feec8e9563090847febe039ce99805
|
7
|
+
data.tar.gz: d2be4901c0fcc8bdd7bd8f1a1887c32445877300f1bf46f1396e7c16312c221f9c295fef1ee58756320a1be20c69f2a0e4dc4d0048451043998f51d89bb2c68c
|
data/.github/workflows/test.yml
CHANGED
data/.rubocop.yml
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
AllCops:
|
2
|
-
TargetRubyVersion: 2.
|
2
|
+
TargetRubyVersion: 2.5
|
3
3
|
NewCops: enable
|
4
4
|
SuggestExtensions: false
|
5
5
|
|
@@ -29,7 +29,7 @@ Layout/LineLength:
|
|
29
29
|
Max: 120
|
30
30
|
|
31
31
|
Naming/MethodName:
|
32
|
-
|
32
|
+
AllowedPatterns:
|
33
33
|
- '.*Type'
|
34
34
|
|
35
35
|
Lint/ConstantDefinitionInBlock:
|
data/CHANGELOG.md
CHANGED
@@ -4,7 +4,12 @@ All notable changes to this project will be documented in this file.
|
|
4
4
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
5
5
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
6
6
|
|
7
|
-
## Unreleased
|
7
|
+
## [Unreleased]
|
8
|
+
|
9
|
+
## [0.2.2] - 2022-05-03
|
10
|
+
|
11
|
+
### Added
|
12
|
+
- Support Ruby 2.5 & 2.6 [#6](https://github.com/nebulab/omnes/pull/6).
|
8
13
|
|
9
14
|
## [0.2.1] - 2022-04-19
|
10
15
|
|
@@ -23,7 +28,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
23
28
|
|
24
29
|
## [0.1.0] - 2022-03-23
|
25
30
|
|
26
|
-
[Unreleased]: https://github.com/nebulab/omnes/compare/v0.2.
|
31
|
+
[Unreleased]: https://github.com/nebulab/omnes/compare/v0.2.2...HEAD
|
32
|
+
[0.2.1]: https://github.com/nebulab/omnes/compare/v0.2.1...v0.2.2
|
27
33
|
[0.2.1]: https://github.com/nebulab/omnes/compare/v0.2.0...v0.2.1
|
28
34
|
[0.2.0]: https://github.com/nebulab/omnes/compare/v0.1.0...v0.2.0
|
29
35
|
[0.1.0]: https://github.com/nebulab/omnes/releases/tag/v0.1.0
|
data/README.md
CHANGED
@@ -162,7 +162,7 @@ class LogEventsSubscription
|
|
162
162
|
end
|
163
163
|
|
164
164
|
def call(event)
|
165
|
-
logger.info("Event #{event.
|
165
|
+
logger.info("Event #{event.omnes_event_name} published")
|
166
166
|
end
|
167
167
|
end
|
168
168
|
|
@@ -176,7 +176,7 @@ Custom event matchers can be defined. A matcher is something responding to
|
|
176
176
|
to match or ignore the event.
|
177
177
|
|
178
178
|
```ruby
|
179
|
-
ORDER_EVENTS_MATCHER = ->(event) { event.
|
179
|
+
ORDER_EVENTS_MATCHER = ->(event) { event.omnes_event_name.start_with?(:order) }
|
180
180
|
|
181
181
|
bus.subscribe_with_matcher(ORDER_EVENTS_MATCHER) do |event|
|
182
182
|
# ...
|
@@ -246,7 +246,7 @@ class LogEventsSubscriber
|
|
246
246
|
end
|
247
247
|
|
248
248
|
def log_event(event)
|
249
|
-
logger.info("Event #{event.
|
249
|
+
logger.info("Event #{event.omnes_event_name} published")
|
250
250
|
end
|
251
251
|
end
|
252
252
|
```
|
data/lib/omnes/errors.rb
CHANGED
data/lib/omnes/version.rb
CHANGED
data/lib/omnes.rb
CHANGED
@@ -44,7 +44,12 @@ module Omnes
|
|
44
44
|
klass.define_method(:omnes_bus) { @omnes_bus ||= Bus.new(cal_loc_start: 2) }
|
45
45
|
Bus.instance_methods(false).each do |method|
|
46
46
|
klass.define_method(method) do |*args, **kwargs, &block|
|
47
|
-
|
47
|
+
# TODO: Forward with ... once we deprecate ruby 2.5 & 2.6
|
48
|
+
if kwargs.any?
|
49
|
+
omnes_bus.send(method, *args, **kwargs, &block)
|
50
|
+
else
|
51
|
+
omnes_bus.send(method, *args, &block)
|
52
|
+
end
|
48
53
|
end
|
49
54
|
end
|
50
55
|
end
|
data/omnes.gemspec
CHANGED
@@ -17,7 +17,7 @@ Gem::Specification.new do |spec|
|
|
17
17
|
MSG
|
18
18
|
spec.homepage = "https://github.com/nebulab/omnes"
|
19
19
|
spec.license = "MIT"
|
20
|
-
spec.required_ruby_version = Gem::Requirement.new(">= 2.
|
20
|
+
spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0")
|
21
21
|
|
22
22
|
spec.metadata["allowed_push_host"] = "https://rubygems.org"
|
23
23
|
|
@@ -36,7 +36,7 @@ Gem::Specification.new do |spec|
|
|
36
36
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
37
37
|
spec.require_paths = ["lib"]
|
38
38
|
|
39
|
-
spec.add_development_dependency "activejob"
|
39
|
+
spec.add_development_dependency "activejob"
|
40
40
|
spec.add_development_dependency "redcarpet", "~> 3.5"
|
41
41
|
spec.add_development_dependency "sidekiq", "~> 6.4"
|
42
42
|
spec.add_development_dependency "yard", "~> 0.9"
|
metadata
CHANGED
@@ -1,29 +1,29 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omnes
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marc Busqué
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-05-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activejob
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '0'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - "
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '
|
26
|
+
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: redcarpet
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -130,7 +130,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
130
130
|
requirements:
|
131
131
|
- - ">="
|
132
132
|
- !ruby/object:Gem::Version
|
133
|
-
version: 2.
|
133
|
+
version: 2.5.0
|
134
134
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
135
135
|
requirements:
|
136
136
|
- - ">="
|