cotton-tail 0.7.0 → 0.8.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: 59a0b8fe6472fc78f13f5347a249a85118ec1df3e1274b13e31a32f79aafd290
4
- data.tar.gz: 7db834f63293c4bb811dbff278a2dec964e1b55317476e2b2819852bafc9217b
3
+ metadata.gz: 6a1f8fb4fc5ac2144c02ee4083860ca0860c21a239a32adc946f0d437ea394e4
4
+ data.tar.gz: 3b9d84ae8362a8f750a833077de1d6ad790029c9d66984fd8c9ef6397264c83e
5
5
  SHA512:
6
- metadata.gz: 44fe3a5e0a10a005dc7ded35338770324d1f487cc411d61975023b05a30bdbbeae5a6c759195cf577c5d055b2a5d395b2067088aea4abdc120d25980bab7be94
7
- data.tar.gz: 5fca20076db46c78e1c49b40da3725e8f5863d3c1165845699bb1f6167cd1fd0c86658ce567e26fcf1010868cc5c9054a71c90019a4a5927e783440cd3c2e7ff
6
+ metadata.gz: 95676e70821e9d51227ae1c0bf8b54a8ffd007ab9e68edf1951744af38200fb7cb9a62758675dd3a5535c806b81dcceef2806f0707d7f116ccc3396ed85605b3
7
+ data.tar.gz: 3af050689c858d654f8778e63594d4c910acd83105c9506d5ce4a2811bd5a1a81f1c64376acbb683993c88fb825f7f4f8cd27e67db1ef4cbf3a7b2140372b82e
checksums.yaml.gz.sig CHANGED
Binary file
data/.circleci/config.yml CHANGED
@@ -2,8 +2,8 @@ version: 2
2
2
  jobs:
3
3
  build:
4
4
  docker:
5
- - image: circleci/ruby:2.5.1-node-browsers
6
- - image: rabbitmq:3.7-management
5
+ - image: cimg/ruby:3.3-node
6
+ - image: rabbitmq:3.7-management
7
7
 
8
8
  working_directory: ~/repo
9
9
 
@@ -22,8 +22,8 @@ jobs:
22
22
 
23
23
  - restore_cache:
24
24
  keys:
25
- - v1-dependencies-{{ checksum "Gemfile.lock" }}
26
- - v1-dependencies-
25
+ - v1-dependencies-{{ checksum "Gemfile.lock" }}
26
+ - v1-dependencies-
27
27
 
28
28
  - run:
29
29
  name: install dependencies
@@ -68,4 +68,4 @@ jobs:
68
68
  path: /tmp/test-results
69
69
  - store_artifacts:
70
70
  path: /tmp/test-results
71
- destination: test-results
71
+ destination: test-results
data/.rubocop.yml CHANGED
@@ -1,11 +1,16 @@
1
- Metrics/LineLength:
1
+ AllCops:
2
+ NewCops: enable
3
+ TargetRubyVersion: 3.0.0
4
+
5
+ plugins:
6
+ - rubocop-rake
7
+ - rubocop-rspec
8
+
9
+ Layout/LineLength:
2
10
  Max: 120
3
11
  Exclude:
4
12
  - 'lib/tasks/**/*'
5
13
 
6
- Metrics/MethodLength:
7
- Max: 20
8
-
9
14
  Metrics/BlockLength:
10
15
  Exclude:
11
16
  - 'spec/**/*'
@@ -13,12 +18,53 @@ Metrics/BlockLength:
13
18
  - '*.gemspec'
14
19
  - 'examples/app.rb'
15
20
 
16
- Style/Documentation:
21
+ Metrics/MethodLength:
22
+ Max: 20
23
+
24
+ Metrics/ModuleLength:
17
25
  Exclude:
18
26
  - 'spec/**/*'
19
27
  - 'integration/**/*'
20
28
 
21
- Metrics/ModuleLength:
29
+ Style/Documentation:
22
30
  Exclude:
23
31
  - 'spec/**/*'
24
32
  - 'integration/**/*'
33
+
34
+ Style/OptionalBooleanParameter:
35
+ Enabled: false
36
+
37
+ Style/SelectByRegexp:
38
+ Exclude:
39
+ - lib/cotton_tail/middleware/router.rb
40
+
41
+ Gemspec/DevelopmentDependencies:
42
+ Enabled: true
43
+ EnforcedStyle: gemspec
44
+
45
+ RSpec/ExampleLength:
46
+ Max: 10
47
+ Exclude:
48
+ - 'spec/integration/cotton_tail/app_spec.rb'
49
+ - 'spec/integration/dsl_integration_spec.rb'
50
+
51
+ RSpec/MultipleExpectations:
52
+ Enabled: false
53
+
54
+ RSpec/VerifiedDoubles:
55
+ Exclude:
56
+ - 'spec/integration/cotton_tail/app_spec.rb'
57
+
58
+ RSpec/MultipleMemoizedHelpers:
59
+ Enabled: false
60
+
61
+ RSpec/ContextWording:
62
+ Prefixes:
63
+ - 'given'
64
+ - 'when'
65
+ - 'with'
66
+ - 'without'
67
+ - 'and'
68
+
69
+ RSpec/NestedGroups:
70
+ Max: 4
data/.ruby-gemset ADDED
@@ -0,0 +1 @@
1
+ cotton
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 2.6.0@cotton
1
+ 3.3.1
data/Dockerfile CHANGED
@@ -1,7 +1,7 @@
1
1
  FROM ruby:alpine
2
2
 
3
3
  # Use most recent versions of available packages
4
- RUN sed -i -e 's/v[[:digit:]]\.[[:digit:]]/edge/g' /etc/apk/repositories
4
+ RUN sed -i -e 's/v[0-9]\+\.[0-9]\+/edge/g' /etc/apk/repositories
5
5
 
6
6
  RUN apk update && apk add git yarn build-base
7
7
 
@@ -13,7 +13,7 @@ COPY Gemfile* ./
13
13
  COPY cotton-tail.gemspec ./
14
14
  COPY ./lib/cotton_tail/version.rb ./lib/cotton_tail/
15
15
 
16
- RUN bundle install
16
+ RUN bundle install --without development
17
17
 
18
18
  # copy the contents to working directory
19
19
  COPY . /usr/src/cotton_tail
data/Gemfile.lock CHANGED
@@ -1,93 +1,127 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- cotton-tail (0.7.0)
5
- bunny (~> 2.12)
6
- ibsciss-middleware (~> 0.4.2)
4
+ cotton-tail (0.8.0)
5
+ bunny (~> 2.24)
6
+ ibsciss-middleware (~> 0.4.3)
7
7
 
8
8
  GEM
9
9
  remote: https://rubygems.org/
10
10
  specs:
11
- amq-protocol (2.3.0)
12
- ast (2.4.0)
13
- benchmark-perf (0.4.0)
14
- benchmark-trend (0.2.0)
15
- bunny (2.13.0)
16
- amq-protocol (~> 2.3, >= 2.3.0)
17
- debase (0.2.3.beta5)
18
- debase-ruby_core_source (>= 0.10.2)
19
- debase-ruby_core_source (0.10.4)
20
- diff-lcs (1.3)
21
- faraday (0.13.1)
22
- multipart-post (>= 1.2, < 3)
23
- faraday_middleware (0.12.2)
24
- faraday (>= 0.7.4, < 1.0)
25
- hashie (3.6.0)
26
- ibsciss-middleware (0.4.2)
27
- jaro_winkler (1.5.1)
28
- multi_json (1.13.1)
29
- multipart-post (2.0.0)
30
- parallel (1.12.1)
31
- parser (2.5.3.0)
32
- ast (~> 2.4.0)
33
- powerpack (0.1.2)
34
- rabbitmq_http_api_client (1.11.0)
35
- faraday (~> 0.13.0)
36
- faraday_middleware (~> 0.12.0)
37
- hashie (~> 3.5)
38
- multi_json (~> 1.12)
39
- rainbow (3.0.0)
40
- rake (12.3.2)
41
- rspec (3.8.0)
42
- rspec-core (~> 3.8.0)
43
- rspec-expectations (~> 3.8.0)
44
- rspec-mocks (~> 3.8.0)
45
- rspec-benchmark (0.4.0)
46
- benchmark-perf (~> 0.4.0)
47
- benchmark-trend (~> 0.2.0)
48
- rspec (>= 3.0.0, < 4.0.0)
49
- rspec-core (3.8.0)
50
- rspec-support (~> 3.8.0)
51
- rspec-expectations (3.8.2)
11
+ addressable (2.8.7)
12
+ public_suffix (>= 2.0.2, < 7.0)
13
+ amq-protocol (2.3.4)
14
+ ast (2.4.3)
15
+ benchmark-malloc (0.2.0)
16
+ benchmark-perf (0.6.0)
17
+ benchmark-trend (0.4.0)
18
+ bunny (2.24.0)
19
+ amq-protocol (~> 2.3)
20
+ sorted_set (~> 1, >= 1.0.2)
21
+ diff-lcs (1.6.2)
22
+ faraday (2.13.1)
23
+ faraday-net_http (>= 2.0, < 3.5)
24
+ json
25
+ logger
26
+ faraday-follow_redirects (0.3.0)
27
+ faraday (>= 1, < 3)
28
+ faraday-net_http (3.4.0)
29
+ net-http (>= 0.5.0)
30
+ hashie (4.1.0)
31
+ ibsciss-middleware (0.4.3)
32
+ json (2.12.2)
33
+ language_server-protocol (3.17.0.5)
34
+ lint_roller (1.1.0)
35
+ logger (1.7.0)
36
+ multi_json (1.15.0)
37
+ net-http (0.6.0)
38
+ uri
39
+ parallel (1.27.0)
40
+ parser (3.3.8.0)
41
+ ast (~> 2.4.1)
42
+ racc
43
+ prism (1.4.0)
44
+ public_suffix (6.0.2)
45
+ rabbitmq_http_api_client (3.0.0)
46
+ addressable (~> 2.7)
47
+ faraday (~> 2.9)
48
+ faraday-follow_redirects (~> 0.3)
49
+ hashie (~> 4.1)
50
+ multi_json (~> 1.15)
51
+ racc (1.8.1)
52
+ rainbow (3.1.1)
53
+ rake (13.3.0)
54
+ rbtree (0.4.6)
55
+ regexp_parser (2.10.0)
56
+ rspec (3.13.1)
57
+ rspec-core (~> 3.13.0)
58
+ rspec-expectations (~> 3.13.0)
59
+ rspec-mocks (~> 3.13.0)
60
+ rspec-benchmark (0.6.0)
61
+ benchmark-malloc (~> 0.2)
62
+ benchmark-perf (~> 0.6)
63
+ benchmark-trend (~> 0.4)
64
+ rspec (>= 3.0)
65
+ rspec-core (3.13.4)
66
+ rspec-support (~> 3.13.0)
67
+ rspec-expectations (3.13.5)
52
68
  diff-lcs (>= 1.2.0, < 2.0)
53
- rspec-support (~> 3.8.0)
54
- rspec-its (1.2.0)
55
- rspec-core (>= 3.0.0)
56
- rspec-expectations (>= 3.0.0)
57
- rspec-mocks (3.8.0)
69
+ rspec-support (~> 3.13.0)
70
+ rspec-its (2.0.0)
71
+ rspec-core (>= 3.13.0)
72
+ rspec-expectations (>= 3.13.0)
73
+ rspec-mocks (3.13.5)
58
74
  diff-lcs (>= 1.2.0, < 2.0)
59
- rspec-support (~> 3.8.0)
60
- rspec-support (3.8.0)
61
- rspec_junit_formatter (0.4.1)
75
+ rspec-support (~> 3.13.0)
76
+ rspec-support (3.13.4)
77
+ rspec_junit_formatter (0.6.0)
62
78
  rspec-core (>= 2, < 4, != 2.12.0)
63
- rubocop (0.62.0)
64
- jaro_winkler (~> 1.5.1)
79
+ rubocop (1.76.1)
80
+ json (~> 2.3)
81
+ language_server-protocol (~> 3.17.0.2)
82
+ lint_roller (~> 1.1.0)
65
83
  parallel (~> 1.10)
66
- parser (>= 2.5, != 2.5.1.1)
67
- powerpack (~> 0.1)
84
+ parser (>= 3.3.0.2)
68
85
  rainbow (>= 2.2.2, < 4.0)
86
+ regexp_parser (>= 2.9.3, < 3.0)
87
+ rubocop-ast (>= 1.45.0, < 2.0)
69
88
  ruby-progressbar (~> 1.7)
70
- unicode-display_width (~> 1.4.0)
71
- ruby-debug-ide (0.7.0.beta7)
72
- rake (>= 0.8.1)
73
- ruby-progressbar (1.10.0)
74
- unicode-display_width (1.4.1)
89
+ unicode-display_width (>= 2.4.0, < 4.0)
90
+ rubocop-ast (1.45.1)
91
+ parser (>= 3.3.7.2)
92
+ prism (~> 1.4)
93
+ rubocop-rake (0.7.1)
94
+ lint_roller (~> 1.1)
95
+ rubocop (>= 1.72.1)
96
+ rubocop-rspec (3.6.0)
97
+ lint_roller (~> 1.1)
98
+ rubocop (~> 1.72, >= 1.72.1)
99
+ ruby-progressbar (1.13.0)
100
+ set (1.1.2)
101
+ sorted_set (1.0.3)
102
+ rbtree
103
+ set (~> 1.0)
104
+ unicode-display_width (3.1.4)
105
+ unicode-emoji (~> 4.0, >= 4.0.4)
106
+ unicode-emoji (4.0.4)
107
+ uri (1.0.3)
75
108
 
76
109
  PLATFORMS
110
+ arm64-darwin-23
77
111
  ruby
78
112
 
79
113
  DEPENDENCIES
80
- bundler (~> 1.16)
114
+ bundler (~> 2.5)
81
115
  cotton-tail!
82
- debase (= 0.2.3.beta5)
83
- rabbitmq_http_api_client (~> 1.9)
84
- rake (~> 12.0)
85
- rspec (~> 3.0)
86
- rspec-benchmark (~> 0.4)
87
- rspec-its (~> 1.2)
116
+ rabbitmq_http_api_client (~> 3.0)
117
+ rake (~> 13.3)
118
+ rspec (~> 3.13)
119
+ rspec-benchmark (~> 0.6)
120
+ rspec-its (~> 2.0)
88
121
  rspec_junit_formatter
89
- rubocop (~> 0.60)
90
- ruby-debug-ide (= 0.7.0.beta7)
122
+ rubocop (~> 1.76)
123
+ rubocop-rake (~> 0.7.1)
124
+ rubocop-rspec (~> 3.6)
91
125
 
92
126
  BUNDLED WITH
93
- 1.17.3
127
+ 2.5.9
@@ -1,21 +1,27 @@
1
1
  -----BEGIN CERTIFICATE-----
2
- MIIDgDCCAmigAwIBAgIBATANBgkqhkiG9w0BAQUFADBDMRUwEwYDVQQDDAxicmVu
2
+ MIIEgDCCAuigAwIBAgIBATANBgkqhkiG9w0BAQsFADBDMRUwEwYDVQQDDAxicmVu
3
3
  bmFubXVzaWMxFTATBgoJkiaJk/IsZAEZFgVnbWFpbDETMBEGCgmSJomT8ixkARkW
4
- A2NvbTAeFw0xODA3MDYwMDA2MzRaFw0xOTA3MDYwMDA2MzRaMEMxFTATBgNVBAMM
4
+ A2NvbTAeFw0yNTA2MTUwOTA4MTFaFw0yNjA2MTUwOTA4MTFaMEMxFTATBgNVBAMM
5
5
  DGJyZW5uYW5tdXNpYzEVMBMGCgmSJomT8ixkARkWBWdtYWlsMRMwEQYKCZImiZPy
6
- LGQBGRYDY29tMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyxykNKqp
7
- jD5gnQd2YHuRDNsLN5limGMDjSb38lMZAfJJugoWbSSeQM3+iVl26YWE5JeJpqDu
8
- Rr/GOQ54bsev4IxCfPl8yIkhAao0i96+k1EeEb/i3pgZOfjXgGSTM71baCZzbqBH
9
- A5ivcb0wqoHWyqrxNtc4XhSs5RtvtNl3IEe/bs5qqixt6PwsCorD6kAoUUNHNM9W
10
- MLexivfiJooHOvVRmf1DQuJ2fDccKNHf7ZR4PuiguT4Z73bT2njCBm2o86o/clvR
11
- WV0jasBOKvsgcg65U10klngBEG56nWSdIE9PrXGPqwBwA6jXttAwFLUNvuam5nGQ
12
- V3MbCFDeHUUrtwIDAQABo38wfTAJBgNVHRMEAjAAMAsGA1UdDwQEAwIEsDAdBgNV
13
- HQ4EFgQUPJGTSMevbRtDlY9WBrs21ae/+5YwIQYDVR0RBBowGIEWYnJlbm5hbm11
14
- c2ljQGdtYW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HU50RDqk79LAgMBAAGj
15
+ fzB9MAkGA1UdEwQCMAAwCwYDVR0PBAQDAgSwMB0GA1UdDgQWBBQvr5stbmmfkP/I
16
+ WYftxVjyNXHtmDAhBgNVHREEGjAYgRZicmVubmFubXVzaWNAZ21haWwuY29tMCEG
17
+ A1UdEgQaMBiBFmJyZW5uYW5tdXNpY0BnbWFpbC5jb20wDQYJKoZIhvcNAQELBQAD
18
+ ggGBAHxVPs6IJrhdhxOyyxq7R06JIz1953ppR2bAW5LqVUNf2BmAiqPSqiog/ggz
19
+ ILK/anuRLHKozygzaz0bbTR5EWPlR6CesiLjmJgLUyg9P0SrY6X6jt2k8c4G9fAx
20
+ YAbg09B/KPZ9FGX9+F05FexiBM1tipxZ2NnrwMIMTsxqeapuGBlgb14u2ZqwLunj
21
+ 3Kd9pGEmf7JoX6sqjZl9KAjIRIWnBjS2Df53Nejb/46vs4A0W9wduwT11Za1QCOj
22
+ XNR5XrU2FBwBpeE4DG3UbbDyBvQee1w7PvTqKAMq2yPTpG+AlURAT7WBqtoVyMqr
23
+ oJ05zcgvox0d9Q2W85Ilv9NNunxbOVbpoh8UhkTWReS7roTBa/MF1ubt8P6OHSVx
24
+ 3ju8CQvfdn7UsxyuVNxNdsrf9aoWTnvCCaRzwA50evk+GwJ7iIkOrkhyVgYMO9oC
25
+ EOU9A8gtMc051I0oe757O9RAJSx+2FFXGBB11YAAMVSFyftESWOELjSfo9i/sfwa
26
+ 3ww/OA==
21
27
  -----END CERTIFICATE-----
data/cotton-tail.gemspec CHANGED
@@ -16,7 +16,7 @@ Gem::Specification.new do |spec|
16
16
  your services'
17
17
 
18
18
  spec.license = 'MIT'
19
-
19
+ spec.required_ruby_version = '>= 3.0.0'
20
20
  spec.cert_chain = ['certs/jamesbrennan.pem']
21
21
  spec.signing_key = File.expand_path('~/.ssh/gem-private_key.pem') if $PROGRAM_NAME.end_with? 'gem'
22
22
 
@@ -28,17 +28,18 @@ Gem::Specification.new do |spec|
28
28
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
29
29
  spec.require_paths = ['lib']
30
30
 
31
- spec.add_dependency 'bunny', '~> 2.12'
32
- spec.add_dependency 'ibsciss-middleware', '~> 0.4.2'
31
+ spec.add_dependency 'bunny', '~> 2.24'
32
+ spec.add_dependency 'ibsciss-middleware', '~> 0.4.3'
33
33
 
34
- spec.add_development_dependency 'bundler', '~> 1.16'
35
- spec.add_development_dependency 'debase', '0.2.3.beta5'
36
- spec.add_development_dependency 'rabbitmq_http_api_client', '~> 1.9'
37
- spec.add_development_dependency 'rake', '~> 12.0'
38
- spec.add_development_dependency 'rspec', '~> 3.0'
39
- spec.add_development_dependency 'rspec-benchmark', '~> 0.4'
40
- spec.add_development_dependency 'rspec-its', '~> 1.2'
34
+ spec.add_development_dependency 'bundler', '~> 2.5'
35
+ spec.add_development_dependency 'rabbitmq_http_api_client', '~> 3.0'
36
+ spec.add_development_dependency 'rake', '~> 13.3'
37
+ spec.add_development_dependency 'rspec', '~> 3.13'
38
+ spec.add_development_dependency 'rspec-benchmark', '~> 0.6'
39
+ spec.add_development_dependency 'rspec-its', '~> 2.0'
41
40
  spec.add_development_dependency 'rspec_junit_formatter'
42
- spec.add_development_dependency 'rubocop', '~> 0.60'
43
- spec.add_development_dependency 'ruby-debug-ide', '0.7.0.beta7'
41
+ spec.add_development_dependency 'rubocop', '~> 1.76'
42
+ spec.add_development_dependency 'rubocop-rake', '~> 0.7.1'
43
+ spec.add_development_dependency 'rubocop-rspec', '~> 3.6'
44
+ spec.metadata['rubygems_mfa_required'] = 'true'
44
45
  end
@@ -1,6 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'middleware'
4
+ require 'amq/settings'
4
5
 
5
6
  module CottonTail
6
7
  # Configuration options
@@ -17,9 +18,8 @@ module CottonTail
17
18
  # to Bunny.new. Any valid params for Bunny.new are accepted.
18
19
  #
19
20
  # @see http://rubybunny.info/articles/connecting.html
20
- def connection_args=(*args, **kwargs)
21
- url, = args
22
- @connection_args = url ? Bunny::Session.parse_uri(url) : kwargs
21
+ def connection_args=(params)
22
+ @connection_args = AMQ::Settings.configure(params)
23
23
  end
24
24
 
25
25
  # Modify or retrieve the application middleware stack.
@@ -1,5 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require 'delegate'
3
4
  require 'forwardable'
4
5
  require 'bunny'
5
6
 
@@ -13,7 +14,7 @@ module CottonTail
13
14
  end
14
15
 
15
16
  def initialize(name:, connection:, manual_ack: false, **opts)
16
- super ::Queue.new
17
+ super(::Queue.new)
17
18
 
18
19
  @connection = connection
19
20
  @source = build_source(name, opts)
@@ -1,7 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require 'fiber'
4
-
5
3
  module CottonTail
6
4
  module Queue
7
5
  # Queue Reader
@@ -1,7 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require 'fiber'
4
-
5
3
  module CottonTail
6
4
  module Queue
7
5
  # A supervisor for a single queue
@@ -1,11 +1,13 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require 'delegate'
4
+
3
5
  module CottonTail
4
6
  # Route pattern matcher
5
7
  class Route < SimpleDelegator
6
8
  def initialize(pattern)
7
9
  @pattern = pattern
8
- super build_regex
10
+ super(build_regex)
9
11
  end
10
12
 
11
13
  def extract_params(routing_key)
@@ -1,11 +1,14 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require 'delegate'
4
+
3
5
  module CottonTail
4
6
  # RouteSegment implements the pattern matching for route segments
5
7
  class RouteSegment < SimpleDelegator
6
8
  def initialize(value)
7
9
  @value = value
8
- super Regexp.new definition(value)
10
+ @transformed = definition(value)
11
+ super(Regexp.new "^#{@transformed}$")
9
12
  end
10
13
 
11
14
  def star?
@@ -24,6 +27,18 @@ module CottonTail
24
27
  @value
25
28
  end
26
29
 
30
+ def match?(other)
31
+ return false unless other
32
+ return false if other.to_s.empty?
33
+ return super if other.is_a?(String)
34
+
35
+ false
36
+ end
37
+
38
+ def to_s
39
+ @transformed.to_s
40
+ end
41
+
27
42
  private
28
43
 
29
44
  TRANSFORM = ->(val, func) { func.call(val) }
@@ -61,10 +76,12 @@ module CottonTail
61
76
  ]
62
77
  end
63
78
 
64
- STAR = /\*/.freeze
65
- HASH = /#/.freeze
66
- NAMED = /:(\w+)/.freeze
67
- NAMED_STAR = /#{STAR}#{NAMED}/.freeze
68
- NAMED_HASH = /#{HASH}#{NAMED}/.freeze
79
+ STAR = /\*/
80
+ HASH = /#/
81
+ NAMED = /:(\w+)/
82
+ NAMED_STAR = /#{STAR}#{NAMED}/
83
+ NAMED_HASH = /#{HASH}#{NAMED}/
84
+
85
+ private_constant :TRANSFORM, :STAR, :HASH, :NAMED, :NAMED_STAR, :NAMED_HASH
69
86
  end
70
87
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CottonTail
4
- VERSION = '0.7.0'
4
+ VERSION = '0.8.0'
5
5
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,36 +1,42 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cotton-tail
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Brennan
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain:
11
11
  - |
12
12
  -----BEGIN CERTIFICATE-----
13
- MIIDgDCCAmigAwIBAgIBATANBgkqhkiG9w0BAQUFADBDMRUwEwYDVQQDDAxicmVu
13
+ MIIEgDCCAuigAwIBAgIBATANBgkqhkiG9w0BAQsFADBDMRUwEwYDVQQDDAxicmVu
14
14
  bmFubXVzaWMxFTATBgoJkiaJk/IsZAEZFgVnbWFpbDETMBEGCgmSJomT8ixkARkW
15
- A2NvbTAeFw0xODA3MDYwMDA2MzRaFw0xOTA3MDYwMDA2MzRaMEMxFTATBgNVBAMM
15
+ A2NvbTAeFw0yNTA2MTUwOTA4MTFaFw0yNjA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ZqwLunj
32
+ 3Kd9pGEmf7JoX6sqjZl9KAjIRIWnBjS2Df53Nejb/46vs4A0W9wduwT11Za1QCOj
33
+ XNR5XrU2FBwBpeE4DG3UbbDyBvQee1w7PvTqKAMq2yPTpG+AlURAT7WBqtoVyMqr
34
+ oJ05zcgvox0d9Q2W85Ilv9NNunxbOVbpoh8UhkTWReS7roTBa/MF1ubt8P6OHSVx
35
+ 3ju8CQvfdn7UsxyuVNxNdsrf9aoWTnvCCaRzwA50evk+GwJ7iIkOrkhyVgYMO9oC
36
+ EOU9A8gtMc051I0oe757O9RAJSx+2FFXGBB11YAAMVSFyftESWOELjSfo9i/sfwa
37
+ 3ww/OA==
32
38
  -----END CERTIFICATE-----
33
- date: 2019-02-06 00:00:00.000000000 Z
39
+ date: 2025-06-15 00:00:00.000000000 Z
34
40
  dependencies:
35
41
  - !ruby/object:Gem::Dependency
36
42
  name: bunny
@@ -38,126 +44,112 @@ dependencies:
38
44
  requirements:
39
45
  - - "~>"
40
46
  - !ruby/object:Gem::Version
41
- version: '2.12'
47
+ version: '2.24'
42
48
  type: :runtime
43
49
  prerelease: false
44
50
  version_requirements: !ruby/object:Gem::Requirement
45
51
  requirements:
46
52
  - - "~>"
47
53
  - !ruby/object:Gem::Version
48
- version: '2.12'
54
+ version: '2.24'
49
55
  - !ruby/object:Gem::Dependency
50
56
  name: ibsciss-middleware
51
57
  requirement: !ruby/object:Gem::Requirement
52
58
  requirements:
53
59
  - - "~>"
54
60
  - !ruby/object:Gem::Version
55
- version: 0.4.2
61
+ version: 0.4.3
56
62
  type: :runtime
57
63
  prerelease: false
58
64
  version_requirements: !ruby/object:Gem::Requirement
59
65
  requirements:
60
66
  - - "~>"
61
67
  - !ruby/object:Gem::Version
62
- version: 0.4.2
68
+ version: 0.4.3
63
69
  - !ruby/object:Gem::Dependency
64
70
  name: bundler
65
71
  requirement: !ruby/object:Gem::Requirement
66
72
  requirements:
67
73
  - - "~>"
68
74
  - !ruby/object:Gem::Version
69
- version: '1.16'
75
+ version: '2.5'
70
76
  type: :development
71
77
  prerelease: false
72
78
  version_requirements: !ruby/object:Gem::Requirement
73
79
  requirements:
74
80
  - - "~>"
75
81
  - !ruby/object:Gem::Version
76
- version: '1.16'
77
- - !ruby/object:Gem::Dependency
78
- name: debase
79
- requirement: !ruby/object:Gem::Requirement
80
- requirements:
81
- - - '='
82
- - !ruby/object:Gem::Version
83
- version: 0.2.3.beta5
84
- type: :development
85
- prerelease: false
86
- version_requirements: !ruby/object:Gem::Requirement
87
- requirements:
88
- - - '='
89
- - !ruby/object:Gem::Version
90
- version: 0.2.3.beta5
82
+ version: '2.5'
91
83
  - !ruby/object:Gem::Dependency
92
84
  name: rabbitmq_http_api_client
93
85
  requirement: !ruby/object:Gem::Requirement
94
86
  requirements:
95
87
  - - "~>"
96
88
  - !ruby/object:Gem::Version
97
- version: '1.9'
89
+ version: '3.0'
98
90
  type: :development
99
91
  prerelease: false
100
92
  version_requirements: !ruby/object:Gem::Requirement
101
93
  requirements:
102
94
  - - "~>"
103
95
  - !ruby/object:Gem::Version
104
- version: '1.9'
96
+ version: '3.0'
105
97
  - !ruby/object:Gem::Dependency
106
98
  name: rake
107
99
  requirement: !ruby/object:Gem::Requirement
108
100
  requirements:
109
101
  - - "~>"
110
102
  - !ruby/object:Gem::Version
111
- version: '12.0'
103
+ version: '13.3'
112
104
  type: :development
113
105
  prerelease: false
114
106
  version_requirements: !ruby/object:Gem::Requirement
115
107
  requirements:
116
108
  - - "~>"
117
109
  - !ruby/object:Gem::Version
118
- version: '12.0'
110
+ version: '13.3'
119
111
  - !ruby/object:Gem::Dependency
120
112
  name: rspec
121
113
  requirement: !ruby/object:Gem::Requirement
122
114
  requirements:
123
115
  - - "~>"
124
116
  - !ruby/object:Gem::Version
125
- version: '3.0'
117
+ version: '3.13'
126
118
  type: :development
127
119
  prerelease: false
128
120
  version_requirements: !ruby/object:Gem::Requirement
129
121
  requirements:
130
122
  - - "~>"
131
123
  - !ruby/object:Gem::Version
132
- version: '3.0'
124
+ version: '3.13'
133
125
  - !ruby/object:Gem::Dependency
134
126
  name: rspec-benchmark
135
127
  requirement: !ruby/object:Gem::Requirement
136
128
  requirements:
137
129
  - - "~>"
138
130
  - !ruby/object:Gem::Version
139
- version: '0.4'
131
+ version: '0.6'
140
132
  type: :development
141
133
  prerelease: false
142
134
  version_requirements: !ruby/object:Gem::Requirement
143
135
  requirements:
144
136
  - - "~>"
145
137
  - !ruby/object:Gem::Version
146
- version: '0.4'
138
+ version: '0.6'
147
139
  - !ruby/object:Gem::Dependency
148
140
  name: rspec-its
149
141
  requirement: !ruby/object:Gem::Requirement
150
142
  requirements:
151
143
  - - "~>"
152
144
  - !ruby/object:Gem::Version
153
- version: '1.2'
145
+ version: '2.0'
154
146
  type: :development
155
147
  prerelease: false
156
148
  version_requirements: !ruby/object:Gem::Requirement
157
149
  requirements:
158
150
  - - "~>"
159
151
  - !ruby/object:Gem::Version
160
- version: '1.2'
152
+ version: '2.0'
161
153
  - !ruby/object:Gem::Dependency
162
154
  name: rspec_junit_formatter
163
155
  requirement: !ruby/object:Gem::Requirement
@@ -178,28 +170,42 @@ dependencies:
178
170
  requirements:
179
171
  - - "~>"
180
172
  - !ruby/object:Gem::Version
181
- version: '0.60'
173
+ version: '1.76'
182
174
  type: :development
183
175
  prerelease: false
184
176
  version_requirements: !ruby/object:Gem::Requirement
185
177
  requirements:
186
178
  - - "~>"
187
179
  - !ruby/object:Gem::Version
188
- version: '0.60'
180
+ version: '1.76'
189
181
  - !ruby/object:Gem::Dependency
190
- name: ruby-debug-ide
182
+ name: rubocop-rake
191
183
  requirement: !ruby/object:Gem::Requirement
192
184
  requirements:
193
- - - '='
185
+ - - "~>"
194
186
  - !ruby/object:Gem::Version
195
- version: 0.7.0.beta7
187
+ version: 0.7.1
196
188
  type: :development
197
189
  prerelease: false
198
190
  version_requirements: !ruby/object:Gem::Requirement
199
191
  requirements:
200
- - - '='
192
+ - - "~>"
201
193
  - !ruby/object:Gem::Version
202
- version: 0.7.0.beta7
194
+ version: 0.7.1
195
+ - !ruby/object:Gem::Dependency
196
+ name: rubocop-rspec
197
+ requirement: !ruby/object:Gem::Requirement
198
+ requirements:
199
+ - - "~>"
200
+ - !ruby/object:Gem::Version
201
+ version: '3.6'
202
+ type: :development
203
+ prerelease: false
204
+ version_requirements: !ruby/object:Gem::Requirement
205
+ requirements:
206
+ - - "~>"
207
+ - !ruby/object:Gem::Version
208
+ version: '3.6'
203
209
  description: |-
204
210
  Simply and easily add AMQP messaging capabilities to
205
211
  your services
@@ -213,6 +219,7 @@ files:
213
219
  - ".gitignore"
214
220
  - ".rspec"
215
221
  - ".rubocop.yml"
222
+ - ".ruby-gemset"
216
223
  - ".ruby-version"
217
224
  - Dockerfile
218
225
  - Gemfile
@@ -256,8 +263,9 @@ files:
256
263
  homepage: https://github.com/jamesBrennan/cotton-tail
257
264
  licenses:
258
265
  - MIT
259
- metadata: {}
260
- post_install_message:
266
+ metadata:
267
+ rubygems_mfa_required: 'true'
268
+ post_install_message:
261
269
  rdoc_options: []
262
270
  require_paths:
263
271
  - lib
@@ -265,15 +273,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
265
273
  requirements:
266
274
  - - ">="
267
275
  - !ruby/object:Gem::Version
268
- version: '0'
276
+ version: 3.0.0
269
277
  required_rubygems_version: !ruby/object:Gem::Requirement
270
278
  requirements:
271
279
  - - ">="
272
280
  - !ruby/object:Gem::Version
273
281
  version: '0'
274
282
  requirements: []
275
- rubygems_version: 3.0.2
276
- signing_key:
283
+ rubygems_version: 3.5.9
284
+ signing_key:
277
285
  specification_version: 4
278
286
  summary: A simple multi-threaded amqp server
279
287
  test_files: []
metadata.gz.sig CHANGED
Binary file