sps-pub 0.4.3 → 0.5.0

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
  SHA1:
3
- metadata.gz: 6ebc344417b378aded8289a69f8f31ec3335ae72
4
- data.tar.gz: dada4b78af3af6e3924410993ad782f416a81ba4
3
+ metadata.gz: ab9d248e2990551e063728e7ce2a914d496271f3
4
+ data.tar.gz: 7a0c0eb1f19cdaec132b8abfe673c9e4fd129f44
5
5
  SHA512:
6
- metadata.gz: 726066168133a30ed79e8cf0867ff793ac7dc5229b3752564f4f1c67b47447a36176631b66c256a5dc4d37026e377140aea300e22410333ba503309c95f65759
7
- data.tar.gz: 6fee716949cc77f617fea34f8ced4d6c3335bb8b8cf938f75856ce9c2dcda335294b3088b3dc9bdd1a7f4eda2b0be3104273351183e1eb4067ec2d7ee3b991b7
6
+ metadata.gz: e45591640e5294aaf23570b1922297d8732729a4fa886ffc02be8f0ffb2855cde16b4deb8627f2e253574b833760ce95fc94491b56c658c1fed92f7e7bf75788
7
+ data.tar.gz: 2b62ade433a74973517cddb8f12619d795500de94abab57ce6b34d97181fd7de027b2d6aa3e83ac6c34881f6460eb47d17ee66c57230e2cfabef072d25a2f898
Binary file
data.tar.gz.sig CHANGED
@@ -1,2 +1,2 @@
1
- E|�9E��rlYe�s�����v��x\��x�t��"�~�JV6�"*�El���E2��7ay���\8�/���(\+�t ���-xP]��IJ<u�$L�kbIȺR%W�3��E����01�U|�-�5������Є�ɢJ^��?�m/�ޘ�Bg��A�W%�y8��A.g�R�#�k���M�']�r"�l�/&�lb�VĝxR��dX=C��
2
- bR��J�����L8�°~��l3��#s5Л!�]
1
+ X ��B�-�����+�ל���b_}Y��$h<?Ol�� (^�Q*<[e�€��᱗~��|�/Z���*l݄��²��7�b
2
+ J��Ȝ#vADk�e�� ��m��ݎ�$t(��m��Xݫ�?lv��W}��<O�&j�+{�$<'���lD�]v����cju���٢"G-�p���?�\�7�R,s$nj�'�5�L�|*;��[j��Pߒ��z�p ���O(s���
@@ -2,13 +2,17 @@
2
2
 
3
3
  # file: sps-pub.rb
4
4
 
5
- require 'ws'
5
+ require 'websocket-client-simple'
6
6
 
7
7
 
8
8
  class SPSPub
9
9
 
10
- def initialize(address: 'sps', port: '59000')
11
- @client = Net::WS.new "ws://%s:%s/" % [address, port]
10
+ def initialize(host: 'sps', address: host, port: '59000')
11
+
12
+
13
+ @client = WebSocket::Client::Simple.connect "ws://%s:%s/" % [address, port]
14
+ sleep 0.02
15
+
12
16
  end
13
17
 
14
18
  def notice(s)
@@ -17,10 +21,12 @@ class SPSPub
17
21
 
18
22
  alias publish notice
19
23
 
20
- def self.notice(s, host='sps', address: host, port: '59000', retries: 3)
24
+ def self.notice(s, hostx='sps', host: hostx, address: host,
25
+ port: '59000', retries: 3)
21
26
 
22
27
  retry_attempts = 0
23
- client = Net::WS.new "ws://%s:%s/" % [host, port]
28
+
29
+ client = WebSocket::Client::Simple.connect "ws://%s:%s/" % [address, port]
24
30
 
25
31
  begin
26
32
 
@@ -44,11 +50,11 @@ class SPSPub
44
50
 
45
51
  end
46
52
 
47
- def self.pub(s, address: 'sps', port: '59000')
53
+ def self.pub(s, address: 'sps', host: address, port: '59000')
48
54
  self.notice(s, address: 'sps', port: '59000')
49
55
  end
50
56
 
51
- def self.publish(s, address: 'sps', port: '59000')
57
+ def self.publish(s, address: 'sps', host: address, port: '59000')
52
58
  self.notice(s, address: 'sps', port: '59000')
53
59
  end
54
60
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sps-pub
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.3
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
@@ -12,47 +12,47 @@ cert_chain:
12
12
  -----BEGIN CERTIFICATE-----
13
13
  MIIDljCCAn6gAwIBAgIBATANBgkqhkiG9w0BAQUFADBIMRIwEAYDVQQDDAlnZW1t
14
14
  YXN0ZXIxHj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ke//2Urv5XozW5nKniqR+yI7YVIlgDHWEjHdlCaQH3fMHsliDCeDF/lxRd902EDM
32
+ pCvgnGqKZoDb7g==
33
33
  -----END CERTIFICATE-----
34
- date: 2015-11-18 00:00:00.000000000 Z
34
+ date: 2017-01-01 00:00:00.000000000 Z
35
35
  dependencies:
36
36
  - !ruby/object:Gem::Dependency
37
- name: simpleblockingwebsocketclient
37
+ name: websocket-client-simple
38
38
  requirement: !ruby/object:Gem::Requirement
39
39
  requirements:
40
40
  - - "~>"
41
41
  - !ruby/object:Gem::Version
42
- version: '0.43'
42
+ version: '0.3'
43
43
  - - ">="
44
44
  - !ruby/object:Gem::Version
45
- version: '0.43'
45
+ version: 0.3.0
46
46
  type: :runtime
47
47
  prerelease: false
48
48
  version_requirements: !ruby/object:Gem::Requirement
49
49
  requirements:
50
50
  - - "~>"
51
51
  - !ruby/object:Gem::Version
52
- version: '0.43'
52
+ version: '0.3'
53
53
  - - ">="
54
54
  - !ruby/object:Gem::Version
55
- version: '0.43'
55
+ version: 0.3.0
56
56
  description:
57
57
  email: james@r0bertson.co.uk
58
58
  executables: []
@@ -80,7 +80,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
80
80
  version: '0'
81
81
  requirements: []
82
82
  rubyforge_project:
83
- rubygems_version: 2.4.8
83
+ rubygems_version: 2.6.8
84
84
  signing_key:
85
85
  specification_version: 4
86
86
  summary: A SimplePubSub client for publishing messages in 1 line of code.
metadata.gz.sig CHANGED
Binary file