Skip to content
tezvyn:

⚙️Backend Dev

Backend engineering, APIs, and databases

280 bites

Test yourself: Top 30 advanced Backend Dev interview questionsMultiple choice, with the correct answer and why it is correct on every question. Free, no sign-in.

Advanced everything in Backend Dev, page 7

How does Uvicorn use asyncio to handle thousands of concurrent connections?
advanced2 min read

How does Uvicorn use asyncio to handle thousands of concurrent connections?

Tests async concurrency and the GIL. Great answers cover the event loop suspending coroutines at await, Uvicorn interleaving connections, and multi-process workers for parallelism. Red flag: claiming asyncio uses threads per request or bypasses the GIL.

FastAPI Container Build and Deploy Pipeline
advanced2 min read

FastAPI Container Build and Deploy Pipeline

Treat the Docker image as the immutable artifact: one build runs everywhere. Deploy FastAPI workers behind a load balancer, one process per container. The footgun is baking secrets into the image or running multiple processes; that breaks horizontal scaling.

advanced2 min read

Overriding FastAPI's OpenAPI Generator

FastAPI lets you swap app.openapi to reshape its generated schema without forking. Use this for vendor extensions, filtered operations, or merging external schemas. Forgetting to cache the result means every docs request rebuilds it and destroys performance.

Async Path Operations in FastAPI
advanced2 min read

Async Path Operations in FastAPI

FastAPI path operations can be async, letting the server switch to other requests during I/O waits. Declare dependencies and sub-dependencies async when they await external calls.

Python Async Context Managers
advanced2 min read

Python Async Context Managers

Async context managers let you await during setup and teardown. Use async with for database connections or streams where acquiring and releasing both need I/O. The footgun is applying @contextmanager to async cleanup, which cannot await and will crash.

advanced2 min read

Node.js DNS: lookup vs. resolve

Node.js splits DNS into two paths: dns.lookup uses getaddrinfo for IPs, while the dns.resolve family fetches records like MX or TXT. Use lookup for connections and the resolve family for service discovery.

advanced2 min read

Design a safe Rust wrapper taking &[i32] and returning Vec<i32>

Tests Rust FFI buffer-output encapsulation. A strong answer declares an unsafe extern C block, allocates a Vec with capacity, passes as_mut_ptr and a local size_t, validates returned length, then calls set_len.

advanced2 min read

Implement a custom derive macro for a Builder pattern

Tests proc-macro AST transformation. A strong answer lists: parse TokenStream with syn into DeriveInput, inspect fields, then quote builder code as TokenStream, noting the separate proc-macro crate. Red flag: treating tokens as strings instead of AST nodes.

advanced2 min read

Compare Go and Rust approaches to exposing profiling data

Contrast Go's pprof import with Rust crates or profilers, noting runtime versus OS-level sampling.

advanced2 min read

What does go mod tidy do beyond adding dependencies?

Tests reproducible Go module graph knowledge. A strong answer covers that tidy reconciles imports with go.mod, prunes unused modules, and ensures go.sum contains every checksum for the minimal build list.

advanced2 min read

How do you manage multiple related Rust crates as a single unit?

Tests Cargo workspaces for multi-crate Rust projects. Strong answers cite the [workspace] section, shared Cargo.lock, unified target directory, inherited metadata, and workspace-wide commands.

advanced2 min read

When should Rust atomics replace a Mutex, and how do orderings work?

Atomics replace mutexes for counters; Relaxed is atomicity only, SeqCst adds global order, weaker ones skip fences on ARM.

advanced2 min read

Describe Rust's orphan rule and its ecosystem purpose

State that either trait or type must be local; explain this stops conflicting foreign impls; note crates.io would see silent impl collisions breaking downstream builds.

advanced2 min read

Design a custom Go error type with context, Is, As, and Unwrap

This tests Go 1.13 error wrapping and Unwrap conventions. Answer: struct with Err and context fields; implement Error and Unwrap; note errors.Is and errors.As walk the chain. Red flag: stringifying the error via fmt.Errorf %v, which severs unwrapping.

advanced2 min read

Rust unsafe FFI vs Cgo: who owns memory safety?

Tests your grasp of where compiler guarantees end at the FFI boundary. A strong answer contrasts Rust raw-pointer validity and aliasing invariants in unsafe blocks against Cgo's automatic copying, pointer-passing restrictions, and runtime thread-switching…

advanced2 min read

Explain Rust Rc and Arc versus Go's tracing GC

This tests deterministic reference counting versus tracing GC. A strong answer contrasts Rc's heap reference counts with Go's root tracing, and notes Rc cannot reclaim cycles while Go's GC can. Red flag: claiming Rc has no cycle leak risk.

advanced2 min read

Explain Go escape analysis and Rust ownership for stack vs heap

Tests compiler-driven memory placement. Go escape analysis keeps non-escaping locals on stack, shrinking heap and GC work. Rust ownership lets the compiler pick stack or heap at build time with zero cost.

advanced3 min read

Compare enum vs trait objects for heterogeneous shapes in Rust

This tests compile-time vs run-time polymorphism in Rust. A strong answer contrasts enum's closed set, static dispatch, and stack layout against trait objects' open extensibility, heap allocation, and vtable indirection.

advanced2 min read

How does struct field ordering affect memory layout in Go and Rust?

It tests alignment, padding, and compiler layout knowledge. A strong answer explains that alignment inserts padding, Go and Rust keep declared order, and reordering by size can shrink size. Red flag: saying order is irrelevant or that compiler auto-packs.

advanced2 min read

Explain Go struct embedding vs inheritance and method promotion

What it tests: knowing Go composition and method promotion from embeds. Outline: embedding adds a type as part without is-a; promoted methods join the outer type; collisions resolve by outer-type precedence.

We are hiring for this. Every open role lists the topics its interview covers, so you can prepare for the real thing rather than guessing.

See open roles