Logstash 8.10+ versions fail with (Errno::ENOENT) No such file or directory error. It is happening after Ruby 2.6 to Ruby 3.1 upgrade through JRuby.
As a solution, it seems there are multiple discussions (1, 2) and current solution is to change open to URI.open
Description
Logstash 8.10+ versions fail with
(Errno::ENOENT) No such file or directory
error. It is happening after Ruby 2.6 to Ruby 3.1 upgrade through JRuby. As a solution, it seems there are multiple discussions (1, 2) and current solution is to changeopen
toURI.open
Test
kafka-output
plugin withavro-codec
output { stdout { codec => rubydebug } kafka { bootstrap_servers => "192.168.1.66:9092" codec => avro { schema_uri => "http://127.0.0.1:8081/my-schema"
schema_uri => "/static/avro-sample.xml"
}
[2023-10-13T11:01:11,713][DEBUG][logstash.plugins.registry] On demand adding plugin to the registry {:name=>"avro", :type=>"codec", :class=>LogStash::Codecs::Avro} [2023-10-13T11:01:11,714][DEBUG][logstash.codecs.avro ] config LogStash::Codecs::Avro/@encoding = "binary" [2023-10-13T11:01:11,714][DEBUG][logstash.codecs.avro ] config LogStash::Codecs::Avro/@schema_uri = "/Users/mashhur/Dev/elastic/temp/simple-nodejs/static/avro-sample.xml" [2023-10-13T11:01:11,715][DEBUG][logstash.codecs.avro ] config LogStash::Codecs::Avro/@id = "96ef7bd9-34cc-4a71-b184-c6087411fa3c" [2023-10-13T11:01:11,715][DEBUG][logstash.codecs.avro ] config LogStash::Codecs::Avro/@enable_metric = true [2023-10-13T11:01:11,715][DEBUG][logstash.codecs.avro ] config LogStash::Codecs::Avro/@tag_on_failure = false