I have an HTTP request looking like this:
Request URL:
http://127.0.0.1:8888/data/fetch/country
Request Method:
POST
Request Headers
Content-Type:
text/xml; charset=UTF-8
Origin:
http://127.0.0.1:8888
Referer:
http://127.0.0.1:8888/
User-Agent:
Mozilla/5.0 (X11; U; Linux x86_64; en-US) AppleWebKit/534.3 (KHTML,
like Gecko) Chrome/6.0.458.1 Safari/534.3
Request Payload
<request>
<data>
<isc_RestDataSource_0/>
</data>
<dataSource>isc_RestDataSource_0</dataSource>
<operationType>fetch</operationType>
<startRow>0</startRow>
<endRow>75</endRow>
<textMatchStyle>exact</textMatchStyle>
<componentId>isc_ListGrid_0</componentId>
<oldValues></oldValues>
</request>
And I have:
public class TableManagerService extends HttpServlet {
@Override
public void doPost(HttpServletRequest req, HttpServletResponse res)
throws IOException {
Document doc = null;
try {
DocumentBuilderFactory dbf =
DocumentBuilderFactory.newInstance();
DocumentBuilder db = dbf.newDocumentBuilder();
doc = db.parse(req.getInputStream());
} catch (ParserConfigurationException e) {
e.printStackTrace();
} catch (SAXException e) {
e.printStackTrace();
}
...
}
}
but doc is always empty.
Are the parameters accessed before the processing of doPost that would
cause the request to have empty content?
req.getContentType returns text/xml
req.getCharacterEncoding returns UTF-8
--
You received this message because you are subscribed to the Google Groups
"Google App Engine for Java" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-appengine-java?hl=en.