anycable 1.0.0.rc1 → 1.0.0.rc2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/anycable/cli.rb +12 -5
- data/lib/anycable/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d42f34d7d5f20b9978b36e5fb56cbf46b3cfd711d44d9fd50c6cf1f8257b5c9f
|
4
|
+
data.tar.gz: e8d121977adbec6aa7f1a08bc682eba32e84ac5b71f5ae2b4f88f711e95e06ba
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fd47edb035d0be736e0309bc8c1a0fcd8c8f7fe88fff79662b35edcaa65f2bfc9bd80f7491e5c2be230eb4577fee97b5191190dd5244735e2c8613037065baa4
|
7
|
+
data.tar.gz: 424143bad004b0016f0953d46ae4c926cd367efa1a7c3e59d3541895aa49773b4554d8cabcc77cee0a8070e695bcf66dd043e667fc0c4253df4efd2e2e65b16e
|
data/CHANGELOG.md
CHANGED
data/lib/anycable/cli.rb
CHANGED
@@ -20,17 +20,22 @@ module AnyCable
|
|
20
20
|
# Wait for external process termination (s)
|
21
21
|
WAIT_PROCESS = 2
|
22
22
|
|
23
|
-
attr_reader :server, :health_server
|
23
|
+
attr_reader :server, :health_server, :embedded
|
24
|
+
alias embedded? embedded
|
25
|
+
|
26
|
+
def initialize(embedded: false)
|
27
|
+
@embedded = embedded
|
28
|
+
end
|
24
29
|
|
25
30
|
# rubocop:disable Metrics/AbcSize, Metrics/MethodLength
|
26
|
-
def run(args =
|
31
|
+
def run(args = [])
|
27
32
|
@at_stop = []
|
28
33
|
|
29
34
|
extra_options = parse_cli_options!(args)
|
30
35
|
|
31
36
|
# Boot app first, 'cause it might change
|
32
37
|
# configuration, loggin settings, etc.
|
33
|
-
boot_app!
|
38
|
+
boot_app! unless embedded?
|
34
39
|
|
35
40
|
parse_gem_options!(extra_options)
|
36
41
|
|
@@ -40,7 +45,7 @@ module AnyCable
|
|
40
45
|
|
41
46
|
print_versions!
|
42
47
|
|
43
|
-
logger.info "Serving #{defined?(::Rails) ? "Rails " : ""}application from #{boot_file}"
|
48
|
+
logger.info "Serving #{defined?(::Rails) ? "Rails " : ""}application from #{boot_file}" unless embedded?
|
44
49
|
|
45
50
|
verify_connection_factory!
|
46
51
|
|
@@ -66,6 +71,8 @@ module AnyCable
|
|
66
71
|
|
67
72
|
run_custom_server_command! unless server_command.nil?
|
68
73
|
|
74
|
+
return if embedded?
|
75
|
+
|
69
76
|
begin
|
70
77
|
wait_till_terminated
|
71
78
|
rescue Interrupt => e
|
@@ -81,7 +88,7 @@ module AnyCable
|
|
81
88
|
|
82
89
|
def shutdown
|
83
90
|
at_stop.each(&:call)
|
84
|
-
server
|
91
|
+
server&.stop
|
85
92
|
end
|
86
93
|
|
87
94
|
private
|
data/lib/anycable/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: anycable
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0.
|
4
|
+
version: 1.0.0.rc2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- palkan
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-06-
|
11
|
+
date: 2020-06-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: anyway_config
|