Interesting performance issue with high cardinality indexing

Try these tweaks to improve the regexp:

  1. Put anchors in your expression: /^web10009.*$/
  2. If you can’t use block anchors, use lazy quantifiers: /.*?web10009.*/
  3. Negate the regexp instead of the result inside filter: @filter(regexp(tagvalue_name,/^((?!web10009).)*$/)) {}

Let me know if these changes make any difference.

3 Likes