theseus-rs / postgresql-embedded

Embed PostgreSQL database
Apache License 2.0
34 stars 5 forks source link

refactor!: move version from PostgreSQL::new() to Settings #82

Closed brianheineman closed 2 weeks ago

brianheineman commented 2 weeks ago

This PR makes significant changes to the way the PostgreSQL Version is managed. The version is moved into Settings to provide a consistent configuration approach. This also enables the version to be configured from a URL.

API Changes

Migration If a specific version was being specified, then the code can generally change from this:

let version = V15;
let settings = Settings::default();
let postgresql = PostgreSQL::new(version, settings);

to this:

let version = V15;
let settings = Settings {
    version,
    ..Settings::default()
};
let postgresql = PostgreSQL::new(settings);
github-actions[bot] commented 2 weeks ago

🐰Bencher

ReportFri, June 21, 2024 at 19:46:03 UTC
Projecttheseus-rs/postgresql-embedded
Branchrefactor-version
Testbedlocalhost

⚠️ WARNING: The following Measure does not have a Threshold. Without a Threshold, no Alerts will ever be generated!

  • Latency (latency)

Click here to create a new Threshold
For more information, see the Threshold documentation.
To only post results if a Threshold exists, set the --ci-only-thresholds CLI flag.

Click to view all benchmark results
BenchmarkLatencyLatency Results
nanoseconds (ns)
extract➖ (view plot)152,170.00
lifecycle➖ (view plot)904,920,000.00

Bencher - Continuous Benchmarking
View Public Perf Page
Docs | Repo | Chat | Help
codecov[bot] commented 2 weeks ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 99.75%. Comparing base (4055763) to head (589596b).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #82 +/- ## ========================================== - Coverage 99.78% 99.75% -0.03% ========================================== Files 59 59 Lines 7775 7775 ========================================== - Hits 7758 7756 -2 - Misses 17 19 +2 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.