Hi, everyone!
I can not encode with utf-8.
logstash filter:
urldecode { field => "kw_nm" }
ruby {
code => "
kw_nm = event.get('kw_nm')
kw_nm.force_encoding('ISO-8859-1').encode('UTF-8')
event.set('enc_kw_nm', kw_nm)
end
"
}
error code:
[2019-01-29T20:07:08,692][WARN ][logstash.filters.urldecode] Received an event that has a different character encoding than you configured. {:text=>"\xB5\xB5\xB8\xB6", :expected_charset=>"UTF-8"}
Can you give me a code example?