📁

55 Files

Comprehensive implementation

💻

~21,835 Lines

Production-ready code

📚

11 Modules

Well-organized structure

Directory Structure

  • jvr-netstack/
    • src/ — Core implementation (~15,270 lines)
      • core/ — Foundation (~1,500 lines)
        • error.c (250 lines) - Error handling
        • memory.c (420 lines) - Memory management & pools
        • buffer.c (380 lines) - Dynamic buffers
        • event.c (450 lines) - Event loop (epoll/kqueue/IOCP)
      • socket/ — Socket layer (~1,200 lines)
        • socket.c (650 lines) - Cross-platform sockets
        • dns.c (550 lines) - DNS + Happy Eyeballs
      • tls/ — TLS layer (~800 lines)
        • tls.c (800 lines) - TLS 1.3 & 1.2, ALPN, SNI
      • http/ — HTTP stack (~4,200 lines)
        • http.c (1,100 lines) - HTTP/1.1 engine
        • client.c (850 lines) - High-level client API
        • pool.c (650 lines) - Connection pooling
        • http2.c (1,200 lines) - HTTP/2 with HPACK
        • http3.c (400 lines) - HTTP/3 over QUIC
      • quic/ — QUIC protocol (~2,800 lines)
        • quic.c (2,350 lines) - QUIC RFC 9000 implementation
        • quic_advanced.c (450 lines) - Migration & 0-RTT
      • websocket/ — WebSocket (~900 lines)
        • websocket.c (900 lines) - RFC 6455 WebSocket
      • resilience/ — Resilience patterns (~650 lines)
        • circuit_breaker.c (650 lines) - Circuit breaker
      • middleware/ — Middleware system (~720 lines)
        • middleware.c (720 lines) - Pipeline & middlewares
      • cache/ — Caching layer (~850 lines)
        • response_cache.c (850 lines) - HTTP caching
      • observability/ — Metrics system (~800 lines)
        • metrics.c (800 lines) - Prometheus metrics
    • include/ — Public headers (~2,300 lines)
      • jvr/
        • client.h - Client API
        • http.h - HTTP protocol
        • http2.h - HTTP/2 API
        • http3.h - HTTP/3 API
        • quic.h - QUIC API
        • quic_advanced.h - Advanced QUIC
        • websocket.h - WebSocket API
        • circuit_breaker.h - Circuit breaker
        • middleware.h - Middleware
        • response_cache.h - Caching
        • metrics.h - Observability
    • examples/ — Example apps (~1,030 lines)
      • simple_http_get.c (98 lines)
      • http2_multiplexing.c (155 lines)
      • websocket_chat.c (178 lines)
      • circuit_breaker_demo.c (165 lines)
      • middleware_pipeline.c (200 lines)
      • response_caching.c (220 lines)
      • README.md (369 lines)
    • tests/ — Test suite (~350 lines)
      • test_framework.h (151 lines)
      • test_core.c (205 lines)
    • tools/ — CLI tools (~510 lines)
      • jvrcurl/
        • main.c (510 lines) - curl clone
    • docs/ — Documentation (~4,500 lines)
      • MasterContext.md
      • OriginalPlan.md
      • BuildPlan.md
      • ContinuePrompt.md
      • HTTP3_COMPLETE.md
      • EXAMPLES_COMPLETE.md
      • ADVANCED_FEATURES_COMPLETE.md
      • README.md
    • CMakeLists.txt (175 lines) - Build system
    • LICENSE (MIT)
    • .gitignore

Module Breakdown

Module Files Lines Description
Core 4 ~1,500 Foundation (error, memory, buffers, events)
Socket 2 ~1,200 Cross-platform sockets + DNS
TLS 1 ~800 TLS 1.3/1.2 with OpenSSL
HTTP 5 ~4,200 HTTP/1.1, HTTP/2, HTTP/3 stack
QUIC 2 ~2,800 QUIC protocol + advanced features
WebSocket 1 ~900 RFC 6455 WebSocket
Resilience 1 ~650 Circuit breaker pattern
Middleware 1 ~720 Request/response pipeline
Cache 1 ~850 HTTP response caching
Observability 1 ~800 Metrics & monitoring
Examples 7 ~1,030 Demo applications

Key Files

📘 include/jvr/client.h

High-level HTTP client API - your main entry point

📘 include/jvr/quic_advanced.h

Connection migration & 0-RTT (unique features!)

📘 include/jvr/metrics.h

Built-in observability system

💻 src/quic/quic.c

Largest file (2,350 lines) - Complete QUIC implementation

💻 src/http/http2.c

Full HTTP/2 with HPACK compression

📝 CMakeLists.txt

Build configuration for all platforms