Enhance server configuration and performance optimizations
- Added max_connections option to server configuration - Updated Makefile to include performance.c and related headers - Implemented memory-mapped file caching and buffer pooling for improved performance - Refactored config parser to handle new configuration options - Increased maximum request size and optimized file handling
This commit is contained in:
41
server.conf
41
server.conf
@@ -1,31 +1,32 @@
|
||||
# Carbon Web Server Configuration File
|
||||
# Lines starting with # are comments
|
||||
|
||||
# Server listening port
|
||||
port = 8080
|
||||
|
||||
# Enable HTTPS (requires valid certificates in certs/ directory)
|
||||
use_https = false
|
||||
|
||||
# Log file location
|
||||
log_file = log/server.log
|
||||
|
||||
# Maximum number of worker threads
|
||||
max_threads = 4
|
||||
|
||||
# Server running state
|
||||
running = true
|
||||
|
||||
# ---Network configuration---
|
||||
# Server listening port
|
||||
port = 8080
|
||||
# Enable HTTPS (requires valid certificates in certs/ directory)
|
||||
use_https = false
|
||||
# Enable HTTP/2 support (requires HTTPS)
|
||||
enable_http2 = false
|
||||
# Enable WebSocket support
|
||||
enable_websocket = false
|
||||
# Server name or IP address (used for logging and response headers)
|
||||
|
||||
server_name = Your_domain/IP
|
||||
|
||||
# ---Performance configuration---
|
||||
# Maximum number of worker threads
|
||||
max_threads = 4
|
||||
max_connections = 1024
|
||||
|
||||
|
||||
|
||||
# ---Path configuration---
|
||||
# Log file location
|
||||
log_file = log/server.log
|
||||
# Enable verbose logging
|
||||
verbose = true
|
||||
|
||||
# Enable HTTP/2 support (requires HTTPS)
|
||||
enable_http2 = false
|
||||
|
||||
# Enable WebSocket support
|
||||
enable_websocket = false
|
||||
|
||||
# Path to www
|
||||
www_path = www
|
||||
Reference in New Issue
Block a user