Scaling horizontally
If we add further nodes to the application, it must add to the total processing power. To create frontend systems that perform more data transmission than computation, async
frameworks are better suited. If we use PyPy, it will give a performance boost to the application. Code for Python 3 or Python 2 compatibility using six or other such libraries so that we can use anything available for optimization.
We can use message pack or JSON for message transfer. I prefer JSON for language agnostic and easy-text representation. Workers can be multiprocessing workers for CPU-bound tasks or thread-based for other scenarios.
The system should not store the state but pass it with messages. Everything doesn't need to be in DB. We can take some things out when not necessary.
ZeroMQ (messageQueue): ZMQ is a wonderful library that acts as a glue to connect your programs together. It has connectors for almost all language. You can easily use multiple languages/frameworks to enable their...