Skip to content

[stable32] refactor: move status validation to sequential service#6165

Merged
vitormattos merged 3 commits intostable32from
backport/6163/stable32
Dec 12, 2025
Merged

[stable32] refactor: move status validation to sequential service#6165
vitormattos merged 3 commits intostable32from
backport/6163/stable32

Conversation

@backportbot-libresign
Copy link
Copy Markdown

Backport of PR #6163

Move status-related validation logic to SequentialSigningService where
it belongs, improving code cohesion and testability.

Changes:
- Add hasPendingLowerOrderSigners() method to check for incomplete
  lower-order signers
- Add isStatusUpgrade() method to validate status transitions
- Add validateStatusByOrder() method to encapsulate ordering
  validation logic for status transitions

These methods are now public and easily testable, centralizing all
sequential signing validation logic in a single specialized service.

Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
Remove internal validation methods from RequestSignatureService and
delegate to SequentialSigningService for better separation of concerns.

Changes:
- Remove hasPendingLowerOrderSigners() private method
- Remove isStatusUpgrade() private method
- Replace inline ordering validation with call to
  validateStatusByOrder()
- Simplify determineInitialStatus() by delegating validation logic

This reduces complexity in RequestSignatureService and makes the code
more maintainable by following single responsibility principle. All
sequential signing logic is now centralized in the specialized service.

Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
@github-project-automation github-project-automation Bot moved this to 0. Needs triage in Roadmap Dec 12, 2025
@backportbot-libresign backportbot-libresign Bot added this to the Next Patch (32) milestone Dec 12, 2025
@vitormattos vitormattos merged commit 7aa2c59 into stable32 Dec 12, 2025
62 checks passed
@vitormattos vitormattos deleted the backport/6163/stable32 branch December 12, 2025 18:29
@github-project-automation github-project-automation Bot moved this from 0. Needs triage to 4. to release in Roadmap Dec 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

1 participant