anvilglobaldynamics / torque

Lipi is an easy-to-adopt and easy-to-use mobile-first business management solution for medium size retailers.
https://lipi.live
0 stars 0 forks source link

Async/Await Conversion #229

Open iShafayet opened 6 years ago

iShafayet commented 6 years ago

After a lot of experimenting, I have come to realize that using async, our workflow can be made much more simpler and smoother.

I'll update this thread with progress on the conversion.

Additional features to implement (alongside the conversion) -

iShafayet commented 6 years ago

It'll be a bad decision if other parts are disabled until the conversion is complete. So, I'm adding parallel support for both the legacy callback based workflow, as well as the new async workflow.

For this, I've added the 'legacy' prefix to all callback based APIs and Collections. The Router and server will now support both the legacy apis and async based apis in perfect harmony.

I will of course, have to rewrite all the collections as the async approach is from root to leaves. However, the server will continue to work even before all (or any or some) of the APIs have been converted to async. That way, code duplication will be kept minimal.

iShafayet commented 6 years ago

All the collections have been rewritten as Async.

All the components have been rewritten as Async.

Pending are the APIs and Api Base Class.