HttpCorsServer Class — netty Architecture
Architecture documentation for the HttpCorsServer class in HttpCorsServer.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD c654e8a2_cbeb_5bae_4d48_18ae9fbb5221["HttpCorsServer"] 5dfa0077_d85f_19c5_cc67_eb02d5cace7a["HttpCorsServer.java"] c654e8a2_cbeb_5bae_4d48_18ae9fbb5221 -->|defined in| 5dfa0077_d85f_19c5_cc67_eb02d5cace7a 45db7b0d_4f13_5111_3fce_d718918e8cef["main()"] c654e8a2_cbeb_5bae_4d48_18ae9fbb5221 -->|method| 45db7b0d_4f13_5111_3fce_d718918e8cef
Relationship Graph
Source Code
example/src/main/java/io/netty/example/http/cors/HttpCorsServer.java lines 74–96
public final class HttpCorsServer {
static final boolean SSL = System.getProperty("ssl") != null;
static final int PORT = Integer.parseInt(System.getProperty("port", SSL? "8443" : "8080"));
public static void main(String[] args) throws Exception {
// Configure SSL.
final SslContext sslCtx = ServerUtil.buildSslContext();
EventLoopGroup group = new MultiThreadIoEventLoopGroup(NioIoHandler.newFactory());
try {
ServerBootstrap b = new ServerBootstrap();
b.group(group)
.channel(NioServerSocketChannel.class)
.handler(new LoggingHandler(LogLevel.INFO))
.childHandler(new HttpCorsServerInitializer(sslCtx));
b.bind(PORT).sync().channel().closeFuture().sync();
} finally {
group.shutdownGracefully();
}
}
}
Source
Frequently Asked Questions
What is the HttpCorsServer class?
HttpCorsServer is a class in the netty codebase, defined in example/src/main/java/io/netty/example/http/cors/HttpCorsServer.java.
Where is HttpCorsServer defined?
HttpCorsServer is defined in example/src/main/java/io/netty/example/http/cors/HttpCorsServer.java at line 74.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free