Skip to content

Commit

Permalink
Upgrade kube, json-patch and jsonptr libraries
Browse files Browse the repository at this point in the history
  • Loading branch information
mortenlj committed Dec 16, 2024
1 parent e319528 commit 50f334c
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 35 deletions.
46 changes: 17 additions & 29 deletions Cargo.lock

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

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ edition = "2021"
anyhow = "1.0.94"
axum = { version = "0.7.9", features = ["tracing", "http2", "macros"] }
axum-server = { version = "0.7.1", features = ["rustls", "tls-rustls"] }
json-patch = "2.0.0"
json-patch = "3.0.1"
k8s-openapi = { version = "0.23.0", default-features = false, features = ["v1_30", "schemars"] }
kube = { version = "0.96.0", features = ["rustls-tls", "admission", "jsonpatch", "derive"], default-features = false }
kube = { version = "0.97.0", features = ["rustls-tls", "admission", "jsonpatch", "derive"], default-features = false }
log = { version = "0.4.22", features = ["kv_unstable", "serde", "kv_unstable_serde"] }
schemars = { version = "0.8.21", features = ["derive_json_schema"] }
serde = { version = "1.0.216", features = ["serde_derive", "derive"] }
Expand All @@ -25,7 +25,7 @@ opentelemetry-otlp = { version = "0.26.0", features = ["opentelemetry-http"] }
opentelemetry-semantic-conventions = { version = "0.26.0", features = ["semconv_experimental"] }
opentelemetry_sdk = { version = "0.26.0", features = ["rt-tokio"] }
schematic = "0.17.7"
jsonptr = "0.4.7"
jsonptr = "0.6.3"
rustls = { version = "0.23.20", features = ["ring"] }

[dev-dependencies]
Expand Down
6 changes: 3 additions & 3 deletions src/mutators.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use std::sync::Arc;
use crate::aiven_object::AivenObject;
use crate::settings::AppConfig;
use json_patch::PatchOperation;
use jsonptr::Pointer;
use jsonptr::PointerBuf;
use serde_json::{json, Value};
use std::str::FromStr;
use tracing::{debug, info, instrument};
Expand Down Expand Up @@ -108,14 +108,14 @@ pub fn add_project_vpc_id(

fn add_patch(path: String, value: Value) -> PatchOperation {
PatchOperation::Add(json_patch::AddOperation {
path: Pointer::from_str(&path).unwrap(),
path: PointerBuf::from_str(&path).unwrap(),
value,
})
}

fn replace_patch(path: String, value: Value) -> PatchOperation {
PatchOperation::Replace(json_patch::ReplaceOperation {
path: Pointer::from_str(&path).unwrap(),
path: PointerBuf::from_str(&path).unwrap(),
value,
})
}
Expand Down

0 comments on commit 50f334c

Please sign in to comment.