Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gcarreno/testpeer-to-peer
A simple class that implements a peer in a Peer-to-Peer network
https://github.com/gcarreno/testpeer-to-peer
fpc free-pascal freepascal lazarus p2p p2p-network p2p-node peer-to-peer
Last synced: about 2 months ago
JSON representation
A simple class that implements a peer in a Peer-to-Peer network
- Host: GitHub
- URL: https://github.com/gcarreno/testpeer-to-peer
- Owner: gcarreno
- License: mit
- Created: 2024-09-15T15:30:33.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2024-09-16T18:50:01.000Z (4 months ago)
- Last Synced: 2024-09-17T17:26:24.881Z (4 months ago)
- Topics: fpc, free-pascal, freepascal, lazarus, p2p, p2p-network, p2p-node, peer-to-peer
- Language: Pascal
- Homepage: https://github.com/gcarreno/TestStar
- Size: 40 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Test Peer-to-Peer
> **Disclaimer**
>
> In the spirit of full disclosure and due to my utter laziness in coming up with the bulk of the boilerplate code, I turned to `ChatGPT`.\
> You can see the series of prompts and answers I've got in the [research](research) folder.This is an attempt at a very basic peer class that can participate on a Peer-to-Peer( `P2P` ) network.
It will not have peer discovery via `UDP` broadcast, nor will it have any `DHT` features.
Just a simple message exchange protocol in a `P2P` context.
## Todo
- The `TPeer` class, at the moment, does not need to be a thread
- Hook up event for data received from connection thread to the internal peer method
- Add a property to allow hooking to data received from outside of the peer
- Hook up event for connection removal from connection thread to peer
- Understand if a connection needs to be disconnected when being removed
- Implement command line switch `--connect-to`
- Ponder having a Ping/Pong immediately before a connection is about to timeout