Skip to main content
PreparationZone Logo
PrepZone

Hexagonal Architecture

Ports define needs; adapters provide technology.

Pass checkpoint below

Why this matters

  • Ports — detailed pointwise breakdown in the section below.
  • Adapters — detailed pointwise breakdown in the section below.
  • Payment example — detailed pointwise breakdown in the section below.
  • Testing — detailed pointwise breakdown in the section below.
  • Games and architecture patterns signal staff+ depth.
Application core
Driving adaptersREST, CLI
Domain + ports
Driven adaptersDB, messaging
Domain at the centre; ports define interfaces; adapters plug in infrastructure.

Overview

Ports define needs; adapters provide technology. Study each section below in order — every list is interview-ready reference material.

Ports

Points to cover

  • Definition — what Ports means in one clear sentence
  • When to use — the force or smell that triggers this concept
  • CampusOS example — where this appears in parking, booking, or library modules
  • How to explain — pointwise bullets you can say aloud in an interview
  • Common mistake — what weak candidates do instead
  • Refactor move — one concrete change that improves the design

The rest of this guide is part of Pro

Free covers every fresher guide in full. Pro unlocks Senior, Staff and Architect guides across every track.

Still to come · 3 sections

  • Adapters
  • Payment example
  • Testing

Test yourself

Answer these before moving on — recall is what makes it stick.