comments inline...
Paul Sandoz wrote:
> Peter Liu wrote:
>> BTW, this is what's causing the 406 (unacceptable) status code I
>> mentioned before since we don't
>> know the media type.
>>
>
> But for a 406 response are you still getting the representation
> returned? If so that is another bug.
Server did not return the representation on 406 response.
>
> If you don't specify any content type in the request then the runtime
> should choose one for you [*].
I think the jersey REST impl behaviour is appropriate, since the test
client (due to a bug in it, which I fixed it) was sending 'GET'
as the content-type.
>
> Paul.
>
> [*] Not that since the xml and json are equally valid it is not clear
> which one takes precendence. It is planned to implement the quality
> parameter, 'q', so that it is possible to prefer XML over JSON.
Thanks
Ayub
>>
>> Peter
>>
>> Ayub Khan wrote:
>>> Hi Marc/Paul,
>>>
>>> I am using latest GF b55 with jersey 0.2. Using latest REST tooling
>>> source, I am seeing the following in generated wadl
>>> file.
>>>
>>> <application xmlns="http://research.sun.com/wadl/2006/10">
>>> <resources base="%%REPLACE%%/resources">
>>> <resource path="/customers/">
>>> <method name="GET">
>>> <response>
>>> <representation/>
>>> </response>
>>> </method>
>>> <method name="GET">
>>> <response>
>>> <representation/>
>>> </response>
>>> </method>
>>> ...
>>> instead of
>>>
>>> <application xmlns="http://research.sun.com/wadl/2006/10">
>>> <resources base="%%REPLACE%%/resources">
>>> <resource path="/customers/">
>>> <method name="GET">
>>> <response>
>>> <representation mediatype="application/xml"/>
>>> </response>
>>> </method>
>>> <method name="GET">
>>> <response>
>>> <representation mediatype="application/json"/>
>>> </response>
>>> </method>
>>> ...
>>>
>>> This is same for POST too.
>>>
>>> Attached is the application.wadl and the CustomerResource.java
>>>
>>> Thanks
>>> Ayub
>>> ------------------------------------------------------------------------
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: dev-unsubscribe_at_jersey.dev.java.net
>>> For additional commands, e-mail: dev-help_at_jersey.dev.java.net
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe_at_jersey.dev.java.net
>> For additional commands, e-mail: dev-help_at_jersey.dev.java.net
>>
>