MCPcopy Index your code
hub / github.com/apache/tomcat / buildGoaway

Method buildGoaway

test/org/apache/coyote/http2/Http2TestBase.java:881–893  ·  view source on GitHub ↗
(int streamId, int lastStreamId, long errorCode)

Source from the content-addressed store, hash-verified

879
880
881 byte[] buildGoaway(int streamId, int lastStreamId, long errorCode) {
882 byte[] goawayFrame = new byte[17];
883 ByteUtil.setThreeBytes(goawayFrame, 0, 8);
884 // Type
885 goawayFrame[3] = FrameType.GOAWAY.getIdByte();
886 // No flags
887 // Stream
888 ByteUtil.set31Bits(goawayFrame, 5, streamId);
889 // Last stream
890 ByteUtil.set31Bits(goawayFrame, 9, lastStreamId);
891 ByteUtil.setFourBytes(goawayFrame, 13, errorCode);
892 return goawayFrame;
893 }
894
895
896 void sendGoaway(int streamId, int lastStreamId, long errorCode) throws IOException {

Callers 1

sendGoawayMethod · 0.95

Calls 4

setThreeBytesMethod · 0.95
set31BitsMethod · 0.95
setFourBytesMethod · 0.95
getIdByteMethod · 0.80

Tested by

no test coverage detected