On Mon, Nov 14, 2016 at 8:51 AM, <lists@lazygranch.com> wrote:
> I'd be shocked if the map function doesn't use a smart search scheme
> rather than check every item.
>
You're in for a bit of a shock then. It is a linear search :p Curious as to
what you think it should look like instead?
Getting back to the original question though, a map should (_should_) be
faster than building a larger and larger regex, particularly if the map is
doing string comparison as opposed to regex searching for each map member.
Building large alternation-oriented regular expressions can get pretty
expensive rather quickly, though some of that will depend on the regex
engine and compile-time options (e.g, are you using PCRE JIT, etc).
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx