Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Performance] 🟢 TPS 73% & MTTFB 74% Improved by - RDB Caching GET /api-chat/friends #302

Open
ghkdqhrbals opened this issue Dec 13, 2023 · 0 comments
Assignees
Labels
feature: performance performance improvement

Comments

@ghkdqhrbals
Copy link
Owner

ghkdqhrbals commented Dec 13, 2023

GET /api-chat/friends

  • Implements
    • caching FriendsList DTO into Redis
  • Resource consumption
    • chat-db : 0.23 cpu
    • chat-server : 0.69 cpu
  • Improvements
    • avg MTTFB : 438.32 -> 324.82 👍 74% improvement
    • avg TPS : 225.7 -> 307.5 👍 73% improvement

Reducing SELECT query is important to improve performance, so I use Redis cache which has fast R/W performance because of its in-memory feature.

  • Before and after
image

Resource usage graph

image image image image
@ghkdqhrbals ghkdqhrbals added the feature: performance performance improvement label Dec 13, 2023
@ghkdqhrbals ghkdqhrbals self-assigned this Dec 13, 2023
@ghkdqhrbals ghkdqhrbals changed the title [Performance] www.litcodev.com/api-chat/friends [Performance] TPS 73% Improvement - Cached Data Dec 14, 2023
@ghkdqhrbals ghkdqhrbals changed the title [Performance] TPS 73% Improvement - Cached Data [Performance] TPS 73% avg MTTFB 74% Improvement - Cached Data Dec 14, 2023
@ghkdqhrbals ghkdqhrbals changed the title [Performance] TPS 73% avg MTTFB 74% Improvement - Cached Data [Performance] TPS 73% & avg MTTFB 74% Improvement - Cached Data Dec 14, 2023
@ghkdqhrbals ghkdqhrbals changed the title [Performance] TPS 73% & avg MTTFB 74% Improvement - Cached Data [Performance] TPS 73% & avg MTTFB 74% Improvement - Cached Data GET /api-chat/friends Dec 14, 2023
@ghkdqhrbals ghkdqhrbals changed the title [Performance] TPS 73% & avg MTTFB 74% Improvement - Cached Data GET /api-chat/friends [Performance] TPS 73% & MTTFB 74% Improvement - Cached Data GET /api-chat/friends Dec 14, 2023
@ghkdqhrbals ghkdqhrbals changed the title [Performance] TPS 73% & MTTFB 74% Improvement - Cached Data GET /api-chat/friends [Performance] 🟢 TPS 73% & MTTFB 74% Improvement - Cached Data GET /api-chat/friends Jan 3, 2024
@ghkdqhrbals ghkdqhrbals changed the title [Performance] 🟢 TPS 73% & MTTFB 74% Improvement - Cached Data GET /api-chat/friends [Performance] 🟢 TPS 73% & MTTFB 74% Improved by - RDB Caching GET /api-chat/friends Jan 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature: performance performance improvement
Projects
None yet
Development

No branches or pull requests

1 participant