Skip to main content

Crate perfgate_app

Crate perfgate_app 

Source
Expand description

Application layer for perfgate.

The app layer coordinates adapters and domain logic into use-case workflows such as run, compare, report, check, export, paired, and promote. It does not parse CLI flags and it does not do filesystem I/O.

Part of the perfgate workspace.

Re-exports§

pub use badge::Badge;
pub use badge::BadgeInput;
pub use badge::BadgeOutcome;
pub use badge::BadgeRequest;
pub use badge::BadgeStyle;
pub use badge::BadgeType;
pub use badge::BadgeUseCase;
pub use bisect::BisectRequest;
pub use bisect::BisectUseCase;
pub use blame::BlameOutcome;
pub use blame::BlameRequest;
pub use blame::BlameUseCase;

Modules§

badge
SVG badge generation for perfgate performance status.
baseline_resolve
Baseline path resolution logic.
bisect
Bisection orchestration.
blame
cargo_bench
Cargo bench integration: parse Criterion and libtest bench output into RunReceipts.
comparison_logic
Logic for building budgets and metric statistics for comparisons.
discover
Auto-discovery of benchmarks in a repository.
init
Benchmark discovery and config generation for perfgate init.
watch
Watch use case — re-run benchmarks on file changes with live terminal output.

Structs§

AggregateOutcome
AggregateRequest
AggregateUseCase
BenchDiffOutcome
Outcome for a single benchmark diff.
CheckOutcome
Outcome of the check use case.
CheckRequest
Request for the check use case.
CheckUseCase
Use case for running a config-driven check.
CompareExportRow
Row structure for CompareReceipt export.
CompareRequest
CompareResult
Result from CompareUseCase including host mismatch information.
CompareUseCase
DiffOutcome
Overall outcome of the diff command.
DiffRequest
Request for the diff use case.
DiffUseCase
Use case for running a diff workflow.
ExplainOutcome
ExplainRequest
ExplainUseCase
ExportUseCase
Use case for exporting receipts to different formats.
PairedRunOutcome
PairedRunRequest
PairedRunUseCase
PromoteRequest
Request for promoting a run receipt to become a baseline.
PromoteResult
Result of a promote operation.
PromoteUseCase
Use case for promoting run receipts to baselines.
ReportRequest
Request for generating a report from a compare receipt.
ReportResult
Result of a report generation operation.
ReportUseCase
Use case for generating perfgate reports.
RunBenchOutcome
RunBenchRequest
RunBenchUseCase
RunExportRow
Row structure for RunReceipt export.
SensorCheckOptions
Options for run_sensor_check.
SensorReportBuilder
Builder for creating SensorReports.
SystemClock
TrendOutcome
Result of trend analysis.
TrendRequest
Request for local trend analysis from run receipt files.
TrendUseCase
Use case for trend analysis.

Enums§

BenchOutcome
ExportFormat
Supported export formats.

Traits§

Clock

Functions§

classify_error
Classify an error into (stage, error_kind) for structured error reporting.
default_engine_capability
direction_str
Return a human-readable label for a budget Direction.
discover_config
Walk up from start looking for perfgate.toml or perfgate.json.
format_metric
Return the canonical string key for a Metric.
format_metric_with_statistic
Format a metric key, appending the statistic name when it is not the default (median).
format_pct
Format a fractional change as a percentage string.
format_trend_chart
Format a mini ASCII chart line for a metric’s history.
format_trend_output
Format trend analysis results for terminal display.
format_value
Format a metric value for display.
github_annotations
Produce GitHub Actions annotation strings from a CompareReceipt.
markdown_template_context
Build the JSON context object used by render_markdown_template.
metric_status_icon
Return an emoji icon for a MetricStatus.
metric_status_str
Return a lowercase string label for a MetricStatus.
parse_reason_token
Parse a verdict reason token like "wall_ms_warn" into its metric and status.
render_json_diff
Render the diff outcome as JSON.
render_markdown
Render a CompareReceipt as a Markdown table for PR comments.
render_markdown_template
Render a CompareReceipt using a custom Handlebars template.
render_reason_line
Render a single verdict reason token as a human-readable bullet line.
render_terminal_diff
Render a terminal-friendly colored diff output from a DiffOutcome.
run_sensor_check
Run a sensor check and return a SensorReport directly.
sensor_fingerprint
Generates a fingerprint for a set of findings.