Package com.privatechain.network.peer
package com.privatechain.network.peer
Peer lifecycle management — maintains the list of connected peers, runs heartbeat
checks, and prunes unresponsive connections (FR-NET-01, FR-NET-07).
Classes in this package:
Peer— immutable value object representing a remote peer:nodeId,host,port,publicKey, andlastSeentimestamp.PeerManager— connects to seed peers, runs a ping/pong heartbeat every 30 seconds, and removes peers that have not responded within the configured timeout. PublishesBlockchainEvent.PeerConnectedEventandBlockchainEvent.PeerDisconnectedEvent.PeerStore— persists known peer addresses toBlockchainStorageso the peer set is available after a node restart.
Maximum simultaneous peer connections is configurable; the default is 25 (FR-NET-07).
- Since:
- 1.0.0