InterviewStack.io LogoInterviewStack.io

Performance Engineering and Cost Optimization Questions

Engineering practices and trade offs for meeting performance objectives while controlling operational cost. Topics include setting latency and throughput targets and latency budgets; benchmarking profiling and tuning across application database and infrastructure layers; memory compute serialization and batching optimizations; asynchronous processing and workload shaping; capacity estimation and right sizing for compute and storage to reduce cost; understanding cost drivers in cloud environments including network egress and storage tiering; trade offs between real time and batch processing; and monitoring to detect and prevent performance regressions. Candidates should describe measurement driven approaches to optimization and be able to justify trade offs between cost complexity and user experience.

MediumTechnical
55 practiced
Serverless functions in production suffer occasional cold starts that violate a 100ms P95 latency SLO. Describe mitigation techniques (for example provisioned concurrency, keep-alive warmers, reducing package size), the cost and operational trade-offs of each, and an experimental plan to measure whether each approach meets the SLO while minimizing incremental cost.
MediumTechnical
43 practiced
A production API shows occasional, significant P99 latency spikes while P50 and P95 remain relatively stable. Describe a step-by-step investigation plan covering application tracing, runtime (GC, thread pool), database checks, network and infra measurements. Name specific tools or metrics you'd use at each step and quick mitigations you might try while the investigation continues.
EasyTechnical
55 practiced
Explain asynchronous processing patterns such as background workers, message queues, and event streams. Describe when to prefer asynchronous designs over synchronous ones, and how asynchronous architectures influence capacity planning, operational complexity, and cost profiles.
HardTechnical
61 practiced
Create a plan to instrument a backend service to measure the cost and latency contributions of serialization/deserialization and network I/O. Specify which trace spans, metrics, and profiling data you would collect, how to attribute end-to-end latency to serialization vs transport, and what experiments you would run to justify changing formats or enabling compression.
MediumTechnical
46 practiced
Write (or describe in pseudocode) a Python script that parses an HTTP access log where each entry includes timestamp, request path, status, and latency-ms. The script should compute request rate, p50, p95, p99 latencies, and error rate for a given time window. Explain how you would modify your approach to work on streaming logs and very large datasets without storing all latencies in memory.

Unlock Full Question Bank

Get access to hundreds of Performance Engineering and Cost Optimization interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.