WIP: RUES HTTP server | RUES Domain Layer Implementation #3302
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.
WIP: RUES Domain Layer Implementation
Summary
This PR implements the core domain layer for the RUES server, focusing on type definitions, processing pipelines with validation rules, and error handling. It follows Hexagonal Architecture principles and strict code quality guidelines.
Documentation
cd rusk
and runcargo doc --open
. Then navigate tohttp
module, and then navigate todomain
module.Tests (currently, 166 tests and 177 doc tests)
run
cargo test --release --features testwallet -p rusk -- http::domain --nocapture --color=always --show-output --include-ignored
Changes by Module
🔧 Core Types (
domain/types/
)Topic
- String-based topic representationRuesPath
- Path structure with modern/legacy supportRuesHeaders
- Protocol headers with serializationSessionId
- 16-byte session identifierVersion
- Semantic versioning supportIdentifierBytes
- Base type for binary identifiers🚦 Validation (
domain/validation/
)Core validation framework
ValidationRule
traitValidationContext
with metricsIdentifier validation
Header validation
Path validation
❌ Error Handling (
domain/error/
)🏭 Factory (
domain/factory/
)domain
module (needed in processors and in doc tests and examples)📝 Formats (
domain/formats/
)🔄 Processing (
domain/processing/
)Testing Coverage
Documentation
Future Work
Breaking Changes
None - this is a new implementation.
Dependencies Added
serde
andserde_json
for serializationthiserror
for error handlingbytes
for binary dataparking_lot
for efficient locksmetrics
for monitoring