Issues
- org.jruby.exceptions.JumpException$BreakJump in /logstash/inputs/ganglia.rb:38LOGSTASH-1655Resolved issue: LOGSTASH-1655Jordan Sissel
- Using lumberjack to connect two logstash instances hangs after 4999 events are transmittedLOGSTASH-1570Logstash Developers
- Redis output pluginLOGSTASH-1544Logstash Developers
- Plugin path doesn't allow codec pluginsLOGSTASH-1495Resolved issue: LOGSTASH-1495Logstash Developers
- unexpected error..."...probably a bug... Illegal pattern component: l"LOGSTASH-1487Philippe Weber
- 1.2.x Conditional + split/clone events is currently brokenLOGSTASH-1477Resolved issue: LOGSTASH-1477Logstash Developers
- sample_rate parameter does not work for statsd outputLOGSTASH-1441Resolved issue: LOGSTASH-1441Jordan Sissel
- X-Frame-Options defaults setting prevents kibana from being embedded in an iFrameLOGSTASH-1418Resolved issue: LOGSTASH-1418Philippe Weber
- Error message: "code converter not found (ASCII-8BIT to UTF-8)"LOGSTASH-1411Resolved issue: LOGSTASH-1411Logstash Developers
- "in" operator is not working in conditionalsLOGSTASH-1403Resolved issue: LOGSTASH-1403Logstash Developers
- Watchdog no longer functions in logstash 1.2.1 (and 1.2.0)LOGSTASH-1401Logstash Developers
- Mongodb output plugin fails with authenticationLOGSTASH-1371Resolved issue: LOGSTASH-1371Jordan Sissel
- New Config Hash Rocket Syntax does not pass syntax check for Grok FilterLOGSTASH-1358Resolved issue: LOGSTASH-1358Philippe Weber
- Logstash printing to stdout even with logfile specifiedLOGSTASH-1348Resolved issue: LOGSTASH-1348Logstash Developers
- If filter replaces @timestamp with a string flushing of event failsLOGSTASH-1340Resolved issue: LOGSTASH-1340Logstash Developers
- Empty plugin directory causes logstash to exitLOGSTASH-1324Resolved issue: LOGSTASH-1324Richard Pijnenburg
- Filter plugins applied to the input after the Split plugin are skipped on Logstash 1.2.xLOGSTASH-1312Resolved issue: LOGSTASH-1312Colin Surprenant
- format => json_event doesn't work correctly (backwards compatibility)LOGSTASH-1309Resolved issue: LOGSTASH-1309Logstash Developers
- Source sequence is illegal/malformed utf-8LOGSTASH-1308Jordan Sissel
- Logstash fails with ERROR: too many argumentsLOGSTASH-1307Resolved issue: LOGSTASH-1307Jordan Sissel
- Native ES output can become a master in the clusterLOGSTASH-1304Resolved issue: LOGSTASH-1304Logstash Developers
- ES mapping for GELF input data not correct (user fields)LOGSTASH-1303Resolved issue: LOGSTASH-1303Logstash Developers
- Failed to flush outgoing itemsLOGSTASH-1302Resolved issue: LOGSTASH-1302Jason Kendall
- Add posibility to remove namespaces in xml filterLOGSTASH-1301Resolved issue: LOGSTASH-1301Philippe Weber
- RabbitMQ input using HotBunny driver do not bind the queue to the exchangeLOGSTASH-1300Resolved issue: LOGSTASH-1300Jordan Sissel
- malformed JSON causes codec looping "unrecoverable error"LOGSTASH-1299Resolved issue: LOGSTASH-1299Piotr Popieluch
- elasticsearch_river uses undefined function receive_rawLOGSTASH-1298Resolved issue: LOGSTASH-1298Logstash Developers
- Unable to use Multiline FilterLOGSTASH-1297Resolved issue: LOGSTASH-1297Jordan Sissel
- json_encode exception (undefined local variable or method `key')LOGSTASH-1296Resolved issue: LOGSTASH-1296Jordan Sissel
- Timestamp fails by default, with codec/multiline it works fineLOGSTASH-1295Resolved issue: LOGSTASH-1295Jordan Sissel
- SQS output plugin cannot access queueLOGSTASH-1294Resolved issue: LOGSTASH-1294Former user
- Can't stop Logstash with a UDP inputLOGSTASH-1290Resolved issue: LOGSTASH-1290Jordan Sissel
- TCP adds empty event on EOFLOGSTASH-1289Resolved issue: LOGSTASH-1289Jordan Sissel
- Events shipped by lumberjack are agitatedLOGSTASH-1288Resolved issue: LOGSTASH-1288Logstash Developers
- CSV fileLOGSTASH-1287Jason Kendall
- "nil is not a string" error with logstash 1.2 on shipper.LOGSTASH-1286Resolved issue: LOGSTASH-1286Jordan Sissel
- Multiline changing from a filter to a codec breaks my Cisco ACS configLOGSTASH-1285Resolved issue: LOGSTASH-1285Logstash Developers
- Metrics filter is brokenLOGSTASH-1284Resolved issue: LOGSTASH-1284Logstash Developers
- Field "type" is empty all the timeLOGSTASH-1283Resolved issue: LOGSTASH-1283Logstash Developers
- Weird behavior of "multiline" codecLOGSTASH-1282Resolved issue: LOGSTASH-1282Logstash Developers
- Using "nxlog" to send Windows EventLogs causes "source sequence is illegal/malformed utf-8"-crashLOGSTASH-1280Resolved issue: LOGSTASH-1280Jordan Sissel
- Missing "-t"/"--configtest" optionLOGSTASH-1279Resolved issue: LOGSTASH-1279Jordan Sissel
- Output thread not namedLOGSTASH-1275Resolved issue: LOGSTASH-1275Logstash Developers
- Logging to log file breaks in 1.2.0LOGSTASH-1274Resolved issue: LOGSTASH-1274Jordan Sissel
- Logstash 1.2.0 daily builds failLOGSTASH-1209Resolved issue: LOGSTASH-1209Logstash Developers
- logstash 1.2.0 documentation tasksLOGSTASH-1163Resolved issue: LOGSTASH-1163Logstash Developers
org.jruby.exceptions.JumpException$BreakJump in /logstash/inputs/ganglia.rb:38
Description
Gliffy Diagrams
Activity
Former user December 3, 2013 at 12:22 PM
That does fix the bug originally reported, but it leads to a plugin that does not work.
The other changes fix the root cause of the error (the reference to the non-existent variable, "source") and the run method that starts a thread and then returns, which causes the input worker to call terminate on the plugin before it has even started!
That gets the plugin to run, but output incorrect information.
The remaining changes fix the broken functionality.
Jordan Sissel December 3, 2013 at 4:57 AM
Should be fixed in next release
Jordan Sissel December 3, 2013 at 4:44 AM
Jordan Sissel December 3, 2013 at 2:14 AM
The 'break if ...' on line 42 (in v1.2.2) is the problem. Changing this to simply use another means to abort than 'break' (which isn't valid at all in this case)
Former user December 2, 2013 at 11:27 PMEdited
OK. This patch seems to work pretty good:
diff --git a/lib/logstash/inputs/ganglia.rb b/lib/logstash/inputs/ganglia.rb
index f491fc9..f7e9ced 100644
--- a/lib/logstash/inputs/ganglia.rb
+++ b/lib/logstash/inputs/ganglia.rb
@@ -24,7 +24,6 @@ class LogStash::Inputs::Ganglia < LogStash::Inputs::Base
public
def initialize(params)
super
- @shutdown_requested = false
BasicSocket.do_not_reverse_lookup = true
end # def initialize
@@ -34,20 +33,8 @@ class LogStash::Inputs::Ganglia < LogStash::Inputs::Base
public
def run(output_queue)
- # udp server
- Thread.new do
- begin
- udp_listener(output_queue)
- rescue => e
- break if @shutdown_requested
- @logger.warn("ganglia udp listener died",
- :address => "#{@host}:#{@port}", :exception => e,
- :backtrace => e.backtrace)
- sleep(5)
- retry
- end # begin
- end # Thread.new
-
+ # udp server retries, exceception handling/logging all happens upstairs.
+ udp_listener(output_queue)
end # def run
private
@@ -67,8 +54,9 @@ class LogStash::Inputs::Ganglia < LogStash::Inputs::Base
loop do
packet, client = @udp.recvfrom(9000)
# TODO(sissel): make this a codec...
- e = parse_packet(packet,source)
+ e = parse_packet(packet)
unless e.nil?
+ decorate(e)
e["host"] = client[3] # the IP address
output_queue << e
end
@@ -81,7 +69,6 @@ class LogStash::Inputs::Ganglia < LogStash::Inputs::Base
public
def teardown
- @shutdown_requested = true
close_udp
finished
end
@@ -96,7 +83,7 @@ class LogStash::Inputs::Ganglia < LogStash::Inputs::Base
end
public
- def parse_packet(packet,source)
+ def parse_packet(packet)
gmonpacket=GmonPacket.new(packet)
if gmonpacket.meta?
@@ -116,11 +103,18 @@ class LogStash::Inputs::Ganglia < LogStash::Inputs::Base
event=LogStash::Event.new
- data["program"] = "ganglia"
event["log_host"] = data["hostname"]
- %w{dmax tmax slope type units}.each do |info|
+ # Fields in the data packet itself
+ %w{name spoof format val}.each do |info|
+ event[info] = data[info]
+ end
+ # Fields that are from MetaData
+ %w{dmax tmax slope units}.each do |info|
event[info] = @metadata[data["name"]][info]
end
+ # Change the Ganglia type to dtype, so it can be decorated later.
+ event["dtype"] = @metadata[data["name"]]["type"]
+ # Let it rip!
return event
else
# Skipping unknown packet types
I get this as a JSON event:
{"@timestamp":"2013-12-02T23:25:00.726Z","@version":"1","log_host":"XXXX.com","name":"metricssystem.MetricsSystem.snapshot_num_ops","spoof":0,"format":"%s","val":8.407790785948902e-45,"dmax":0,"tmax":60,"slope":"positive","units":"","dtype":"float","type":"tasktracker-metrics2","host":"127.0.0.1"}
Not perfect. The blank units field is troubling.
I am getting:
Exception in thread "RubyThread-5: file:/opt/logstash/agent/lib/logstash-1.2.2-flatjar-backtrace.jar!/logstash/inputs/ganglia.rb:38" org.jruby.exceptions.JumpException$BreakJump
when trying to process the first ganglia packet in version 1.2.X . It used to work fine with version 1.1.13 .
I have filed a bug with the JRUBY folks at https://github.com/jruby/jruby/issues/1268 since I suspect there is a problem in JRUBY.