Skip to content

Commit 3a92835

Browse files
Merge pull request #106 from theseus-rs/update-docs
docs: add version optimization documentation
2 parents 8b29f29 + 4aa0cd5 commit 3a92835

File tree

2 files changed

+16
-6
lines changed

2 files changed

+16
-6
lines changed

postgresql_embedded/README.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,15 +78,20 @@ determined by the `POSTGRESQL_VERSION` environment variable. If the `POSTGRESQL_
7878
environment variable is not set, then `postgresql_archive::LATEST` will be used to determine the
7979
version of the PostgreSQL binaries to download.
8080

81-
When downloading the PostgreSQL binaries, either during build, or at runtime, the `GITHUB_TOKEN`
82-
environment variable can be set to a GitHub personal access token to increase the rate limit for
83-
downloading the PostgreSQL binaries. The `GITHUB_TOKEN` environment variable is not required.
81+
When downloading the theseus PostgreSQL binaries, either during build, or at runtime, the
82+
`GITHUB_TOKEN` environment variable can be set to a GitHub personal access token to increase
83+
the rate limit for downloading the PostgreSQL binaries. The `GITHUB_TOKEN` environment
84+
variable is not required.
8485

8586
At runtime, the PostgreSQL binaries are cached by default in the following directories:
8687

8788
- Unix: `$HOME/.theseus/postgresql`
8889
- Windows: `%USERPROFILE%\.theseus\postgresql`
8990

91+
Performance can be improved by Using a specific version of the PostgreSQL binaries (e.g. `=16.3.0`).
92+
After the first download, the PostgreSQL binaries will be cached and reused for subsequent runs.
93+
Further, the repository will no longer be queried to calculate the version match.
94+
9095
## Feature flags
9196

9297
postgresql_embedded uses feature flags to address compile time and binary size

postgresql_embedded/src/lib.rs

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,20 @@
6565
//! environment variable is not set, then `postgresql_archive::LATEST` will be used to determine the
6666
//! version of the PostgreSQL binaries to download.
6767
//!
68-
//! When downloading the PostgreSQL binaries, either during build, or at runtime, the `GITHUB_TOKEN`
69-
//! environment variable can be set to a GitHub personal access token to increase the rate limit for
70-
//! downloading the PostgreSQL binaries. The `GITHUB_TOKEN` environment variable is not required.
68+
//! When downloading the theseus PostgreSQL binaries, either during build, or at runtime, the
69+
//! `GITHUB_TOKEN` environment variable can be set to a GitHub personal access token to increase
70+
//! the rate limit for downloading the PostgreSQL binaries. The `GITHUB_TOKEN` environment
71+
//! variable is not required.
7172
//!
7273
//! At runtime, the PostgreSQL binaries are cached by default in the following directories:
7374
//!
7475
//! - Unix: `$HOME/.theseus/postgresql`
7576
//! - Windows: `%USERPROFILE%\.theseus\postgresql`
7677
//!
78+
//! Performance can be improved by Using a specific version of the PostgreSQL binaries (e.g. `=16.3.0`).
79+
//! After the first download, the PostgreSQL binaries will be cached and reused for subsequent runs.
80+
//! Further, the repository will no longer be queried to calculate the version match.
81+
//!
7782
//! ## Feature flags
7883
//!
7984
//! postgresql_embedded uses feature flags to address compile time and binary size

0 commit comments

Comments
 (0)