nats 0.4.26 → 0.4.28

Sign up to get free protection for your applications and to get access to all the features.
data/HISTORY.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # HISTORY
2
2
 
3
+ ## v0.4.28 (September 22, 2012)
4
+ - Binary payload bug fix
5
+ - Lock EM to version 0.12.10, 1.0 does not pass tests currently.
6
+ - See full list @ https://github.com/derekcollison/nats/compare/v0.4.26...v0.4.28
7
+
3
8
  ## v0.4.26 (July 30, 2012)
4
9
  - Syslog support
5
10
  - Fixed reconnect bug to authorized servers
@@ -50,4 +55,3 @@
50
55
  ## v0.3.12 (Nov 21, 2010)
51
56
 
52
57
  - Initial Release
53
-
data/README.md CHANGED
@@ -12,7 +12,11 @@ This gem currently works on the following Ruby platforms:
12
12
  - Rubinius
13
13
  - JRuby
14
14
 
15
- There is a [Node.js](https://github.com/derekcollison/node_nats) client available as well.
15
+ There are several other client language bindings as well.
16
+
17
+ [Node.js](https://github.com/derekcollison/node_nats)
18
+ [Go - Apcera](https://github.com/apcera/nats)
19
+ [Go - CloudFoundry](https://github.com/cloudfoundry/gonats)
16
20
 
17
21
  ## Getting Started
18
22
 
data/lib/nats/client.rb CHANGED
@@ -8,7 +8,7 @@ require "#{ep}/ext/json"
8
8
 
9
9
  module NATS
10
10
 
11
- VERSION = '0.4.26'.freeze
11
+ VERSION = '0.4.28'.freeze
12
12
 
13
13
  DEFAULT_PORT = 4222
14
14
  DEFAULT_URI = "nats://localhost:#{DEFAULT_PORT}".freeze
@@ -631,4 +631,3 @@ module NATS
631
631
  end
632
632
 
633
633
  end
634
-
@@ -89,9 +89,7 @@ module NATSD #:nodoc: all
89
89
 
90
90
  def receive_data(data)
91
91
  @buf = @buf ? @buf << data : data
92
- return close_connection if @buf =~ /(\006|\004)/ # ctrl+c or ctrl+d for telnet friendly
93
92
 
94
- # while (@buf && !@buf.empty? && !@closing)
95
93
  while (@buf && !@closing)
96
94
  case @parse_state
97
95
  when AWAITING_CONTROL_LINE
@@ -161,6 +159,12 @@ module NATSD #:nodoc: all
161
159
  return connect_auth_timeout if @auth_pending
162
160
  @buf = $'
163
161
  queue_data(UNKNOWN_OP)
162
+ when CTRL_C # ctrl+c or ctrl+d for telnet friendly
163
+ ctrace('CTRL-C encountered', strip_op($&)) if NATSD::Server.trace_flag?
164
+ return close_connection
165
+ when CTRL_D # ctrl+d for telnet friendly
166
+ ctrace('CTRL-D encountered', strip_op($&)) if NATSD::Server.trace_flag?
167
+ return close_connection
164
168
  else
165
169
  # If we are here we do not have a complete line yet that we understand.
166
170
  # If too big, cut the connection off.
@@ -1,7 +1,7 @@
1
1
 
2
2
  module NATSD #:nodoc:
3
3
 
4
- VERSION = '0.4.26'
4
+ VERSION = '0.4.28'
5
5
  APP_NAME = 'nats-server'
6
6
 
7
7
  DEFAULT_PORT = 4222
@@ -20,6 +20,8 @@ module NATSD #:nodoc:
20
20
  PONG = /\APONG\s*\r\n/i
21
21
  CONNECT = /\ACONNECT\s+([^\r\n]+)\r\n/i
22
22
  UNKNOWN = /\A(.*)\r\n/
23
+ CTRL_C = /\006/
24
+ CTRL_D = /\004/
23
25
 
24
26
  # RESPONSES
25
27
  CR_LF = "\r\n".freeze
data/nats.gemspec CHANGED
@@ -16,7 +16,7 @@ spec = Gem::Specification.new do |s|
16
16
  s.authors = ['Derek Collison']
17
17
  s.email = ['derek.collison@gmail.com']
18
18
 
19
- s.add_dependency('eventmachine', '>= 0.12.10')
19
+ s.add_dependency('eventmachine', '= 0.12.10')
20
20
  s.add_dependency('json_pure', '>= 1.7.3')
21
21
  s.add_dependency('daemons', '>= 1.1.5')
22
22
  s.add_dependency('thin', '>= 1.4.1')
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nats
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.26
4
+ version: 0.4.28
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,27 +9,22 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-07-30 00:00:00.000000000 Z
12
+ date: 2012-09-22 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: eventmachine
16
- requirement: !ruby/object:Gem::Requirement
16
+ requirement: &70321680098440 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
- - - ! '>='
19
+ - - =
20
20
  - !ruby/object:Gem::Version
21
21
  version: 0.12.10
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
- requirements:
27
- - - ! '>='
28
- - !ruby/object:Gem::Version
29
- version: 0.12.10
24
+ version_requirements: *70321680098440
30
25
  - !ruby/object:Gem::Dependency
31
26
  name: json_pure
32
- requirement: !ruby/object:Gem::Requirement
27
+ requirement: &70321680097320 !ruby/object:Gem::Requirement
33
28
  none: false
34
29
  requirements:
35
30
  - - ! '>='
@@ -37,15 +32,10 @@ dependencies:
37
32
  version: 1.7.3
38
33
  type: :runtime
39
34
  prerelease: false
40
- version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
- requirements:
43
- - - ! '>='
44
- - !ruby/object:Gem::Version
45
- version: 1.7.3
35
+ version_requirements: *70321680097320
46
36
  - !ruby/object:Gem::Dependency
47
37
  name: daemons
48
- requirement: !ruby/object:Gem::Requirement
38
+ requirement: &70321680096000 !ruby/object:Gem::Requirement
49
39
  none: false
50
40
  requirements:
51
41
  - - ! '>='
@@ -53,15 +43,10 @@ dependencies:
53
43
  version: 1.1.5
54
44
  type: :runtime
55
45
  prerelease: false
56
- version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
- requirements:
59
- - - ! '>='
60
- - !ruby/object:Gem::Version
61
- version: 1.1.5
46
+ version_requirements: *70321680096000
62
47
  - !ruby/object:Gem::Dependency
63
48
  name: thin
64
- requirement: !ruby/object:Gem::Requirement
49
+ requirement: &70321680095100 !ruby/object:Gem::Requirement
65
50
  none: false
66
51
  requirements:
67
52
  - - ! '>='
@@ -69,12 +54,7 @@ dependencies:
69
54
  version: 1.4.1
70
55
  type: :runtime
71
56
  prerelease: false
72
- version_requirements: !ruby/object:Gem::Requirement
73
- none: false
74
- requirements:
75
- - - ! '>='
76
- - !ruby/object:Gem::Version
77
- version: 1.4.1
57
+ version_requirements: *70321680095100
78
58
  description: A lightweight cloud messaging system.
79
59
  email:
80
60
  - derek.collison@gmail.com
@@ -132,7 +112,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
132
112
  version: '0'
133
113
  requirements: []
134
114
  rubyforge_project:
135
- rubygems_version: 1.8.24
115
+ rubygems_version: 1.8.10
136
116
  signing_key:
137
117
  specification_version: 3
138
118
  summary: A lightweight cloud messaging system.