无法解析msgpack输入,无法返回纯文本

时间:2019-04-04 08:44:41

标签: logstash msgpack

通过kafka传入的数据在msgpack中编码,因此我尝试使用编解码器对其进行解压缩。 但是,会发生以下错误。

  • config
input {
kafka {
    zk_connect => "localhost:2181"
    topic_id => "topic"
    group_id => "test"
    codec => "msgpack"
    }
}

output {
 stdout {      }
}
  • 错误
[FATAL][logstash.runner          ] An unexpected error occurred! {:error=>#<NoMethodError: undefined method `set' for nil:NilClass....

Did you mean? send&gt;, :backtrace=&gt;["/home/logstash/logstash-6.5.4/vendor/bundle/jruby/2.3.0/gems/logstash-codec-msgpack-3.0.7-java/lib/logstash/codecs/msgpack.rb:36:in `decode'", "/home/logstash/logstash-6.5.4/vendor/bundle/jruby/2.3.0/gems/logstash-input-kafka-8.2.1/lib/logstash/inputs/kafka.rb:256:in `block in thread_runner'", "/home1/logstash/logstash-6.5.4/vendor/bundle/jruby/2.3.0/gems/logstash-input-kafka-8.2.1/lib/logstash/inputs/kafka.rb:255:in `block in thread_runner'"]}```

Thanks,

0 个答案:

没有答案