← Soti Interview Insights

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

SeniorPrefer not to say
May 2026

Summary

System design round at Soti for a software engineer role, focused entirely on designing an IP firewall blacklist service. The whole session revolved around caching and read-path latency, which I wasn't fully prepared to go deep on.

Questions Asked (5)

Q1

Design the API surface for an IP firewall blacklist system that supports adding, removing, updating, and querying blacklisted IPs and CIDR ranges.

API & IntegrationsSystem DesignData Modeling
Author's notes

Started with the obvious CRUD endpoints and felt okay about it until they asked how I'd handle CIDR ranges differently from exact IPs in the API contract.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying requirements and constraints, then design a RESTful API with clear resource modeling for IPs and CIDR ranges, ensuring idempotency and proper error handling. Discuss data modeling considerations like normalization and indexing, and cover operational aspects such as pagination, filtering, and bulk operations.

Pro tip: Demonstrate awareness of real-world firewall integration by discussing how the API will be consumed by enforcement points, and mention the importance of atomic updates and audit trails for security-sensitive operations.

1. Clarify Requirements and Constraints

Ask about scale, consistency needs, authentication, and whether the API is for internal or external use. Confirm if bulk operations and querying by attributes like expiration or reason are needed.

2. Define Resource Model and Endpoints

Model blacklist entries as resources with fields like IP/CIDR, action, expiration, and metadata. Design RESTful endpoints for CRUD operations, using appropriate HTTP methods and status codes.

3. Address Data Modeling and Validation

Discuss how to store IPs and CIDRs efficiently, including normalization and indexing. Explain validation rules to prevent invalid entries and ensure CIDR notation correctness.

4. Incorporate Operational Features

Include pagination, filtering, sorting, and bulk operations for scalability. Mention idempotency for safe retries and rate limiting for abuse prevention.

5. Discuss Security and Integration

Cover authentication, authorization, and audit logging. Explain how the API integrates with firewall systems, possibly via webhooks or polling, and how to handle conflicts or updates.

Key Points to Mention

  • RESTful design with proper HTTP methods and status codes (e.g., POST /blacklist, GET /blacklist/{id}, PUT/PATCH, DELETE)
  • Idempotency for add/update operations to avoid duplicates and ensure safe retries
  • Data modeling: storing IPs as integers or strings, using CIDR libraries, and indexing for fast lookups
  • Pagination and filtering for querying large blacklists (e.g., by IP range, expiration date)
  • Bulk operations (e.g., bulk add/remove) to support efficient management
  • Security considerations: authentication (API keys, OAuth), authorization (RBAC), and audit logging for compliance

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

Q2

How would you store exact IP addresses alongside CIDR ranges in the backend, and what data structures or storage systems would you use?

System DesignData ModelingAlgorithms & Data Structures
Author's notes

This tripped me up more than I expected.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying requirements: whether exact IPs and CIDR ranges are stored together or separately, and what queries will be run (e.g., lookup by IP, range containment). Then propose a hybrid storage model: store exact IPs as integers (or binary) in a relational or key-value store, and CIDR ranges as start/end integer pairs in a separate table or index, using a data structure like a sorted array or interval tree for efficient range queries. Finally, discuss trade-offs between relational databases, NoSQL, and specialized in-memory structures.

Pro tip: Mention that you would normalize IPs to integers for compact storage and fast comparison, and consider using a database with native IP/CIDR support (e.g., PostgreSQL's inet/cidr types) to avoid reinventing the wheel. Also, highlight the importance of indexing for range queries, such as using a GiST index on a range type.

1. Clarify requirements and access patterns

Ask whether exact IPs and CIDR ranges are stored together or separately, and what queries are needed (e.g., point lookup, range containment, overlap). This determines the optimal data model and indexing strategy.

2. Choose a storage representation

Represent exact IPs as 32-bit (IPv4) or 128-bit (IPv6) integers for efficient storage and comparison. For CIDR ranges, store as start and end integers, or use a native CIDR type if the database supports it.

3. Select storage system and schema

For relational databases, use separate tables for exact IPs and CIDR ranges, with appropriate indexes (e.g., B-tree for exact IPs, GiST for ranges). For NoSQL, consider a key-value store with IP as key and a sorted set or interval tree for ranges.

4. Implement efficient querying

For exact IP lookup, use a hash index or B-tree. For CIDR containment, use an interval tree, segment tree, or database range index. If using PostgreSQL, leverage the inet/cidr types and GiST indexes for containment queries.

5. Discuss trade-offs and scalability

Compare relational vs. NoSQL vs. in-memory solutions in terms of query performance, storage overhead, and scalability. Mention partitioning or sharding for large datasets, and caching for frequent lookups.

Key Points to Mention

  • IP address normalization to integers for compact storage and fast comparison
  • Use of native database types (e.g., PostgreSQL inet/cidr) to simplify storage and querying
  • Indexing strategies: B-tree for exact IPs, GiST or SP-GiST for range types
  • Data structures for in-memory range queries: interval tree, segment tree, or sorted array with binary search
  • Trade-offs between relational databases (strong consistency, complex queries) and NoSQL (scalability, flexibility)
  • Handling IPv4 vs. IPv6 and mixed storage, including conversion and compatibility

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

Q3

How would you design the read path for blacklist checks to achieve very low latency at high throughput?

System DesignTechnical Trade-offs
Author's notes

This was the core of the whole interview.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying requirements: expected QPS, latency target, data size, update frequency, and consistency needs. Then propose a layered architecture: an in-memory cache (e.g., Redis or local cache) backed by a persistent store, with a write path that updates the cache asynchronously. Discuss trade-offs like cache invalidation, sharding, and read replicas to achieve low latency at high throughput.

Pro tip: Emphasize the importance of measuring and monitoring latency percentiles (p99, p999) and having a fallback mechanism to handle cache misses gracefully without impacting the overall system. Also, mention that you would consider using a bloom filter to quickly rule out non-blacklisted items, reducing cache lookups.

1. Clarify Requirements

Ask about expected throughput (QPS), latency SLA, data size, update frequency, and consistency requirements (e.g., eventual vs strong). This ensures the design meets actual needs.

2. High-Level Architecture

Propose a multi-tiered read path: in-memory cache (e.g., Redis) for hot data, possibly a local cache for ultra-low latency, and a persistent database (e.g., Cassandra) as the source of truth. Use a write path that updates the cache asynchronously or via change data capture.

3. Optimize for Latency and Throughput

Discuss techniques like sharding the cache, using read replicas, connection pooling, and batching. Consider using a bloom filter to avoid unnecessary cache lookups for non-blacklisted items.

4. Handle Consistency and Failures

Address cache invalidation strategies (TTL, write-through, write-behind), handling cache misses (fallback to DB with circuit breaker), and ensuring high availability (replication, failover).

5. Monitor and Iterate

Mention the need for monitoring latency (p50, p95, p99), throughput, cache hit ratio, and error rates. Be prepared to iterate based on metrics.

Key Points to Mention

  • Use of in-memory data stores like Redis or Memcached for low-latency reads.
  • Sharding and replication to scale horizontally and handle high throughput.
  • Bloom filters to reduce unnecessary lookups for non-blacklisted items.
  • Cache invalidation strategies (TTL, write-through, write-behind) and their trade-offs.
  • Fallback mechanisms and circuit breakers to handle cache failures gracefully.
  • Monitoring and metrics to ensure SLAs are met and to identify bottlenecks.

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

Q4

Walk through how cache invalidation and update propagation would work when the blacklist changes.

System DesignTechnical Trade-offs
Author's notes

Went with a pub/sub model pushing diffs to gateway nodes.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the system context: what the blacklist is used for, where it's cached, and the consistency requirements. Then describe the end-to-end flow from blacklist update to cache invalidation and propagation, highlighting trade-offs between consistency, latency, and complexity. Finally, discuss failure modes and mitigation strategies.

Pro tip: Emphasize that cache invalidation is not just about deleting keys; it's about ensuring all layers (CDN, application cache, database) are updated in the right order to avoid stale reads. Mention that you'd monitor invalidation lag and have a fallback to bypass cache if needed.

1. Clarify requirements and context

Ask about the blacklist's purpose, expected update frequency, read/write ratio, and consistency needs (e.g., is eventual consistency acceptable?). Identify all cache layers involved.

2. Describe the update propagation flow

Explain how a blacklist change is written to the source of truth (e.g., database) and then propagated to caches. Discuss push vs. pull models and ordering.

3. Detail cache invalidation strategies

Cover techniques like TTL, write-through, write-behind, and explicit invalidation. Explain how to handle distributed caches and avoid race conditions.

4. Address consistency and failure handling

Discuss trade-offs between strong and eventual consistency, and how to handle failures (e.g., retries, dead-letter queues, fallback to source).

5. Summarize trade-offs and recommendations

Conclude with a recommended approach based on the requirements, and mention monitoring and testing strategies.

Key Points to Mention

  • Cache invalidation patterns: write-through, write-behind, and cache-aside
  • Propagation mechanisms: pub/sub, message queues, or change data capture
  • Consistency models: strong vs. eventual consistency and their implications
  • Handling race conditions and stale reads (e.g., versioning, timestamps)
  • Failure modes: cache stampede, network partitions, and retry strategies
  • Monitoring and observability: metrics for invalidation lag and cache hit ratio

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

Q5

How would you handle scale, consistency tradeoffs, failure scenarios, and observability for this system?

System DesignTechnical Trade-offs
Author's notes

Felt like a cleanup question at the end to see how broadly I could think.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Structure your answer around the four dimensions—scale, consistency, failure, and observability—by first clarifying requirements and then discussing trade-offs for each. Use a concrete example from Soti's domain (e.g., IoT device management) to ground your reasoning and show practical judgment.

Pro tip: Always tie trade-offs back to business impact and explicitly state your assumptions; this shows you can make pragmatic decisions under uncertainty, which is highly valued at Soti.

1. Clarify Requirements and Constraints

Ask questions to understand expected scale (e.g., number of devices, QPS), consistency needs (strong vs eventual), failure tolerance, and observability goals. This ensures your answer is tailored to the actual problem.

2. Address Scale and Consistency Trade-offs

Discuss how you would scale (horizontal vs vertical, sharding, caching) and the consistency models you'd choose (e.g., eventual consistency for availability, strong consistency for critical data). Explain the trade-offs and justify your choices.

3. Design for Failure Scenarios

Outline strategies like redundancy, graceful degradation, circuit breakers, retries with backoff, and chaos engineering. Emphasize how you'd detect and recover from failures automatically.

4. Implement Observability

Describe logging, metrics, tracing, and alerting. Explain how you'd use tools like Prometheus, Grafana, or ELK to monitor system health and debug issues, and how observability informs capacity planning and failure response.

5. Summarize and Iterate

Recap key decisions and trade-offs, and mention that these are starting points that would be refined with real-world data and feedback. Show willingness to adapt.

Key Points to Mention

  • CAP theorem and its practical implications for distributed systems
  • Horizontal scaling with sharding and load balancing
  • Consistency models: strong vs eventual, and use cases for each
  • Failure mitigation: redundancy, circuit breakers, retries, and idempotency
  • Observability pillars: logging, metrics, tracing, and alerting
  • Soti's context: IoT device management, remote diagnostics, and scalability challenges

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