mediatorlite-rest-api-benchmarks

Run MediatorLite versus MediatR REST API benchmarks in ASP.NET Core scenarios.

4|1|Updated Jan 11, 2026
One-click install
npx skills add https://github.com/behl1anmol/MediatorLite --skill mediatorlite-rest-api-benchmarks
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: mediatorlite-rest-api-benchmarks
Source: https://github.com/behl1anmol/MediatorLite/tree/main/.cursor/skills/mediatorlite-rest-api-benchmarks
Command: npx skills add https://github.com/behl1anmol/MediatorLite --skill mediatorlite-rest-api-benchmarks

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill solves the challenge of getting accurate, real-world performance comparisons between MediatorLite and MediatR by eliminating test drift and ensuring both implementations are tested in identical, production-like ASP.NET Core + EF Core scenarios.

Core Features & Use Cases

  • End-to-end benchmark harness: Runs realistic ASP.NET Core minimal API workflows with EF Core SQLite persistence to measure actual dispatch cost, not synthetic microbenchmarks.
  • Built-in parity validation: The BenchmarkParityGuard automatically verifies that both mediator implementations have identical handler, behavior, and validator counts at startup, so any performance difference is attributable to the mediator itself, not test configuration drift.
  • Configurable test matrix: Test across multiple axes including in-process TestServer vs localhost Kestrel transport, medium/large datasets, and 1/8/32 concurrent request levels.
  • Use case: Use this to validate that changes to MediatorLite's source generator do not introduce performance regressions compared to MediatR, or to diagnose unexpected benchmark result changes by catching parity issues before test runs.

Quick Start

Use this skill to run the full MediatorLite vs MediatR REST API benchmark matrix and identify performance regressions in mediator dispatch for production-like ASP.NET Core applications.

Frequently Asked Questions about mediatorlite-rest-api-benchmarks

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I benchmark MediatorLite vs MediatR performance in an ASP.NET Core API?

To benchmark MediatorLite vs MediatR performance in an ASP.NET Core API, use a harness that runs realistic minimal API workflows with EF Core SQLite persistence and built-in parity validation. This measures actual dispatch cost across HTTP transport, dataset size, and concurrent request loads.

Why do my mediator performance benchmarks show inconsistent results between test runs?

Inconsistent mediator performance benchmarks often result from test configuration drift. A parity guard automatically validates identical handler, behavior, and validator counts at startup, ensuring performance differences reflect the mediator itself rather than mismatched test setups.

How do I test mediator dispatch cost under concurrent load in .NET 10+?

Testing mediator dispatch cost under concurrent load in .NET 10+ requires a configurable test matrix. You can measure end-to-end dispatch performance across in-process TestServer or localhost Kestrel transports with 1, 8, or 32 concurrent request levels.

What is the best way to catch MediatorLite source generator regressions against MediatR?

The best way to catch MediatorLite source generator regressions against MediatR is running end-to-end REST API benchmarks that enforce implementation parity. This isolates dispatch performance differences and validates that source generator changes do not introduce slowdowns.

Can I benchmark mediator dispatch using synthetic microbenchmarks instead of real API workflows?

Synthetic microbenchmarks do not reflect real-world dispatch overhead. Running realistic ASP.NET Core minimal API workflows with EF Core SQLite persistence provides accurate end-to-end dispatch performance measurement for production-like applications.

Does the MediatorLite benchmark tool support testing with different dataset sizes?

Yes, the MediatorLite benchmark tool supports testing with different dataset sizes. You can configure the test matrix to use medium or large datasets alongside varying transport types and concurrency levels to measure dispatch performance accurately.