Skip to content

Commit

Permalink
have diffus simply eat oxnet and newtype-uuid
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewjstone committed Dec 18, 2024
1 parent 605e71f commit 48fb11f
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 47 deletions.
63 changes: 28 additions & 35 deletions Cargo.lock

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

13 changes: 5 additions & 8 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ derive-where = "1.2.7"
diesel = { version = "2.2.4", features = ["i-implement-a-third-party-backend-and-opt-into-breaking-changes", "postgres", "r2d2", "chrono", "serde_json", "network-address", "uuid"] }
diesel-dtrace = "0.4.2"
#diffus = { version = "0.10.0", features = ["uuid-impl", "derive"] }
diffus = { path = "../diffus/diffus", features = ["uuid-impl", "derive"] }
diffus = { path = "../diffus/diffus", features = ["uuid-impl", "derive", "newtype-uuid-impl", "oxnet-impl"] }
dns-server = { path = "dns-server" }
dns-server-api = { path = "dns-server-api" }
dns-service-client = { path = "clients/dns-service-client" }
Expand Down Expand Up @@ -452,8 +452,7 @@ maplit = "1.0.2"
mockall = "0.13"
newtype_derive = "0.1.6"
mg-admin-client = { git = "https://github.com/oxidecomputer/maghemite", rev = "93cd0d642cf1b58f9f4528275e2a2aa758e9feb3" }
#ddm-admin-client = { git = "https://github.com/oxidecomputer/maghemite", rev = "93cd0d642cf1b58f9f4528275e2a2aa758e9feb3" }
ddm-admin-client = { path = "../maghemite/ddm-admin-client" }
ddm-admin-client = { git = "https://github.com/oxidecomputer/maghemite", rev = "93cd0d642cf1b58f9f4528275e2a2aa758e9feb3" }
multimap = "0.10.0"
nexus-auth = { path = "nexus/auth" }
nexus-client = { path = "clients/nexus-client" }
Expand Down Expand Up @@ -499,8 +498,7 @@ omicron-zone-package = "0.11.1"
oxide-client = { path = "clients/oxide-client" }
oxide-vpc = { git = "https://github.com/oxidecomputer/opte", rev = "b56afeeb14e0042cbd7bda85b166ed86ee17820e", features = [ "api", "std" ] }
oxlog = { path = "dev-tools/oxlog" }
#oxnet = { git = "https://github.com/oxidecomputer/oxnet", features = ["diffus"] }
oxnet = { path = "../oxnet", features = ["diffus"] }
oxnet = { git = "https://github.com/oxidecomputer/oxnet" }
once_cell = "1.20.2"
openapi-lint = { git = "https://github.com/oxidecomputer/openapi-lint", branch = "main" }
openapi-manager-types = { path = "dev-tools/openapi-manager/types" }
Expand Down Expand Up @@ -676,9 +674,8 @@ zone = { version = "0.3", default-features = false, features = ["async"] }
# the kinds). However, uses of omicron-uuid-kinds _within omicron_ will have
# std and the other features enabled because they'll refer to it via
# omicron-uuid-kinds.workspace = true.
#newtype-uuid = { version = "1.1.3", default-features = false }
newtype-uuid = { path = "../newtype-uuid/crates/newtype-uuid", default-features = false }
omicron-uuid-kinds = { path = "uuid-kinds", features = ["serde", "schemars08", "uuid-v4", "diffus"] }
newtype-uuid = { version = "1.1.3", default-features = false }
omicron-uuid-kinds = { path = "uuid-kinds", features = ["serde", "schemars08", "uuid-v4"] }

# NOTE: The test profile inherits from the dev profile, so settings under
# profile.dev get inherited. AVOID setting anything under profile.test: that
Expand Down
2 changes: 1 addition & 1 deletion nexus/types/src/deployment.rs
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ pub struct Blueprint {
pub clickhouse_cluster_config: Option<ClickhouseClusterConfig>,

/// when this blueprint was generated (for debugging)
#[diffus_ignore]
#[diffus(ignore)]
pub time_created: chrono::DateTime<chrono::Utc>,
/// identity of the component that generated the blueprint (for debugging)
/// This would generally be the Uuid of a Nexus instance.
Expand Down
1 change: 0 additions & 1 deletion uuid-kinds/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ paste.workspace = true

[features]
default = ["std"]
diffus = ["newtype-uuid/diffus"]
serde = ["newtype-uuid/serde"]
schemars08 = ["newtype-uuid/schemars08", "schemars", "std"]
std = ["newtype-uuid/std"]
Expand Down
3 changes: 1 addition & 2 deletions uuid-kinds/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ pub use newtype_uuid::{
GenericUuid, ParseError, TagError, TypedUuid, TypedUuidKind, TypedUuidTag,
};

#[cfg(feature = "diffus")]
use diffus::Diffus;
#[cfg(feature = "schemars08")]
use schemars::JsonSchema;
Expand All @@ -24,7 +23,7 @@ macro_rules! impl_typed_uuid_kind {
$(
paste::paste! {
#[cfg_attr(feature = "schemars08", derive(JsonSchema))]
#[cfg_attr(feature = "diffus", derive(Diffus))]
#[derive(Diffus)]
pub enum [< $kind Kind>] {}

impl TypedUuidKind for [< $kind Kind >] {
Expand Down

0 comments on commit 48fb11f

Please sign in to comment.