tail-cf-plugin 0.0.16.pre → 0.0.17.pre
Sign up to get free protection for your applications and to get access to all the features.
@@ -15,6 +15,9 @@ module TailCfPlugin
|
|
15
15
|
|
16
16
|
ws.on :open do |event|
|
17
17
|
output.puts("Connected to server.")
|
18
|
+
EventMachine.add_periodic_timer(keep_alive_interval) do
|
19
|
+
ws.send([42])
|
20
|
+
end
|
18
21
|
end
|
19
22
|
|
20
23
|
ws.on :message do |event|
|
@@ -27,14 +30,20 @@ module TailCfPlugin
|
|
27
30
|
end
|
28
31
|
|
29
32
|
ws.on :close do |event|
|
33
|
+
ws.close
|
30
34
|
output.puts("Server dropped connection...goodbye.")
|
31
35
|
EM.stop
|
36
|
+
ws = nil
|
32
37
|
end
|
33
38
|
}
|
34
39
|
end
|
35
40
|
|
36
41
|
private
|
37
42
|
|
43
|
+
def keep_alive_interval
|
44
|
+
25
|
45
|
+
end
|
46
|
+
|
38
47
|
attr_reader :output
|
39
48
|
end
|
40
49
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tail-cf-plugin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.17.pre
|
5
5
|
prerelease: 7
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-08-02 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: cf
|