MCPcopy Create free account
hub / github.com/apache/tomcat / finishResponse

Method finishResponse

java/org/apache/coyote/ajp/AjpProcessor.java:1009–1029  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1007
1008
1009 @Override
1010 protected final void finishResponse() throws IOException {
1011 if (responseFinished) {
1012 return;
1013 }
1014
1015 responseFinished = true;
1016
1017 // Swallow the unread body packet if present
1018 if (waitingForBodyMessage || first && request.getContentLengthLong() > 0) {
1019 refillReadBuffer(true);
1020 }
1021
1022 // Add the end message
1023 if (getErrorState().isError()) {
1024 socketWrapper.write(true, endAndCloseMessageArray, 0, endAndCloseMessageArray.length);
1025 } else {
1026 socketWrapper.write(true, endMessageArray, 0, endMessageArray.length);
1027 }
1028 socketWrapper.flush(true);
1029 }
1030
1031
1032 @Override

Callers 1

serviceMethod · 0.95

Calls 6

refillReadBufferMethod · 0.95
getErrorStateMethod · 0.80
getContentLengthLongMethod · 0.65
writeMethod · 0.65
flushMethod · 0.65
isErrorMethod · 0.45

Tested by

no test coverage detected