Airplane Seat Booking System
Problem Statement
Design the Low-Level Design (LLD) of an Airplane Seat Booking System that allows passengers to search, select, and book seats on flights operated by different airlines.
The focus should be on object-oriented design, class modeling, and workflow, not large-scale infrastructure, load balancing, or distributed consistency (which would fall under HLD).
π― Goal
Design a system that can:
β Functional Requirements
1. Flight Search
2. Seat Selection & Booking
3. Booking Management
4. Payment
5. Admin / Airline Management
βοΈ Non-Functional Requirements
π§± Key Classes to Design
ClassResponsibility
User
Represents a customer using the system.
Flight
Represents a flight with details (number, source, destination, schedule).
Seat
Represents an individual seat on a flight (number, class, status).
Aircraft
Represents the aircraft model and seating configuration.
Booking
Represents a confirmed booking for one or more passengers.
Passenger
Represents passenger details within a booking.
Payment
Represents payment info and status.
FlightSearchService
Handles searching for flights.
BookingService
Manages seat reservation, booking confirmation, and cancellation.
PaymentService
Handles payments and updates booking status.
SeatLockService
Prevents concurrent seat bookings (temporary locks).
π§© Example Class Relationships
1
2User
3 βββ id
4 βββ name
5 βββ email
6 βββ List<Booking>
7
8Flight
9 βββ flightNumber
10 βββ source
11 βββ destination
12 βββ departureTime
13 βββ arrivalTime
14 βββ Aircraft aircraft
15 βββ List<Seat>
16
17Aircraft
18 βββ model
19 βββ seatLayout (rows, seatsPerRow)
20 βββ List<Seat>
21
22Seat
23 βββ seatNumber
24 βββ seatClass (Economy / Business / First)
25 βββ status (AVAILABLE / RESERVED / BOOKED)
26 βββ price
27
28Booking
29 βββ bookingId (PNR)
30 βββ user
31 βββ flight
32 βββ List<Passenger>
33 βββ List<Seat>
34 βββ status (CONFIRMED / CANCELLED)
35 βββ payment
36
37Payment
38 βββ paymentId
39 βββ amount
40 βββ status (PENDING / SUCCESS / FAILED)
41 βββ method (Card / UPI / Wallet)π Typical Flow
βοΈ Flight Search
πΊ Booking Flow
β Cancellation Flow
π Concurrency & Data Integrity
π§ Possible Extensions
β Final Summary:
Design an Airplane Seat Booking System that enables:
Focus on class design, state transitions, and concurrent seat handling, not on distributed systems or APIs.