Skip to content

Commit

Permalink
chore: try shrinking global event buffer pool to a minimum of 32 buffers
Browse files Browse the repository at this point in the history
  • Loading branch information
tobz committed Nov 15, 2024
1 parent bb3af25 commit 5adfbc7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/saluki-core/src/topology/blueprint.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ impl TopologyBlueprint {
// having to change it in all places that need to do these manual minimum/firm calculations.
const GLOBAL_EVENT_BUFFER_SIZE: usize =
std::mem::size_of::<FixedSizeEventBufferInner>() + (1024 * std::mem::size_of::<Event>());
const GLOBAL_EVENT_BUFFER_POOL_SIZE_MIN: usize = 64 * GLOBAL_EVENT_BUFFER_SIZE;
const GLOBAL_EVENT_BUFFER_POOL_SIZE_MIN: usize = 32 * GLOBAL_EVENT_BUFFER_SIZE;
const GLOBAL_EVENT_BUFFER_POOL_SIZE_FIRM: usize =
(512 * GLOBAL_EVENT_BUFFER_SIZE) - GLOBAL_EVENT_BUFFER_POOL_SIZE_MIN;

Expand Down
2 changes: 1 addition & 1 deletion lib/saluki-core/src/topology/built.rs
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ impl BuiltTopology {
let mut component_task_map = HashMap::new();

// Build our interconnects, which we'll grab from piecemeal as we spawn our components.
let (event_buffer_pool, shrinker) = ElasticObjectPool::with_builder("global_event_buffers", 64, 512, || {
let (event_buffer_pool, shrinker) = ElasticObjectPool::with_builder("global_event_buffers", 32, 512, || {
FixedSizeEventBufferInner::with_capacity(1024)
});
spawn_traced(shrinker);
Expand Down

0 comments on commit 5adfbc7

Please sign in to comment.