Skip to content

v3/feature/217: Remove Scrutor Dependency / Offer Manual Registration#234

Merged
eneshoxha merged 1 commit into
v3.2/releasefrom
v3/feature/217
Feb 24, 2026
Merged

v3/feature/217: Remove Scrutor Dependency / Offer Manual Registration#234
eneshoxha merged 1 commit into
v3.2/releasefrom
v3/feature/217

Conversation

@eneshoxha
Copy link
Copy Markdown
Contributor

Remove Scrutor; add custom assembly scanning for DI

Replaced Scrutor-based assembly scanning and registration with a custom ScanAndRegister method using reflection. Updated all handler and processor registrations to use the new approach. Removed Scrutor package reference and updated comments to reflect the change. The codebase no longer depends on Scrutor for DI scanning.

ServiceCollectionExtensions.cs — Replaced all 8 services.Scan(...) Scrutor calls with a new ScanAndRegister private helper method that uses reflection (GetExportedTypes/GetTypes) to discover and
register handlers. Updated usings: added System.Reflection, removed unused System.Data.

Cortex.Mediator.csproj — Removed the Scrutor 6.0.1 PackageReference.

HandlerLifetimeTests.cs — Updated comment from "Scrutor" to "assembly scanning".

Verification: All 226 mediator tests pass, and Scrutor no longer appears in the dependency list.

Remove Scrutor; add custom assembly scanning for DI

Replaced Scrutor-based assembly scanning and registration with a custom ScanAndRegister method using reflection. Updated all handler and processor registrations to use the new approach. Removed Scrutor package reference and updated comments to reflect the change. The codebase no longer depends on Scrutor for DI scanning.

ServiceCollectionExtensions.cs — Replaced all 8 services.Scan(...) Scrutor calls with a new ScanAndRegister private helper method that uses reflection (GetExportedTypes/GetTypes) to discover and
  register handlers. Updated usings: added System.Reflection, removed unused System.Data.

  Cortex.Mediator.csproj — Removed the Scrutor 6.0.1 PackageReference.

  HandlerLifetimeTests.cs — Updated comment from "Scrutor" to "assembly scanning".

  Verification: All 226 mediator tests pass, and Scrutor no longer appears in the dependency list.
@eneshoxha eneshoxha added this to the Cortex v3.2 milestone Feb 24, 2026
@eneshoxha eneshoxha self-assigned this Feb 24, 2026
@eneshoxha eneshoxha added enhancement New feature or request feature This label is in use for minor version increments labels Feb 24, 2026
@eneshoxha eneshoxha linked an issue Feb 24, 2026 that may be closed by this pull request
@eneshoxha eneshoxha merged commit ed8bc81 into v3.2/release Feb 24, 2026
@eneshoxha eneshoxha deleted the v3/feature/217 branch February 24, 2026 13:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request feature This label is in use for minor version increments

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: Remove Scrutor Dependency / Offer Manual Registration

1 participant