haredo 2.0.3 → 2.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/src/bin/haredo +30 -4
- data/src/lib/haredo/service/daemon.rb +2 -2
- data/src/lib/haredo/version.rb +3 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: adcb099319bb52f459a005ddd10a86995fef2093
|
4
|
+
data.tar.gz: 848ea0c89540ff8298f035bfcb9cd228a42c3fde
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 19d58fc3a38f411b09b1d2c91f4678fc8b3cf6401ed0e6f16d0985891686cfc41e4f29daf9cee796ec791c6be19d637a273040f35efb80e3d73862ae3eb016ef
|
7
|
+
data.tar.gz: 2aeaf95425000d2a19fe15f5881e6b5cb2e6e26a7844104ea9f3e577e0c242d330e22d382feacfef3cace2ec1417b21c9f85c06e84d5e553e77474fc553cc077
|
data/src/bin/haredo
CHANGED
@@ -22,13 +22,39 @@ class CommandLine
|
|
22
22
|
@commands[interface.name] = interface
|
23
23
|
end
|
24
24
|
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
25
|
+
# Guard against Bunny connection errors.
|
26
|
+
# @return Returns false if connection error occurs, true for normal shutdown.
|
27
|
+
def runforever()
|
28
|
+
while true
|
29
|
+
begin
|
30
|
+
daemon = HareDo::Service::Daemon::new(@service)
|
31
|
+
daemon.run()
|
32
|
+
rescue
|
33
|
+
begin
|
34
|
+
daemon.shutdown()
|
35
|
+
daemon = nil
|
36
|
+
return false
|
37
|
+
rescue
|
38
|
+
# Ignore
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
29
42
|
|
43
|
+
# Normal shutdown
|
30
44
|
daemon.shutdown()
|
31
45
|
|
46
|
+
return true
|
47
|
+
end
|
48
|
+
|
49
|
+
def daemonize()
|
50
|
+
while runforever() == false
|
51
|
+
begin
|
52
|
+
puts 'Reconnecting'
|
53
|
+
sleep 5
|
54
|
+
rescue
|
55
|
+
# Ignore
|
56
|
+
end
|
57
|
+
end
|
32
58
|
puts 'Daemon exiting'
|
33
59
|
end
|
34
60
|
|
data/src/lib/haredo/version.rb
CHANGED
@@ -4,8 +4,8 @@ module HareDo
|
|
4
4
|
VERSION_MAJ = '2'
|
5
5
|
VERSION_MIN = '0'
|
6
6
|
VERSION_CL = ''
|
7
|
-
VERSION_PL = '
|
8
|
-
VERSION = '2.0.
|
9
|
-
RELEASE_DATE = 'Tue, 08 Oct 2013
|
7
|
+
VERSION_PL = '4'
|
8
|
+
VERSION = '2.0.4-1'
|
9
|
+
RELEASE_DATE = 'Tue, 08 Oct 2013 14:41:57 -0500'
|
10
10
|
|
11
11
|
end # module HareDo
|