users@jersey.java.net

Re: [Jersey] What is the "Container-Containee" Error?

From: Paul Sandoz <Paul.Sandoz_at_Sun.COM>
Date: Mon, 26 Jan 2009 11:09:14 +0100

Hi David,

I tried using NetBeans 6.5 with a test case similar to that you
presented and could see stuff i POSTed in the Raw View if i just send
some simple text (non-XML) but for XML it seems to require that an XML
header be present e.g. <?xml version="1.0" encoding="UTF-8"?>, and the
HTTP monitor does not show such content if the XML header is not
present, otherwise it does.

So i cannot reproduce exactly what you described.

What version are you using?

Bugs against NBs can be logged here:

http://www.netbeans.org/issues/enter_bug.cgi?component=websvc

using "rest" as the subcomponent.

Paul.

On Jan 23, 2009, at 8:43 PM, Woodbury David-R28558 wrote:

> Hello:
>
> I'm trying to create a web-service that accepts an XML string and
> returns an XML string, similar to XML-RPC.
>
> The code fragment I'm using to learn about Jersey is the following:
>
> @POST
> @Path("/v1/post")
> @ConsumeMime("text/xml")
> @ProduceMime("text/xml")
> public String postXML(String content) {
> return content;
> }
>
> When I test this within NetBeans using the "Test Restful Web-
> Services" facility, I get the following errors:
>
> Under "Tabular View" - Content may not have Container-Containee
> Relationship. See Raw View for content.
> Under "Raw View" - Post failed: Server returned --> Status: (200)
> Response: {Insert content here.}
>
> However, the HTTP Monitor tab shows a message exchange that seems
> fine.
>
> Can someone explain what these errors mean and if it they are
> significant? It seems to me that the post succeeded.
>
> Thank you.
>
> David Woodbury
>