Home / Function/ preflightRequestWithConnectionKeepAliveShouldStayOpen() — netty Function Reference

preflightRequestWithConnectionKeepAliveShouldStayOpen() — netty Function Reference

Architecture documentation for the preflightRequestWithConnectionKeepAliveShouldStayOpen() function in CorsHandlerTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  582efbff_0155_22d4_8e7e_859bd5724c67["preflightRequestWithConnectionKeepAliveShouldStayOpen()"]
  e946b2e4_b243_053e_5c0a_3d1a9a50042d["CorsHandlerTest"]
  582efbff_0155_22d4_8e7e_859bd5724c67 -->|defined in| e946b2e4_b243_053e_5c0a_3d1a9a50042d
  style 582efbff_0155_22d4_8e7e_859bd5724c67 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-http/src/test/java/io/netty/handler/codec/http/cors/CorsHandlerTest.java lines 394–408

    @Test
    public void preflightRequestWithConnectionKeepAliveShouldStayOpen() throws Exception {

        final CorsConfig config = forOrigin("http://localhost:8888").build();
        final EmbeddedChannel channel = new EmbeddedChannel(new CorsHandler(config));
        final FullHttpRequest request = optionsRequest("http://localhost:8888", "", KEEP_ALIVE);
        assertFalse(channel.writeInbound(request));
        final HttpResponse response = channel.readOutbound();
        assertTrue(HttpUtil.isKeepAlive(response));

        assertTrue(channel.isOpen());
        assertEquals(OK, response.status());
        assertTrue(ReferenceCountUtil.release(response));
        assertFalse(channel.finish());
    }

Domain

Subdomains

Frequently Asked Questions

What does preflightRequestWithConnectionKeepAliveShouldStayOpen() do?
preflightRequestWithConnectionKeepAliveShouldStayOpen() is a function in the netty codebase, defined in codec-http/src/test/java/io/netty/handler/codec/http/cors/CorsHandlerTest.java.
Where is preflightRequestWithConnectionKeepAliveShouldStayOpen() defined?
preflightRequestWithConnectionKeepAliveShouldStayOpen() is defined in codec-http/src/test/java/io/netty/handler/codec/http/cors/CorsHandlerTest.java at line 394.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free