Drop python <3.5 support
The idea is to take advantage of the asyncio module which is only available since python 3.5.x
Besides, python 2.7 is about to be EOL by 2020.
The idea is to take advantage of the asyncio module which is only available since python 3.5.x
Besides, python 2.7 is about to be EOL by 2020.
closed via commit 97b35373
mentioned in commit 97b35373
I just ran some empiric tests: measure the time for a few API calls to complete with the old burp2
backend and then with the new async
backend.
The results were:
Api call | burp2 | async |
---|---|---|
/api/clients/all | 8s | 2s |
/api/clients/stats | 7s | 2s |
/api/client/stats/{name} | 8s | 2s |
So the new backend is roughly 4 times faster than the old one. Besides, the overall loading page is faster since the requests are processed in parallel for real. With the old backend, even if Ajax processed them asynchronously, the server could only process one request at the time due to locking issues.
Of course the performance gain is dependent on the underlying server capabilities. I ran those tests on a VM with 8 cores. On another VM of mine with only 2 cores I'm only two times faster.