feat: add initial Socket.IO queue server implementation
- Created a basic Socket.IO server that manages user connections and queues for events. - Implemented queue logic to handle concurrent user limits and JWT token issuance. - Added MySQL configuration for potential persistence of queue positions. - Introduced environment variables for configuration through a .env.example file.
This commit is contained in:
17
.env.example
Normal file
17
.env.example
Normal file
@@ -0,0 +1,17 @@
|
||||
# Socket server
|
||||
SOCKET_PORT=4000
|
||||
NEXT_PUBLIC_SOCKET_URL=http://localhost:4000
|
||||
|
||||
# Queue settings
|
||||
QUEUE_THRESHOLD=100
|
||||
CONCURRENT_ACTIVE=50
|
||||
TOKEN_TTL_SECONDS=900
|
||||
|
||||
# JWT
|
||||
JWT_SECRET=your_jwt_secret_here
|
||||
|
||||
# MySQL (optional)
|
||||
MYSQL_HOST=localhost
|
||||
MYSQL_USER=root
|
||||
MYSQL_PASSWORD=yourpassword
|
||||
MYSQL_DATABASE=queue_demo
|
||||
Reference in New Issue
Block a user