RE: Re: @Post not handling multiple variants properly?

2013-02-26 Thread Jon Sawyer
Thank you, Thierry. I added a comment to the ticket describing my workaround 
(though it's probably obvious).

--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=3049873


Re: @Post not handling multiple variants properly?

2013-02-26 Thread Thierry Boileau
Hello Jon,

thanks for reporting this issue. I've entred a new ticket for this :
https://github.com/restlet/restlet-framework-java/issues/733

Best regards,
Thierry Boileau


2013/2/16 Jon Sawyer 

> I have a Restlet ServerResource method annotated with @Post("multipart").
> It works fine that way. I change only the annotation to
> @Post("multipart|xml"), and now I get "Unsupported Media Type - The server
> is refusing to service the request because the entity of the request is in
> a format not supported by the requested resource for the requested method".
> Why would *adding* a handled mediatype stop the previously working
> mediatype from working?
>
> I have also tried @Post("multipart:html|xml"), because HTML is what the
> client is requesting, but this fails with the same error.
>
> I do have a converter for multipart form data in effect, and that is the
> type of data I'm submitting via POST.
>
> I turned up global logging to FINEST to try understand how Restlet
> searches for the handler for a particular meditype, but apparently that
> code isn't instrumented with logging. That in itself I would consider a
> minor bug.
>
> This is Restlet 2.1.1, GAE edition.
>
> --
>
> http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=3049012
>

--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=3049855

@Post not handling multiple variants properly?

2013-02-16 Thread Jon Sawyer
I have a Restlet ServerResource method annotated with @Post("multipart"). It 
works fine that way. I change only the annotation to @Post("multipart|xml"), 
and now I get "Unsupported Media Type - The server is refusing to service the 
request because the entity of the request is in a format not supported by the 
requested resource for the requested method". Why would *adding* a handled 
mediatype stop the previously working mediatype from working?

I have also tried @Post("multipart:html|xml"), because HTML is what the client 
is requesting, but this fails with the same error.

I do have a converter for multipart form data in effect, and that is the type 
of data I'm submitting via POST.

I turned up global logging to FINEST to try understand how Restlet searches for 
the handler for a particular meditype, but apparently that code isn't 
instrumented with logging. That in itself I would consider a minor bug.

This is Restlet 2.1.1, GAE edition.

--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=3049012