Logstash if any array element exists in [tags]

You have to do this:

if "element1" in [tags] or "element2" in [tags] or "element3" in [tags] {