Steps to Reproduce: Run Logstash 6.4+ version on Korean Windows.
Description:
When I execute logstash-plugin list command, I got the following error ArgumentError: invalid byte sequence in CP949.
2020-06-30T09:54:10.644+09:00 [main] WARN FilenoUtil : Native subprocess control requires open access to sun.nio.ch
Pass '--add-opens java.base/sun.nio.ch=org.jruby.dist' or '=org.jruby.core' to enable.
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.jruby.ext.openssl.SecurityHelper (file:/C:/logstash-7.8.0/vendor/jruby/lib/ruby/stdlib/jopenssl.jar) to field java.security.MessageDigest.provider
WARNING: Please consider reporting this to the maintainers of org.jruby.ext.openssl.SecurityHelper
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
ArgumentError: invalid byte sequence in CP949
split at org/jruby/RubyString.java:4218
set_path at C:/logstash-7.8.0/vendor/bundle/jruby/2.5.0/gems/bundler-1.17.3/lib/bundler/shared_helpers.rb:329
set_bundle_environment at C:/logstash-7.8.0/vendor/bundle/jruby/2.5.0/gems/bundler-1.17.3/lib/bundler/shared_helpers.rb:90
setup at C:/logstash-7.8.0/vendor/bundle/jruby/2.5.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:22
setup at C:/logstash-7.8.0/vendor/bundle/jruby/2.5.0/gems/bundler-1.17.3/lib/bundler.rb:107
setup! at C:/logstash-7.8.0/lib/bootstrap/bundler.rb:77
execute at C:/logstash-7.8.0/lib/pluginmanager/list.rb:33
run at C:/logstash-7.8.0/vendor/bundle/jruby/2.5.0/gems/clamp-0.6.5/lib/clamp/command.rb:67
execute at C:/logstash-7.8.0/vendor/bundle/jruby/2.5.0/gems/clamp-0.6.5/lib/clamp/subcommand/execution.rb:11
run at C:/logstash-7.8.0/vendor/bundle/jruby/2.5.0/gems/clamp-0.6.5/lib/clamp/command.rb:67
run at C:/logstash-7.8.0/vendor/bundle/jruby/2.5.0/gems/clamp-0.6.5/lib/clamp/command.rb:132
<main> at C:\logstash-7.8.0\lib\pluginmanager\main.rb:64
logstash-plugin list
command, I got the following errorArgumentError: invalid byte sequence in CP949
.Some KR Ruby users reported a similar issue and it seems related to KR Windows and Ruby 1.9+. https://groups.google.com/u/1/g/rubykr/c/NMsPJ9ZjMN0/m/n1NPSOSmNhEJ
If I inserting
set JRUBY_OPTS=-J-Dfile.encoding=UTF-8
in top oflogstash-plugin.bat
, it works well.