Skip to content
Sharp

Spring Core · interview question

How does using DTOs in a Spring application help maintain API versioning?

Multiple choiceHardchapter-9-curatedpremiumspring-coredtos-and-entities
Choose one answer
Answer and explanation

Correct answer

C. Allows changing the underlying entity model without affecting the API.

Why

DTOs abstract the API layer from the internal entity models, allowing changes to internal structures without impacting the external API contract, which is vital for API versioning.

Test yourself on Spring Core

A free test with instant, explained results. No account needed.

Start free test
All Spring Core questions →