My JSON RPC server stopped working after apache config

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

My JSON RPC server stopped working after apache config

slah
This post was updated on .
Hi everybody,

I've built a json rpc server using the Delphi lang, I'm running it on port 7777.

I deployed the server to be used by my customers on domain, let's say www.mysever.com, apache is serving qooxdoo build of my application and the qooxdoo application is calling (qx.io.remote.Rpc) the json RPC server directly on port 7777 (www.mysever.com:7777).

Then I've noticed that customers who were behind firewalls were enable to access the rpc server, so I decided to use the proxy module of apache so www.mysever.com:7777 will be served as www.mysever.com/services/ and I'm using non cross domain queries now.

Everything went fine but queries returning date objects in the qooxdoo format: new Date(Data.UTC(...)) failed with abort exception. If I remove dates from result, queries work like a charm.

I'm using qooxdoo-1.6.1-sdk.

I've noticed that queries used to be a GET queries, now the method is POST.

Does anyone encountred such behavior before?

PS: please ask if you need more details

Regards,
Reply | Threaded
Open this post in threaded view
|

Re: My JSON RPC server stopped working after apache config

slah
This post was updated on .
When I set crossDomain to true, it uses GET method and works even with dates in result.

When crossDomain is false, it uses POST method and doesn't work (abort exception) when result contain dates.

Sample server output result: {result:{"values":[{"CODE":41566679,"LIB":"Extra Milk","DT":new Date(Date.UTC(2013,0,20,9,2,32,0))}]},"id":15}


slah wrote
Hi everybody,

I've built a json rpc server using the Delphi lang, I'm running it on port 7777.

I deployed the server to be used by my customers on domain, let's say www.mysever.com, apache is serving qooxdoo build of my application and the qooxdoo application is calling (qx.io.remote.Rpc) the json RPC server directly on port 7777 (www.mysever.com:7777).

Then I've noticed that customers who were behind firewalls were enable to access the rpc server, so I decided to use the proxy module of apache so www.mysever.com:7777 will be served as www.mysever.com/services/ and I'm using non cross domain queries now.

Everything went fine but queries returning date objects in the qooxdoo format: new Date(Data.UTC(...)) failed with abort exception. If I remove dates from result, queries work like a charm.

I'm using qooxdoo-1.6.1-sdk.

I've noticed that queries used to be a GET queries, now the method is POST.

Does anyone encountred such behavior before?

PS: please ask if you need more details

Regards,