Interface ApiVersionDeprecationHandler
- All Known Implementing Classes:
StandardApiVersionDeprecationHandler
public interface ApiVersionDeprecationHandler
Contract to add handling of requests with a deprecated API version. Typically,
this involves use of response headers to send hints and information about
the deprecated version to clients.
- Since:
- 7.0
- Author:
- Rossen Stoyanchev
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
handleVersion
(Comparable<?> version, HttpServletRequest request, HttpServletResponse response) Check if the requested API version is deprecated, and if so handle it accordingly, e.g.
-
Method Details
-
handleVersion
Check if the requested API version is deprecated, and if so handle it accordingly, e.g. by setting response headers to signal the deprecation, to specify relevant dates and provide links to further details.- Parameters:
version
- the resolved and parsed request versionrequest
- the current requestresponse
- the current response
-