Crate winbrew_database

Crate winbrew_database 

Source
Expand description

Persistence layer for WinBrew.

winbrew-database owns SQLite access, config persistence, journal replay, and MSI inventory normalization. It stays close to the runtime database contract so higher layers can use typed helpers instead of direct SQL plumbing.

The database module keeps its pool registry keyed by resolved paths. That makes the current process-local root model explicit while still keeping the storage boundary centralized for the app and CLI layers.

Re-exportsยง

pub use error::CatalogNotFoundError;
pub use error::CatalogSchemaVersionMismatchError;
pub use winbrew_core as core;
pub use winbrew_models as models;

Modulesยง

bootstrap ๐Ÿ”’
catalog ๐Ÿ”’
command_registry ๐Ÿ”’
config ๐Ÿ”’
connection
error
installed_packages ๐Ÿ”’
journal ๐Ÿ”’
migration ๐Ÿ”’
msi_inventory ๐Ÿ”’

Structsยง

CommandRegistryConflictError
CommittedJournalPackage
Config
ConfigEnv
ConfigSection
A rendered configuration section with key/value pairs.
CoreConfig
FileHash
JournalReader
JournalShimBinding
Lossless command shim binding captured at install time.
JournalWriter
PackageNotFoundError
PathsConfig

Enumsยง

ConfigError
Errors raised while reading, parsing, or validating config values.
ConfigSource
The provenance of a resolved configuration value.
ConfigValidationError
Errors raised while validating config values.
HashAlgo
JournalEntry
JournalReadError
JournalReplayError

Constantsยง

CURRENT_PATHS ๐Ÿ”’

Staticsยง

CATALOG_DB_POOLS ๐Ÿ”’
DB_POOLS ๐Ÿ”’

Functionsยง

apply_snapshot
commit_install
commit_install_with_commands
config_sections
config_set
config_unset
delete_package
find_command_owner
find_command_owners
find_packages_by_normalized_path
find_packages_by_normalized_registry_key_path
get_catalog_conn
Return a pooled connection to the catalog database.
get_catalog_pool ๐Ÿ”’
get_conn
Return a pooled connection to the primary database.
get_effective_value
get_installers
Return all catalog installers for a package id.
get_package
get_package_by_id
Return a single catalog package by its catalog package id.
get_package_command_names
get_pool ๐Ÿ”’
get_snapshot
init
Initialize the process-local storage state for the given resolved paths.
insert_package
list_commands_for_package
list_installing_packages
list_packages
package_journal_key
parse_command_names
pool_for ๐Ÿ”’
replace_snapshot
replay_committed_journal
resolved_paths ๐Ÿ”’
search
Search the catalog database for packages matching the query.
suggest_key
sync_package_commands
update_installing_identity
update_status
update_status_and_engine_metadata
upsert_receipt

Type Aliasesยง

DbConnection