Summary
Compatibility engine wrapping Go's net/http with H2C support. Works on all platforms (macOS, Windows, Linux). Implements the Engine interface.
Deliverables
StdEngine struct implementing Engine interface
- Wrap
net/http.Server with h2c.NewHandler for H2C support
- Bridge between
*celeris.Context and http.ResponseWriter/*http.Request
- Same application code works across all engines (io_uring, epoll, std)
- Graceful shutdown via
server.Shutdown(ctx)
Design
// StdEngine wraps net/http for cross-platform compatibility
type StdEngine struct {
server *http.Server
// ...
}
- H2C enabled via
golang.org/x/net/http2/h2c package
- Context bridging: convert between Celeris zero-copy context and stdlib request/response
- Metrics collection: request count, latency, connections via
ConnState hook
Tests
SDD Reference
Sections 2.3, 11.4
Dependencies
Depends on #2, #3, #4, #6
Summary
Compatibility engine wrapping Go's
net/httpwith H2C support. Works on all platforms (macOS, Windows, Linux). Implements theEngineinterface.Deliverables
StdEnginestruct implementingEngineinterfacenet/http.Serverwithh2c.NewHandlerfor H2C support*celeris.Contextandhttp.ResponseWriter/*http.Requestserver.Shutdown(ctx)Design
golang.org/x/net/http2/h2cpackageConnStatehookTests
h2c.NewHandler)SDD Reference
Sections 2.3, 11.4
Dependencies
Depends on #2, #3, #4, #6