🍪 TechCookies
HomeDSASystem DesignMy Progress
Free
Log inStart free
TechCookies — Practice · Learn · PrepareTechCookies — Practice · Learn · Prepare
ConceptsPracticeSD challengesPricingPrivacyTermsContact
© 2026 TechCookies
📚Synchronous vs Asynchronous CommunicationFree
18 sections
~29 min total
100 quick quizzes
4 SD challenges linked
0 of 18 done·~34 min left
Concepts›Synchronous vs Asynchronous Communication›What Is Synchronous Communication?
0 / 18
0%
18 sections~29 min
1
What Is Synchronous Communication?
Sender waits (blocks) for a response before proceeding; common in REST and gRPC.
ReadQuizCode
~2 min
⋯
What Is Asynchronous Communication?
Sender publishes message and moves on; receiver processes independently via queue.
ReadQuizCode
~2 min
⋯
REST vs gRPC vs Message Queues: Side-by-Side
Comparison of three communication patterns across latency, throughput, and use cases.
ReadQuizCode
~2 min
⋯
When to Use Each: Real-World Scenarios
Decision rules for choosing sync (login) versus async (email) based on user interaction.
ReadQuizCode
~2 min
⋯
Latency Implications: Blocking vs Non-Blocking
Blocking calls serialize operations; non-blocking allows parallelism and reduces latency.
ReadQuiz
~2 min
⋯
Blocking Calls (Synchronous)
Thread freezes until operation completes; cascading slowdowns if any service is slow.
ReadQuizCode
~2 min
⋯
Non-Blocking Calls (Asynchronous)
Thread continues while awaiting results; parallel execution reduces total latency.
ReadQuizCode
~2 min
⋯
Relevant System Design Questions
Guide to identifying sync/async patterns in notification, code-execution, and tracking systems.
ReadQuiz
~2 min
⋯
System Design: Notification System
Multi-channel notifications require async queues to avoid blocking app server.
ReadQuizCode
~2 min
⋯
System Design: Interview Prep Platform
Code execution must be async; submission is sync but result retrieval uses polling/WebSocket.
ReadQuizCode
~2 min
⋯
System Design: Job Tracker
CRUD operations are sync; background tasks like resume parsing and emails are async.
ReadQuizCode
~2 min
⋯
Job Tracker: Sync + Async Hybrid Flow
User-facing CRUD is synchronous; AI features and analytics run asynchronously in parallel.
ReadQuizCode
~2 min
⋯
Handling Failures: Sync vs Async
Sync failures are immediate and visible; async failures can be retried or sent to DLQ.
ReadQuiz
~2 min
⋯
Failure in Synchronous Systems
External service failure immediately returns error to caller; must retry or fail visibly.
ReadQuizCode
~2 min
⋯
Failure in Asynchronous Systems
Messages persist in queue; consumer can retry; failed messages go to Dead Letter Queue.
ReadQuizCode
~2 min
⋯
Key Concepts Cheat Sheet
Quick reference for sync/async terminology, protocols, and patterns.
ReadQuiz
~2 min
⋯
MCQs: Test Your Understanding
Multiple-choice questions covering sync/async decision-making and architecture tradeoffs.
ReadQuiz
~2 min
⋯
Practice test
100 questions
~34 min
Section 1 of 18ReadQuick quiz
What Is Synchronous Communication?
Sender waits (blocks) for a response before proceeding; common in REST and gRPC.
~2 min read
3 quick quizzes

In synchronous communication, the sender sends a request and waits (blocks) until it receives a response before doing anything else. The two parties must be available at the same time.

Think of it like a phone call:

  • You dial → you wait → the other person answers → you talk → you get your answer.

Common Protocols for Synchronous Communication

ProtocolDescriptionUse Case
REST (HTTP/HTTPS)Text-based, uses JSON/XML, statelessWeb APIs, CRUD operations
gRPCBinary protocol using Protocol Buffers, fastMicroservices, mobile backends
GraphQLQuery language over HTTPFlexible data fetching

REST Example

A browser asks a server: "Give me user #42's profile."

GET /users/42 HTTP/1.1 Host: api.example.com

Server responds:

{
  "id": 42,
  "name": "Alice",
  "email": "alice@example.com"
}

The browser waits for this response before showing the page.

gRPC Example

gRPC uses .proto files to define services:

// user.proto
service UserService {
  rpc GetUser (UserRequest) returns (UserResponse);
}

message UserRequest {
  int32 user_id = 1;
}

message UserResponse {
  int32 id = 1;
  string name = 2;
  string email = 3;
}

The client calls GetUser(user_id=42) and blocks until the server returns a UserResponse.


Synchronous Communication Diagram

Synchronous Communication (REST / gRPC) Client Server 1. Request (GET /users/42) BLOCKED / Waiting Processing 2. Response (200 OK + data) 3. Client continues

☑ Quick check 1/3
What is the defining characteristic of synchronous communication?
AThe sender never waits for a response
BMessages are stored in a queue
CThe sender waits (blocks) until it receives a response
DBoth parties communicate via a broker
Answer the quiz to continue
Notes
🔍
Loading…