Skip to content

docs: pull our configuration guidance into STYLE_GUIDE.md - #4739

Merged
chet merged 1 commit into
NVIDIA:mainfrom
chet:gh-issue-4626
Aug 10, 2026
Merged

docs: pull our configuration guidance into STYLE_GUIDE.md#4739
chet merged 1 commit into
NVIDIA:mainfrom
chet:gh-issue-4626

Conversation

@chet

@chet chet commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

This continues the series from #4641, #4608, #4648, (and related to #4522), with more to come.

This is an attempt to capture the general NICo maintainer design principles and guidance around configuration ownership for the codebase. This change is derived from the pre-OSS review corpus as a whole -- years of MRs and tens of thousands of comments and discussions. As such, it leans into the guiding design decisions and principles used to define and grow the project into the product we have today.

The idea is to ensure we capture our core principles in STYLE_GUIDE.md. If any of those principles have changed, we should capture that too, ensuring we don't lose sight of why decisions were made as the codebase evolves with new contributors, human and agentic alike.

For this change specifically, I focused on where configuration belongs (and how it resolves). The search through previous reviews surfaced discussions related to:

  • Duplicate sources.
  • Unsafe defaults
  • Hard-coded site values.
  • Reloading config/values.
  • Unnecessary knobs.

This pulls out the recurring parts:

  • First ask whether a configuration option is necessary.
  • Give variable behavior one canonical owner and resolution path.
  • Define omission and fallback behavior, validation, precedence and conflict handling.
  • Restart and/or [dynamic] update behavior.
  • Keep site-level and environment-specific values behind declared configuration instead of baking them in.
  • Keep true protocol invariants non-configurable; tunable operational limits still have a hard, non-configurable maximum.

It also keeps the important exceptions that configuration does not have one universal storage location and that some settings must be required and fail closed because no safe default exists. Files, flags, environment variables, Helm, database values, and APIs can each be the right owner; the rule is to make ownership, omission behavior, and precedence explicit instead of creating accidental parallel sources.

Again, we can always adjust this now or later. The hope is that we don't lose the reasoning behind why we made certain decisions to get us where we are now, and can continue using that reasoning to help drive future decisions.

Related issues

This supports #4626

Type of Change

  • Add - New feature or capability
  • Change - Changes in existing functionality
  • Fix - Bug fixes
  • Remove - Removed features or deprecated functionality
  • Internal - Internal changes (refactoring, tests, docs, etc.)

Breaking Changes

  • This PR contains breaking changes

Testing

  • Unit tests added/updated
  • Integration tests added/updated
  • Manual testing performed
  • No testing required (docs, internal refactor, etc.)

Additional Notes

Closes #4626

@chet
chet requested a review from a team as a code owner August 8, 2026 00:51
@chet

chet commented Aug 8, 2026

Copy link
Copy Markdown
Contributor Author

@coderabbitai full_review, thanks!

@coderabbitai

coderabbitai Bot commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

@chet: I will perform a complete review of the pull request.

🐇

✅ Action performed

Full review finished.

@coderabbitai

coderabbitai Bot commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Summary by CodeRabbit

  • Documentation
    • Added guidance on configuration ownership and precedence.
    • Documented configuration requirements, defaults, validation, activation timing, source precedence, and schema reuse.

Walkthrough

STYLE_GUIDE.md adds guidance for configuration necessity, ownership, defaults, validation, activation timing, source precedence, and schema reuse.

Changes

Configuration guidance

Layer / File(s) Summary
Configuration ownership and precedence
STYLE_GUIDE.md
Adds guidance for configuration necessity, canonical ownership, resolution behavior, omission defaults, validation timing, activation semantics, source precedence, and schema reuse.

Estimated code review effort: 1 (Trivial) | ~2 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly summarizes the documentation change that moves configuration guidance into STYLE_GUIDE.md.
Description check ✅ Passed The description directly explains the configuration guidance added to STYLE_GUIDE.md and its purpose.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@STYLE_GUIDE.md`:
- Around line 416-419: Clarify the guidance around configuration options so
protocol invariants remain immutable and non-configurable. For configurable
operational limits, require a non-configurable hard maximum and mandate
rejecting values outside that maximum before activation; distinguish these
bounded limits from true protocol invariants.
- Around line 421-424: Expand the configuration checklist in the relevant
STYLE_GUIDE section to require documentation of each setting’s type, accepted
values, units, bounds, interactions, invalid combinations, validation errors,
ordering, outputs, side effects, and unsupported paths, alongside the existing
omission, activation, and source-resolution requirements.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: b17e8fdd-8b69-4dac-a734-f11396c9ae30

📥 Commits

Reviewing files that changed from the base of the PR and between 86ec7af and 3c0a0c9.

📒 Files selected for processing (1)
  • STYLE_GUIDE.md

Comment thread STYLE_GUIDE.md Outdated
Comment thread STYLE_GUIDE.md
This is an attempt to capture the general NICo maintainer design principles and guidance around configuration ownership for the codebase. This change is derived from the pre-OSS review corpus as a whole -- years of MRs and tens of thousands of comments and discussions. As such, it leans into the guiding design decisions and principles used to define and grow the project into the product we have today.

The idea is to ensure we capture our core principles in `STYLE_GUIDE.md`. If any of those principles have changed, we should capture that too, ensuring we don't lose sight of why decisions were made as the codebase evolves with new contributors, human and agentic alike.

For this change specifically, I focused on where configuration belongs and how it resolves. The search surfaced related duplicate-source, unsafe-default, hard-coded-site-value, precedence, reload, and unnecessary-knob conversations throughout the corpus and across multiple participants.

This pulls out the recurring parts:

- First ask whether a configuration option is necessary.
- Give variable behavior one canonical owner and resolution path.
- Define omission and fallback behavior, validation, precedence and conflict handling, and restart or dynamic-update behavior.
- Keep site- and environment-specific values behind declared configuration instead of baking them into behavior.
- Keep true protocol invariants non-configurable; tunable operational limits still have a hard, non-configurable maximum.

It also keeps the important exceptions that configuration does not have one universal storage location and that some settings must be required and fail closed because no safe default exists. Files, flags, environment variables, Helm, database values, and APIs can each be the right owner; the rule is to make ownership, omission behavior, and precedence explicit instead of creating accidental parallel sources.

Again, we can always adjust this now or later. The hope is that we don't lose the reasoning behind why we made certain decisions to get us where we are now, and can continue using that reasoning to help drive future decisions.

This supports NVIDIA#4626

Signed-off-by: Chet Nichols III <chetn@nvidia.com>
@chet

chet commented Aug 8, 2026

Copy link
Copy Markdown
Contributor Author

@coderabbitai full_review, thanks!

@coderabbitai

coderabbitai Bot commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

@chet: I will perform a complete review of this pull request.

🐇

✅ Action performed

Full review finished.

@chet chet changed the title docs: define where each setting belongs and how it resolves docs: pull our configuration guidance into STYLE_GUIDE.md Aug 8, 2026
@chet
chet merged commit c16f864 into NVIDIA:main Aug 10, 2026
68 of 69 checks passed
@chet
chet deleted the gh-issue-4626 branch August 10, 2026 17:42
chet added a commit that referenced this pull request Aug 12, 2026
_This continues the style-guide series from
#4608,
#4648,
#4739, and
#4641, with more to
come._

This is an attempt to capture the general NICo maintainer design
principles and guidance around external-I/O and async-capacity
boundaries for the codebase. This change is derived from the pre-OSS
review corpus as a whole -- years of MRs and tens of thousands of
comments and discussions. As such, it leans into the guiding design
decisions and principles used to define and grow the project into the
product we have today.

**The idea is to ensure we capture our core principles in
`STYLE_GUIDE.md`.** If any of those principles have changed, we should
capture that too, ensuring we don't lose sight of why decisions were
made as the codebase evolves with new contributors, human and agentic
alike.

**For this change specifically, I focused on external I/O and async
admission.** The search through previous reviews surfaced discussions
related to:

- Request deadlines and transport timeouts.
- Long-lived stream cancellation and liveness.
- Retry safety and backoff behavior.
- Task spawning and queue growth.
- Backpressure and overload handling.

This pulls out the recurring parts:

- Give each external I/O attempt that should finish an intentional
client-side deadline.
- Make cancellation propagation, error mapping, retry safety/backoff,
and observability explicit.
- Bound retry work within each reconciliation iteration and any
enclosing caller deadline.
- Bound active and pending work and define what happens on overload.
- Give long-lived streams explicit cancellation, liveness detection, and
loss handling.
- Document the invariant or nonblocking control-path reason when a
channel is deliberately unbounded.

It also keeps the important exceptions for deliberately long-lived
operations, protocol-derived timeout values, nonblocking lifecycle and
control paths, and producers whose outstanding work is already provably
bounded. I don't want to fix one missing rule by accidentally outlawing
something NICo does on purpose.

Again, we can always adjust this now or later. The hope is that we don't
lose the reasoning behind why we made certain decisions to get us where
we are now, and can continue using that reasoning to help drive future
decisions.

## Related issues

This supports #4622

## Type of Change

- [ ] **Add** - New feature or capability
- [ ] **Change** - Changes in existing functionality
- [ ] **Fix** - Bug fixes
- [ ] **Remove** - Removed features or deprecated functionality
- [x] **Internal** - Internal changes (refactoring, tests, docs, etc.)

## Breaking Changes

- [ ] **This PR contains breaking changes**

## Testing

- [ ] Unit tests added/updated
- [ ] Integration tests added/updated
- [ ] Manual testing performed
- [x] No testing required (docs, internal refactor, etc.)

## Additional Notes

Validated with `cargo make format-nightly`, `cargo make clippy`, the
cached Carbide-lints workflow, `rumdl`, `git diff --check`, and a Pandoc
render. No tests were run because this is a documentation-only change.

Signed-off-by: Chet Nichols III <chetn@nvidia.com>
srinivasadmurthy pushed a commit to srinivasadmurthy/bare-metal-manager-core that referenced this pull request Aug 13, 2026
_This continues the style-guide series from
NVIDIA#4608,
NVIDIA#4648,
NVIDIA#4739, and
NVIDIA#4641, with more to
come._

This is an attempt to capture the general NICo maintainer design
principles and guidance around external-I/O and async-capacity
boundaries for the codebase. This change is derived from the pre-OSS
review corpus as a whole -- years of MRs and tens of thousands of
comments and discussions. As such, it leans into the guiding design
decisions and principles used to define and grow the project into the
product we have today.

**The idea is to ensure we capture our core principles in
`STYLE_GUIDE.md`.** If any of those principles have changed, we should
capture that too, ensuring we don't lose sight of why decisions were
made as the codebase evolves with new contributors, human and agentic
alike.

**For this change specifically, I focused on external I/O and async
admission.** The search through previous reviews surfaced discussions
related to:

- Request deadlines and transport timeouts.
- Long-lived stream cancellation and liveness.
- Retry safety and backoff behavior.
- Task spawning and queue growth.
- Backpressure and overload handling.

This pulls out the recurring parts:

- Give each external I/O attempt that should finish an intentional
client-side deadline.
- Make cancellation propagation, error mapping, retry safety/backoff,
and observability explicit.
- Bound retry work within each reconciliation iteration and any
enclosing caller deadline.
- Bound active and pending work and define what happens on overload.
- Give long-lived streams explicit cancellation, liveness detection, and
loss handling.
- Document the invariant or nonblocking control-path reason when a
channel is deliberately unbounded.

It also keeps the important exceptions for deliberately long-lived
operations, protocol-derived timeout values, nonblocking lifecycle and
control paths, and producers whose outstanding work is already provably
bounded. I don't want to fix one missing rule by accidentally outlawing
something NICo does on purpose.

Again, we can always adjust this now or later. The hope is that we don't
lose the reasoning behind why we made certain decisions to get us where
we are now, and can continue using that reasoning to help drive future
decisions.

## Related issues

This supports NVIDIA#4622

## Type of Change

- [ ] **Add** - New feature or capability
- [ ] **Change** - Changes in existing functionality
- [ ] **Fix** - Bug fixes
- [ ] **Remove** - Removed features or deprecated functionality
- [x] **Internal** - Internal changes (refactoring, tests, docs, etc.)

## Breaking Changes

- [ ] **This PR contains breaking changes**

## Testing

- [ ] Unit tests added/updated
- [ ] Integration tests added/updated
- [ ] Manual testing performed
- [x] No testing required (docs, internal refactor, etc.)

## Additional Notes

Validated with `cargo make format-nightly`, `cargo make clippy`, the
cached Carbide-lints workflow, `rumdl`, `git diff --check`, and a Pandoc
render. No tests were run because this is a documentation-only change.

Signed-off-by: Chet Nichols III <chetn@nvidia.com>
chet added a commit that referenced this pull request Aug 14, 2026
_This continues the style-guide series from
#4608,
#4648,
#4739,
#4641, and
#4783

This is the `STYLE_GUIDE.md` half of the state-controller durability
guidance from #4623.

**Transactions cannot make external side effects atomic.**
State-controller work that crosses database and external-system
boundaries needs a durable recovery point, must avoid holding database
transactions open across external I/O, and needs fencing, idempotency,
or reconciliation when work can repeat or overlap.

The short rule has its own scan point beside the existing long-running
work-lock contract and links to the repository's current state-handling
page for controller-model background. The detailed
`docs/architecture/state_handling.md` refresh is in
#4867 so it can move
through the technical-writer queue separately.

## Related issues

This supports #4623

Documentation companion:
#4867

## Type of Change

- [ ] **Add** - New feature or capability
- [ ] **Change** - Changes in existing functionality
- [ ] **Fix** - Bug fixes
- [ ] **Remove** - Removed features or deprecated functionality
- [x] **Internal** - Internal changes (refactoring, tests, docs, etc.)

## Breaking Changes

- [ ] **This PR contains breaking changes**

## Testing

- [ ] Unit tests added/updated
- [ ] Integration tests added/updated
- [ ] Manual testing performed
- [x] No testing required (docs, internal refactor, etc.)

## Additional Notes

Validated with `cargo make format-nightly`, `cargo make clippy`, the
cached Carbide-lints workflow, `rumdl`, `git diff --check`, and a Pandoc
render. No tests were run because this is a documentation-only change.

Signed-off-by: Chet Nichols III <chetn@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Capture NICo Configuration-Ownership Guidance

2 participants