tags:

views:

500

answers:

2

My Flex application does a remote call to weborb to save some data from Flex. When this data is saved, a service is called on another server. All this time Flex is waiting for an answer.

Is it possible to call this service (on the other server) and not wait for an answer. I have tried to call the service asynchronous but all this does is calling the service in a different thread. Flex still has to wait for both threads to be finished...

Any ideas? So when the data is saved, flex should get its answer. (while the thread handling the service is still running).

+1  A: 

There really isn't anything you can do on the service side. Services over the web can be asynchronous in that they will return a token to you which you can then query the status of later, but generally, they are not asynchronous.

Which means that when you make an async call on a client to a web service, you have to spawn another thread and then make the call, and wait for the response on that thread.

If you want to make a call to another service and perform some work, the only option you have is to spawn another thread on the client. If you don't care about the result, then don't Join (or Flex's equivalent) on that thread, but I assume you care somewhat about the result.

casperOne
Interesting and it seems logic. I thought it would be possible to detach the second thread from the first thread. I will try to find a solution from Flex. The real problem is that I do not care about the result, so I do not want Flex to wait for an answer.
Lieven Cardoen
+1  A: 

Hi,

Are you able to implement asnchronous event in your application? I also want to implement same. I am developing web based Agent application for call center. When agent clicks on ClickToCall button my script got intiated and send back response to client. Now when customer answers the call my server component receives CallAnswered event (CallBack) from Call SDK. Now I want to send this event to respective client.

Using AJAX is one way but it's not asynchronous.

Regards, Umesh

Umesh Chaurasia
No, haven't found how to do it. Luckily, in a few seconds, I get the answer, so that's acceptable. But I still would like to know if it's possible.
Lieven Cardoen