ascii-chat 0.11.33
Video chat in your terminal
Loading...
Searching...
No Matches
acds_server_t Struct Reference

Discovery server state. More...

#include <src/discovery-service/server.h>

Data Fields

tcp_server_t * tcp_server
 TCP server (owned by server_like)
 
uint8_t identity_public [32]
 Ed25519 public key.
 
uint8_t identity_secret [64]
 Ed25519 secret key.
 
sqlite3 * db
 SQLite database handle.
 
struct rate_limiter_s * rate_limiter
 SQLite-backed rate limiter.
 
migration_context_t active_migrations [32]
 Slots for up to 32 concurrent migrations.
 
size_t num_active_migrations
 Number of active migrations.
 
thread_pool_t * worker_pool
 Thread pool for background workers.
 
atomic_t shutdown
 Shutdown flag for worker threads.
 
acds_stats_t stats
 Network statistics for all connections.
 
acds_config_t config
 Runtime configuration.
 

Detailed Description

Discovery server state.

Contains all runtime state for the discovery server including network sockets, identity keys, and database. Sessions are stored directly in SQLite as the single source of truth.

Definition at line 115 of file src/discovery-service/server.h.

Field Documentation

◆ active_migrations

migration_context_t acds_server_t::active_migrations[32]

Slots for up to 32 concurrent migrations.

Definition at line 129 of file src/discovery-service/server.h.

◆ config

acds_config_t acds_server_t::config

Runtime configuration.

Definition at line 140 of file src/discovery-service/server.h.

Referenced by acds_server_init(), and acds_websocket_client_handler().

◆ db

sqlite3* acds_server_t::db

SQLite database handle.

Definition at line 123 of file src/discovery-service/server.h.

Referenced by acds_server_init(), and acds_server_shutdown().

◆ identity_public

uint8_t acds_server_t::identity_public[32]

Ed25519 public key.

Definition at line 119 of file src/discovery-service/server.h.

Referenced by acds_client_handler(), and acds_websocket_client_handler().

◆ identity_secret

uint8_t acds_server_t::identity_secret[64]

Ed25519 secret key.

Definition at line 120 of file src/discovery-service/server.h.

Referenced by acds_client_handler(), and acds_websocket_client_handler().

◆ num_active_migrations

size_t acds_server_t::num_active_migrations

Number of active migrations.

Definition at line 130 of file src/discovery-service/server.h.

◆ rate_limiter

struct rate_limiter_s* acds_server_t::rate_limiter

SQLite-backed rate limiter.

Definition at line 126 of file src/discovery-service/server.h.

Referenced by acds_server_init(), and acds_server_shutdown().

◆ shutdown

atomic_t acds_server_t::shutdown

Shutdown flag for worker threads.

Definition at line 134 of file src/discovery-service/server.h.

Referenced by acds_server_init(), and acds_server_shutdown().

◆ stats

acds_stats_t acds_server_t::stats

Network statistics for all connections.

Definition at line 137 of file src/discovery-service/server.h.

Referenced by acds_client_handler(), and acds_server_init().

◆ tcp_server

tcp_server_t* acds_server_t::tcp_server

TCP server (owned by server_like)

Definition at line 116 of file src/discovery-service/server.h.

Referenced by acds_client_handler(), acds_server_init(), acds_server_shutdown(), and acds_websocket_client_handler().

◆ worker_pool

thread_pool_t* acds_server_t::worker_pool

Thread pool for background workers.

Definition at line 133 of file src/discovery-service/server.h.

Referenced by acds_server_init(), and acds_server_shutdown().


The documentation for this struct was generated from the following file: