Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/paulobressan/rust-socket-server
https://github.com/paulobressan/rust-socket-server
Last synced: 11 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/paulobressan/rust-socket-server
- Owner: paulobressan
- Created: 2023-06-08T08:56:19.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2023-06-08T09:04:13.000Z (over 1 year ago)
- Last Synced: 2024-08-01T16:52:03.994Z (3 months ago)
- Language: Rust
- Size: 38.1 KB
- Stars: 5
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Rust Socket Server
This application is an example of how to implement a socket server using Rust with the Tokio library.
![Example](assets/image.png)
## Requirements
- Rust (>=1.66.0)
## How to execute
Open a terminal to run the server
```bash
cargo run
```Open two additional terminals to act as "Client 1" and "Client 2" to connect to the server.
```bash
telnet localhost 8080
```Now, in the terminal of "Client 1," type a message and observe how it appears in the "Client 2" terminal. Similarly, you can try sending messages from "Client 2" and see them displayed in "Client 1" terminal.