Re: JSON w/ REST

2007-05-19 Thread Thilina Gunarathne



Mapped formatted JSON with namespaces are not supported in Axis2.
Make sure that your request doesn't include namespaces or use the
Badgerfish convention



Badgerfish & Mapped are two JSON to XML conversion conventions..
Badgerfish supports namespaces while Mapped convention does not
support namespaces.

Please try changing your "application/json" message formatter
specified in the axis2.xml to
JSONBadgerfishMessageFormatter as given below...

   
   
   
   

Thanks,
Thilina

PS: For more information refer to JSON Support for Apache Axis2
(http://wso2.org/library/768)


thx

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Thilina Gunarathne  -  http://www.wso2.com - http://thilinag.blogspot.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



JSON w/ REST

2007-05-19 Thread Jian Zhen

Hi, I was wondering if anyone's got JSON and REST working together.

I would like to send in a REST request and have the response be sent  
in JSON.


I took the version sample and added the following two lines:

--- cut here ---
MessageContext mc = MessageContext.getCurrentMessageContext 
().getOperationContext().getMessageContext 
(WSDLConstants.MESSAGE_LABEL_OUT_VALUE);
mc.setProperty(Constants.Configuration.MESSAGE_TYPE, "application/ 
json");

--- cut here ---

What I got back was the following error:



Mapped formatted JSON with namespaces are not supported in Axis2.  
Make sure that your request doesn't include namespaces or use the  
Badgerfish convention




Any idea what might be the problem?

thx

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]