grammyjs / grammyjs/runner

perf: switch queue to use a ring buffer instead of a linked list

Open
#26 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
27
Forks
5
PR merge metrics
No merged PRs in 30d

Description

Initially, we cared a lot about simplicity and correctness. Now, grammY powers some of the largest bots on Telegram, so we should start optimizing down to the last allocation.

Linked lists likely cause a lot more memory overhead (even in V8) and we should:
1. implement a benchmark for throughput
2. implement metrics for memory churn, CPU performance, and other relevant factors
3. implement a ring buffer version
4. run the benchmarks, and compare the implementations
5. switch if the results indicate this

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.