PracHub
QuestionsLearningGuidesInterview Prep
|Home/System Design/Retell

Design a Smooth Per-Customer Calls-Per-Second Controller

Last updated: Aug 5, 2026

Quick Overview

Design a service that smoothly paces outbound calls under a separate rate limit for each customer. Candidates must address durable admission, priority fairness, tenant isolation, partition ownership, failover fencing, retries, backpressure, and observable delivery semantics.

  • medium
  • Retell
  • System Design
  • Software Engineer

Design a Smooth Per-Customer Calls-Per-Second Controller

Company: Retell

Role: Software Engineer

Category: System Design

Difficulty: medium

Interview Round: Technical Screen

## Design a Smooth Per-Customer Calls-Per-Second Controller Design a service that controls outbound calls for many customers. Each customer has a configurable calls-per-second limit. Traffic should be spread smoothly rather than released as one burst each second. High-priority calls should be preferred over regular calls without starving regular work. One noisy customer must not delay others, and the service must remain available across failures. Include the request API, scheduling and pacing model, per-customer isolation, horizontal scaling, retries, timeouts, failure behavior, and operational trade-offs. ### Part 1 — Define Admission and Delivery Semantics Specify what a customer's CPS limit means, whether calls are accepted synchronously or queued, what acknowledgement represents, and the guarantees for ordering, duplication, cancellation, and priority. #### What This Part Should Cover - Separate start-rate, concurrency, and completion semantics. - Durable idempotent enqueue and observable request states. - Honest acknowledgement, cancellation, and duplicate-delivery guarantees. ```hint Separate acceptance from execution Persisting a request and actually starting its outbound call are different events with different failure modes. ``` ### Part 2 — Pace Calls Smoothly Design the per-customer scheduling state that spaces starts over time. Explain burst allowance, limit changes, clock behavior, high-priority selection, and a concrete anti-starvation policy for regular calls. #### What This Part Should Cover - A token bucket, virtual schedule, or equivalent precise pacing invariant. - Explicit burst capacity and controlled-clock behavior. - Priority preference with a measurable regular-traffic fairness bound. ```hint A one-second counter is not smooth pacing A token bucket or virtual next-send time can enforce a rate while controlling how closely starts cluster. ``` ### Part 3 — Partition and Recover Distribute many customers across workers while ensuring one active owner or equivalent atomic scheduler state per customer. Handle worker crash, reassignment, duplicated queue delivery, and customer-specific hot spots without creating a global lock. #### What This Part Should Cover - Stable customer partitioning and renewable ownership. - Fencing or atomic state transitions during failover. - Tenant isolation and a safe plan for exceptionally hot customers. ```hint Make ownership renewable A lease with an epoch lets another worker recover a customer while fencing a stale worker that later resumes. ``` ### Part 4 — Handle Call Outcomes and Operate the Service Define connect and response timeouts, retry eligibility, retry backoff, whether retries consume CPS capacity, dead-letter handling, overload behavior, metrics, and tests. #### What This Part Should Cover - Outcome classification, bounded backoff, and dead-letter policy. - Retries routed through the same rate-control path. - Backpressure, reconciliation, service-level metrics, and failure tests. ```hint Retry policy is part of rate policy An immediate retry can double outbound pressure unless it returns through the same pacing path. ``` ### What a Strong Answer Covers - A precise CPS and burst contract with smooth dispatch. - Durable per-customer queues, priority fairness, and tenant isolation. - Partition ownership, fencing, idempotency, and recovery after partial failure. - Backpressure and bounded work rather than unbounded memory growth. - Explicit retry, timeout, observability, and reconciliation behavior. ### Follow-up Questions 1. How would a customer's limit change take effect without creating a burst? 2. How would you support one customer whose rate exceeds one worker's capacity? 3. Which failure can still produce a duplicate outbound call, and where would idempotency live? 4. How would you prove that regular calls are not starved by a continuous priority backlog?

Quick Answer: Design a service that smoothly paces outbound calls under a separate rate limit for each customer. Candidates must address durable admission, priority fairness, tenant isolation, partition ownership, failover fencing, retries, backpressure, and observable delivery semantics.

Related Interview Questions

  • Design and Implement a Mini SQL Query Engine - Retell (hard)
  • Design a Cloud Call-Center Platform for Programmatic Outbound Calls - Retell (hard)
|Home/System Design/Retell

Design a Smooth Per-Customer Calls-Per-Second Controller

Retell logo
Retell
Jul 27, 2026, 12:00 AM
mediumSoftware EngineerTechnical ScreenSystem Design
0
0

Design a Smooth Per-Customer Calls-Per-Second Controller

Design a service that controls outbound calls for many customers. Each customer has a configurable calls-per-second limit. Traffic should be spread smoothly rather than released as one burst each second. High-priority calls should be preferred over regular calls without starving regular work. One noisy customer must not delay others, and the service must remain available across failures.

Include the request API, scheduling and pacing model, per-customer isolation, horizontal scaling, retries, timeouts, failure behavior, and operational trade-offs.

Part 1 — Define Admission and Delivery Semantics

Specify what a customer's CPS limit means, whether calls are accepted synchronously or queued, what acknowledgement represents, and the guarantees for ordering, duplication, cancellation, and priority.

What This Part Should Cover Guidance

  • Separate start-rate, concurrency, and completion semantics.
  • Durable idempotent enqueue and observable request states.
  • Honest acknowledgement, cancellation, and duplicate-delivery guarantees.

Part 2 — Pace Calls Smoothly

Design the per-customer scheduling state that spaces starts over time. Explain burst allowance, limit changes, clock behavior, high-priority selection, and a concrete anti-starvation policy for regular calls.

What This Part Should Cover Guidance

  • A token bucket, virtual schedule, or equivalent precise pacing invariant.
  • Explicit burst capacity and controlled-clock behavior.
  • Priority preference with a measurable regular-traffic fairness bound.

Part 3 — Partition and Recover

Distribute many customers across workers while ensuring one active owner or equivalent atomic scheduler state per customer. Handle worker crash, reassignment, duplicated queue delivery, and customer-specific hot spots without creating a global lock.

What This Part Should Cover Guidance

  • Stable customer partitioning and renewable ownership.
  • Fencing or atomic state transitions during failover.
  • Tenant isolation and a safe plan for exceptionally hot customers.

Part 4 — Handle Call Outcomes and Operate the Service

Define connect and response timeouts, retry eligibility, retry backoff, whether retries consume CPS capacity, dead-letter handling, overload behavior, metrics, and tests.

What This Part Should Cover Guidance

  • Outcome classification, bounded backoff, and dead-letter policy.
  • Retries routed through the same rate-control path.
  • Backpressure, reconciliation, service-level metrics, and failure tests.

What a Strong Answer Covers Guidance

  • A precise CPS and burst contract with smooth dispatch.
  • Durable per-customer queues, priority fairness, and tenant isolation.
  • Partition ownership, fencing, idempotency, and recovery after partial failure.
  • Backpressure and bounded work rather than unbounded memory growth.
  • Explicit retry, timeout, observability, and reconciliation behavior.

Follow-up Questions Guidance

  1. How would a customer's limit change take effect without creating a burst?
  2. How would you support one customer whose rate exceeds one worker's capacity?
  3. Which failure can still produce a duplicate outbound call, and where would idempotency live?
  4. How would you prove that regular calls are not starved by a continuous priority backlog?

Submit Your Answer to Earn 20XP

Sign in to leave a comment

Loading comments...

Browse More Questions

More System Design•More Retell•More Software Engineer•Retell Software Engineer•Retell System Design•Software Engineer System Design

Your design canvas — auto-saved

PracHub

Master your tech interviews with 9,000+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • AI Coding Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.