Katkat

Design multi-core service startup scheduler

SnowflakeSoftware Engineer · Onsite

Last updated

This question evaluates scheduling and resource-management skills, including DAG dependency handling, concurrency bounding, timeout/retry strategies, observability, and correctness reasoning for service startup orchestration.

Services must start on a host with M CPU cores, and each service may depend on others (a DAG). Design a scheduler that minimizes total startup time while respecting dependencies. Discuss: detecting ready services, maximizing parallelism within core limits, prioritization, bounding concurrency, handling timeouts/retries/failures, backoff, resource constraints (CPU, memory, ports), and observability. Describe data structures (e.g., in-degree tracking, ready queues), correctness properties, and how you would extend it across multiple machines.