|
From: Bill B. <bb...@re...> - 2013-01-18 13:54:39
|
I agree with Robert's earlier post, but are you sure this isn't Tomcat
barfing on you? There's really nothing I can do about that.
On 1/18/2013 5:23 AM, Dave Minter wrote:
>
> res...@li...
> <mailto:res...@li...>
>
> I'd like to use custom HTTP verbs with resteasy running under Tomcat. Is
> this possible? If it is possible is it sensible?
>
> I'm using resteasy 2.3.4.Final with Spring 3.1.2-RELEASE and I've
> created a custom HttpMethod annotation for the new verb:
>
> @Target({ ElementType.METHOD })
> @Retention(RetentionPolicy.RUNTIME)
> @HttpMethod("RESET")
> public @interface RESET {
> }
>
> Spring is configured in the servlet application context with the default
> resteasy config thus:
>
> <tx:annotation-driven />
> <import resource="classpath:springmvc-resteasy.xml" />
>
> The new method in the controller is implemented thus:
>
> @RESET
> @Path("/{uuid}")
> public void reset(@PathParam("uuid") final String uuid) {
> // Reset the model state...
> }
>
> My other controller methods work fine for the normal GET,PUT,POST,DELETE
> verbs but for the custom verb I get the following error message from Tomcat:
>
> HTTP Status 501 - Method RESET is not defined in RFC 2068 and is not
> supported by the Servlet API
>
> That message seems to be the same one that you get with a default
> servlet implementation so I presume I need to configure the
> ResteasyHandlerMapping somehow...?
>
>
>
> ------------------------------------------------------------------------------
> Master HTML5, CSS3, ASP.NET, MVC, AJAX, Knockout.js, Web API and
> much more. Get web development skills now with LearnDevNow -
> 350+ hours of step-by-step video tutorials by Microsoft MVPs and experts.
> SALE $99.99 this month only -- learn more at:
> http://p.sf.net/sfu/learnmore_122812
>
>
>
> _______________________________________________
> Resteasy-developers mailing list
> Res...@li...
> https://lists.sourceforge.net/lists/listinfo/resteasy-developers
>
--
Bill Burke
JBoss, a division of Red Hat
http://bill.burkecentral.com
|