Class NettyHttpServer

java.lang.Object
dev.enola.web.netty.NettyHttpServer
All Implemented Interfaces:
WebServer, AutoCloseable

public class NettyHttpServer extends Object implements WebServer
HTTP WebServer API implementation based on Netty.

Currently supports only HTTP 1.1, without TLS (SSL, https:). HTTP/2 support could be added, but requires TLS (not "technically" by the standard spec, but "practically" by all real-world browsers). TLS support is possible, but self-signed certs and what not are a PITA. The general idea is that a real-world Enola.dev server would anyway run behind a proxy server which does HTTP/2, compression, authentication, etc.

This code is based on Netty's Examples.

This is the successor of a first implementation that was based on com.sun.net.httpserver.HttpServer, which was abandoned because it could not support ThreadLocal.