Forum Discussion
Pconlan_71037
Apr 11, 2011Altocumulus
Yes. We do something like this:
when HTTP_REQUEST {
use tolower to make the match case-insensitive
switch -glob [string tolower [HTTP::path]] {
"/images/*" {
pool ImagesPool
}
"/js/*" {
pool JsPool
}
etc.
etc.
default {
pool defaultPool
}
}
}
The URI gets compared to the strings you specify, and if it matches, the request gets sent to specified pool. If it doesn't match any of them it falls through to the pool specified in the default clause.