soketi / monorepo

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

soketipfs β€” Real-Time 🀝 Web3

Discord CI

soketipfs is a framework for building distributed applications using Websockets. It is built on top of uWebSockets.js and uses the IPFS networking protocol with Helia.

Use it in both public or private networks, where you can control the nodes that are part of the network β€” you have a fully private and secure network for your real-time application.

Read more about Interstellar ✨πŸͺ

🀝 Sponsors

Logos from Sponsors

Features

SRF (🌍 Scalable | ✨ Resilient | 🏎️ Fast)

soketipfs is built with the SRF principles in mind. It is designed to be scalable, resilient and fast by nature, leveraging the power of uWebSockets.js and the IPFS networking.

While IPFS is public, soketipfs is designed to be used in private networks, where you can control the nodes that are part of the network β€” you have a fully private and secure network for your real-time application. πŸš€

The server is built on top of uWebSockets.js - a C application ported to Node.js. uWebSockets.js is demonstrated to perform at levels 8.5x that of Fastify and at least 10x that of Socket.IO. (source)

Cheaper πŸ€‘

For a $49 plan on Pusher, you get a limited amount of connections (500) and messages (30M).

With soketipfs, for the price of an instance on Vultr or DigitalOcean ($5-$10), you get virtually unlimited connections, messages, and some more!

soketipfs is capable to hold thousands of active connections with high traffic on less than 1 GB and 1 CPU in the cloud. You can also get free $100 on Vultr to try out soketipfs β†’

Pusher Protocol πŸ“‘

soketipfs implements the Pusher Protocol v7. Your existing projects that connect to Pusher requires minimal code change to make it work with soketipfs - you just add the host and port and swap the credentials.

Coming Soon πŸš€βœ¨

AI & LLMs πŸ€–: Leverage the market game within the real-time context β€” protect your customers with built-in AI models for sentiment analysis and much more.

Function as a Service πŸš€: The network will have your code and it will run it for you. Zero knowledge required, and you use the languages you love.

Storage-as-a-Service πŸͺ£: Your files will be safe. The network stores it for you, either it is public or private. No disruptions, no data loss.

πŸš€ Getting Started

Get started by using the new soketi CLI to start the server:

npx @soketi/cli ipfs start --port=7001

The CLI replaces the soketi project.

If you wish to install the command as global, make sure to uninstall the old soketi package before installing the new one:

npm uninstall -g @soketi/soketi
npm install -g @soketi/cli
# Now you can use the IPFS server
soketi ipfs start --port=7001

For the legacy server, see the soketi/soketi repository.

πŸ”€ Roadmap

πŸ§‘β€πŸ’» = currently in development
πŸ‘‰ = upcoming for development
⏳ = planned, but not yet scheduled
πŸ‘€ = not sure, maybe in the future
  • Deployment
    • πŸ§‘β€πŸ’» New Soketi CLI
    • πŸ§‘β€πŸ’» Docker
    • πŸ‘‰ Kubernetes
    • πŸ‘‰ Railway
  • Protocols
    • πŸ‘‰ Pusher Protocol
    • πŸ‘‰ Ably Protocol
    • πŸ‘‰ AWS API Gateway Protocol (compatibility)
    • ⏳ MQTT Protocol
    • ⏳ PubNub Protocol
    • ⏳ SockJS Protocol
    • ⏳ Socket.IO / Engine.IO Protocol
    • πŸ‘€ AMQP Protocol
    • πŸ‘€ Centrifugo Protocol
    • πŸ‘€ STOMP Protocol
  • Discovery Mechanisms
    • πŸ§‘β€πŸ’» IPFS
    • ⏳ Redis Pubsub
    • ⏳ NATS
  • Sprinkles
    • πŸ‘‰ Function as a Service
    • πŸ‘‰ AI & LLMs
    • ⏳ Storage as a Service
  • Databases
    • πŸ‘‰ Redis Stack
    • πŸ‘‰ SQL via Knex
    • πŸ‘€ MongoDB

⁉ Ideas or Discussions?

Have any ideas that can make into the project? Perhaps you have questions? Jump into the discussions board or join the Discord channel

πŸ”’ Security

If you discover any security related issues, please email alex@thecodefather.co instead of using the issue tracker.

πŸŽ‰ Credits

Thank you to Bunny! 🌸

🀝 Contributing

✨ This workspace has been generated by Nx, a Smart, fast and extensible build system. ✨

Learn more

Install dependencies

Run npm install to install all dependencies.

npm install

Packages

Each abstraction has its own place in the soketipfs ecosystem, and they can be used independently or together.

soketipfs is a monorepo, and it's composed of the following packages:

  • brain: Used to cache data in memory
  • cli: the CLI took for soketi that supports both legacy and IPFS, plus possibly many more integratins
  • connections: Base implementation for Websocket connections handling
  • gossiper: Integration for the Gossip protocol, used to broadcast messages to all nodes in the network
  • p2p: libp2p networking implementation using Helia
  • server: Ready-to-go & customizable server implemenations for soketipfs
  • utils: Utility functions used across the packages

Protocol: Pusher

The Pusher protocol is implemented in the following packages:

  • pusher-apps: Pusher Apps implementation to juggle with the apps definitions
  • pusher-channels: Pusher Channels implementation to handle channels and events

About


Languages

Language:TypeScript 93.9%Language:Lua 3.9%Language:JavaScript 1.4%Language:Dockerfile 0.5%Language:Shell 0.3%