syslog-sd 1.2.3 → 1.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/CHANGELOG CHANGED
@@ -1,4 +1,7 @@
1
- 1.2.2, 2010-05-18:
1
+ 1.2.4, 2010-05-20:
2
+ * Fix a bug with SD-ID.
3
+
4
+ 1.2.3, 2010-05-18:
2
5
  + Allow to send timestamp as float if desired. It may improve server's parsing speed.
3
6
 
4
7
  1.2.2, 2010-05-17:
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.2.3
1
+ 1.2.4
@@ -197,7 +197,7 @@ module SyslogSD
197
197
  def serialize_sd
198
198
  return '-' if @hash.empty?
199
199
 
200
- res = "@sd_id"
200
+ res = @sd_id
201
201
  @hash.each_pair do |key, value|
202
202
  value = value.to_s.gsub(/([\\\]\"])/) { "\\#{$1}" }
203
203
  res += " #{key}=\"#{value}\""
data/syslog-sd.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{syslog-sd}
8
- s.version = "1.2.3"
8
+ s.version = "1.2.4"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = [%q{Alexey Palazhchenko}, %q{Lennart Koopmann}]
12
- s.date = %q{2011-05-18}
12
+ s.date = %q{2011-05-20}
13
13
  s.description = %q{Super-Duper library to send syslog messages over UDP to logging server such as Graylog2. Supports Structured Data elements as defined by RFC 5424.}
14
14
  s.email = %q{alexey.palazhchenko@gmail.com}
15
15
  s.extra_rdoc_files = [
@@ -122,10 +122,10 @@ class TestNotifier < Test::Unit::TestCase
122
122
  'msgid' => 'msgid'} => '<132>1 2010-05-16T12:13:14.0Z host facility 123 msgid - message',
123
123
  {'short_message' => 'message', 'level' => SyslogSD::WARN,
124
124
  'host' => 'host', 'facility' => 'facility', 'procid' => 123,
125
- 'msgid' => 'msgid', 'user_id' => 123} => '<132>1 2010-05-16T12:13:14.0Z host facility 123 msgid [@sd_id user_id="123"] message',
125
+ 'msgid' => 'msgid', 'user_id' => 123} => '<132>1 2010-05-16T12:13:14.0Z host facility 123 msgid [_@37797 user_id="123"] message',
126
126
  {'short_message' => 'message', 'level' => SyslogSD::WARN,
127
127
  'host' => 'host', 'facility' => 'facility', 'procid' => 123,
128
- 'msgid' => 'msgid', 'user_id' => '\\"]'} => '<132>1 2010-05-16T12:13:14.0Z host facility 123 msgid [@sd_id user_id="\\\\\"\]"] message'
128
+ 'msgid' => 'msgid', 'user_id' => '\\"]'} => '<132>1 2010-05-16T12:13:14.0Z host facility 123 msgid [_@37797 user_id="\\\\\"\]"] message'
129
129
  }
130
130
 
131
131
  expected.each_pair do |key, value|
@@ -139,7 +139,7 @@ class TestNotifier < Test::Unit::TestCase
139
139
  @notifier.timestamp_as_float = true
140
140
  hash = { 'short_message' => 'message', 'level' => SyslogSD::WARN, 'host' => 'host', 'facility' => 'facility', 'procid' => 123,
141
141
  'msgid' => 'msgid', 'user_id' => 123 }
142
- expected = '<132>1 1274011994.0 host facility 123 msgid [@sd_id user_id="123"] message'
142
+ expected = '<132>1 1274011994.0 host facility 123 msgid [_@37797 user_id="123"] message'
143
143
  @notifier.instance_variable_set('@hash', hash)
144
144
  assert_equal expected, @notifier.__send__(:serialize_hash)
145
145
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: syslog-sd
3
3
  version: !ruby/object:Gem::Version
4
- hash: 25
4
+ hash: 23
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 2
9
- - 3
10
- version: 1.2.3
9
+ - 4
10
+ version: 1.2.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - Alexey Palazhchenko
@@ -16,7 +16,7 @@ autorequire:
16
16
  bindir: bin
17
17
  cert_chain: []
18
18
 
19
- date: 2011-05-18 00:00:00 Z
19
+ date: 2011-05-20 00:00:00 Z
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
22
22
  name: shoulda