Package org.restheart.mongodb.handlers
Class SizeRequestTransformer
- java.lang.Object
-
- org.restheart.handlers.PipelinedHandler
-
- org.restheart.mongodb.handlers.SizeRequestTransformer
-
- All Implemented Interfaces:
io.undertow.server.HttpHandler
public class SizeRequestTransformer extends PipelinedHandler
For count request (/_size) sets the pagesize to 0 to avoid retrieving data and sets response content to just contain the _size property- Author:
- Andrea Di Cesare <andrea@softinstigate.com>
-
-
Field Summary
-
Fields inherited from class org.restheart.handlers.PipelinedHandler
CONTENT_TYPE
-
-
Constructor Summary
Constructors Constructor Description SizeRequestTransformer(boolean phase)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidhandleRequest(io.undertow.server.HttpServerExchange exchange)-
Methods inherited from class org.restheart.handlers.PipelinedHandler
getNext, next, pipe, setNext
-
-
-
-
Method Detail
-
handleRequest
public void handleRequest(io.undertow.server.HttpServerExchange exchange) throws Exception- Specified by:
handleRequestin interfaceio.undertow.server.HttpHandler- Specified by:
handleRequestin classPipelinedHandler- Parameters:
exchange-- Throws:
Exception
-
-