added echo server to tools

This commit is contained in:
mfahampshire
2024-10-09 22:28:12 +02:00
parent 429c700705
commit 6f6127859f
2 changed files with 17 additions and 2 deletions
@@ -1,5 +1,4 @@
{
"nym-cli": "NYM-CLI tool",
"cli-wallet": "CLI wallet",
"nym-cli": "Nym-cli",
"echo-server": "Echo Server"
}
@@ -0,0 +1,16 @@
# Echo Server
There is an initial version of a simple echo server located at [`nym/tools/echo-server`](https://github.com/nymtech/nym/tree/develop/tools/echo-server).
This is an initial minimal implementation of an echo server built using the [`NymProxyServer`](../rust/tcpproxy) Rust SDK abstraction that, aside from the initialisation and running of a `NymProxyServer` instance in the background, is essentially a vanilla TCP echo server written with `tokio`.
You can find usage commands [here](https://github.com/nymtech/nym/tree/develop/tools/echo-server#usage).
This server was initially built for the `TcpProxy` tests, but can be useful for developers to need a constant endpoint to ping when developing. In the future this will be deployed to a remote server so developers don't have to run their own.
## Logging
Every 10 seconds, the server logs:
- the total number of bytes received since startup
- the total number of bytes sent since startup
- the current number of concurrent connections it has
- the total number of concurrent connections it has