VictoriaMetrics/lib/regexutil
Aliaksandr Valialkin 3e93fa61ad
lib/regexutil: properly handle alternate regexps surrounded by .+ or .*
Previously the following regexps were improperly handled:

  .+foo|bar.+
  .*foo|bar.*

This could lead to unexpected regexp match results.

See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5297

Thanks to @Haleygo for the initial attempt to fix the issue at https://github.com/VictoriaMetrics/VictoriaMetrics/pull/5308
2023-11-13 18:23:38 +01:00
..
promregex_test.go lib/regexutil: properly handle alternate regexps surrounded by .+ or .* 2023-11-13 18:23:38 +01:00
promregex_timing_test.go all: consistently use %w instead of %s in when error is passed to fmt.Errorf() 2023-10-25 21:24:03 +02:00
promregex.go lib/regexutil: properly handle alternate regexps surrounded by .+ or .* 2023-11-13 18:23:38 +01:00
regexutil_test.go lib/regexutil: properly handle alternate regexps surrounded by .+ or .* 2023-11-13 18:23:38 +01:00
regexutil.go lib/promrelabel: properly parse regex with escaped $ at the end 2022-09-30 08:15:43 +03:00