← Ramp Interview Insights

Ramp·Software Engineer·Onsite - System Design / Architecture·Senior

SeniorPrefer not to say
Jul 2026

Summary

System design round at Ramp for a software engineer role. The question was a full hotel reservation aggregator design, Expedia-style, and it went deep fast. Lots of back and forth on caching strategy and consistency trade-offs.

Questions Asked (4)

Q1

Design a hotel reservation aggregator like Expedia that searches for and books rooms across multiple hotel chains in real time.

System DesignAPI & IntegrationsTechnical Trade-offs
Author's notes

This one spiraled in a good way.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying functional and non-functional requirements, then design a high-level architecture with separate services for search, booking, and inventory sync. Focus on real-time availability and booking consistency across chains, discussing trade-offs between consistency, latency, and scalability.

Pro tip: Emphasize idempotency and distributed transactions to handle double bookings, and discuss how to handle partial failures when some chains are down. This shows maturity in building reliable distributed systems.

1. Clarify Requirements

Ask about scale (users, hotels, searches per second), consistency needs (real-time vs eventual), and supported chains. Define core features: search, book, cancel, and view reservations.

2. High-Level Design

Sketch components: API gateway, search service, booking service, inventory service, and external chain adapters. Use a message queue for async updates and a cache for hot data.

3. Deep Dive into Real-Time Search

Explain how to aggregate results from multiple chains with low latency: parallel requests, timeouts, fallbacks, and caching. Discuss indexing strategies for fast availability checks.

4. Booking and Consistency

Detail the booking flow: reserve inventory, process payment, confirm with chain. Use idempotency keys, distributed transactions (e.g., saga pattern), and compensating actions for failures.

5. Scalability and Trade-offs

Discuss scaling reads vs writes, sharding by hotel/chain, and trade-offs between strong consistency (for bookings) and eventual consistency (for search). Mention monitoring and rate limiting.

Key Points to Mention

  • Idempotency and distributed transactions to prevent double bookings
  • Caching strategies and TTL for search results to reduce latency
  • Handling partial failures and circuit breakers for external chain APIs
  • Data consistency models: strong for bookings, eventual for search
  • Scalability via sharding, read replicas, and async processing
  • API design for chain integration: REST vs GraphQL, rate limiting, and error handling

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q2

Should you call upstream hotel APIs on every search request, cache availability data, or pre-allocate a block of inventory in advance? Walk through the trade-offs.

Technical Trade-offsSystem DesignData Modeling
Author's notes

This was the core of the whole discussion.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the constraints: search volume, latency requirements, freshness needs, and cost of upstream calls. Then compare the three options—real-time calls, caching, and pre-allocation—across dimensions like latency, consistency, cost, and complexity, and recommend a hybrid approach based on the specific scenario.

Pro tip: Emphasize that the right answer depends on the business context—e.g., for a high-traffic travel platform, a hybrid of caching with short TTL and pre-allocated blocks for high-demand hotels often balances freshness and performance. Show you can quantify trade-offs with rough numbers (e.g., QPS, cache hit rate, cost per call).

1. Clarify Requirements

Ask about expected search volume, acceptable latency, data freshness requirements, and budget constraints. This ensures your analysis is grounded in real needs.

2. Evaluate Real-Time Calls

Discuss pros (always fresh, no stale data) and cons (high latency, rate limits, cost, dependency on upstream availability). Mention when this is appropriate (low volume, high freshness).

3. Evaluate Caching

Explain caching strategies (TTL, write-through, refresh-ahead) and trade-offs: reduced latency and cost vs. potential staleness and cache invalidation complexity. Note that TTL should align with how often inventory changes.

4. Evaluate Pre-allocation

Describe pre-allocating inventory blocks: guarantees availability and fast response, but risks over/under-allocation, wasted inventory, and reconciliation complexity. Suitable for high-demand, predictable inventory.

5. Recommend Hybrid Approach

Propose a combination: e.g., cache with short TTL for most searches, pre-allocate for peak or premium inventory, and fall back to real-time calls for cache misses or critical freshness. Justify based on the constraints from step 1.

Key Points to Mention

  • Latency vs. freshness trade-off: real-time calls are fresh but slow; caching is fast but may be stale; pre-allocation is fast and guaranteed but risks waste.
  • Cost implications: upstream API call costs, infrastructure for caching, and financial risk of unsold pre-allocated inventory.
  • Scalability: real-time calls may not scale under high QPS; caching and pre-allocation can handle higher loads.
  • Consistency and correctness: caching introduces eventual consistency; pre-allocation requires reconciliation with actual inventory.
  • Hybrid strategies: combine caching with TTL, pre-allocation for high-demand, and real-time fallback for misses.
  • Monitoring and adaptation: track cache hit rates, staleness, and upstream errors to dynamically adjust strategy.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q3

When your pre-allocated room pool runs out, do you make a live API call to the hotel or block the request and wait for a refill? How does each choice affect tail latency?

System DesignTechnical Trade-offs
Author's notes

Honestly the most interesting sub-question of the whole session.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Acknowledge that both options have trade-offs, but the best answer depends on the specific SLOs and business context. Propose a hybrid approach that uses a fast fallback (e.g., live API call with a tight timeout) and a circuit breaker to prevent cascading failures, while also considering asynchronous refill and request queuing with bounded wait times. Emphasize that tail latency is critical for user experience, so blocking indefinitely is rarely acceptable.

Pro tip: Show that you think in terms of percentiles (p99, p99.9) and not just averages, and mention that you'd instrument both paths to measure the actual tail latency impact before deciding. This demonstrates a data-driven approach and maturity.

1. Clarify requirements and constraints

Ask about the expected request rate, the size of the room pool, the acceptable latency SLOs, and the cost of a live API call (e.g., rate limits, latency).

2. Analyze the trade-offs of each option

For live API call: adds latency and potential failures but avoids blocking. For blocking: may cause timeouts and increased tail latency, but avoids external dependency.

3. Propose a hybrid solution

Suggest a fallback to live API with a short timeout (e.g., 100ms) and a circuit breaker to fail fast if the API is slow or down. Also consider asynchronous refill of the pool to reduce the chance of exhaustion.

4. Discuss tail latency implications

Explain that live API calls can increase p99 latency due to network variability, while blocking can cause queue buildup and timeouts, also increasing tail latency. A hybrid approach bounds the worst-case latency.

5. Mention monitoring and iteration

Emphasize the need to measure both approaches in production, monitor p99/p99.9 latencies, and adjust thresholds based on data.

Key Points to Mention

  • Tail latency is more important than average latency for user-facing systems.
  • Circuit breakers and timeouts prevent cascading failures.
  • Asynchronous refill of the pool can reduce the frequency of exhaustion.
  • Live API calls introduce external dependency and network variability.
  • Blocking can lead to thread pool exhaustion and increased latency for all requests.
  • Hybrid approaches with bounded wait times balance availability and latency.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q4

How would you design the cache invalidation and refresh strategy for room availability, and how do you partition that data across hotels, regions, and dates?

System DesignAPI & Integrations
Author's notes

Partitioning by hotel ID plus date felt natural and I said so.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the requirements: read/write patterns, consistency needs, and scale. Then propose a cache invalidation strategy that balances consistency and performance, such as event-driven invalidation with TTL as a fallback. Finally, describe a partitioning scheme that shards data by hotel, region, and date to distribute load and enable efficient queries.

Pro tip: Mention that you would monitor cache hit rates and invalidation latency, and be prepared to adjust the strategy based on real-world metrics. Also, consider using a write-through cache for critical availability data to ensure consistency.

1. Clarify Requirements

Ask about read/write ratio, consistency requirements, and scale (number of hotels, regions, dates). This informs the choice of caching and partitioning strategy.

2. Design Cache Invalidation

Propose an invalidation strategy: e.g., event-driven invalidation when availability changes, combined with a TTL to handle missed events. Discuss trade-offs between consistency and latency.

3. Choose Refresh Strategy

Decide between write-through, write-behind, or refresh-ahead based on access patterns. For high-read availability, consider proactive refresh for popular hotels/dates.

4. Partition Data

Describe partitioning across hotels, regions, and dates. For example, shard by hotel ID to keep all dates for a hotel together, or by region for geo-distribution. Use date-based partitioning for efficient range queries.

5. Address Hotspots and Failures

Discuss how to handle hot keys (e.g., popular hotels) and cache failures (e.g., fallback to database, circuit breakers). Mention monitoring and auto-scaling.

Key Points to Mention

  • Event-driven invalidation using a message queue (e.g., Kafka) to propagate changes.
  • TTL as a safety net to prevent stale data in case of missed invalidation events.
  • Write-through caching for strong consistency on critical updates.
  • Sharding by hotel ID to localize data and simplify invalidation per hotel.
  • Date-based partitioning to optimize queries for specific date ranges.
  • Handling hot keys with local caching or read replicas.
  • Monitoring cache hit rate and invalidation latency to tune strategy.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.