Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dev-tools/omdb/src/bin/omdb/db.rs
Original file line number Diff line number Diff line change
Expand Up @@ -583,7 +583,7 @@ impl DbArgs {
/// incompatible because in practice it may well not matter and it's very
/// valuable for this tool to work if it possibly can.
async fn check_schema_version(datastore: &DataStore) {
let expected_version = nexus_db_model::schema::SCHEMA_VERSION;
let expected_version = nexus_db_model::SCHEMA_VERSION;
let version_check = datastore.database_schema_version().await;

match version_check {
Expand Down
4 changes: 4 additions & 0 deletions nexus/db-model/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ omicron-rpaths.workspace = true

[dependencies]
anyhow.workspace = true
camino.workspace = true
chrono.workspace = true
derive-where.workspace = true
diesel = { workspace = true, features = ["postgres", "r2d2", "chrono", "serde_json", "network-address", "uuid"] }
Expand All @@ -17,6 +18,7 @@ ipnetwork.workspace = true
macaddr.workspace = true
newtype_derive.workspace = true
omicron-uuid-kinds.workspace = true
once_cell.workspace = true
parse-display.workspace = true
# See omicron-rpaths for more about the "pq-sys" dependency.
pq-sys = "*"
Expand All @@ -29,6 +31,7 @@ serde_json.workspace = true
steno.workspace = true
strum.workspace = true
thiserror.workspace = true
tokio.workspace = true
uuid.workspace = true

db-macros.workspace = true
Expand All @@ -42,4 +45,5 @@ sled-agent-client.workspace = true
omicron-workspace-hack.workspace = true

[dev-dependencies]
camino-tempfile.workspace = true
expectorate.workspace = true
2 changes: 2 additions & 0 deletions nexus/db-model/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ mod role_assignment;
mod role_builtin;
pub mod saga_types;
pub mod schema;
mod schema_versions;
mod service;
mod service_kind;
mod silo;
Expand Down Expand Up @@ -158,6 +159,7 @@ pub use region::*;
pub use region_snapshot::*;
pub use role_assignment::*;
pub use role_builtin::*;
pub use schema_versions::*;
pub use semver_version::*;
pub use service::*;
pub use service_kind::*;
Expand Down
9 changes: 0 additions & 9 deletions nexus/db-model/src/schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,6 @@
//!
//! NOTE: Should be kept up-to-date with dbinit.sql.

use omicron_common::api::external::SemverVersion;

/// The version of the database schema this particular version of Nexus was
/// built against.
///
/// This should be updated whenever the schema is changed. For more details,
/// refer to: schema/crdb/README.adoc
pub const SCHEMA_VERSION: SemverVersion = SemverVersion::new(45, 0, 0);

table! {
disk (id) {
id -> Uuid,
Expand Down
Loading