Class UnconsumedArgumentRelease
java.lang.Object
io.micronaut.http.server.binding.UnconsumedArgumentRelease
Releases bound argument values that are owned by the route (for example a refcounted body)
when the request ends before the route was invoked. Each value belongs to the route whose
binding produced it, so invoking another route for the same request (an error or status
route) does not take over the values of a route that never ran.
- Since:
- 5.2.21
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidadd(LifecycleHttpRequest<?> request, Runnable release) Release a bound argument value with the request, unless the route that is currently matched for the request is invoked first.static voidrouteInvoked(HttpRequest<?> request, RouteInfo<?> routeInfo) Called when a route is invoked: the route now owns its argument values.
-
Method Details
-
add
Release a bound argument value with the request, unless the route that is currently matched for the request is invoked first.- Parameters:
request- The requestrelease- Releases the value
-
routeInvoked
Called when a route is invoked: the route now owns its argument values.- Parameters:
request- The requestrouteInfo- The invoked route
-