Hello list, I've about 5000 hostnames + path that should be mapped to 3000 
backends or so. I'm using map converters and the lay out is something like this:

/dir/file.map
    d1.tld/path/sub back1
    d1.tld/path back2
    d2.tld/path/sub/other back3
    d2.tld/path/sub back4
    d2.tld/path back5
    d3.tld/path/sub back6
    d3.tld/path back7

And frontend looks like this:

    http-request set-var(req.backend) base,map_beg(/dir/file.map)
    use_backend %[var(req.backend)] if { var(req.backend) -m found }

The problem here is that the map has about 5k lines and the search isn't 
indexed. I could eg split this map into smaller ones and create an index of 
maps stored in another map, but cannot use the result because the file name 
param in the converter cannot be dynamic. Any other idea to help haproxy find 
the backend in a faster way?

~jm


Reply via email to