.
📰 Medium · Programming
Learn to stop guessing pod size and understand the relationship between concurrency, latency, and resource allocation to optimize system performance.
Action Steps
- Calculate the actual work each request does using Little's Law: Concurrency = RPS × Latency
- Analyze the chain of work for each request, including HTTP parsing, authentication, query preparation, database execution, business logic, and serialization
- Determine the CPU time required for each request to understand its cost
- Use this information to right-size pods and prevent CPU thrashing, latency spikes, and OOM errors
- Monitor system performance and adjust resource allocation as needed to maintain optimal performance
Who Needs to Know This
DevOps engineers and system administrators can benefit from this knowledge to ensure their systems can handle increased traffic without failing under load.
Key Insight
💡 RPS tells you load, but not cost. Calculate the actual work each request does to right-size pods and prevent performance issues.
Share This
🚀 Stop guessing pod size! Understand concurrency, latency, and resource allocation to optimize system performance 🚀
Key Takeaways
Learn to stop guessing pod size and understand the relationship between concurrency, latency, and resource allocation to optimize system performance.
Full Article
Title: 𝐒𝐭𝐨𝐩 𝐠𝐮𝐞𝐬𝐬𝐢𝐧𝐠 𝐩𝐨𝐝 𝐬𝐢𝐳𝐞.
URL Source: https://medium.com/@ag3152000/-826cbe4dfcc6?source=rss------programming-5
Published Time: 2026-04-22T21:29:45Z
Markdown Content:
# 𝐒𝐭𝐨𝐩 𝐠𝐮𝐞𝐬𝐬𝐢𝐧𝐠 𝐩𝐨𝐝 𝐬𝐢𝐳𝐞. | by Ankit Gupta | Apr, 2026 | Medium
[Sitemap](https://medium.com/sitemap/sitemap.xml)
[Open in app](https://play.google.com/store/apps/details?id=com.medium.reader&referrer=utm_source%3DmobileNavBar&source=post_page---top_nav_layout_nav-----------------------------------------)
Sign up
[Sign in](https://medium.com/m/signin?operation=login&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&source=post_page---top_nav_layout_nav-----------------------global_nav------------------)
[](https://medium.com/?source=post_page---top_nav_layout_nav-----------------------------------------)
Get app
[Write](https://medium.com/m/signin?operation=register&redirect=https%3A%2F%2Fmedium.com%2Fnew-story&source=---top_nav_layout_nav-----------------------new_post_topnav------------------)
[Search](https://medium.com/search?source=post_page---top_nav_layout_nav-----------------------------------------)
Sign up
[Sign in](https://medium.com/m/signin?operation=login&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&source=post_page---top_nav_layout_nav-----------------------global_nav------------------)

[](https://medium.com/@ag3152000?source=post_page---byline--826cbe4dfcc6---------------------------------------)
[Ankit Gupta](https://medium.com/@ag3152000?source=post_page---byline--826cbe4dfcc6---------------------------------------)
Follow
3 min read
·
1 hour ago
[](https://medium.com/m/signin?actionUrl=https%3A%2F%2Fmedium.com%2F_%2Fvote%2Fp%2F826cbe4dfcc6&operation=register&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&user=Ankit+Gupta&userId=b05ba128135e&source=---header_actions--826cbe4dfcc6---------------------clap_footer------------------)
[](https://medium.com/m/signin?actionUrl=https%3A%2F%2Fmedium.com%2F_%2Fbookmark%2Fp%2F826cbe4dfcc6&operation=register&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&source=---header_actions--826cbe4dfcc6---------------------bookmark_footer------------------)
[Listen](https://medium.com/m/signin?actionUrl=https%3A%2F%2Fmedium.com%2Fplans%3Fdimension%3Dpost_audio_button%26postId%3D826cbe4dfcc6&operation=register&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&source=---header_actions--826cbe4dfcc6---------------------post_audio_button------------------)
Share
### 𝐒𝐭𝐨𝐩 𝐠𝐮𝐞𝐬𝐬𝐢𝐧𝐠 𝐩𝐨𝐝 𝐬𝐢𝐳𝐞. 𝐃𝐨 𝐭𝐡𝐞 𝐦𝐚𝐭𝐡 𝐨𝐧𝐜𝐞 𝐚𝐧𝐝 𝐲𝐨𝐮 𝐰𝐨𝐧’𝐭 𝐠𝐞𝐭 𝐂𝐏𝐔 𝐭𝐡𝐫𝐨𝐭𝐭𝐥𝐢𝐧𝐠 𝐨𝐫 𝐎𝐎𝐌 𝐢𝐧 𝐩𝐫𝐨𝐝𝐮𝐜𝐭𝐢𝐨𝐧.
### 𝐋𝐢𝐭𝐭𝐥𝐞’𝐬 𝐋𝐚𝐰: 𝐂𝐨𝐧𝐜𝐮𝐫𝐫𝐞𝐧𝐜𝐲 = 𝐑𝐏𝐒 × 𝐋𝐚𝐭𝐞𝐧𝐜𝐲
Press enter or click to view image in full size

Resources Allocation
## 𝐖𝐡𝐲 𝐦𝐨𝐬𝐭 𝐬𝐲𝐬𝐭𝐞𝐦𝐬 𝐟𝐚𝐢𝐥 𝐮𝐧𝐝𝐞𝐫 𝐥𝐨𝐚𝐝
You deployed a service. It works fine in testing.
Then traffic increases and suddenly:
CPU hits 100 percent
Latency spikes
Pods restart due to OOM
The common pattern is simple.
No one calculated how much work each request actually does.
---
### 𝐖𝐡𝐚𝐭 𝐝𝐨𝐞𝐬 𝐚 𝐫𝐞𝐪𝐮𝐞𝐬𝐭 𝐫𝐞𝐚𝐥𝐥𝐲 𝐜𝐨𝐧𝐬𝐮𝐦𝐞
A request is not just an API call. It is a chain of work:
HTTP parsing
Authentication
Query preparation
Database execution
Business logic
Serialization
Only one thing matters for CPU:
How much time all of this takes
---
### 𝐐𝐮𝐞𝐬𝐭𝐢𝐨𝐧: 𝐂𝐚𝐧 𝐈 𝐬𝐢𝐳𝐞 𝐛𝐚𝐬𝐞𝐝 𝐨𝐧 𝐑𝐏𝐒 𝐚𝐥𝐨𝐧𝐞
No.
RPS tells you load.
It does not tell you cost.
Two systems at 100 RPS can have completely different CPU needs depending on:
Query complexity
Data si
URL Source: https://medium.com/@ag3152000/-826cbe4dfcc6?source=rss------programming-5
Published Time: 2026-04-22T21:29:45Z
Markdown Content:
# 𝐒𝐭𝐨𝐩 𝐠𝐮𝐞𝐬𝐬𝐢𝐧𝐠 𝐩𝐨𝐝 𝐬𝐢𝐳𝐞. | by Ankit Gupta | Apr, 2026 | Medium
[Sitemap](https://medium.com/sitemap/sitemap.xml)
[Open in app](https://play.google.com/store/apps/details?id=com.medium.reader&referrer=utm_source%3DmobileNavBar&source=post_page---top_nav_layout_nav-----------------------------------------)
Sign up
[Sign in](https://medium.com/m/signin?operation=login&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&source=post_page---top_nav_layout_nav-----------------------global_nav------------------)
[](https://medium.com/?source=post_page---top_nav_layout_nav-----------------------------------------)
Get app
[Write](https://medium.com/m/signin?operation=register&redirect=https%3A%2F%2Fmedium.com%2Fnew-story&source=---top_nav_layout_nav-----------------------new_post_topnav------------------)
[Search](https://medium.com/search?source=post_page---top_nav_layout_nav-----------------------------------------)
Sign up
[Sign in](https://medium.com/m/signin?operation=login&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&source=post_page---top_nav_layout_nav-----------------------global_nav------------------)

[](https://medium.com/@ag3152000?source=post_page---byline--826cbe4dfcc6---------------------------------------)
[Ankit Gupta](https://medium.com/@ag3152000?source=post_page---byline--826cbe4dfcc6---------------------------------------)
Follow
3 min read
·
1 hour ago
[](https://medium.com/m/signin?actionUrl=https%3A%2F%2Fmedium.com%2F_%2Fvote%2Fp%2F826cbe4dfcc6&operation=register&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&user=Ankit+Gupta&userId=b05ba128135e&source=---header_actions--826cbe4dfcc6---------------------clap_footer------------------)
[](https://medium.com/m/signin?actionUrl=https%3A%2F%2Fmedium.com%2F_%2Fbookmark%2Fp%2F826cbe4dfcc6&operation=register&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&source=---header_actions--826cbe4dfcc6---------------------bookmark_footer------------------)
[Listen](https://medium.com/m/signin?actionUrl=https%3A%2F%2Fmedium.com%2Fplans%3Fdimension%3Dpost_audio_button%26postId%3D826cbe4dfcc6&operation=register&redirect=https%3A%2F%2Fmedium.com%2F%40ag3152000%2F-826cbe4dfcc6&source=---header_actions--826cbe4dfcc6---------------------post_audio_button------------------)
Share
### 𝐒𝐭𝐨𝐩 𝐠𝐮𝐞𝐬𝐬𝐢𝐧𝐠 𝐩𝐨𝐝 𝐬𝐢𝐳𝐞. 𝐃𝐨 𝐭𝐡𝐞 𝐦𝐚𝐭𝐡 𝐨𝐧𝐜𝐞 𝐚𝐧𝐝 𝐲𝐨𝐮 𝐰𝐨𝐧’𝐭 𝐠𝐞𝐭 𝐂𝐏𝐔 𝐭𝐡𝐫𝐨𝐭𝐭𝐥𝐢𝐧𝐠 𝐨𝐫 𝐎𝐎𝐌 𝐢𝐧 𝐩𝐫𝐨𝐝𝐮𝐜𝐭𝐢𝐨𝐧.
### 𝐋𝐢𝐭𝐭𝐥𝐞’𝐬 𝐋𝐚𝐰: 𝐂𝐨𝐧𝐜𝐮𝐫𝐫𝐞𝐧𝐜𝐲 = 𝐑𝐏𝐒 × 𝐋𝐚𝐭𝐞𝐧𝐜𝐲
Press enter or click to view image in full size

Resources Allocation
## 𝐖𝐡𝐲 𝐦𝐨𝐬𝐭 𝐬𝐲𝐬𝐭𝐞𝐦𝐬 𝐟𝐚𝐢𝐥 𝐮𝐧𝐝𝐞𝐫 𝐥𝐨𝐚𝐝
You deployed a service. It works fine in testing.
Then traffic increases and suddenly:
CPU hits 100 percent
Latency spikes
Pods restart due to OOM
The common pattern is simple.
No one calculated how much work each request actually does.
---
### 𝐖𝐡𝐚𝐭 𝐝𝐨𝐞𝐬 𝐚 𝐫𝐞𝐪𝐮𝐞𝐬𝐭 𝐫𝐞𝐚𝐥𝐥𝐲 𝐜𝐨𝐧𝐬𝐮𝐦𝐞
A request is not just an API call. It is a chain of work:
HTTP parsing
Authentication
Query preparation
Database execution
Business logic
Serialization
Only one thing matters for CPU:
How much time all of this takes
---
### 𝐐𝐮𝐞𝐬𝐭𝐢𝐨𝐧: 𝐂𝐚𝐧 𝐈 𝐬𝐢𝐳𝐞 𝐛𝐚𝐬𝐞𝐝 𝐨𝐧 𝐑𝐏𝐒 𝐚𝐥𝐨𝐧𝐞
No.
RPS tells you load.
It does not tell you cost.
Two systems at 100 RPS can have completely different CPU needs depending on:
Query complexity
Data si
DeepCamp AI