[x] I have searched the issues of this repository and believe that this is not a duplicate.
Description 😯
sourceGlobalPermissions in api is a major bottleneck (to the point of unusability) when a number of permission events get moderately large. Execution time increases linearly with the array length passed to for..of loop.
Asymptotic running time is not the real issue, but rather that it processes all of this data repeatedly, even if it is not changed.
Permission events from which data is sourced are already cached.
Caching globalPerms.permissions object is expected to result in a large performance improvement.
Description 😯
sourceGlobalPermissions in api is a major bottleneck (to the point of unusability) when a number of permission events get moderately large. Execution time increases linearly with the array length passed to for..of loop. Asymptotic running time is not the real issue, but rather that it processes all of this data repeatedly, even if it is not changed.
Permission events from which data is sourced are already cached.
Caching globalPerms.permissions object is expected to result in a large performance improvement.
Affected APIs: /network.list /network.listActive /global.listPermissions
How to reproduce 🕹
Screenshots 📷
Add screenshots or screen recording video if applicable.
Your Environment 🌎