hanami-events-cloud_pubsub 2.3.0 → 2.3.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6a149ec7d07642ff795eb1102b595bc2332368f4baf41b438a8b2a3cba181e11
4
- data.tar.gz: c053e05e3cb6523acc2e6b0e4c63579081f09e76ef20285ad7ea4e72ca59b90b
3
+ metadata.gz: 359363457aee7a897b7deb7f0f99512b35e73f18a125e63afb006305013e17ef
4
+ data.tar.gz: dc023884ef32591122fdc8ce2be13e620115ce8146a733176bba2bd79f37c602
5
5
  SHA512:
6
- metadata.gz: cc39732f19e786147e7023389e71b30e1f0e61170df1edbd6e8e03ea9eb37fa5be5f300f18cf368bacc765e12f6b53de16df27b17a41f1a0849b137fc632443d
7
- data.tar.gz: aa90fc9e19feacb57f9928c05bfc4f8fec02a4ea28e76e16739e6447165b1271edd6de8b972e4e645e12268af072c0ceab253dbd2e42d45086aebd9d5f62b33d
6
+ metadata.gz: 90ace734579e619e422d93c44bf0a863cc3192d296730c3ccdfa2cf54abdb9a8ff8f14e79b62b5643488c2c0c04dea6568476e399c597cf345b4bfe9a7d4780e
7
+ data.tar.gz: eec416bde4dccbb7b69229aa30522fcb38842c0238422a4e3121e1fca6e6125e27a141be59c2c0183cd0db49fde663712d9228f308ca13be0e70bb59e2af8179
data/.tool-versions ADDED
@@ -0,0 +1 @@
1
+ ruby 2.6.5
data/Gemfile.lock CHANGED
@@ -8,8 +8,8 @@ GIT
8
8
  PATH
9
9
  remote: .
10
10
  specs:
11
- hanami-events-cloud_pubsub (2.3.0)
12
- dry-configurable (~> 0.8.0)
11
+ hanami-events-cloud_pubsub (2.3.1)
12
+ dry-configurable (>= 0.8, < 0.10)
13
13
  google-cloud-pubsub (>= 0.38.1, < 1.2)
14
14
  hanami-cli (~> 0.2)
15
15
  hanami-events (~> 0.2.0)
@@ -24,25 +24,26 @@ GEM
24
24
  concurrent-ruby (1.1.5)
25
25
  diff-lcs (1.3)
26
26
  docile (1.3.2)
27
- dry-configurable (0.8.3)
27
+ dry-configurable (0.9.0)
28
28
  concurrent-ruby (~> 1.0)
29
29
  dry-core (~> 0.4, >= 0.4.7)
30
30
  dry-container (0.7.1)
31
31
  concurrent-ruby (~> 1.0)
32
32
  dry-configurable (~> 0.1, >= 0.1.3)
33
- dry-core (0.4.8)
33
+ dry-core (0.4.9)
34
34
  concurrent-ruby (~> 1.0)
35
- faraday (0.17.0)
35
+ faraday (0.17.1)
36
36
  multipart-post (>= 1.2, < 3)
37
37
  google-cloud-core (1.4.1)
38
38
  google-cloud-env (~> 1.0)
39
39
  google-cloud-env (1.3.0)
40
40
  faraday (~> 0.11)
41
- google-cloud-pubsub (1.1.0)
41
+ google-cloud-pubsub (1.1.2)
42
42
  concurrent-ruby (~> 1.1)
43
43
  google-cloud-core (~> 1.2)
44
44
  google-gax (~> 1.8)
45
45
  googleapis-common-protos (>= 1.3.9, < 2.0)
46
+ googleapis-common-protos-types (>= 1.0.4, < 2.0)
46
47
  grpc-google-iam-v1 (~> 0.6.9)
47
48
  google-gax (1.8.1)
48
49
  google-protobuf (~> 3.9)
@@ -50,7 +51,7 @@ GEM
50
51
  googleauth (~> 0.9)
51
52
  grpc (~> 1.24)
52
53
  rly (~> 0.2.3)
53
- google-protobuf (3.10.1)
54
+ google-protobuf (3.11.2)
54
55
  googleapis-common-protos (1.3.9)
55
56
  google-protobuf (~> 3.0)
56
57
  googleapis-common-protos-types (~> 1.0)
@@ -64,7 +65,7 @@ GEM
64
65
  multi_json (~> 1.11)
65
66
  os (>= 0.9, < 2.0)
66
67
  signet (~> 0.12)
67
- grpc (1.24.0)
68
+ grpc (1.25.0)
68
69
  google-protobuf (~> 3.8)
69
70
  googleapis-common-protos-types (~> 1.0)
70
71
  grpc-google-iam-v1 (0.6.9)
@@ -79,7 +80,7 @@ GEM
79
80
  jaro_winkler (1.5.3)
80
81
  json (2.2.0)
81
82
  jwt (2.2.1)
82
- memoist (0.16.0)
83
+ memoist (0.16.2)
83
84
  method_source (0.9.2)
84
85
  multi_json (1.14.1)
85
86
  multipart-post (2.1.1)
@@ -142,4 +143,4 @@ DEPENDENCIES
142
143
  simplecov
143
144
 
144
145
  BUNDLED WITH
145
- 1.17.1
146
+ 1.17.2
@@ -22,7 +22,7 @@ Gem::Specification.new do |spec|
22
22
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
23
23
  spec.require_paths = ['lib']
24
24
 
25
- spec.add_dependency 'dry-configurable', '~> 0.8.0'
25
+ spec.add_dependency 'dry-configurable', '>= 0.8', '< 0.10'
26
26
  spec.add_dependency 'google-cloud-pubsub', '>= 0.38.1', '< 1.2'
27
27
  spec.add_dependency 'hanami-cli', '~> 0.2'
28
28
  spec.add_dependency 'hanami-events', '~> 0.2.0'
@@ -95,7 +95,7 @@ module Hanami
95
95
  end
96
96
 
97
97
  def setup_signal_handlers
98
- Signal.trap('TTIN') { @event_queue << runner.method(:print_debug_info) }
98
+ Signal.trap('TTIN') { @event_queue << method(:print_debug_info) }
99
99
  Signal.trap('INT') { @event_queue << method(:shutdown) }
100
100
  Signal.trap('TERM') { @event_queue << method(:shutdown) }
101
101
  Signal.trap('TSTP') { @event_queue << runner.method(:shutdown) }
@@ -103,6 +103,7 @@ module Hanami
103
103
 
104
104
  def shutdown
105
105
  STDOUT.flush
106
+ STDERR.flush
106
107
  runner.gracefully_shutdown
107
108
  ensure
108
109
  @finished_shutting_down = true
@@ -111,6 +112,10 @@ module Hanami
111
112
  def finished_shutting_down?
112
113
  @finished_shutting_down == true
113
114
  end
115
+
116
+ def print_debug_info
117
+ warn(runner.debug_info)
118
+ end
114
119
  end
115
120
 
116
121
  Commands.register 'run', Run
@@ -50,7 +50,7 @@ module Hanami
50
50
  def health_endpoint(_req, res)
51
51
  res['Content-Type'] = 'text/plain'
52
52
  res.status = runner.healthy? ? 200 : 503
53
- res.body = res.status.to_s
53
+ res.body = runner.debug_info
54
54
  end
55
55
  end
56
56
  end
@@ -40,6 +40,8 @@ module Hanami
40
40
  handle_message(message)
41
41
  end
42
42
 
43
+ logger.debug("Registered listener for #{subscriber_id} with opts #{subscriber_opts}")
44
+
43
45
  @subscriber = listener
44
46
 
45
47
  self
@@ -84,8 +84,8 @@ module Hanami
84
84
  #
85
85
  # See: https://github.com/mperham/sidekiq/blob/e447dae961ebc894f12848d9f33446a07ffc67dc/bin/sidekiqload#L74
86
86
  # rubocop:disable Metrics/AbcSize
87
- def print_debug_info(stream = STDOUT)
88
- stream.puts <<~MSG
87
+ def debug_info
88
+ <<~MSG
89
89
  ╔══════ BACKTRACES
90
90
  #{Thread.list.flat_map { |thr| ThreadInspector.new(thr).to_s }.join("\n")}
91
91
  ╠══════ LISTENERS
@@ -3,7 +3,7 @@
3
3
  module Hanami
4
4
  module Events
5
5
  module CloudPubsub
6
- VERSION = '2.3.0'
6
+ VERSION = '2.3.1'
7
7
  end
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,29 +1,35 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hanami-events-cloud_pubsub
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.0
4
+ version: 2.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ian Ker-Seymer
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-10-30 00:00:00.000000000 Z
11
+ date: 2019-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dry-configurable
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0.8'
20
+ - - "<"
18
21
  - !ruby/object:Gem::Version
19
- version: 0.8.0
22
+ version: '0.10'
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
- - - "~>"
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: '0.8'
30
+ - - "<"
25
31
  - !ruby/object:Gem::Version
26
- version: 0.8.0
32
+ version: '0.10'
27
33
  - !ruby/object:Gem::Dependency
28
34
  name: google-cloud-pubsub
29
35
  requirement: !ruby/object:Gem::Requirement
@@ -126,6 +132,7 @@ files:
126
132
  - ".rspec"
127
133
  - ".rubocop.yml"
128
134
  - ".rubocop_todo.yml"
135
+ - ".tool-versions"
129
136
  - ".travis.yml"
130
137
  - CODE_OF_CONDUCT.md
131
138
  - Gemfile
@@ -178,8 +185,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
178
185
  - !ruby/object:Gem::Version
179
186
  version: '0'
180
187
  requirements: []
181
- rubyforge_project:
182
- rubygems_version: 2.7.8
188
+ rubygems_version: 3.0.3
183
189
  signing_key:
184
190
  specification_version: 4
185
191
  summary: Google Cloud Pub/Sub adapter for the hanami-events gem