I implemented a wrapper web service that returns a string with a call to
qx.io.remote.transport.Script._requestFinished.

And made a simple test with the following code:

url = "http://localhost:8080/sparql/resources/sparql/update";;
req = new qx.io.remote.Request(url, "GET", "application/json");
req.setParameter("id", "10");
req.setCrossDomain(true);
req.addListener("completed", function(e) {
                                     alert(e.getContent());       
                                 });
req.send();

I get these timeout tmessages on the chrome console (similar with
firefox4+firebug):

001214 qx.core.Init: Load runtime: 1214ms
Native.js:91001285 qx.core.Init: Main runtime: 65ms
Native.js:91001476 qx.core.Init: Finalize runtime: 190ms
update:-1Resource interpreted as Script but transferred with MIME type
application/json.
Native.js:91020281 qx.io.remote.RequestQueue[509]: Timeout: transport 511
Native.js:91020283 qx.io.remote.RequestQueue[509]: 5021ms > 5000ms
Native.js:91020285 qx.io.remote.Exchange[511]: Timeout: implementation 512,
http://localhost:8080/sparql/resources/sparql/update [GET],
&nocache=1304821602481&id=10

My Java code that returns the string with the callback is:

String result = "'qx.io.remote.transport.Script._requestFinished(" + id +
"," + updateResult + ");'";

What should be the MIME type for the request?  I am using application/json
but in fact the request returns the jsonp which is application/javascript.

I have no idea what may be causing the timeouts because I can invoke the web
service directly from the browser with no problems and it returns the
expected result:

'qx.io.remote.transport.Script._requestFinished(10,{"head":{"link":[],"vars":["callret-0"]},"results":{"bindings":[{"callret-0":{"type":"literal","value":"Insert
into <http://mydomain.com>, 1 (or less) triples --
done"}}],"distinct":false,"ordered":true}});'

--
View this message in context: 
http://qooxdoo.678.n2.nabble.com/problem-with-AJAX-request-tp6340301p6341148.html
Sent from the qooxdoo mailing list archive at Nabble.com.

------------------------------------------------------------------------------
WhatsUp Gold - Download Free Network Management Software
The most intuitive, comprehensive, and cost-effective network 
management toolset available today.  Delivers lowest initial 
acquisition cost and overall TCO of any competing solution.
http://p.sf.net/sfu/whatsupgold-sd
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to