users@jersey.java.net

[Jersey] Any built-in for support for forcing media type with Uri elements like a path suffix?

From: jaxzin <Brian.R.Jackson_at_espn3.com>
Date: Sun, 16 Aug 2009 00:55:30 -0500 (CDT)

So I'd like my resources to support path suffixes like '.xml' and '.json' to
make is simpler for users to choose their response format without needing to
set the Accept header properly. Is there anything similar built into
Jersey such as a query param it looks for or something? I'm willing to go
with an turn-key solution even if its differs from my path suffix idea. Any
other good ideas? I'd like to do it transparently without changes to my
resource classes such as accomplishing it with a Provider implementation or
some other configuration setting.

Thanks,
Brian

P.S. Another 'real world' reason I need to skip out on the Accept header is
that our page caching solution is know to have trouble with caching properly
when requests to the same URL differ by the Accept header. (In case anyone
was ready to reply "Don't do that") :-)
-- 
View this message in context: http://n2.nabble.com/Any-built-in-for-support-for-forcing-media-type-with-Uri-elements-like-a-path-suffix--tp3452599p3452599.html
Sent from the Jersey mailing list archive at Nabble.com.