🕵️ SicherheitslückenCVE-2026-69116 | xpf0000 FlyEnv up to 4.17.x Html Sanitization injection(17.09.2026 um 04:28 Uhr)
🕵️ SicherheitslückenCVE-2026-69114 | Spacebar Server Message Deletion Handlers permission(17.09.2026 um 04:28 Uhr)
🕵️ SicherheitslückenCVE-2026-18695 | MongoDB Server up to 7.0.39/8.0.28/8.3.7 denial of service(17.09.2026 um 04:28 Uhr)
🕵️ SicherheitslückenCVE-2026-69116 | xpf0000 FlyEnv up to 4.17.x Html Sanitization injection(17.09.2026 um 04:28 Uhr)
🕵️ SicherheitslückenCVE-2026-69114 | Spacebar Server Message Deletion Handlers permission(17.09.2026 um 04:28 Uhr)
🕵️ SicherheitslückenCVE-2026-18695 | MongoDB Server up to 7.0.39/8.0.28/8.3.7 denial of service(17.09.2026 um 04:28 Uhr)
🔧 Programmierung 🕛 vor 3 Monaten 2 Min Lesezeit
0

How Does Amazon Stop Two People from Booking the Same Seat?

↗ Quelle (dev.to)
🗣️ Stimme:

You're on BookMyShow or Amazon. You see 1 seat left. You click it. Someone else clicks it at the exact same moment.

The Problem

Imagine 1000 people are staring at the same "1 seat left" screen. When multiple people click Book Now at the same time, the server receives all those requests together.

Without any protection — all of them could "successfully" book the same seat. That's a disaster.



How it's actually solved:-




  1. Locking the seat temporarily (Optimistic / Pessimistic Lock)
    When you click a seat, the system locks it for you for ~10 minutes.



"Seat 12A is reserved for this session. Complete payment in 9:45"



You've seen this countdown on BookMyShow. That's a temporary lock in the database. No one else can book it while you're paying.

If you don't complete payment → lock expires → seat goes back to available.




  1. Database-level constraint
    The database has a rule:



"Only ONE booking record can exist per seat per show."



Even if 500 requests hit the server at the same time, the database only allows one of them to win. The rest get an error — and the user sees "Sorry, seat just got booked."

This is called a unique constraint.




  1. Queue the requests
    Instead of handling 1000 requests at the same time, Amazon puts them in a line (queue).
    First come, first served. Each request is processed one at a time for that seat. Simple and fair.



🎯 Real world analogy

Think of it like a token system at a restaurant



You take token #47

Only token #47 is called at the counter at a time

No two people handle the same counter simultaneously



Same idea.

🔑 Key terms

Pessimistic Lock : Lock the seat the moment someone clicks it

Optimistic Lock: Allow clicks, but only first one wins at save time

Unique Constraint: Database rule — no duplicates allowed

Queue: Process one request at a time, in order



Wrapping up

Next time you see that countdown timer on a booking site — you know exactly what's happening behind the scenes. The system locked that seat just for you, and is racing against your payment.

Pretty cool, right?

Vollständiger Original-Artikel
Den kompletten Beitrag mit allen Details direkt auf dev.to lesen.
↗ Original-Artikel auf dev.to lesen
Wie bewertest du diesen Beitrag?
1 Klick Feedback
Teilen mit Netzwerk & Team:

Community-Analysen & Experten-Meinungen 0

Verfasse deine eigene Analyse, teile Workarounds oder diskutiere diesen Vorfall im Blog.
Noch keine Community-Analyse verfasst. Markiere einen Textabschnitt oder klicke oben auf Eigene Analyse verfassen“!
Community Pulse: Relevanz-Einschätzung
1 Klick Experten-Votum
🔴 Akute Relevanz 0%
🟡 In Evaluierung 0%
🟢 Keine Auswirkung 0%
Spannende Innovation 0%
Verwandte Story-Cluster & Quellen (Vektor-KI)
Port 8095 Engine
2 Quellen
CVE-2026-76460 | Cisco Identity Services Engine Software API improper authentication
1 Quelle
Microsoft confirms it accidentally broke copy and paste in Excel with a major security update you shouldn’t remove
1 Quelle
CVE-2026-69116 | xpf0000 FlyEnv up to 4.17.x Html Sanitization injection
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten How Does Amazon Stop Two People from Booking the Same Seat?

Thematisch verwandte Begriffe: Does, Amazon, Stop, People · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...