Asynchronous operations in Custom Events

It appears the preferred architecture for server-side Custom Event handlers that must return result data is synchronous. In particular if one needs to query the Data Service in a Custom Event, one uses the synchronous form of the Backendless.Persistence.of( T ).find() and returns the result of that as the return value for the CustomEvent handleEvent() method.

In some applications one may want to launch multiple queries to the Data Service. Here one could launch multiple asyncrhronous queries and handle the callbacks as needed to finally get the desired results.

Is there an asynchronous form of the Custom Event handler that shifts handling of the final callback or future to the Backendless infrastructure so that one can still return data from the handler to the client as with a synchronous Custom Event handler?

There is no asynchronous form of any of the APIs when you use them in your custom code. We do not allow creation of new threads either explicitly or implicitly (by using async APIs for instance).

Regards,
Mark

Thanks very much, this clarifies what we needed to know.