SES URLs in Jetty

Has anyone ever successfully implemented SES URLs in Jetty? I'm
running the latest stable Railo build on Jetty 7 on top of RHEL, using
the J2EE Tuckey Rewrite filter (UrlRewriteFilter - Rewrite URL's in Java Web Application Servers).

In general I want to take a URL that looks like "/index.cfm/ideas/
list" and have it translate as "/ideas/list." I've done this
successfully with Resin in the past.

However, it looks like ColdBox is expecting the requested path to be
put into CGI.PATH_INFO and I can't find a way to specify this in
Tuckey. Since ColdBox seems to have a way to configure everything, is
there a way to ask it to match based on a query string (which I CAN
assign) or another set of criteria or will it always look at

I tried a really basic rule in my config:

<!-- For now assign a URL variable containing the path info we
captured -->
<to last="true">/index.cfm?PATH_INFO=$1</to>
<!-- I thought this might set the CGI var but it doesn't -->
<set name="PATH_INFO">%{request-uri}</set>

I can confirm it's rewriting the URLs to index.cfm but they all come
back to the home page because (I'm guessing) ColdBox doesn't see the
path info it was trying to reach.

Has anyone made this work? Any advice is much appreciated.



I have not got to this yet, but it looks like jetty 7 has rewrite rules built in

Would be interested to hear how you get on with Jetty 7

Thanks AJ, I had heard nothing but Tuckey for URL rewriting with
Jetty. Hopefully this works with the Hightide distro Railo requires as
well, I'll have to play with it.

I'll let you know how Jetty works out once I have it running well.
ColdBox on Railo with Resin is super fast and smooth, I'm only trying
Jetty because a lot of features I need (Gzip, etc.) aren't in the free
version of Resin.

- William

I'll take a wild guess and say you'll probably run into the same issue
with the Jetty rewrites as you are with Tuckey. That's just a guess

One *awesome* feature of the Tuckey URLRewriteFilter is the ability to
rewrite outbound links. This allows you to implement the SES stuff
outside of the framework itself (and outside of whatever servlet
container you deploy on).

This technique is particularly suited for frameworked code, as any
framework worth it's salt has an abstracted way of building links, so
you usually only need to make the tweak for outbound rewrites in one
place. As long as you've leveraged this abstraction and refrained
from using hard-coded links. =)

For ColdBox, theoretically, the tweak would be to event.buildLink().
I've yet to test this approach with CB, but it's working fine for 3
other frameworks.

Eventually I'll ship a CB example with cfdistro-- I got sucked into
CFML parsing for CFE, so that'll still be a bit.


Also remember that coldbox allows you to build a context decorator. So you can easily expand the request context and mold it into submission according to your requirements.