Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/007tickooayush/bun-redis-socket
A Bun project made for portraying the concepts of load balancing ready application for sockets interaction along with http requests.
https://github.com/007tickooayush/bun-redis-socket
bun express redis redis-adapter socket-io typescript
Last synced: about 1 month ago
JSON representation
A Bun project made for portraying the concepts of load balancing ready application for sockets interaction along with http requests.
- Host: GitHub
- URL: https://github.com/007tickooayush/bun-redis-socket
- Owner: 007tickooayush
- Created: 2024-01-08T15:19:43.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2024-01-12T05:48:50.000Z (12 months ago)
- Last Synced: 2024-01-13T08:28:48.170Z (12 months ago)
- Topics: bun, express, redis, redis-adapter, socket-io, typescript
- Language: TypeScript
- Homepage:
- Size: 238 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Bun Redis Adapter
A project implementing load balancing using @socket.io/redis-adapter and Express as the server for handling HTTP requests and socket events.
## Description
This project aims to provide load balancing capabilities for socket.io applications using the @socket.io/redis-adapter package. It utilizes Express as the server to handle both HTTP requests and socket events.
## Features
- Load balancing of socket.io connections using @socket.io/redis-adapter
- Handling of HTTP requests using Express
- Handling of socket events using Express## Installation
1. Clone the repository:
```bash
git clone https://github.com/007tickooayush/bun-redis-socket.git
```2. Install the dependencies:
```bash
bun install
```## Usage
1. Start the server:
```bash
bun run dev
```2. Access the application in your browser at `http://localhost:3002` or `http://localhost:3003`.
## Configuration
The following environment variables can be configured:
- `REDIS_URL`: The URL of the Redis server (default: `redis://localhost:6379`)
- `PORT`: The port on which the server should listen (default: `3009` or `3010`)## License
N/A