Scrivio Interview library

Dropwizard

17 questions in 4 subtopics.

Dropwizard application and configuration

ConceptFoundations6 min read
Describe the structure of a Dropwizard application: the Application class, Configuration, Bootstrap and Environment. What happens when you run java -jar app.jar server config.yml?
CodingFoundations6 min read
In Dropwizard, how do you put a database password from an environment variable into config.yml, and override the HTTP port at start without editing the file?
InternalsIntermediate7 min read
How do Managed objects and bundles work in Dropwizard, and how would you make sure a Kafka consumer stops cleanly when the service shuts down?
ScenarioIntermediate7 min read
A team upgrades an old Dropwizard 1.x service to the current major version. What changes and risks would you plan for?
LeadershipAdvanced6 min read
Your company has 60 Dropwizard services built since 2014 and new services are written in Spring Boot. Do you migrate the Dropwizard services, and how would you decide?
LeadershipPrincipal6 min read
Dropwizard once represented an opinionated bundle of best-of-breed libraries: Jetty, Jersey, Jackson and Metrics. Spring Boot later dominated. What lessons from that history apply to choosing or building an internal platform today?

Dropwizard HTTP client

CodingFoundations7 min read
Show how to build an HTTP client in a Dropwizard application with configured timeouts and connection pool size, and explain why you would use Dropwizard's builder rather than a plain client.
DebuggingIntermediate7 min read
A Dropwizard service calling a slow partner API starts timing out on every request, and metrics show the HTTP client's pool fully leased with requests waiting. What is wrong and how do you fix it?
DesignAdvanced7 min read
Dozens of Dropwizard services call each other with hand-built clients. Design a standard client library for them.

Dropwizard authentication

CodingFoundations6 min read
Protect a Dropwizard resource with bearer token authentication using dropwizard-auth. Show the main classes and how a resource method gets the user.
ScenarioIntermediate7 min read
A Dropwizard authenticator validates tokens by calling the identity provider on every request, and the provider becomes a bottleneck. How would you improve it?
DesignAdvanced6 min read
Your Dropwizard and Spring Boot services each implement authentication differently. Design a consistent approach across both stacks.
LeadershipPrincipal6 min read
Older Dropwizard services each contain home-grown authenticators backed by a legacy user database, written by teams that have since left. How do you plan the move to a central identity provider, and would you build or buy it?

Dropwizard health checks

ConceptFoundations6 min read
How do you write and register a health check in Dropwizard, and where does it appear? Why does Dropwizard warn at start if you have none?
ScenarioIntermediate7 min read
Kubernetes restarts all pods of a Dropwizard service whenever the database is briefly unavailable, because the liveness probe calls /healthcheck. What is wrong and how would you set up probes correctly?
LeadershipAdvanced6 min read
After an outage where all services reported healthy while customers saw errors, leadership asks you to fix health checking across Dropwizard and Spring Boot services. What standard would you set?
DesignPrincipal6 min read
Health endpoints, metrics and logs have evolved from Dropwizard Metrics and Codahale health checks to Micrometer and OpenTelemetry. How would you set a long-term observability direction for a mixed estate?