How to write logical or(||) in logstash


How can I write a logical or operator for two values?

I've tried if [type] == "test-request" || [type] == "test1-request" but this gives me a syntax error.
I want it to work on how a logical OR operator works. If type value matches either one then true else false.

Use the word or

sorry for the trouble. Got confused going through multiple documents.

Ruby logical operator on tutorialspoint gives another description of how "or" is used. so I wasn't sure if that works.

"Called Logical OR Operator. If any of the two operands are non zero, then the condition becomes true."

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