Design an artifact store on K8s and Cassandra
Company: NVIDIA
Role: Software Engineer
Category: System Design
Difficulty: hard
Interview Round: Technical Screen
You operate a Java web API on Kubernetes backed by a Cassandra cluster that stores artifacts identified by a user-provided name. The system must ensure each artifact name is created exactly once. a) How do you handle concurrent Create requests so only one succeeds? Specify the primary key schema, idempotency keys, and the concurrency-control mechanism (e.g., Cassandra LWT/IF NOT EXISTS, unique-name reservation rows, or a distributed lock), including retry behavior and failure modes. b) If a Delete capability is later introduced, how do you model deletes and subsequent re-adds to avoid races and duplicates (e.g., soft deletes with tombstones, grace periods/TTLs, name reuse policy, and tombstone compaction considerations)? c) How do you design and optimize the Read API for latency and throughput while controlling consistency (e.g., read consistency levels, caching, pagination, read repair, replication factors, hot-partition mitigation, and fallback strategies during partial outages)?
Quick Answer: This question evaluates distributed-systems and system-design competencies, including concurrency control for unique-name creation, idempotency and retry semantics, deletion modeling (soft deletes, tombstones, TTL), and read-path consistency, caching and performance when running a Java API on Kubernetes with Cassandra storage.