Thanks for Compojure, it's a nice library! We're using it for routing in a web server that partially serves content itself, and partially proxies it to another server. That other server is unfortunately (somewhat) case insensitive when it comes to paths. We want to give some of the URLs special treatment using extra middleware for example. Is there a way to specify routes in compojure that have case insensitive path?
This returns 403 for "/bla/specialPath", but passes the request on when it is sent as "/bla/SpecialPath".
I was thinking of something like (GET #"(?i)/specialPath" [] {:status 403}) but regexes don't work in this context apparently, also not when using clout directly.
Hi,
Thanks for Compojure, it's a nice library! We're using it for routing in a web server that partially serves content itself, and partially proxies it to another server. That other server is unfortunately (somewhat) case insensitive when it comes to paths. We want to give some of the URLs special treatment using extra middleware for example. Is there a way to specify routes in compojure that have case insensitive path?
For example:
This returns 403 for "/bla/specialPath", but passes the request on when it is sent as "/bla/SpecialPath".
I was thinking of something like
(GET #"(?i)/specialPath" [] {:status 403})
but regexes don't work in this context apparently, also not when using clout directly.