Package ratpack.core.handling
Interface RequestOutcome
-
public interface RequestOutcome
The outcome of processing a request.- See Also:
Context.onClose(Action)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default Duration
getDuration()
The amount of elapsed time betweenRequest.getTimestamp()
andgetSentAt()
.Request
getRequest()
The request.SentResponse
getResponse()
The response.Instant
getSentAt()
The time at when this request was dealt with from the application's point of view.
-
-
-
Method Detail
-
getRequest
Request getRequest()
The request.- Returns:
- the request
-
getResponse
SentResponse getResponse()
The response.- Returns:
- the response
-
getSentAt
Instant getSentAt()
The time at when this request was dealt with from the application's point of view.After this instant, it may have taken further time to actually get the response bytes to the client. That is, this timestamp effectively denotes when application processing of the request finished.
- Returns:
- the instant at which the response was sent
-
getDuration
default Duration getDuration()
The amount of elapsed time betweenRequest.getTimestamp()
andgetSentAt()
.This is the wall clock time, not the CPU time. It does not include the time taken to send the response bytes to the client.
- Returns:
- how long it took to process the request
-
-