Skip to main content

Module multicore

Module multicore 

Source
Expand description

Multicore processing management.

This module provides abstractions for distributing network subscription processing across multiple CPU cores using channel-based message passing. It supports both shared worker pools and dedicated worker pools.

Structs§

ChannelDispatcher
A unified thread-safe interface for dispatching subscriptions.
DedicatedWorkerThreadSpawner
Spawns worker threads dedicated to a single dispatcher, with all threads using the same handler function. Optimizes for single-receiver scenarios by avoiding select overhead.
SharedWorkerThreadSpawner
Spawns worker threads that share multiple dispatchers, with each thread handling subscriptions from all configured dispatchers using different handlers per dispatcher type.
SubscriptionStats
Thread-safe statistics tracker for the various stages of subscription processing. All counters use atomic operations for thread safety.

Enums§

ChannelMode
Defines the operating mode for the channel dispatcher.
Channels
Internal representation of the channel configuration based on chosen operating mode.

Functions§

pin_thread_to_core
Pins the current thread to a specific CPU core.