An open API service indexing awesome lists of open source software.

https://github.com/hasnocool/litep2p_network

A Rust-based implementation of a peer-to-peer network using the libp2p protocol suite.
https://github.com/hasnocool/litep2p_network

decentralized-applications event-driven-architecture libp2p peer-to-peer-networking ping-protocol quic request-response-protocol rust tcp

Last synced: 6 months ago
JSON representation

A Rust-based implementation of a peer-to-peer network using the libp2p protocol suite.

Awesome Lists containing this project

README

          

**Project Title:** Litep2P Network
=====================================

## Description

I built this to create a highly scalable and performant peer-to-peer (P2P) network using Rust and the [Litep2p](https://github.com/litep2p/litep2p-rs) library. This project aims to showcase the flexibility of Litep2p by implementing multiple transport protocols (TCP and QUIC), event-driven architecture, and a range of built-in features.

## Features

One cool feature is... **Multi-Transport Support**! Our Litep2P Network uses both TCP and QUIC transports to ensure seamless communication between nodes. We also have:

* Built-in support for IPFS PING protocol
* Efficient event-driven architecture using Tokio and Futures libraries
* Request-response protocol with configurable settings

### More Features (Coming Soon!)

* Integration with existing networks like InterPlanetary File System (IPFS)
* Advanced security features like encryption and authentication
* Support for multiple network protocols (e.g., TCP, QUIC, WebSockets)

## Installation

To get started, make sure you have Rust and Cargo installed on your machine. Then, run the following command:

```bash
cargo build --release
```

This will compile the project in release mode.

## Usage

Run the project using:

```bash
cargo run
```

You should see some logs indicating that the P2P node is running and listening for incoming connections.

### Event Loop

The event loop allows our P2P node to handle events from various sources, such as new connections, ping requests, or request-response messages. You can see this in action by running the project and observing the console output.

## Contributing

Contributions are welcome! If you'd like to contribute to this project, please submit a pull request with your changes. I'm thinking about adding support for other network protocols; maybe you have an idea or two?

## License

This project is licensed under the Apache License 2.0. See `LICENSE` in the root directory.

## Tags/Keywords:

* Peer-to-Peer (P2P)
* Litep2p
* Rust
* Tokio
* Futures
* QUIC
* TCP