Where can i learning the official grammar of ruby code which apply in logstash script

Hi experts,

Would you please provide some materials or WEB Link for me that include the introduction of grammar of ruby code which apply in logstash script.

Such like this:

ruby {
    code => 'event.get("message").scan(/loc[A-Z]{4}/).each {|loc| event.tag(loc)}'
}

ruby {
 event.set('except_fcn_trace', event.get('except_fcn_trace').delete(' ').scan(/.{16}/).join(' '))
}

I just want to know how many event function(.get .set .scan . delete) defined and how to use them in logstash.

Thank you.

.get and .set are part of the logstash event API. .scan and .delete are functions of a Ruby string.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.