users@grizzly.java.net

Re: Grizzly 2 + Guice + Jersey

From: Christopher Piggott <cpiggott_at_gmail.com>
Date: Thu, 7 Jun 2012 17:03:32 -0400

Ahh, nuts.

I think I figured it out. This did not work:

                http://localhost:8890/test

so I tried changing the context to this:

                WebappContext ctx = new WebappContext("hub", "/crap");

then, this worked:

                http://localhost:8890/crap/test

but I don't want that, I want it at the root. So I changed it back to this:

                WebappContext ctx = new WebappContext("hub", "/");


and discovered that this worked:

                http://localhost:8890//test


so then I tried, somewhat randomly, an empty context path:

                WebappContext ctx = new WebappContext("hub", "/");

and, holy smokes, this now works:

                http://localhost:8890/test

That wasn't obvious to me AT ALL.

I'm sorry to spam the list, but I want this documented for others.
I'll try to pull together a concise blog post about it tonight.

--Chris