|
StormByte C++ Library: Network module 1.1.0
StormByte-Network is the C++26 networking module of the StormByte suite.
|
StormByte-Network is the C++26 networking module of the StormByte suite.
It depends on StormByte Base 1.1.0 (or newer), StormByte Buffer 1.1.0 (or newer), and StormByte Logger 1.1.0 (or newer).
It is not a thin socket wrapper. You inherit Client or Server, define packets, and attach Buffer pipelines. POSIX and Winsock, framing, event-driven I/O and bounded packet processing stay private.
| Goal | How it is achieved |
|---|---|
| Inherit, don't wrap sockets | Client / Server are abstract application endpoints. |
| Framed messages | Transport::Packet + private Frame (opcode, size, payload). |
| Buffer as I/O | Pipelines on inbound/outbound payloads; Reader/Writer adapters. |
| IPv4 and IPv6 | Connection::Protocol. |
| Cross-platform | POSIX and Winsock behind Socket / Handler. |
Endpoint, Client, ServerDeserializePacketFunction)Send) and fire-and-forget (Reply)Packet::PROCESS_THRESHOLD| Dependency | Required Version | Role |
|---|---|---|
| StormByte (base) | 1.1.0 | Expected, exceptions, visibility |
| StormByte-Buffer | 1.1.0 | FIFO, Pipeline, Consumer, External I/O |
| StormByte-Logger | 1.1.0 | Diagnostics |
| Module | Role | API |
|---|---|---|
| Base | Exceptions, Expected, serialization, strings, UUID, concepts | /StormByte |
| Buffer | FIFO, SharedFIFO, Ring, Producer/Consumer and multi-stage pipelines | /StormByte-Buffer |
| Config | Human-readable text and versioned binary documents (groups, lists, raw bytes) | /StormByte-Config |
| Crypto | Hash, compress, encrypt, sign and key agreement — Crypto++ never leaves the private tree | /StormByte-Crypto |
| Database | One API over SQLite, PostgreSQL and MariaDB | /StormByte-Database |
| Logger | Stream logger with levels, headers, human-readable sizes and redaction (ThreadedLog) | /StormByte-Logger |
| Multimedia | Decode, encode and containers without raw FFmpeg types; codecs enabled only if present | /StormByte-Multimedia |
| Network | This repository | /StormByte-Network |
| System | Processes, pipes and environment variables across Linux, Windows and macOS | /StormByte-System |
Under StormByte::Network:
| Type | Role |
|---|---|
Client | Inherit; implement pipelines; call Send |
Server | Inherit; implement ProcessClientPacket |
Transport::Packet | Inherit; implement DoSerialize |
Connection::Protocol | IPv4 / IPv6 |
Connection::Status | Lifecycle |
Exception / ConnectionError / ConnectionClosed | Errors |
Sockets, frames and Winsock bootstrap are private.
Connect on Server means bind + listen + accept loop.size_t for payload length. Same architecture on both ends.PROCESS_THRESHOLD.Enable tests in CMake (ENABLE_TEST) and run CTest from the build tree.
Issues on GitHub. No wiki, no discussions.
GNU Lesser General Public License v3 or later.