Coder Social home page Coder Social logo

solitude's Introduction

SOLITUDE (WIP)

i2p SAMv3 library written in Rust for use in the EVA project.

Examples

Datagram Server

Creates a datagram service that logs whatever is sent to it.

cargo run --example datagram_server

Datagram client

Sends a datagram with the payload "Hello World! "to the supplied server

cargo run --example datagram_client <server_name>

Stream Server

Creates a Stream style server that logs whatever is sent to it.

cargo run --example stream_server

Stream Client

Sends "Hello World!" to the supplied server

cargo run --example stream_client <server_name>

solitude's People

Contributors

mooseman1241 avatar linden avatar

Stargazers

 avatar  avatar Ohkubo KOHEI avatar Evgesha avatar Vitalii avatar idk avatar  avatar

Watchers

 avatar  avatar

solitude's Issues

Library hangs if SAMv3 doesn't add a newline to it's replies

If RESULT is not OK, SAM closes the connection without adding a newline byte. The library hangs when this happens. I believe this is caused by the line self.reader.read_line(&mut response)?. it doesn't find a \n byte so it keeps waiting until it finds one.

Add other session styles (Raw and Stream)

Stream will be important for most communication between eva nodes, as raw and datagrams can fail and don't have any corrective measures to fix this. Datagrams would be useful to have, although for our voice chat implementation we'd probably want to use Raw format with a custom return field to save bandwidth.

Stream client/server examples working?

Do you currently consider the stream examples to be working? I tried to execute them using i2pd as backend router, but the router always fails with the error messages:

error - SAM: Read error: End of file
error - SAM: Stream read error: Operation canceled

I tried inserting a newline or nullbyte at the end of the "Hello World!" test text, but that did not help. So either my setup is somehow faulty, or there may be an issue in the usage of Rust's TcpStream or such (?)

Add config

Adding a struct for config stuff such as timeout for the stream and session style.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.