|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
public interface RoutesCache
By default the Routes engine will sequential check each route method until a match is found. With lots of route methods, this can potentially become a performance bottle neck. If a cache implementation is provided, the Routes engine will first check the cache for a hit before running the sequential check.
RoutesConfiguration.routesCache| Method Summary | |
|---|---|
java.lang.Object |
get(HttpMethod method,
RequestedMediaType requestedMediaType,
RequestPath path,
RequestParameters parameters)
Retrieve the cached route instance or null on a cache miss. |
void |
put(java.lang.Object routeNode,
HttpMethod method,
RequestedMediaType requestedMediaType,
RequestPath path,
RequestParameters parameters)
Called after a request has been processed by the given routeNode. |
| Method Detail |
|---|
void put(java.lang.Object routeNode,
HttpMethod method,
RequestedMediaType requestedMediaType,
RequestPath path,
RequestParameters parameters)
routeNode. This request should be cached for later retrieval
from get when the HTTP request input parameters match.
routeNode - The route instance to be retrieved later from get.method - The HTTP method.requestedMediaType - The requested media type.path - The HTTP path.parameters - The HTTP parameters.
java.lang.Object get(HttpMethod method,
RequestedMediaType requestedMediaType,
RequestPath path,
RequestParameters parameters)
null on a cache miss.
method - The HTTP method.requestedMediaType - The requested media type.path - The HTTP path.parameters - The HTTP parameters.
null on a cache miss.
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||