feat(config): add ValidateConfig trait and per-service validation#1224
Closed
geoffjay wants to merge 2 commits into
Closed
feat(config): add ValidateConfig trait and per-service validation#1224geoffjay wants to merge 2 commits into
geoffjay wants to merge 2 commits into
Conversation
Add a ValidateConfig trait to agentd_common with implementations for all 12 shared config sections. Add AgentdConfig::validate() that collects errors from every section. Implement ValidateConfig on all service-level config structs and wire validate() into each service's startup path so misconfigurations fail early with descriptive error messages. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add impl ValidateConfig for EmbeddingConfig and LanceConfig in crates/memory/src/config.rs (blocking gap: memory was the only service with no validation at startup) - Wire validation in memory/main.rs: call validate() on embedding and lance configs, load shared config for port/host so port=0 is caught before any I/O with a clear error message - Remove validate_inner() indirection in crates/index/src/config.rs; move logic directly into impl ValidateConfig for IndexConfig and import the trait in index/main.rs and the test module - Make validate_url() pub in agentd-common so service crates can reuse it without duplicating the http/https check Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Owner
Author
|
This change is part of the following stack:
Change managed by git-spice. |
This was referenced May 12, 2026
Owner
Author
|
Duplicate of #1212 — created erroneously by git-spice during restack. Closing in favour of the original PR. |
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.
feat(config): add ValidateConfig trait and per-service validation
Add a ValidateConfig trait to agentd_common with implementations for all
12 shared config sections. Add AgentdConfig::validate() that collects
errors from every section. Implement ValidateConfig on all service-level
config structs and wire validate() into each service's startup path so
misconfigurations fail early with descriptive error messages.
Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com
fix(config): address review feedback on ValidateConfig PR
crates/memory/src/config.rs (blocking gap: memory was the only service
with no validation at startup)
lance configs, load shared config for port/host so port=0 is caught
before any I/O with a clear error message
move logic directly into impl ValidateConfig for IndexConfig and
import the trait in index/main.rs and the test module
it without duplicating the http/https check
Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com