Skip to content

Refactor validator server naming and modules#2231

Merged
sergerad merged 4 commits into
sergerad-validator-startupfrom
sergerad-validator-modules
Jun 11, 2026
Merged

Refactor validator server naming and modules#2231
sergerad merged 4 commits into
sergerad-validator-startupfrom
sergerad-validator-modules

Conversation

@sergerad

@sergerad sergerad commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

Stacked PR.

Creates clearer separation between validator server scaffolding (ValidatorServer) and api impl / business logic (Validator).

  • Validator renamed to ValidatorServer (has ValidatorServer::serve()) and ValidatorServer renamed to Validator
  • validator module added to validator server module
  • error renamed to ValidatorError

From

server/
    mod.rs
    sign_block.rs
    validate_block.rs
    ...

To

server/
    mod.rs
    validator/
        *.rs

@sergerad sergerad added the no changelog This PR does not require an entry in the `CHANGELOG.md` file label Jun 10, 2026
@Mirko-von-Leipzig

Mirko-von-Leipzig commented Jun 11, 2026

Copy link
Copy Markdown
Collaborator

I agree with the concept, but I dislike the raw validator nesting in there. Maybe we can move to a common pattern across the crates of:

server/
  mod.rs
  xxx_service/
    mod.rs
    method_a
    method_b
  yyy_service/
    mod.rs
    method_y
    method_z
  other_thing

so in this case I guess the primary objection I have is that Validator should be ValidatorService or something indicating Grpc in the validator_service or similar?

@sergerad sergerad merged commit eeeafd8 into sergerad-validator-startup Jun 11, 2026
20 checks passed
@sergerad sergerad deleted the sergerad-validator-modules branch June 11, 2026 22:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no changelog This PR does not require an entry in the `CHANGELOG.md` file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants