cannotSendGoAwayFrameWithIncreasingLastStreamIds() — netty Function Reference
Architecture documentation for the cannotSendGoAwayFrameWithIncreasingLastStreamIds() function in Http2ConnectionHandlerTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD a9289aa9_3851_e8af_e75f_8016e0966564["cannotSendGoAwayFrameWithIncreasingLastStreamIds()"] e8b32c7d_fa9d_422b_0744_82047ac00ea5["Http2ConnectionHandlerTest"] a9289aa9_3851_e8af_e75f_8016e0966564 -->|defined in| e8b32c7d_fa9d_422b_0744_82047ac00ea5 style a9289aa9_3851_e8af_e75f_8016e0966564 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
codec-http2/src/test/java/io/netty/handler/codec/http2/Http2ConnectionHandlerTest.java lines 674–699
@Test
public void cannotSendGoAwayFrameWithIncreasingLastStreamIds() throws Exception {
handler = newHandler();
ByteBuf data = dummyData();
long errorCode = Http2Error.INTERNAL_ERROR.code();
handler.goAway(ctx, STREAM_ID, errorCode, data.retain(), promise);
verify(connection).goAwaySent(eq(STREAM_ID), eq(errorCode), eq(data));
verify(frameWriter).writeGoAway(eq(ctx), eq(STREAM_ID), eq(errorCode), eq(data), eq(promise));
// The frameWriter is only mocked, so it should not have interacted with the promise.
assertFalse(promise.isDone());
when(connection.goAwaySent()).thenReturn(true);
when(remote.lastStreamKnownByPeer()).thenReturn(STREAM_ID);
doAnswer(new Answer<Boolean>() {
@Override
public Boolean answer(InvocationOnMock invocationOnMock) {
throw new IllegalStateException();
}
}).when(connection).goAwaySent(anyInt(), anyLong(), any(ByteBuf.class));
handler.goAway(ctx, STREAM_ID + 2, errorCode, data, promise);
assertTrue(promise.isDone());
assertFalse(promise.isSuccess());
assertEquals(0, data.refCnt());
verifyNoMoreInteractions(frameWriter);
}
Domain
Subdomains
Source
Frequently Asked Questions
What does cannotSendGoAwayFrameWithIncreasingLastStreamIds() do?
cannotSendGoAwayFrameWithIncreasingLastStreamIds() is a function in the netty codebase, defined in codec-http2/src/test/java/io/netty/handler/codec/http2/Http2ConnectionHandlerTest.java.
Where is cannotSendGoAwayFrameWithIncreasingLastStreamIds() defined?
cannotSendGoAwayFrameWithIncreasingLastStreamIds() is defined in codec-http2/src/test/java/io/netty/handler/codec/http2/Http2ConnectionHandlerTest.java at line 674.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free