Open
Conversation
added 7 commits
April 27, 2026 17:45
…d count in Keeper
…ngestion-thread-count
This comment was marked as outdated.
This comment was marked as outdated.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds configurable ingestion/RPC thread counts for ChronoKeeper, ChronoGrapher, and ChronoPlayer recording/query services via JSON configuration, and wires the configured values into the margo_init(..., rpc_thread_count) setup to control server-side RPC concurrency.
Changes:
- Added
IngestionThreadCountconfiguration under each service block and updateddefault_conf.json.indefaults (Keeper=4, Grapher=1, Player=1). - Refactored service configuration structs to nest RPC settings under
RPC_CONFand updated call sites accordingly. - Updated server initialization to pass configured thread counts to
margo_init, and adjusted an integration test to match the new config shape.
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| test/integration/keeper-grapher/keeper_grapher_ingest_test.cpp | Updates test to use nested RPC_CONF fields for KeeperGrapherDrainService addressing/provider id. |
| default_conf.json.in | Adds IngestionThreadCount keys and sets defaults per component. |
| ChronoPlayer/src/ChronoPlayerConfiguration.cpp | Parses IngestionThreadCount and routes rpc parsing through RPC_CONF. |
| ChronoPlayer/src/ChronoPlayer.cpp | Uses configured thread count when calling margo_init for PlaybackQueryService. |
| ChronoPlayer/include/ChronoPlayerConfiguration.h | Introduces PlaybackServiceConf wrapper with RPC_CONF and thread count. |
| ChronoKeeper/src/ChronoKeeperInstance.cpp | Uses configured thread count when calling margo_init for KeeperRecordingService. |
| ChronoKeeper/src/ChronoKeeperConfiguration.cpp | Parses IngestionThreadCount under KeeperRecordingService and routes rpc parsing through RPC_CONF. |
| ChronoKeeper/include/KeeperRecordingService.h | Adjusts per-event logging (TRACE in debug builds + added debug line for ULT/ES). |
| ChronoKeeper/include/IngestionQueue.h | Tweaks logging level/guards inside ingestion path. |
| ChronoKeeper/include/ChronoKeeperConfiguration.h | Introduces KeeperRecordingServiceConf wrapper with RPC_CONF and thread count. |
| ChronoGrapher/src/ChronoGrapherConfiguration.cpp | Parses IngestionThreadCount under KeeperGrapherDrainService and routes rpc parsing through RPC_CONF. |
| ChronoGrapher/src/ChronoGrapher.cpp | Uses configured thread count when calling margo_init for KeeperGrapherDrainService. |
| ChronoGrapher/include/ChronoGrapherConfiguration.h | Introduces KeeperGrapherDrainServiceConf wrapper with RPC_CONF and thread count. |
| chrono_common/src/deprecated_ConfigurationManager.cpp | Adds parsing for IngestionThreadCount (deprecated path). |
Comments suppressed due to low confidence (1)
ChronoKeeper/include/IngestionQueue.h:73
- ingestLogEvent() reads from storyIngestionHandles without holding ingestionQueueMutex (find/size/use). With this PR increasing Margo RPC thread counts (e.g., ChronoKeeper default 4), record_event can call ingestLogEvent concurrently, which makes unordered_map access a data race and can lead to crashes/corruption. Protect all accesses to storyIngestionHandles with a lock (or switch to a reader/writer strategy) and ensure the handle pointer remains valid while used.
#endif
auto ingestionHandle_iter = storyIngestionHandles.find(event.storyId);
if(ingestionHandle_iter == storyIngestionHandles.end())
{
LOG_WARNING("[IngestionQueue] Orphan event for story {}. Storing for later processing.", event.storyId);
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
iameneko
reviewed
May 7, 2026
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
iameneko
approved these changes
May 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes in this PR: