redux-cluster 2.0.1 β 2.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +40 -5
- package/package.json +4 -3
package/README.md
CHANGED
|
@@ -1,15 +1,20 @@
|
|
|
1
1
|
# Redux Cluster 2.0
|
|
2
2
|
|
|
3
|
-
[](https://www.npmjs.com/package/redux-cluster)
|
|
4
|
+
[](https://www.npmjs.com/package/redux-cluster)
|
|
5
|
+
[](https://www.npmjs.com/package/redux-cluster)
|
|
6
|
+

|
|
7
|
+

|
|
6
8
|
|
|
7
9
|
A modern TypeScript library for synchronizing Redux stores across multiple processes and machines using TCP, Unix Domain Sockets, and IPC.
|
|
8
10
|
|
|
11
|
+
> π **Need WebSocket support for browsers?** Check out [redux-cluster-ws](https://www.npmjs.com/package/redux-cluster-ws) - our companion package that extends Redux Cluster with WebSocket transport for browser clients.
|
|
12
|
+
|
|
9
13
|
## π Key Features
|
|
10
14
|
|
|
11
15
|
- π **Real-time State Synchronization** across multiple processes/machines
|
|
12
16
|
- π **Multiple Transport Options**: TCP, Unix Domain Sockets, IPC
|
|
17
|
+
- π **WebSocket Support**: Available via [redux-cluster-ws](https://www.npmjs.com/package/redux-cluster-ws)
|
|
13
18
|
- π‘ **Bidirectional Communication** - any node can dispatch actions
|
|
14
19
|
- π **Built-in Security** with authentication and IP banning
|
|
15
20
|
- β‘ **High Performance** with optimized networking and compression
|
|
@@ -261,8 +266,34 @@ See the [examples/](./examples/) directory for complete working examples:
|
|
|
261
266
|
- **[File Socket](./examples/file-socket/)** - Local IPC via Unix sockets
|
|
262
267
|
- **[Basic Store](./examples/basic/)** - Local Redux store without networking
|
|
263
268
|
|
|
269
|
+
> π **WebSocket Examples**: For browser integration examples with WebSocket transport, visit the [redux-cluster-ws examples](https://github.com/siarheidudko/redux-cluster-ws/tree/main/examples).
|
|
270
|
+
|
|
264
271
|
Each example includes a README with step-by-step instructions.
|
|
265
272
|
|
|
273
|
+
## π¦ Related Packages
|
|
274
|
+
|
|
275
|
+
### redux-cluster-ws
|
|
276
|
+
|
|
277
|
+
WebSocket transport layer for Redux Cluster, enabling browser client support:
|
|
278
|
+
|
|
279
|
+
```bash
|
|
280
|
+
npm install redux-cluster-ws
|
|
281
|
+
```
|
|
282
|
+
|
|
283
|
+
**Features:**
|
|
284
|
+
|
|
285
|
+
- π WebSocket server and client
|
|
286
|
+
- π Seamless integration with Redux Cluster
|
|
287
|
+
- π₯οΈ Browser support for web applications
|
|
288
|
+
- π± Real-time state synchronization to browsers
|
|
289
|
+
- π Same security features as core package
|
|
290
|
+
|
|
291
|
+
**Links:**
|
|
292
|
+
|
|
293
|
+
- π [NPM Package](https://www.npmjs.com/package/redux-cluster-ws)
|
|
294
|
+
- π [Documentation](https://github.com/siarheidudko/redux-cluster-ws)
|
|
295
|
+
- π― [Examples](https://github.com/siarheidudko/redux-cluster-ws/tree/main/examples)
|
|
296
|
+
|
|
266
297
|
## π§ͺ Testing
|
|
267
298
|
|
|
268
299
|
```bash
|
|
@@ -299,7 +330,7 @@ Benchmark results:
|
|
|
299
330
|
## πΊοΈ Roadmap
|
|
300
331
|
|
|
301
332
|
- [ ] **Redis Transport** - Redis pub/sub for clustering
|
|
302
|
-
- [
|
|
333
|
+
- [x] **WebSocket Transport** - Available in [redux-cluster-ws](https://www.npmjs.com/package/redux-cluster-ws)
|
|
303
334
|
- [ ] **Conflict Resolution** - CRDT-based conflict resolution
|
|
304
335
|
- [ ] **Persistence Layer** - Automatic state persistence
|
|
305
336
|
- [ ] **Monitoring Dashboard** - Real-time cluster monitoring
|
|
@@ -307,7 +338,11 @@ Benchmark results:
|
|
|
307
338
|
|
|
308
339
|
## π€ Contributing
|
|
309
340
|
|
|
310
|
-
|
|
341
|
+
1. Fork the repository
|
|
342
|
+
2. Create your feature branch (`git checkout -b feature/amazing-feature`)
|
|
343
|
+
3. Commit your changes (`git commit -m 'Add amazing feature'`)
|
|
344
|
+
4. Push to the branch (`git push origin feature/amazing-feature`)
|
|
345
|
+
5. Open a Pull Request
|
|
311
346
|
|
|
312
347
|
### Development Setup
|
|
313
348
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "redux-cluster",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "TypeScript cluster module for Redux that synchronizes Redux stores across cluster processes via IPC and TCP sockets",
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -49,6 +49,7 @@
|
|
|
49
49
|
"build:pkg": "./scripts/create-package-files.sh",
|
|
50
50
|
"build:watch": "tsc --watch",
|
|
51
51
|
"clean": "rm -rf dist",
|
|
52
|
+
"update": "eval \"$(node -e 'const t = require(`./package.json`);const ignore = require(`./ignoreUpdatesModules.json`);console.log(`npm i ${(Object.keys(t.dependencies || {}).filter((e)=>ignore.base.indexOf(e) === -1).map((e)=>(`${e}@latest`)).join(` `))} --save&&npm i ${(Object.keys(t.devDependencies || {}).filter((e)=>ignore.dev.indexOf(e) === -1).map((e)=>(`${e}@latest`)).join(` `))} --save-dev`);')\"",
|
|
52
53
|
"prepublishOnly": "npm run clean && npm run build",
|
|
53
54
|
"test": "npm run test:all",
|
|
54
55
|
"test:all": "node --test --import tsx tests/unit.test.ts tests/error.test.ts tests/transport.test.ts",
|
|
@@ -96,8 +97,8 @@
|
|
|
96
97
|
},
|
|
97
98
|
"devDependencies": {
|
|
98
99
|
"@types/node": "^20.11.17",
|
|
99
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
100
|
-
"@typescript-eslint/parser": "^8.
|
|
100
|
+
"@typescript-eslint/eslint-plugin": "^8.43.0",
|
|
101
|
+
"@typescript-eslint/parser": "^8.43.0",
|
|
101
102
|
"eslint": "^9.35.0",
|
|
102
103
|
"ts-node": "^10.9.2",
|
|
103
104
|
"tsx": "^4.20.5",
|