Recall & Review
beginner
What is API versioning in microservices?
API versioning is the practice of managing changes to an API by creating different versions. It helps services evolve without breaking existing clients.
Click to reveal answer
beginner
Name two common ways to specify API versions.
1. URL path versioning (e.g., /v1/resource)<br>2. Header versioning (e.g., custom header like X-API-Version)
Click to reveal answer
intermediate
Why is backward compatibility important in API versioning?
Backward compatibility ensures that older clients can still use the API without breaking when new versions are released.
Click to reveal answer
intermediate
What is semantic versioning and how does it relate to API versioning?
Semantic versioning uses MAJOR.MINOR.PATCH format to indicate changes. Major changes break compatibility, minor add features, patch fixes bugs. It guides API version updates.
Click to reveal answer
intermediate
Explain the difference between URL path versioning and header versioning.
URL path versioning includes the version in the URL making it visible and cache-friendly. Header versioning hides version info in headers, keeping URLs clean but harder to cache.
Click to reveal answer
Which of the following is NOT a common API versioning method?
✗ Incorrect
Database schema versioning is about database changes, not API versioning.
What does a major version change usually indicate in API versioning?
✗ Incorrect
Major version changes usually mean breaking changes that can break existing clients.
Why might you choose header versioning over URL path versioning?
✗ Incorrect
Header versioning keeps URLs clean by hiding version info in headers.
What is a risk of not using API versioning?
✗ Incorrect
Without versioning, changes can break existing clients.
Which versioning method is easiest for caching proxies to handle?
✗ Incorrect
URL path versioning makes version part of the URL, which caching proxies can easily cache.
Describe the main strategies for API versioning and their pros and cons.
Think about visibility, caching, and client complexity.
You got /4 concepts.
Explain why API versioning is critical in microservices and how it supports service evolution.
Consider how many clients use the service and how often it changes.
You got /4 concepts.