Protocol Support

๐ŸŒ HTTP/1.1

Full HTTP/1.1 implementation with persistent connections, chunked encoding, and pipelining support.

  • โœ… GET, POST, PUT, DELETE, PATCH, HEAD, OPTIONS
  • โœ… Persistent connections (Keep-Alive)
  • โœ… Chunked transfer encoding
  • โœ… Compression (gzip, deflate)
  • โœ… Custom headers support
  • โœ… Cookie management

โšก HTTP/2

Binary framing with multiplexing for maximum performance.

  • โœ… Binary framing protocol
  • โœ… Stream multiplexing (100+ concurrent streams)
  • โœ… Server push support
  • โœ… Header compression (HPACK)
  • โœ… Stream prioritization
  • โœ… Flow control per stream
  • โœ… ALPN negotiation

๐Ÿš€ HTTP/3

The latest HTTP protocol built on QUIC for ultimate speed and reliability.

  • โœ… HTTP over QUIC transport
  • โœ… QPACK header compression
  • โœ… HTTP/3 framing (DATA, HEADERS, SETTINGS)
  • โœ… Control stream management
  • โœ… 0-RTT resumption
  • โœ… Connection migration

๐Ÿ”Œ WebSocket

Full-duplex communication channels for real-time applications.

  • โœ… RFC 6455 compliant
  • โœ… Text and binary frames
  • โœ… Fragmentation support
  • โœ… Ping/Pong heartbeat
  • โœ… Secure WebSocket (WSS)
  • โœ… Event-driven API

Advanced QUIC Features

๐Ÿ”„ Connection Migration

THE ONLY C LIBRARY WITH THIS FEATURE!

Seamlessly switch between networks (WiFi โ†” cellular) without dropping connections.

  • โœ… Automatic path validation
  • โœ… PATH_CHALLENGE/RESPONSE frames
  • โœ… Old and new path tracking
  • โœ… Graceful fallback on failure
  • โœ… < 100ms migration overhead
// Enable migration
jvr_quic_enable_migration(conn);

// Switch networks seamlessly
jvr_quic_migrate_connection(conn, new_ip, port);
// Connection continues without interruption!

โšก 0-RTT (Zero Round-Trip Time)

THE ONLY C LIBRARY WITH THIS FEATURE!

Send data before handshake completes - 50% faster reconnections!

  • โœ… Session ticket save/restore
  • โœ… Early data buffering
  • โœ… Cached transport parameters
  • โœ… 0-RTT acceptance checking
  • โœ… Configurable max early data (16KB default)
// Save session for future use
jvr_quic_save_session(conn, &ticket, &ticket_len);

// Later: Restore and send data immediately
jvr_quic_restore_session(new_conn, ticket, ticket_len);
jvr_quic_send_early_data(new_conn, data, len);
// Data sent before handshake completes!

๐Ÿ›ฃ๏ธ Path Validation

Probe alternate network paths without migration.

  • โœ… Multi-path probing
  • โœ… Path quality detection
  • โœ… Automatic failover
  • โœ… Network condition monitoring

Resilience & Performance

๐Ÿ›ก๏ธ Circuit Breaker Pattern

Prevent cascading failures in distributed systems.

  • โœ… Three states: CLOSED, OPEN, HALF_OPEN
  • โœ… Configurable failure threshold
  • โœ… Automatic timeout and recovery
  • โœ… Success threshold for closing
  • โœ… Real-time state monitoring

๐Ÿ”Œ Middleware Pipeline

Composable request/response processing.

  • โœ… Chain multiple middlewares
  • โœ… Built-in: logging, auth, compression
  • โœ… Custom middleware support
  • โœ… Pre/post request hooks
  • โœ… Context passing between middlewares

๐Ÿ’พ Intelligent Response Caching

HTTP-compliant caching with LRU eviction.

  • โœ… Cache-Control header support
  • โœ… ETag validation
  • โœ… Conditional requests (If-None-Match)
  • โœ… LRU eviction policy
  • โœ… Configurable size limits
  • โœ… Cache statistics and hit rates

๐ŸŠ Connection Pooling

Reuse connections for better performance.

  • โœ… Automatic connection reuse
  • โœ… Per-host connection limits
  • โœ… Idle connection timeout
  • โœ… Connection health checks
  • โœ… Thread-safe pool management

Observability & Metrics

๐Ÿ“Š Built-in Metrics System

THE ONLY C LIBRARY WITH BUILT-IN OBSERVABILITY!

Production-ready metrics without external dependencies.

  • โœ… Counter, Gauge, and Histogram metrics
  • โœ… Built-in HTTP/connection/protocol metrics
  • โœ… Request tracking with auto-latency
  • โœ… Prometheus format export
  • โœ… JSON export
  • โœ… Thread-safe operations
  • โœ… < 1ยตs overhead per request
// Track request automatically
jvr_request_tracker_t* tracker = 
    jvr_metrics_track_request(metrics, "GET", "/api/users");

// ... handle request ...

// Automatically records latency, status, errors
jvr_metrics_complete_request(tracker, 200);

// Export to Prometheus
jvr_metrics_export_prometheus(metrics, &text, &size);

๐Ÿ“ˆ Real-time Statistics

  • โœ… Request/response counters
  • โœ… Latency percentiles (p50, p95, p99)
  • โœ… Error rates
  • โœ… Connection statistics
  • โœ… Protocol distribution
  • โœ… Cache hit/miss rates

Security

๐Ÿ”’ TLS 1.3 Support

Modern cryptography and security features.

  • โœ… TLS 1.3 and 1.2 support
  • โœ… Certificate validation
  • โœ… SNI (Server Name Indication)
  • โœ… ALPN protocol negotiation
  • โœ… Custom CA certificates
  • โœ… Client certificates

Platform Support

๐ŸชŸ Windows

Full support for Windows 7+

  • Visual Studio compatible
  • MinGW support
  • Winsock2 integration

๐Ÿง Linux

All major distributions

  • GCC and Clang
  • epoll event loop
  • Native socket API

๐ŸŽ macOS

macOS 10.12+

  • Xcode compatible
  • kqueue support
  • Universal binaries

Testing Framework

๐Ÿงช Integrated Testing

Self-contained test framework - no external dependencies!

  • โœ… Lightweight macro-based API
  • โœ… Rich assertions (ASSERT, ASSERT_EQ, ASSERT_NOT_NULL, etc.)
  • โœ… Test suites and organization
  • โœ… Colored output
  • โœ… Detailed error messages
  • โœ… 12+ unit tests included

Ready to Experience These Features?

Get started with JVR NetStack today.