-
Notifications
You must be signed in to change notification settings - Fork 33
Description
Logstash information:
- Logstash version: Tested in 7.16, 7.17 and 8.1
- Logstash installation source: From tar gz
- How is Logstash being run: Command line
- How was the Logstash Plugin installed: Installed by default in the tar package
JVM (e.g. java -version): Packaged version
OS version (uname -a if on a Unix-like system): 5.13.0-39-generic #44~20.04.1-Ubuntu SMP Thu Mar 24 16:43:35 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
Description of the problem including expected versus actual behavior:
Issue detected by using the input file. The input file seems to use the identity_map_codec from multiline codec.
The problem is sometimes a pipeline never stop. I analysed the issue by adding some logs and I notice that the pipeline is trapped in an infinite loop. This loop is located in the identity_map_codec.rb file in the stop method of the PeriodicRunner class:
def stop
return if !running?
@running.make_false
while @thread.alive?
begin
@thread.wakeup
rescue ThreadError
# thread might drop dead since the alive? check
else
puts "Before join"
@thread.join(0.1) # raises $! if there was any
puts "After join"
end
end
@listener = nil
endThe cause of the loop is the @running variable which is never changed to false. Unfortunately, I don't understand why the boolean stay to true :-(
Steps to reproduce:
This issue is random and so tricky to reproduce. I just create a pipeline in logstash with the file input and remove it from the pipeline.yml config file.