mirror of
https://github.com/cerc-io/watcher-ts
synced 2025-01-08 12:28:05 +00:00
bd73dae1b1
* Add Consensus class with placeholders * Implement Consensus constructor * Move PubsubType to peer package * Implement remaining methods in Consensus class * Use existing consensus stream if it exists * Setup send and receive pipes on consensus streams * Refactor P2P and consensus setup in server command * Add Nitro node initialization in server command * Return objects from server initializations * Use dynamic imports for ES modules in util package * Fix util deps * Change target to es6 to allow creating a Mokka instance * Set moduleResolution to node16 in util for dynamic imports * Upgrade @cerc-io/nitro-node package * Implement retries while sending consensus messages * Use bunyan for consensus logs and subscribe to state changes * Use debug for logging state change events * Handle empty watcher party file path * Return object from initP2P * Upgrade @cerc-io/nitro-node package * Update package versions |
||
---|---|---|
.. | ||
src | ||
.env.sample | ||
.eslintignore | ||
.eslintrc.json | ||
.gitignore | ||
.mocharc.yml | ||
package.json | ||
README.md | ||
tsconfig.json |
peer
Package used for connecting between peers and send messages
Implementations
- Discover peers
- Connect between peers and send messages
- Use package in browser
- Use package in server
- Send messages between systems in different LANs using relay node
Note
- Avoid any nodejs specific exports from this package as it is intented to be used in browser applications as well
Known Issues
peer:disconnect
event is not fired when remote peer browser is closed