SumitM

29.9K posts

SumitM banner
SumitM

SumitM

@SumitM_X

16 years In IT | Author of a bestselling Java book | All Books links in the pinned tweet https://t.co/NmsenbKiBW

Katılım Haziran 2021
1K Takip Edilen43.5K Takipçiler
Sabitlenmiş Tweet
SumitM
SumitM@SumitM_X·
I have launched four digital products via Topmate and Gumroad so far . Given the constant inquiries through DMs for purchase links, I have decided to consolidate all relevant links in one place for your convenience. Individual Products: Cracking The Java Interview With Sumit: Topmate: topmate.io/interviewswith… Gumroad: msumit.gumroad.com/l/qturr HARD COPY: store.pothi.com/book/sumit-m-c… Cracking the MERN Interviews: Topmate: topmate.io/interviewswith… Gumroad: msumit.gumroad.com/l/imzsr Cracking The Reactjs Interviews: Topmate: topmate.io/interviewswith… Gumroad: msumit.gumroad.com/l/qqheh Cracking The React Native Interviews: Topmate: topmate.io/interviewswith… Gumroad: msumit.gumroad.com/l/yakhkx Bundle Offers: All in One Bundle (Java + Reactjs + MERN + React Native): Topmate: topmate.io/interviewswith… Gumroad:msumit.gumroad.com/l/ypbkul (Java book pdf + Java Interviews in 2026 webinar Recording): Topmate: topmate.io/interviewswith… (Java + Reactjs + MERN): Topmate: topmate.io/interviewswith… Gumroad: msumit.gumroad.com/l/rikeb Reactjs + MERN Bundle: Topmate: topmate.io/interviewswith… Gumroad: msumit.gumroad.com/l/rikeb Java + MERN Bundle: Topmate: topmate.io/interviewswith… Gumroad: msumit.gumroad.com/l/psdfn Java + Reactjs Bundle: Topmate: topmate.io/interviewswith… Gumroad: msumit.gumroad.com/l/gvabt Thank you for your interest and support. 🙏
English
2
3
40
26.9K
SumitM
SumitM@SumitM_X·
Thread dump shows all threads waiting. What now?
English
2
0
1
176
SumitM
SumitM@SumitM_X·
Your feature branch has 50 commits. Main has moved ahead with 300 commits. What will you do: Rebase your branch or merge main into your branch?
English
15
0
23
3.5K
SumitM
SumitM@SumitM_X·
@BoysReviewer Looks like Insta has more audience...She has good number of comments and likes..
English
0
0
0
23
SumitM
SumitM@SumitM_X·
Two users hit "Book Now" at the exact same millisecond on Booking and Expedia. Only 1 seat left. Both requests reach your system. How do you make sure ONLY ONE ticket gets booked?
SumitM tweet media
English
25
3
101
22.7K
SumitM
SumitM@SumitM_X·
As a developer, Have you ever thought : WHY disk access is so slow compared to memory access?
English
15
0
51
8K
SumitM retweetledi
SumitM
SumitM@SumitM_X·
I’m so glad the book helped in the interview—it means a lot to me to know my book made a difference. Honestly, hearing stories like these is the best kind of feedback and keeps me motivated to keep improving it. Thank you ❤️
SumitM tweet media
English
2
4
149
14.2K
SumitM retweetledi
SumitM
SumitM@SumitM_X·
Messages like these make all the effort worthwhile . Super happy the book helped in someone's journey.
SumitM tweet media
English
4
5
134
18K
SumitM
SumitM@SumitM_X·
As a backend dev, You see: GET /api/v1/reports?from=2020-01-01&to=2026-01-01 Table size: 70M rows What are your next steps?
English
58
9
530
97.3K
KrunalSinh Sisodia
KrunalSinh Sisodia@krunalbuilds·
As a developer, here’s what’s likely happening: That QR code isn’t just a random string - it’s usually a short-lived pairing token. Flow looks like this: • TV generates a temporary session / device ID • QR code encodes that ID • Your phone scans it and authenticates with your account • Backend links your account to that TV session • TV polls or gets notified → logged in instantly So yeah, it’s basically secure device pairing using short-lived tokens + backend sync.
KrunalSinh Sisodia tweet media
English
1
1
16
1.6K
SumitM
SumitM@SumitM_X·
You open YouTube on your TV and scan a QR code from your phone… You are logged in instantly. No password. As a developer , do you think that QR code is just a short-lived token or something else ?
SumitM tweet media
English
10
4
80
14.1K
Priyanka Pudi
Priyanka Pudi@priyankapudi·
Thanks for the question, honestly idk the answer for this but i have studied this through these sources 1. milanjovanovic.tech/blog/solving-r… 2. martin.kleppmann.com/2016/02/08/how… for some time to answer you here - to control the concurrencies and such race conditions where two systems competing each other to write the data we have - implement the locking , locking what ?? - lock the requests , being written to the storage, req 1 is locked till it writes into storage and then the req 2 writes - another way is if req 1 appears first lock it with token no, so if token no higher than this already persists to write then this expired token which already waited long is going to expire ... (similar to optimistic locking in redis eg in the article i mentioned) - what is optimistic locking ? Both requests read the row, both see version = 7 Req 1 writes first, bumps it to version = 8 Req 2 tries to write WHERE version = 7 version 7 doesn't exist , because it's over written and
English
1
0
6
987
Ashok Sahoo
Ashok Sahoo@ashoKumar89·
It means the system is deployed across multiple availability zones. So if one AZ goes down, traffic can shift to another. But it does not mean everything is safe: If database is single-AZ, still a risk If failover is not tested, it may break App bugs still exist Multi-AZ helps with infra failures, not everything.
English
1
0
24
2.6K
SumitM
SumitM@SumitM_X·
Tech Lead in a meeting says: "Our system is Multi-AZ, so we are safe." As a developer… did you understand what that means?
English
15
3
97
23.9K
SumitM
SumitM@SumitM_X·
As a developer, Have you ever wondered : You type a Gmail username and UI instantly shows "Username already taken"... There are millions of users globally How is this check so fast?
SumitM tweet media
English
219
85
4.6K
2.6M
SumitM
SumitM@SumitM_X·
Many replies say Bloom Filter . But as a developer , do you know what is a Bloom Filter ? A Bloom filter is a data structure made of: - a bit array (just 0s and 1s) - multiple hash functions. Thats it. Nothing else. Let's see how it works : Add an element ("john") Step 1: Run hash functions h1("john") -> 2 h2("john") -> 5 h3("john") -> 8 Step 2: Set those indexes to 1 bitArray = [0,1,0,0,1,0,0,1,0,0] 2 5 8 Now, Check an element ("Raj") Step 1: Hash again h1("Raj") -> 2 h2("Raj") -> 4 h3("Raj") -> 9 Step 2: Check bits index 2 -> 1 index 4 -> 0 If any index = 0 → return FALSE (definitely not present) Now, Check another ("Sumit") h1("Sumit") -> 2 h2("Sumit") -> 5 h3("Sumit") -> 8 Check bits: 2 -> 1 5 -> 1 8 -> 1 All 1 -> return TRUE (maybe present, check DB) Why "maybe"? Different inputs can map to same indexes: john -> 2,5,8 Sumit -> 2,5,8 (collision) So: You didnt add "Sumit" But bits are already 1 (false positive)
SumitM@SumitM_X

As a developer, Have you ever wondered : You type a Gmail username and UI instantly shows "Username already taken"... There are millions of users globally How is this check so fast?

English
9
9
187
20.2K
SumitM
SumitM@SumitM_X·
I said millions but there are ~ 1.8 B Gmail users globally.. Does it change anything in the design?
English
1
0
60
33.4K
raj
raj@rajacquire·
@SumitM_X Your questions are very helpful. Thank you so much.....
English
1
0
2
5K
Gustavo Delgado
Gustavo Delgado@gustavonecore·
@SumitM_X Easy: all the usernames are downloaded into your browser localstorage
Gustavo Delgado tweet media
English
7
2
437
33.6K