From 29681f16475df095053bcd310ed47461437f7ac0 Mon Sep 17 00:00:00 2001 From: CeerDecy <1748788674@qq.com> Date: Fri, 6 Sep 2024 15:42:44 +0800 Subject: [PATCH 1/4] Upgrade serde_yaml Signed-off-by: CeerDecy <1748788674@qq.com> --- Cargo.lock | 9 +++++---- agent/Cargo.toml | 4 ++-- discovery-handlers/debug-echo/Cargo.toml | 2 +- discovery-handlers/opcua/Cargo.toml | 1 + discovery-handlers/opcua/src/discovery_handler.rs | 1 + discovery-utils/Cargo.toml | 2 +- shared/Cargo.toml | 2 +- 7 files changed, 12 insertions(+), 9 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index ba116e178..b1d8f8500 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -253,7 +253,7 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "serde_yaml 0.8.26", + "serde_yaml 0.9.30", "simple-mermaid", "tempfile", "thiserror", @@ -298,7 +298,7 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "serde_yaml 0.8.26", + "serde_yaml 0.9.30", "tokio", "tokio-stream", "tonic", @@ -317,7 +317,7 @@ dependencies = [ "prost", "serde", "serde_derive", - "serde_yaml 0.8.26", + "serde_yaml 0.9.30", "tempfile", "tokio", "tokio-stream", @@ -368,6 +368,7 @@ dependencies = [ "serde", "serde_derive", "serde_json", + "serde_yaml 0.9.30", "tokio", "tokio-stream", "tonic", @@ -392,7 +393,7 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "serde_yaml 0.8.26", + "serde_yaml 0.9.30", "tokio", "tonic", "tower", diff --git a/agent/Cargo.toml b/agent/Cargo.toml index 90d22ad28..38ca06954 100644 --- a/agent/Cargo.toml +++ b/agent/Cargo.toml @@ -36,7 +36,7 @@ prost = "0.12" serde = "1.0.104" serde_derive = "1.0.104" serde_json = "1.0.45" -serde_yaml = { version = "0.8.11", optional = true } +serde_yaml = { version = "0.9", optional = true } simple-mermaid = "0.1" # used for docs thiserror = "1.0.50" tokio = { version = "1.0", features = ["rt-multi-thread", "time", "fs", "macros", "net"] } @@ -57,7 +57,7 @@ akri-udev = { path = "../discovery-handlers/udev"} env_logger = "0.10.0" mock_instant = { version = "0.2", features = ["sync"] } mockall = "0.12" -serde_yaml = "0.8.11" +serde_yaml = "0.9" tempfile = "3.1.0" [features] diff --git a/discovery-handlers/debug-echo/Cargo.toml b/discovery-handlers/debug-echo/Cargo.toml index d391ccd26..d5734e9f1 100644 --- a/discovery-handlers/debug-echo/Cargo.toml +++ b/discovery-handlers/debug-echo/Cargo.toml @@ -24,4 +24,4 @@ tonic = { version = "0.10", features = ["tls"] } akri-shared = { path = "../../shared" } anyhow = "1.0.38" serde_json = "1.0.45" -serde_yaml = "0.8.11" +serde_yaml = "0.9" diff --git a/discovery-handlers/opcua/Cargo.toml b/discovery-handlers/opcua/Cargo.toml index 66327888c..3e0b65d59 100644 --- a/discovery-handlers/opcua/Cargo.toml +++ b/discovery-handlers/opcua/Cargo.toml @@ -18,6 +18,7 @@ log = "0.4" opcua = { version = "0.12.0", features = ["client"] } serde = "1.0.104" serde_derive = "1.0.1" +serde_yaml = "0.9" tokio = { version = "1.0.2", features = ["time", "net", "sync"] } tokio-stream = { version = "0.1", features = ["net"] } tonic = { version = "0.10", features = ["tls"] } diff --git a/discovery-handlers/opcua/src/discovery_handler.rs b/discovery-handlers/opcua/src/discovery_handler.rs index dffbbebfe..c9b9ddd27 100644 --- a/discovery-handlers/opcua/src/discovery_handler.rs +++ b/discovery-handlers/opcua/src/discovery_handler.rs @@ -52,6 +52,7 @@ fn lds_discovery_url() -> Vec { #[derive(Serialize, Deserialize, Clone, Debug)] #[serde(rename_all = "camelCase")] pub struct OpcuaDiscoveryDetails { + #[serde(with = "serde_yaml::with::singleton_map")] pub opcua_discovery_method: OpcuaDiscoveryMethod, #[serde(default, skip_serializing_if = "Option::is_none")] pub application_names: Option, diff --git a/discovery-utils/Cargo.toml b/discovery-utils/Cargo.toml index 96cd5b9f7..dbd3c34ec 100644 --- a/discovery-utils/Cargo.toml +++ b/discovery-utils/Cargo.toml @@ -18,7 +18,7 @@ log = "0.4" prost = "0.12" serde = "1.0" serde_derive = "1.0" -serde_yaml = "0.8.11" +serde_yaml = "0.9" tempfile = { version = "3.1.0", optional = true } tokio = { version = "1.0.1", features = ["time", "net", "sync"] } tokio-stream = { version = "0.1", features = ["net"] } diff --git a/shared/Cargo.toml b/shared/Cargo.toml index 2ffe521d0..ddadbe818 100644 --- a/shared/Cargo.toml +++ b/shared/Cargo.toml @@ -22,7 +22,7 @@ schemars = "0.8.0" serde = "1.0" serde_derive = "1.0" serde_json = "1.0" -serde_yaml = "0.8" +serde_yaml = "0.9" tokio = { version = "1.0.1", features = ["full"] } tonic = "0.10" tower = "0.4.8" From 1d2c5b6605d1f4683247af4f87c610bec852a7c1 Mon Sep 17 00:00:00 2001 From: CeerDecy <1748788674@qq.com> Date: Mon, 9 Sep 2024 10:36:48 +0800 Subject: [PATCH 2/4] serialize ConfigurationSpec with singleton_map Signed-off-by: CeerDecy <1748788674@qq.com> --- shared/src/akri/configuration.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/shared/src/akri/configuration.rs b/shared/src/akri/configuration.rs index 3406361d8..d2dd59532 100644 --- a/shared/src/akri/configuration.rs +++ b/shared/src/akri/configuration.rs @@ -119,7 +119,12 @@ pub struct ConfigurationSpec { /// This defines a workload that should be scheduled to any /// node that can access any capability described by this /// configuration - #[serde(default, skip_serializing_if = "Option::is_none")] + #[serde( + default, + skip_serializing_if = "Option::is_none", + deserialize_with = "serde_yaml::with::singleton_map::deserialize", + serialize_with = "serde_yaml::with::singleton_map::serialize" + )] pub broker_spec: Option, /// This defines a service that should be created to access From 827d924548d85fe993d2660658a33cb95440a227 Mon Sep 17 00:00:00 2001 From: CeerDecy <1748788674@qq.com> Date: Sat, 12 Oct 2024 15:38:36 +0800 Subject: [PATCH 3/4] upgrade serde_yaml to 0.9.34 Signed-off-by: CeerDecy <1748788674@qq.com> --- Cargo.lock | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b1d8f8500..75bd7d3c3 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -253,7 +253,7 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "serde_yaml 0.9.30", + "serde_yaml 0.9.34+deprecated", "simple-mermaid", "tempfile", "thiserror", @@ -298,7 +298,7 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "serde_yaml 0.9.30", + "serde_yaml 0.9.34+deprecated", "tokio", "tokio-stream", "tonic", @@ -317,7 +317,7 @@ dependencies = [ "prost", "serde", "serde_derive", - "serde_yaml 0.9.30", + "serde_yaml 0.9.34+deprecated", "tempfile", "tokio", "tokio-stream", @@ -368,7 +368,7 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "serde_yaml 0.9.30", + "serde_yaml 0.9.34+deprecated", "tokio", "tokio-stream", "tonic", @@ -393,7 +393,7 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "serde_yaml 0.9.30", + "serde_yaml 0.9.34+deprecated", "tokio", "tonic", "tower", From 61597365cfc6f66e427a365cbdad28877df9a3be Mon Sep 17 00:00:00 2001 From: CeerDecy <1748788674@qq.com> Date: Sat, 12 Oct 2024 15:53:32 +0800 Subject: [PATCH 4/4] update akri version to 0.13.4 Signed-off-by: CeerDecy <1748788674@qq.com> --- Cargo.lock | 28 ++++++++++++++-------------- Cargo.toml | 2 +- deployment/helm/Chart.yaml | 4 ++-- version.txt | 2 +- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 75bd7d3c3..3ab72ff65 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -224,7 +224,7 @@ checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627" [[package]] name = "agent" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-debug-echo", "akri-discovery-utils", @@ -288,7 +288,7 @@ dependencies = [ [[package]] name = "akri-debug-echo" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-discovery-utils", "akri-shared", @@ -306,7 +306,7 @@ dependencies = [ [[package]] name = "akri-discovery-utils" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-shared", "anyhow", @@ -328,7 +328,7 @@ dependencies = [ [[package]] name = "akri-onvif" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-discovery-utils", "anyhow", @@ -357,7 +357,7 @@ dependencies = [ [[package]] name = "akri-opcua" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-discovery-utils", "anyhow", @@ -377,7 +377,7 @@ dependencies = [ [[package]] name = "akri-shared" -version = "0.13.3" +version = "0.13.4" dependencies = [ "anyhow", "async-trait", @@ -402,7 +402,7 @@ dependencies = [ [[package]] name = "akri-udev" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-discovery-utils", "anyhow", @@ -935,7 +935,7 @@ dependencies = [ [[package]] name = "controller" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-shared", "anyhow", @@ -1109,7 +1109,7 @@ checksum = "e8566979429cf69b49a5c740c60791108e86440e8be149bbea4fe54d2c32d6e2" [[package]] name = "debug-echo-discovery-handler" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-debug-echo", "akri-discovery-utils", @@ -2371,7 +2371,7 @@ dependencies = [ [[package]] name = "onvif-discovery-handler" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-discovery-utils", "akri-onvif", @@ -2420,7 +2420,7 @@ dependencies = [ [[package]] name = "opcua-discovery-handler" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-discovery-utils", "akri-opcua", @@ -3876,7 +3876,7 @@ dependencies = [ [[package]] name = "udev-discovery-handler" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-discovery-utils", "akri-udev", @@ -3887,7 +3887,7 @@ dependencies = [ [[package]] name = "udev-video-broker" -version = "0.13.3" +version = "0.13.4" dependencies = [ "akri-shared", "env_logger", @@ -4143,7 +4143,7 @@ dependencies = [ [[package]] name = "webhook-configuration" -version = "0.13.3" +version = "0.13.4" dependencies = [ "actix-rt", "actix-web", diff --git a/Cargo.toml b/Cargo.toml index ecc5ba90f..6e1e27bb4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,7 +23,7 @@ members = [ resolver = "2" [workspace.package] -version = "0.13.3" +version = "0.13.4" edition = "2021" license = "Apache-2.0" homepage = "https://docs.akri.sh/" diff --git a/deployment/helm/Chart.yaml b/deployment/helm/Chart.yaml index a52232fee..4c9148b08 100644 --- a/deployment/helm/Chart.yaml +++ b/deployment/helm/Chart.yaml @@ -16,9 +16,9 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.13.3 +version: 0.13.4 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to # follow Semantic Versioning. They should reflect the version the application is using. -appVersion: 0.13.3 +appVersion: 0.13.4 diff --git a/version.txt b/version.txt index 288adf538..dffa40ec3 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -0.13.3 +0.13.4