Unify operator and node startup configuration - #8309
Open
Amaury Chamayou (achamayou) with Copilot wants to merge 11 commits into
Open
Amaury Chamayou (achamayou) with Copilot wants to merge 11 commits into
Amaury Chamayou (achamayou) with Copilot wants to merge 11 commits into
Conversation
Co-authored-by: achamayou <4016369+achamayou@users.noreply.github.com>
Co-authored-by: achamayou <4016369+achamayou@users.noreply.github.com>
Co-authored-by: achamayou <4016369+achamayou@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Remove distinct in-memory config type
Unify operator and node startup configuration
Sep 8, 2026
Copilot started reviewing on behalf of
Amaury Chamayou (achamayou)
September 9, 2026 07:26
View session
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
It changes startup, recovery, attestation, and join trust-anchor handling across core host and node boundaries.
Pull request overview
Unifies operator and node startup configuration under the public ccf::CCFConfig API.
Changes:
- Removes duplicate host/startup configuration types and migrates consumers.
- Moves file-backed input loading into node startup paths.
- Preserves genesis serialization and adds configuration/data retention tests.
Custom instructions used
.github/copilot-instructions.md.github/instructions/changelog.instructions.md.github/instructions/reviewing.instructions.md
File summaries
| File | Description |
|---|---|
CHANGELOG.md |
Documents the public API migration. |
CMakeLists.txt |
Moves environment utilities into the CCF implementation. |
include/ccf/node/configuration.h |
Defines the unified configuration type. |
include/ccf/node/node_configuration_interface.h |
Exposes resolved node data separately. |
include/ccf/node/start_type.h |
Adds the public startup-mode enum. |
python/pyproject.toml |
Updates the package version. |
samples/apps/logging/logging.cpp |
Migrates node-data access. |
src/common/configuration.h |
Updates JSON serialization declarations. |
src/common/enclave_interface_types.h |
Uses the public startup-mode definition. |
src/enclave/enclave.h |
Accepts unified configuration. |
src/enclave/entry_points.h |
Updates enclave entry-point signature. |
src/enclave/main.cpp |
Passes unified startup settings. |
src/host/configuration.h |
Removes the redundant host configuration. |
src/host/run.cpp |
Removes host-side conversion and input loading. |
src/kv/kv_types.h |
Updates configuration include. |
src/node/node_configuration_subsystem.h |
Publishes configuration and resolved node data. |
src/node/node_state.h |
Loads and retains startup inputs in node state. |
src/node/recovery_decision_protocol.h |
Updates configuration include. |
src/node/recovery_snapshot_ledger.h |
Updates configuration include. |
src/node/rpc/network_identity_subsystem.h |
Updates configuration include. |
src/node/rpc/node_call_types.h |
Preserves the genesis wire model. |
src/node/rpc/node_frontend.h |
Reads resolved node data. |
src/node/rpc/node_interface.h |
Exposes unified configuration and node data. |
src/node/rpc/test/frontend_test.cpp |
Updates the test configuration fixture. |
src/node/rpc/test/node_frontend_test.cpp |
Tests configuration and genesis serialization. |
tests/governance.py |
Tests file-backed startup data retention. |
Review details
- Files reviewed: 26/26 changed files
- Comments generated: 0
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Main moved the curl client to src/http_client (#8285) and reworked SNP attestation parsing and COSE signature storage in node_state.h (#8083, #8334). Keep this PR's config.command.join path in the join callback with the ccf::http_client rename, drop the stale http/curl.h include, and move the changelog entry into the unreleased 7.0.16 section, keeping the Python SDK version at 7.0.16. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Amaury Chamayou (achamayou)
marked this pull request as ready for review
September 21, 2026 17:00
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
…ct-in-memory-config-type-again
The join-retry check added for node-owned node_data loading queried GET /node/network/nodes/self on a pending node, but a pending node's KV is not ready and its frontend only serves Command endpoints, so it always answered 503 FrontendNotOpen and governance_test failed in bucket_c on every CI run of this branch. Observe the property through the primary instead: after the input file is deleted, accepted join retries keep rewriting the pending entry (last_written advances) and the recorded node_data is unchanged. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
This branch has not been deployed
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.
Startup converted the operator configuration into a near-identical in-memory type, preserving an obsolete host/enclave split and eagerly loading file inputs. This PR removes that split while preserving the operator JSON schema and node-to-node genesis format.
What changed
Single configuration type
host::HostConfigandccf::StartupConfigwith publicccf::CCFConfig; remove the host-side conversion.StartTypepublic and node-owned inccf/node/start_type.h.command.start,command.join, andcommand.recover.Node-owned input loading
src/node/, avoiding a newnode -> hostback-edge.Public API and serialization
ccf/node/configuration.hand resolved node data separately onNodeConfigurationState.pending_node_timeoutand currentmain's additional-worker behavior.Source dependency boundary
common/configuration.hfromsrc/node.commonallowlist:crypto,ds,node, andservice.node/internal_tables_access.hexplicit rather than relying on a transitive include.enclave/entry_points.hinclude the owningcommon/configuration.hdeclaration forEnclaveConfigdirectly.Measured dependency graph
Measured on
bbe4941d1with the production-source projection used byscripts/check-source-dependencies.py:The remaining cyclic SCC is
consensus,endpoints,js,kv,node, andservice.commonis a singleton SCC, andnode -> commonis absent. Relative to the documented current-main baseline in #3517, this removes three displayed source-folder edges and reduces the cyclic core from seven components to six.Compatibility and safety
Validation
cmake -S . -B build -GNinjacmake --build build --target ccf ccf_kv ccf_launcher env_test node_frontend_test frontend_test open_service_testctest --test-dir build -R env_test --no-tests=error --output-on-failurectest --test-dir build -R frontend_test --no-tests=error --output-on-failurectest --test-dir build -R open_service_test --no-tests=error --output-on-failurescripts/includes-checks.shscripts/ascii-checks.shCMakeLists.txtscripts/source-dependencies.jsonCloses #7565
Part of #3517