diff --git a/.cargo/config b/.cargo/config.toml similarity index 100% rename from .cargo/config rename to .cargo/config.toml diff --git a/Cargo.lock b/Cargo.lock index b56965edc..ad3a917c0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1,27 +1,38 @@ # This file is automatically @generated by Cargo. # It is not intended for manual editing. -version = 3 +version = 4 [[package]] name = "addr2line" -version = "0.21.0" +version = "0.24.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" +checksum = "dfbe277e56a376000877090da837660b4427aad530e3028d44e0bffe4f89a1c1" dependencies = [ "gimli", ] [[package]] -name = "adler" -version = "1.0.2" +name = "adler2" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627" + +[[package]] +name = "ahash" +version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" +checksum = "891477e0c6a8957309ee5c45a6368af3ae14bb510732d2684ffa19af310920f9" +dependencies = [ + "getrandom", + "once_cell", + "version_check", +] [[package]] name = "aho-corasick" -version = "1.1.1" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea5d730647d4fadd988536d06fecce94b7b4f2a7efdae548f1cf4b63205518ab" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" dependencies = [ "memchr", ] @@ -58,57 +69,64 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.4" +version = "0.6.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ab91ebe16eb252986481c5b62f6098f3b698a45e34b5b98200cf20dd2484a44" +checksum = "23a1e53f0f5d86382dafe1cf314783b2044280f406e7e1506368220ad11b1338" dependencies = [ "anstyle", "anstyle-parse", "anstyle-query", "anstyle-wincon", "colorchoice", + "is_terminal_polyfill", "utf8parse", ] [[package]] name = "anstyle" -version = "1.0.4" +version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87" +checksum = "8365de52b16c035ff4fcafe0092ba9390540e3e352870ac09933bebcaa2c8c56" [[package]] name = "anstyle-parse" -version = "0.2.2" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317b9a89c1868f5ea6ff1d9539a69f45dffc21ce321ac1fd1160dfa48c8e2140" +checksum = "3b2d16507662817a6a20a9ea92df6652ee4f94f914589377d69f3b21bc5798a9" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.0.0" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ca11d4be1bab0c8bc8734a9aa7bf4ee8316d462a08c6ac5052f888fef5b494b" +checksum = "79947af37f4177cfead1110013d678905c37501914fba0efea834c3fe9a8d60c" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.59.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.1" +version = "3.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0699d10d2f4d628a98ee7b57b289abbc98ff3bad977cb3152709d4bf2330628" +checksum = "2109dbce0e72be3ec00bed26e6a7479ca384ad226efdd66db8fa2e3a38c83125" dependencies = [ "anstyle", - "windows-sys 0.48.0", + "windows-sys 0.59.0", ] [[package]] name = "anyhow" -version = "1.0.75" +version = "1.0.91" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c042108f3ed77fd83760a5fd79b53be043192bb3b9dba91d8c574c0ada7850c8" + +[[package]] +name = "arrayvec" +version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4668cab20f66d8d020e1fbc0ebe47217433c1b6c8f2040faf858554e394ace6" +checksum = "7c02d123df017efcdfbd739ef81735b36c5ba83ec3c59c80a9d7ecc718f92e50" [[package]] name = "assert_matches" @@ -118,62 +136,64 @@ checksum = "9b34d609dfbaf33d6889b2b7106d3ca345eacad44200913df5ba02bfd31d2ba9" [[package]] name = "async-channel" -version = "1.9.0" +version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35" +checksum = "89b47800b0be77592da0afd425cc03468052844aff33b84e33cc696f64e77b6a" dependencies = [ "concurrent-queue", - "event-listener 2.5.3", + "event-listener-strategy", "futures-core", + "pin-project-lite", ] [[package]] name = "async-io" -version = "1.13.0" +version = "2.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fc5b45d93ef0529756f812ca52e44c221b35341892d3dcc34132ac02f3dd2af" +checksum = "444b0228950ee6501b3568d3c93bf1176a1fdbc3b758dcd9475046d30f4dc7e8" dependencies = [ "async-lock", - "autocfg", "cfg-if", "concurrent-queue", + "futures-io", "futures-lite", - "log", "parking", "polling", - "rustix 0.37.27", + "rustix", "slab", - "socket2 0.4.10", - "waker-fn", + "tracing", + "windows-sys 0.59.0", ] [[package]] name = "async-lock" -version = "2.7.0" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa24f727524730b077666307f2734b4a1a1c57acb79193127dcc8914d5242dd7" +checksum = "ff6e472cdea888a4bd64f342f09b3f50e1886d32afe8df3d663c01140b811b18" dependencies = [ - "event-listener 2.5.3", + "event-listener", + "event-listener-strategy", + "pin-project-lite", ] [[package]] name = "async-nats" -version = "0.32.1" +version = "0.37.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e45b67ea596bb94741ef15ba1d90b72c92bdc07553d8033734cb620a2b39f1c" +checksum = "fd3bdd6ea595b2ea504500a3566071beb81125fc15d40a6f6bffa43575f64152" dependencies = [ - "base64", + "aws-lc-rs", + "base64 0.22.1", "bytes", "futures", - "http", "memchr", "nkeys", "nuid", "once_cell", + "portable-atomic", "rand", "regex", - "ring 0.16.20", - "rustls", + "ring", "rustls-native-certs", "rustls-pemfile", "rustls-webpki", @@ -184,34 +204,37 @@ dependencies = [ "thiserror", "time", "tokio", - "tokio-retry", "tokio-rustls", + "tokio-util", "tracing", + "tryhard", "url", ] [[package]] name = "async-process" -version = "1.8.1" +version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea6438ba0a08d81529c69b36700fa2f95837bfe3e776ab39cde9c14d9149da88" +checksum = "63255f1dc2381611000436537bbedfe83183faa303a5a0edaf191edef06526bb" dependencies = [ + "async-channel", "async-io", "async-lock", "async-signal", + "async-task", "blocking", "cfg-if", - "event-listener 3.0.0", + "event-listener", "futures-lite", - "rustix 0.38.21", - "windows-sys 0.48.0", + "rustix", + "tracing", ] [[package]] name = "async-signal" -version = "0.2.4" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2a5415b7abcdc9cd7d63d6badba5288b2ca017e3fbd4173b8f405449f1a2399" +checksum = "637e00349800c0bdf8bfc21ebbc0b6524abea702b0da4168ac00d070d0c0b9f3" dependencies = [ "async-io", "async-lock", @@ -219,17 +242,17 @@ dependencies = [ "cfg-if", "futures-core", "futures-io", - "rustix 0.38.21", + "rustix", "signal-hook-registry", "slab", - "windows-sys 0.48.0", + "windows-sys 0.59.0", ] [[package]] name = "async-stream" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd56dd203fef61ac097dd65721a419ddccb106b2d2b70ba60a6b529f03961a51" +checksum = "0b5a71a6f37880a80d1d7f19efd781e4b5de42c88f0722cc13bcb6cc2cfe8476" dependencies = [ "async-stream-impl", "futures-core", @@ -238,58 +261,85 @@ dependencies = [ [[package]] name = "async-stream-impl" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" +checksum = "c7c24de15d275a1ecfd47a380fb4d5ec9bfe0933f309ed5e705b775596a3574d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "async-task" -version = "4.4.1" +version = "4.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9441c6b2fe128a7c2bf680a44c34d0df31ce09e5b7e401fcca3faa483dbc921" +checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de" [[package]] name = "async-trait" -version = "0.1.74" +version = "0.1.83" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a66537f1bb974b254c98ed142ff995236e81b9d0fe4db0575f46612cb15eb0f9" +checksum = "721cae7de5c34fbb2acd27e21e6d2cf7b886dce0c27388d46c4e6c47ea4318dd" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "atomic-waker" -version = "1.1.1" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1181e1e0d1fce796a03db1ae795d67167da795f9cf4a39c37589e85ef57f26d3" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ace50bade8e6234aa140d9a2f552bbee1db4d353f69b8217bc503490fc1a9f26" + +[[package]] +name = "aws-lc-rs" +version = "1.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cdd82dba44d209fddb11c190e0a94b78651f95299598e472215667417a03ff1d" +dependencies = [ + "aws-lc-sys", + "mirai-annotations", + "paste", + "untrusted 0.7.1", + "zeroize", +] + +[[package]] +name = "aws-lc-sys" +version = "0.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "df7a4168111d7eb622a31b214057b8509c0a7e1794f44c546d742330dc793972" +dependencies = [ + "bindgen 0.69.5", + "cc", + "cmake", + "dunce", + "fs_extra", + "libc", + "paste", +] [[package]] name = "axum" -version = "0.6.20" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b829e4e32b91e643de6eafe82b1d90675f5874230191a4ffbc1b336dec4d6bf" +checksum = "504e3947307ac8326a5437504c517c4b56716c9d98fac0028c2acc7ca47d70ae" dependencies = [ "async-trait", "axum-core", - "bitflags 1.3.2", "bytes", "futures-util", "http", "http-body", - "hyper", + "http-body-util", "itoa", "matchit", "memchr", @@ -298,42 +348,45 @@ dependencies = [ "pin-project-lite", "rustversion", "serde", - "sync_wrapper", - "tower", + "sync_wrapper 1.0.1", + "tower 0.5.1", "tower-layer", "tower-service", ] [[package]] name = "axum-core" -version = "0.3.4" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "759fa577a247914fd3f7f76d62972792636412fbfd634cd452f6a385a74d2d2c" +checksum = "09f2bd6146b97ae3359fa0cc6d6b376d9539582c7b4220f041a33ec24c226199" dependencies = [ "async-trait", "bytes", "futures-util", "http", "http-body", + "http-body-util", "mime", + "pin-project-lite", "rustversion", + "sync_wrapper 1.0.1", "tower-layer", "tower-service", ] [[package]] name = "backtrace" -version = "0.3.69" +version = "0.3.74" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2089b7e3f35b9dd2d0ed921ead4f6d318c27680d4a5bd167b3ee120edb105837" +checksum = "8d82cb332cdfaed17ae235a638438ac4d4839913cc2af585c3c6746e8f8bee1a" dependencies = [ "addr2line", - "cc", "cfg-if", "libc", "miniz_oxide", "object", "rustc-demangle", + "windows-targets 0.52.6", ] [[package]] @@ -342,6 +395,12 @@ version = "0.21.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "35636a1494ede3b646cc98f74f8e62c773a38a659ebc777a2cf26b9b74171df9" +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + [[package]] name = "base64ct" version = "1.6.0" @@ -359,39 +418,37 @@ dependencies = [ [[package]] name = "bindgen" -version = "0.68.1" +version = "0.69.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "726e4313eb6ec35d2730258ad4e15b547ee75d6afaa1361a922e78e59b7d8078" +checksum = "271383c67ccabffb7381723dea0672a673f292304fcb45c01cc648c7a8d58088" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.6.0", "cexpr", "clang-sys", + "itertools", "lazy_static", "lazycell", "log", - "peeking_take_while", "prettyplease", "proc-macro2", "quote", "regex", "rustc-hash", "shlex", - "syn 2.0.38", + "syn 2.0.85", "which", ] [[package]] name = "bindgen" -version = "0.69.4" +version = "0.70.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a00dc851838a2120612785d195287475a3ac45514741da670b735818822129a0" +checksum = "f49d8fed880d473ea71efb9bf597651e77201bdd4893efe54c9e5d65ae04ce6f" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.6.0", "cexpr", "clang-sys", - "itertools 0.11.0", - "lazy_static", - "lazycell", + "itertools", "log", "prettyplease", "proc-macro2", @@ -399,15 +456,14 @@ dependencies = [ "regex", "rustc-hash", "shlex", - "syn 2.0.38", - "which", + "syn 2.0.85", ] [[package]] name = "bit-vec" -version = "0.6.3" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb" +checksum = "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7" [[package]] name = "bitflags" @@ -417,9 +473,21 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.4.0" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" + +[[package]] +name = "bitvec" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4682ae6287fcf752ecaabbfcc7b6f9b72aa33933dc23a554d853aea8eea8635" +checksum = "1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9c" +dependencies = [ + "funty", + "radium", + "tap", + "wyz", +] [[package]] name = "block-buffer" @@ -432,33 +500,34 @@ dependencies = [ [[package]] name = "blocking" -version = "1.3.1" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77231a1c8f801696fc0123ec6150ce92cffb8e164a02afb9c8ddee0e9b65ad65" +checksum = "703f41c54fc768e63e091340b424302bb1c29ef4aa0c7f10fe849dfb114d29ea" dependencies = [ "async-channel", - "async-lock", "async-task", - "atomic-waker", - "fastrand 1.9.0", + "futures-io", "futures-lite", - "log", + "piper", ] [[package]] name = "bollard" -version = "0.15.0" +version = "0.17.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f03db470b3c0213c47e978da93200259a1eb4dae2e5512cba9955e2b540a6fc6" +checksum = "d41711ad46fda47cd701f6908e59d1bd6b9a2b7464c0d0aeab95c6d37096ff8a" dependencies = [ - "base64", + "base64 0.22.1", "bollard-stubs", "bytes", "futures-core", "futures-util", "hex", "http", + "http-body-util", "hyper", + "hyper-named-pipe", + "hyper-util", "hyperlocal", "log", "pin-project-lite", @@ -470,48 +539,96 @@ dependencies = [ "thiserror", "tokio", "tokio-util", + "tower-service", "url", "winapi", ] [[package]] name = "bollard-stubs" -version = "1.43.0-rc.2" +version = "1.45.0-rc.26.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b58071e8fd9ec1e930efd28e3a90c1251015872a2ce49f81f36421b86466932e" +checksum = "6d7c5415e3a6bc6d3e99eff6268e488fd4ee25e7b28c10f08fa6760bd9de16e4" dependencies = [ "serde", "serde_repr", "serde_with", ] +[[package]] +name = "borsh" +version = "1.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a6362ed55def622cddc70a4746a68554d7b687713770de539e59a739b249f8ed" +dependencies = [ + "borsh-derive", + "cfg_aliases", +] + +[[package]] +name = "borsh-derive" +version = "1.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3ef8005764f53cd4dca619f5bf64cafd4664dada50ece25e4d81de54c80cc0b" +dependencies = [ + "once_cell", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 2.0.85", + "syn_derive", +] + [[package]] name = "bumpalo" -version = "3.13.0" +version = "3.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3e2c3daef883ecc1b5d58c15adae93470a91d425f3532ba1695849656af3fc1" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" [[package]] name = "byte-unit" -version = "4.0.19" +version = "5.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da78b32057b8fdfc352504708feeba7216dcd65a2c9ab02978cbd288d1279b6c" +checksum = "33ac19bdf0b2665407c39d82dbc937e951e7e2001609f0fb32edd0af45a2d63e" dependencies = [ + "rust_decimal", "serde", "utf8-width", ] +[[package]] +name = "bytecheck" +version = "0.6.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23cdc57ce23ac53c931e88a43d06d070a6fd142f2617be5855eb75efc9beb1c2" +dependencies = [ + "bytecheck_derive", + "ptr_meta", + "simdutf8", +] + +[[package]] +name = "bytecheck_derive" +version = "0.6.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3db406d29fbcd95542e92559bed4d8ad92636d1ca8b3b72ede10b4bcc010e659" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "byteorder" -version = "1.4.3" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.5.0" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2bd12c1caf447e69cd4528f47f94d203fd2582878ecb9e9465484c4148a8223" +checksum = "9ac0150caa2ae65ca5bd83f25c7de183dea78d4d366469f148435e2acfbad0da" dependencies = [ "serde", ] @@ -524,11 +641,13 @@ checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5" [[package]] name = "cc" -version = "1.0.83" +version = "1.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1174fb0b6ec23863f8b971027804a42614e347eafb0a95bf0b12cdae21fc4d0" +checksum = "c2e7962b54006dcfcc61cb72735f4d89bb97061dd6a7ed882ec6b8ee53714c6f" dependencies = [ + "jobserver", "libc", + "shlex", ] [[package]] @@ -546,11 +665,17 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" +[[package]] +name = "cfg_aliases" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" + [[package]] name = "chrono" -version = "0.4.31" +version = "0.4.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f2c685bad3eb3d45a01354cedb7d5faa66194d1d58ba6e267a8de788f79db38" +checksum = "a21f936df1771bf62b77f047b726c4625ff2e8aa607c01ec06e5a05bd8463401" dependencies = [ "android-tzdata", "iana-time-zone", @@ -558,7 +683,7 @@ dependencies = [ "num-traits", "serde", "wasm-bindgen", - "windows-targets 0.48.5", + "windows-targets 0.52.6", ] [[package]] @@ -590,9 +715,9 @@ dependencies = [ [[package]] name = "clang-sys" -version = "1.6.1" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c688fc74432808e3eb684cae8830a86be1d66a2bd58e1f248ed0960a590baf6f" +checksum = "0b023947811758c97c59bf9d1c188fd619ad4718dcaa767947df1cadb14f39f4" dependencies = [ "glob", "libc", @@ -601,9 +726,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.4.6" +version = "4.5.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d04704f56c2cde07f43e8e2c154b43f216dc5c92fc98ada720177362f953b956" +checksum = "b97f376d85a664d5837dbae44bf546e6477a679ff6610010f17276f686d867e8" dependencies = [ "clap_builder", "clap_derive", @@ -611,9 +736,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.4.6" +version = "4.5.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e231faeaca65ebd1ea3c737966bf858971cd38c3849107aa3ea7de90a804e45" +checksum = "19bc80abd44e4bed93ca373a0704ccbd1b710dc5749406201bb018272808dc54" dependencies = [ "anstream", "anstyle", @@ -623,35 +748,43 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.4.2" +version = "4.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0862016ff20d69b84ef8247369fabf5c008a7417002411897d40ee1f4532b873" +checksum = "4ac6a0c7b1a9e9a5186361f67dfa1b88213572f427fb9ab038efb2bd8c582dab" dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "clap_lex" -version = "0.5.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd7cc57abe963c6d3b9d8be5b06ba7c8957a930305ca90304f24ef040aa6f961" +checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" + +[[package]] +name = "cmake" +version = "0.1.51" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb1e43aa7fd152b1f968787f7dbcdeb306d1867ff373c69955211876c053f91a" +dependencies = [ + "cc", +] [[package]] name = "colorchoice" -version = "1.0.0" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" +checksum = "5b63caa9aa9397e2d9480a9b13673856c78d8ac123288526c37d7839f2a86990" [[package]] name = "colored_json" -version = "4.0.0" +version = "5.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66203a5372a3ffbef29a90b4f8ed98eae3be5662bc7922c7dee1cb57bd40f9a8" +checksum = "e35980a1b846f8e3e359fd18099172a0857140ba9230affc4f71348081e039b6" dependencies = [ - "is-terminal", "serde", "serde_json", "yansi", @@ -665,16 +798,17 @@ dependencies = [ "futures", "ipnetwork", "once_cell", - "serde", + "strum", + "strum_macros", "tokio", "tracing", ] [[package]] name = "concurrent-queue" -version = "2.2.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62ec6771ecfa0762d24683ee5a32ad78487a3d3afdc0fb8cae19d2c5deb50b7c" +checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973" dependencies = [ "crossbeam-utils", ] @@ -697,9 +831,9 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.4" +version = "0.8.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" +checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" [[package]] name = "cpufeatures" @@ -723,7 +857,7 @@ dependencies = [ "criterion-plot", "futures", "is-terminal", - "itertools 0.10.5", + "itertools", "num-traits", "once_cell", "oorandom", @@ -745,16 +879,15 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6b50826342786a51a89e2da3a28f1c32b06e387201bc2d19791f622c673706b1" dependencies = [ "cast", - "itertools 0.10.5", + "itertools", ] [[package]] name = "crossbeam" -version = "0.8.2" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2801af0d36612ae591caa9568261fddce32ce6e08a7275ea334a06a4ad021a2c" +checksum = "1137cd7e7fc0fb5d3c5a8678be38ec56e819125d8d7907411fe24ccb943faca8" dependencies = [ - "cfg-if", "crossbeam-channel", "crossbeam-deque", "crossbeam-epoch", @@ -764,56 +897,46 @@ dependencies = [ [[package]] name = "crossbeam-channel" -version = "0.5.8" +version = "0.5.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" +checksum = "33480d6946193aa8033910124896ca395333cae7e2d1113d1fef6c3272217df2" dependencies = [ - "cfg-if", "crossbeam-utils", ] [[package]] name = "crossbeam-deque" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce6fd6f855243022dcecf8702fef0c297d4338e226845fe067f6341ad9fa0cef" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" dependencies = [ - "cfg-if", "crossbeam-epoch", "crossbeam-utils", ] [[package]] name = "crossbeam-epoch" -version = "0.9.14" +version = "0.9.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46bd5f3f85273295a9d14aedfb86f6aadbff6d8f5295c4a9edb08e819dcf5695" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" dependencies = [ - "autocfg", - "cfg-if", "crossbeam-utils", - "memoffset 0.8.0", - "scopeguard", ] [[package]] name = "crossbeam-queue" -version = "0.3.8" +version = "0.3.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1cfb3ea8a53f37c40dea2c7bedcbd88bdfae54f5e2175d6ecaff1c988353add" +checksum = "df0346b5d5e76ac2fe4e327c5fd1118d6be7c51dfb18f9b7922923f287471e35" dependencies = [ - "cfg-if", "crossbeam-utils", ] [[package]] name = "crossbeam-utils" -version = "0.8.15" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c063cd8cc95f5c377ed0d4b49a4b21f632396ff690e8470c29b3359b346984b" -dependencies = [ - "cfg-if", -] +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" [[package]] name = "crypto-common" @@ -848,16 +971,15 @@ dependencies = [ [[package]] name = "curve25519-dalek" -version = "4.1.0" +version = "4.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "622178105f911d937a42cdb140730ba4a3ed2becd8ae6ce39c7d28b5d75d4588" +checksum = "97fb8b7c4503de7d6ae7b42ab72a5a59857b4c937ec27a3d4539dba95b5ab2be" dependencies = [ "cfg-if", "cpufeatures", "curve25519-dalek-derive", "digest", "fiat-crypto", - "platforms", "rustc_version", "subtle", ] @@ -870,14 +992,14 @@ checksum = "83fdaf97f4804dcebfa5862639bc9ce4121e82140bec2a987ac5140294865b5b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "darling" -version = "0.14.4" +version = "0.20.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b750cb3417fd1b327431a470f388520309479ab0bf5e323505daf0290cd3850" +checksum = "6f63b86c8a8826a49b8c21f08a2d07338eec8d900540f8630dc76284be802989" dependencies = [ "darling_core", "darling_macro", @@ -885,27 +1007,27 @@ dependencies = [ [[package]] name = "darling_core" -version = "0.14.4" +version = "0.20.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "109c1ca6e6b7f82cc233a97004ea8ed7ca123a9af07a8230878fcfda9b158bf0" +checksum = "95133861a8032aaea082871032f5815eb9e98cef03fa916ab4500513994df9e5" dependencies = [ "fnv", "ident_case", "proc-macro2", "quote", "strsim", - "syn 1.0.109", + "syn 2.0.85", ] [[package]] name = "darling_macro" -version = "0.14.4" +version = "0.20.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4aab4dbc9f7611d8b55048a3a16d2d010c2c8334e46304b40ac1cc14bf3b48e" +checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806" dependencies = [ "darling_core", "quote", - "syn 1.0.109", + "syn 2.0.85", ] [[package]] @@ -927,49 +1049,50 @@ dependencies = [ [[package]] name = "deranged" -version = "0.3.8" +version = "0.3.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2696e8a945f658fd14dc3b87242e6b80cd0f36ff04ea560fa39082368847946" +checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4" dependencies = [ + "powerfmt", "serde", ] [[package]] name = "derive_builder" -version = "0.12.0" +version = "0.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d67778784b508018359cbc8696edb3db78160bab2c2a28ba7f56ef6932997f8" +checksum = "507dfb09ea8b7fa618fcf76e953f4f5e192547945816d5358edffe39f6f94947" dependencies = [ "derive_builder_macro", ] [[package]] name = "derive_builder_core" -version = "0.12.0" +version = "0.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c11bdc11a0c47bc7d37d582b5285da6849c96681023680b906673c5707af7b0f" +checksum = "2d5bcf7b024d6835cfb3d473887cd966994907effbe9227e8c8219824d06c4e8" dependencies = [ "darling", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.85", ] [[package]] name = "derive_builder_macro" -version = "0.12.0" +version = "0.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebcda35c7a396850a55ffeac740804b40ffec779b98fffbb1738f4033f0ee79e" +checksum = "ab63b0e2bf4d5928aff72e83a7dace85d7bba5fe12dcc3c5a572d78caffd3f3c" dependencies = [ "derive_builder_core", - "syn 1.0.109", + "syn 2.0.85", ] [[package]] name = "devinfo" version = "1.0.0" dependencies = [ - "bindgen 0.68.1", + "bindgen 0.70.1", "nix", "semver", "snafu", @@ -1009,17 +1132,11 @@ dependencies = [ "winapi", ] -[[package]] -name = "doc-comment" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fea41bba32d969b513997752735605054bc0dfa92b4c56bf1189f2e174be7a10" - [[package]] name = "dunce" -version = "1.0.4" +version = "1.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ce8c6da7551ec6c462cbaf3bfbc75131ebbfa1c944aeaa9dab51ca1c5f0c3b" +checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" [[package]] name = "ed25519" @@ -1044,9 +1161,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "encode_unicode" @@ -1056,26 +1173,36 @@ checksum = "34aa73646ffb006b8f5147f3dc182bd4bcb190227ce861fc4a4844bf8e3cb2c0" [[package]] name = "enum-primitive-derive" -version = "0.2.2" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c375b9c5eadb68d0a6efee2999fef292f45854c3444c86f09d8ab086ba942b0e" +checksum = "ba7795da175654fe16979af73f81f26a8ea27638d8d9823d317016888a63dc4c" dependencies = [ "num-traits", "quote", - "syn 1.0.109", + "syn 2.0.85", +] + +[[package]] +name = "env_filter" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f2c92ceda6ceec50f43169f9ee8424fe2db276791afde7b2cd8bc084cb376ab" +dependencies = [ + "log", + "regex", ] [[package]] name = "env_logger" -version = "0.10.0" +version = "0.11.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0" +checksum = "e13fa619b91fb2381732789fc5de83b45675e882f66623b7d8cb4f643017018d" dependencies = [ + "anstream", + "anstyle", + "env_filter", "humantime", - "is-terminal", "log", - "regex", - "termcolor", ] [[package]] @@ -1086,30 +1213,19 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "add4f07d43996f76ef320709726a556a9d4f965d9410d8d0271132d2f8293480" -dependencies = [ - "errno-dragonfly", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "errno-dragonfly" -version = "0.1.2" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" dependencies = [ - "cc", "libc", + "windows-sys 0.52.0", ] [[package]] name = "etcd-client" -version = "0.12.1" +version = "0.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d982a3b3088a5f95d19882d298b352a2e0be20703e3080c1e6767731d5dec79" +checksum = "39bde3ce50a626efeb1caa9ab1083972d178bebb55ca627639c8ded507dfcbde" dependencies = [ "http", "prost", @@ -1117,24 +1233,28 @@ dependencies = [ "tokio-stream", "tonic", "tonic-build", - "tower", + "tower 0.4.13", "tower-service", ] [[package]] name = "event-listener" -version = "2.5.3" +version = "5.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" +checksum = "6032be9bd27023a771701cc49f9f053c751055f71efb2e0ae5c15809093675ba" +dependencies = [ + "concurrent-queue", + "parking", + "pin-project-lite", +] [[package]] -name = "event-listener" -version = "3.0.0" +name = "event-listener-strategy" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29e56284f00d94c1bc7fd3c77027b4623c88c1f53d8d2394c6199f2921dea325" +checksum = "0f214dc438f977e6d4e3500aaa277f5ad94ca83fbbd9b1a15713ce2344ccc5a1" dependencies = [ - "concurrent-queue", - "parking", + "event-listener", "pin-project-lite", ] @@ -1143,7 +1263,6 @@ name = "event-publisher" version = "0.1.0" dependencies = [ "events-api", - "serde", "serde_json", "tokio", "tracing", @@ -1174,18 +1293,9 @@ dependencies = [ [[package]] name = "fastrand" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" -dependencies = [ - "instant", -] - -[[package]] -name = "fastrand" -version = "2.0.0" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6999dc1837253364c2ebb0704ba97994bd874e8f195d665c50b7548f6ea92764" +checksum = "e8c02a5121d4ea3eb16a80748c74f5549a5665e4c21333c6098f283870fbdea6" [[package]] name = "fiat-crypto" @@ -1223,7 +1333,7 @@ checksum = "1a5c6c585bc94aaf2c7b51dd4c2ba22680844aba4c687be581871a6f518c5742" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] @@ -1234,13 +1344,19 @@ checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b" [[package]] name = "form_urlencoded" -version = "1.2.0" +version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" dependencies = [ "percent-encoding", ] +[[package]] +name = "fs_extra" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42703706b716c37f96a77aea830392ad231f44c9e9a67872fa5548707e11b11c" + [[package]] name = "fsio" version = "0.4.0" @@ -1266,11 +1382,17 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "673464e1e314dd67a0fd9544abc99e8eb28d0c7e3b69b033bcff9b2d00b87333" +[[package]] +name = "funty" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" + [[package]] name = "futures" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23342abe12aba583913b2e62f22225ff9c950774065e4bfb61a19cd9770fec40" +checksum = "65bc07b1a8bc7c85c5f2e110c476c7389b4554ba72af57d8445ea63a576b0876" dependencies = [ "futures-channel", "futures-core", @@ -1283,9 +1405,9 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" +checksum = "2dff15bf788c671c1934e366d07e30c1814a8ef514e1af724a602e8a2fbe1b10" dependencies = [ "futures-core", "futures-sink", @@ -1293,15 +1415,15 @@ dependencies = [ [[package]] name = "futures-core" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" +checksum = "05f29059c0c2090612e8d742178b0580d2dc940c837851ad723096f87af6663e" [[package]] name = "futures-executor" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" +checksum = "1e28d1d997f585e54aebc3f97d39e72338912123a67330d723fdbb564d646c9f" dependencies = [ "futures-core", "futures-task", @@ -1310,53 +1432,51 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" +checksum = "9e5c1b78ca4aae1ac06c48a526a655760685149f0d465d21f37abfe57ce075c6" [[package]] name = "futures-lite" -version = "1.13.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49a9d51ce47660b1e808d3c990b4709f2f415d928835a17dfd16991515c46bce" +checksum = "3f1fa2f9765705486b33fd2acf1577f8ec449c2ba1f318ae5447697b7c08d210" dependencies = [ - "fastrand 1.9.0", + "fastrand", "futures-core", "futures-io", - "memchr", "parking", "pin-project-lite", - "waker-fn", ] [[package]] name = "futures-macro" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" +checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "futures-sink" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" +checksum = "e575fab7d1e0dcb8d0c7bcf9a63ee213816ab51902e6d244a95819acacf1d4f7" [[package]] name = "futures-task" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" +checksum = "f90f7dce0722e95104fcb095585910c0977252f286e354b5e3bd38902cd99988" [[package]] name = "futures-util" -version = "0.3.28" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" +checksum = "9fa08315bb612088cc391249efdc3bc77536f16c91f6cf495e6fbe85b20a4a81" dependencies = [ "futures-channel", "futures-core", @@ -1382,9 +1502,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.10" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if", "libc", @@ -1393,9 +1513,9 @@ dependencies = [ [[package]] name = "gettid" -version = "0.1.2" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34b20f40277dfb8a9dec7e2e945f6d8ff711e733c8f2a2c9b257562764b4c60d" +checksum = "397256552fed4a9e577850498071831ec8f18ea83368aecc114cab469dcb43e5" dependencies = [ "libc", "winapi", @@ -1403,9 +1523,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.28.0" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fb8d784f27acf97159b40fc4db5ecd8aa23b9ad5ef69cdd136d3bc80665f0c0" +checksum = "07e28edb80900c19c28f1072f2e8aeca7fa06b23cd4169cefe1af5aa3260783f" [[package]] name = "git-version-macro" @@ -1413,7 +1533,7 @@ version = "0.3.5" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] @@ -1424,17 +1544,17 @@ checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" [[package]] name = "h2" -version = "0.3.26" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81fe527a889e1532da5c525686d96d4c2e74cdd345badf8dfef9f6b39dd5f5e8" +checksum = "524e8ac6999421f49a846c2d4411f337e53497d8ec55d67753beffa43c5d9205" dependencies = [ + "atomic-waker", "bytes", "fnv", "futures-core", "futures-sink", - "futures-util", "http", - "indexmap 2.0.2", + "indexmap 2.6.0", "slab", "tokio", "tokio-util", @@ -1452,24 +1572,33 @@ name = "hashbrown" version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" +dependencies = [ + "ahash", +] [[package]] name = "hashbrown" -version = "0.14.1" +version = "0.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dfda62a12f55daeae5015f81b0baea145391cb4520f86c248fc615d72640d12" +checksum = "1e087f84d4f86bf4b218b927129862374b72199ae7d8657835f1e89000eea4fb" [[package]] name = "heck" -version = "0.4.1" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" [[package]] name = "hermit-abi" -version = "0.3.3" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hermit-abi" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d77f7ec81a6d05a3abb01ab6eb7590f6083d08449fe5a1c8b1e620283546ccb7" +checksum = "fbf6a919d6cf397374f7dfeeea91d974c7c0a7221d0d0f4f20d859d329e53fcc" [[package]] name = "hex" @@ -1479,18 +1608,18 @@ checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" [[package]] name = "home" -version = "0.5.5" +version = "0.5.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5444c27eef6923071f7ebcc33e3444508466a76f7a2b93da00ed6e19f30c1ddb" +checksum = "e3d1354bf6b7235cb4a0576c2619fd4ed18183f689b12b006a0ee7329eeff9a5" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "http" -version = "0.2.9" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" dependencies = [ "bytes", "fnv", @@ -1499,20 +1628,32 @@ dependencies = [ [[package]] name = "http-body" -version = "0.4.5" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" +checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" dependencies = [ "bytes", "http", - "pin-project-lite", ] [[package]] -name = "httparse" -version = "1.8.0" +name = "http-body-util" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" +checksum = "7d71d3574edd2771538b901e6549113b4006ece66150fb69c0fb6d9a2adae946" [[package]] name = "httpdate" @@ -1528,13 +1669,12 @@ checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] name = "hyper" -version = "0.14.27" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" +checksum = "bbbff0a806a4728c99295b254c8838933b5b082d75e3cb70c8dab21fdfbcfa9a" dependencies = [ "bytes", "futures-channel", - "futures-core", "futures-util", "h2", "http", @@ -1543,50 +1683,85 @@ dependencies = [ "httpdate", "itoa", "pin-project-lite", - "socket2 0.4.10", + "smallvec", "tokio", - "tower-service", - "tracing", "want", ] +[[package]] +name = "hyper-named-pipe" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73b7d8abf35697b81a825e386fc151e0d503e8cb5fcb93cc8669c376dfd6f278" +dependencies = [ + "hex", + "hyper", + "hyper-util", + "pin-project-lite", + "tokio", + "tower-service", + "winapi", +] + [[package]] name = "hyper-timeout" -version = "0.4.1" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbb958482e8c7be4bc3cf272a766a2b0bf1a6755e7a6ae777f017a31d11b13b1" +checksum = "3203a961e5c83b6f5498933e78b6b263e208c197b63e9c6c53cc82ffd3f63793" dependencies = [ "hyper", + "hyper-util", "pin-project-lite", "tokio", - "tokio-io-timeout", + "tower-service", ] [[package]] -name = "hyperlocal" -version = "0.8.0" +name = "hyper-util" +version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fafdf7b2b2de7c9784f76e02c0935e65a8117ec3b768644379983ab333ac98c" +checksum = "df2dcfbe0677734ab2f3ffa7fa7bfd4706bfdc1ef393f2ee30184aed67e631b4" dependencies = [ + "bytes", + "futures-channel", "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower-service", + "tracing", +] + +[[package]] +name = "hyperlocal" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "986c5ce3b994526b3cd75578e62554abd09f0899d6206de48b3e96ab34ccc8c7" +dependencies = [ "hex", + "http-body-util", "hyper", - "pin-project", + "hyper-util", + "pin-project-lite", "tokio", + "tower-service", ] [[package]] name = "iana-time-zone" -version = "0.1.57" +version = "0.1.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" +checksum = "235e081f3925a06703c2d0117ea8b91f042756fd6e7a6e5d901e8ca1a996b220" dependencies = [ "android_system_properties", "core-foundation-sys", "iana-time-zone-haiku", "js-sys", "wasm-bindgen", - "windows", + "windows-core", ] [[package]] @@ -1606,9 +1781,9 @@ checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" [[package]] name = "idna" -version = "0.4.0" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" dependencies = [ "unicode-bidi", "unicode-normalization", @@ -1627,24 +1802,15 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.0.2" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8adf3ddd720272c6ea8bf59463c04e0f93d0bbf7c5439b691bca2987e0270897" +checksum = "707907fe3c25f5424cce2cb7e1cbcafee6bdbe735ca90ef77c29e84591e5b9da" dependencies = [ "equivalent", - "hashbrown 0.14.1", + "hashbrown 0.15.0", "serde", ] -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - [[package]] name = "io-engine" version = "1.0.0" @@ -1712,7 +1878,7 @@ dependencies = [ "tokio", "tokio-stream", "tonic", - "tower", + "tower 0.5.1", "tracing", "tracing-core", "tracing-filter", @@ -1821,7 +1987,7 @@ dependencies = [ "sysfs", "tokio", "tonic", - "tower", + "tower 0.5.1", "tracing", "tracing-core", "tracing-log", @@ -1838,7 +2004,7 @@ version = "0.1.0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] @@ -1847,18 +2013,19 @@ version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" dependencies = [ - "hermit-abi", + "hermit-abi 0.3.9", "libc", "windows-sys 0.48.0", ] [[package]] name = "io-uring" -version = "0.6.2" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "460648e47a07a43110fbfa2e0b14afb2be920093c31e5dccc50e49568e099762" +checksum = "8c9c844e08c94e8558389fb9b8944cb99fc697e231c975e4274b42bc99e0625b" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.6.0", + "cfg-if", "libc", ] @@ -1883,11 +2050,17 @@ version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" dependencies = [ - "hermit-abi", - "rustix 0.38.21", + "hermit-abi 0.3.9", + "rustix", "windows-sys 0.48.0", ] +[[package]] +name = "is_terminal_polyfill" +version = "1.70.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" + [[package]] name = "itertools" version = "0.10.5" @@ -1898,25 +2071,25 @@ dependencies = [ ] [[package]] -name = "itertools" -version = "0.11.0" +name = "itoa" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1c173a5686ce8bfa551b3563d0c2170bf24ca44da99c7ca4bfdab5418c3fe57" -dependencies = [ - "either", -] +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" [[package]] -name = "itoa" -version = "1.0.9" +name = "jobserver" +version = "0.1.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" +checksum = "48d1dbcbbeb6a7fec7e059840aa538bd62aaccf972c7346c4d9d2059312853d0" +dependencies = [ + "libc", +] [[package]] name = "js-sys" -version = "0.3.64" +version = "0.3.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" +checksum = "6a88f1bda2bd75b0452a14784937d796722fdebfe50df998aeb3f0b7603019a9" dependencies = [ "wasm-bindgen", ] @@ -1936,9 +2109,9 @@ dependencies = [ [[package]] name = "lazy_static" -version = "1.4.0" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] name = "lazycell" @@ -1948,25 +2121,25 @@ checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" [[package]] name = "libc" -version = "0.2.149" +version = "0.2.161" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" +checksum = "8e9489c2807c139ffd9c1794f4af0ebe86a828db53ecdc7fea2111d0fed085d1" [[package]] name = "libloading" -version = "0.7.4" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b67380fd3b2fbe7527a606e18729d21c6f3951633d0500574c4dc22d2d638b9f" +checksum = "4979f22fdb869068da03c9f7528f8297c6fd2606bc3a4affe42e6a823fdb8da4" dependencies = [ "cfg-if", - "winapi", + "windows-targets 0.52.6", ] [[package]] name = "libnvme-rs" version = "0.1.0" dependencies = [ - "bindgen 0.68.1", + "bindgen 0.70.1", "cc", "glob", "libc", @@ -1982,7 +2155,7 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.6.0", "libc", ] @@ -1998,21 +2171,15 @@ dependencies = [ [[package]] name = "linux-raw-sys" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ece97ea872ece730aed82664c424eb4c8291e1ff2480247ccf7409044bc6479f" - -[[package]] -name = "linux-raw-sys" -version = "0.4.10" +version = "0.4.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da2479e8c062e40bf0066ffa0bc823de0a9368974af99c9f6df941d2c231e03f" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" [[package]] name = "lock_api" -version = "0.4.10" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" dependencies = [ "autocfg", "scopeguard", @@ -2020,9 +2187,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.20" +version = "0.4.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" [[package]] name = "matchers" @@ -2047,24 +2214,15 @@ checksum = "490cc448043f947bae3cbee9c203358d62dbee0db12107a74be5c30ccfd09771" [[package]] name = "memchr" -version = "2.6.4" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "memoffset" -version = "0.8.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d61c719bcfbcf5d62b3a09efa6088de8c54bc0bfcd3ea7ae39fcc186108b8de1" -dependencies = [ - "autocfg", -] - -[[package]] -name = "memoffset" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" +checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" dependencies = [ "autocfg", ] @@ -2105,50 +2263,57 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.7.1" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" +checksum = "e2d80299ef12ff69b16a84bb182e3b9df68b5a91574d3d4fa6e41b65deec4df1" dependencies = [ - "adler", + "adler2", ] [[package]] name = "mio" -version = "0.8.11" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +checksum = "80e04d1dcff3aae0704555fe5fee3bcfaf3d1fdf8a7e521d5b9d2b42acb52cec" dependencies = [ + "hermit-abi 0.3.9", "libc", "log", "wasi", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] +[[package]] +name = "mirai-annotations" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c9be0862c1b3f26a88803c4a49de6889c10e608b3ee9344e6ef5b45fb37ad3d1" + [[package]] name = "multimap" -version = "0.8.3" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5ce46fe64a9d73be07dcbe690a38ce1b293be448fd8ce1e6c1b8062c9f72c6a" +checksum = "defc4c55412d89136f966bbb339008b474350e5e6e78d2714439c386b3137a03" [[package]] name = "nix" -version = "0.27.1" +version = "0.29.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" +checksum = "71e2746dc3a24dd78b3cfcb7be93368c6de9963d30f43a6a73998a9cf4b17b46" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.6.0", "cfg-if", + "cfg_aliases", "libc", - "memoffset 0.9.0", + "memoffset", ] [[package]] name = "nkeys" -version = "0.3.2" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aad178aad32087b19042ee36dfd450b73f5f934fbfb058b59b198684dfec4c47" +checksum = "9f49e787f4c61cbd0f9320b31cc26e58719f6aa5068e34697dd3aea361412fe3" dependencies = [ - "byteorder", "data-encoding", "ed25519", "ed25519-dalek", @@ -2187,11 +2352,17 @@ dependencies = [ "rand", ] +[[package]] +name = "num-conv" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" + [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -2202,7 +2373,7 @@ version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" dependencies = [ - "hermit-abi", + "hermit-abi 0.3.9", "libc", ] @@ -2225,18 +2396,18 @@ dependencies = [ [[package]] name = "object" -version = "0.32.1" +version = "0.36.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf5f9dd3933bd50a9e1f149ec995f39ae2c496d31fd772c1fd45ebc27e902b0" +checksum = "aedf0a2d09c573ed1d8d85b30c119153926a2b36dce0ab28322c09a117a4683e" dependencies = [ "memchr", ] [[package]] name = "once_cell" -version = "1.18.0" +version = "1.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" +checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" [[package]] name = "oorandom" @@ -2258,15 +2429,15 @@ checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" [[package]] name = "parking" -version = "2.1.0" +version = "2.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14f2252c834a40ed9bb5422029649578e63aa341ac401f74e719dd1afda8394e" +checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba" [[package]] name = "parking_lot" -version = "0.12.1" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" dependencies = [ "lock_api", "parking_lot_core", @@ -2274,22 +2445,22 @@ dependencies = [ [[package]] name = "parking_lot_core" -version = "0.9.8" +version = "0.9.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" dependencies = [ "cfg-if", "libc", "redox_syscall", "smallvec", - "windows-targets 0.48.5", + "windows-targets 0.52.6", ] [[package]] -name = "peeking_take_while" -version = "0.1.2" +name = "paste" +version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" [[package]] name = "pem-rfc7468" @@ -2302,45 +2473,45 @@ dependencies = [ [[package]] name = "percent-encoding" -version = "2.3.0" +version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "petgraph" -version = "0.6.3" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dd7d28ee937e54fe3080c91faa1c3a46c06de6252988a7f4592ba2310ef22a4" +checksum = "b4c5cc86750666a3ed20bdaf5ca2a0344f9c67674cae0515bec2da16fbaa47db" dependencies = [ "fixedbitset", - "indexmap 1.9.3", + "indexmap 2.6.0", ] [[package]] name = "pin-project" -version = "1.1.3" +version = "1.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fda4ed1c6c173e3fc7a83629421152e01d7b1f9b7f65fb301e490e8cfc656422" +checksum = "be57f64e946e500c8ee36ef6331845d40a93055567ec57e8fae13efd33759b95" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.1.3" +version = "1.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" +checksum = "3c0f5fad0874fc7abcd4d750e76917eaebbecaa2c20bde22e1dbeeba8beb758c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "pin-project-lite" -version = "0.2.13" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8afb450f006bf6385ca15ef45d71d2288452bc3683ce2e2cacc0d18e4be60b58" +checksum = "915a1e146535de9163f3987b8944ed8cf49a18bb0056bcebcdcece385cece4ff" [[package]] name = "pin-utils" @@ -2348,6 +2519,17 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" +[[package]] +name = "piper" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96c8c490f422ef9a4efd2cb5b42b76c8613d7e7dfc1caf667b8a3350a5acc066" +dependencies = [ + "atomic-waker", + "fastrand", + "futures-io", +] + [[package]] name = "pkcs8" version = "0.10.2" @@ -2360,15 +2542,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.27" +version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" - -[[package]] -name = "platforms" -version = "3.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4503fa043bf02cee09a9582e9554b4c6403b2ef55e4612e96561d294419429f8" +checksum = "953ec861398dccce10c670dfeaf3ec4911ca479e9c02154b3a215178c5f566f2" [[package]] name = "plotters" @@ -2400,34 +2576,48 @@ dependencies = [ [[package]] name = "polling" -version = "2.8.0" +version = "3.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b2d323e8ca7996b3e23126511a523f7e62924d93ecd5ae73b333815b0eb3dce" +checksum = "cc2790cd301dec6cd3b7a025e4815cf825724a51c98dccfe6a3e55f05ffb6511" dependencies = [ - "autocfg", - "bitflags 1.3.2", "cfg-if", "concurrent-queue", - "libc", - "log", + "hermit-abi 0.4.0", "pin-project-lite", - "windows-sys 0.48.0", + "rustix", + "tracing", + "windows-sys 0.59.0", ] +[[package]] +name = "portable-atomic" +version = "1.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc9c68a3f6da06753e9335d63e27f6b9754dd1920d941135b7ea8224f141adb2" + +[[package]] +name = "powerfmt" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" + [[package]] name = "ppv-lite86" -version = "0.2.17" +version = "0.2.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" +checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" +dependencies = [ + "zerocopy", +] [[package]] name = "prettyplease" -version = "0.2.15" +version = "0.2.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae005bd773ab59b4725093fd7df83fd7892f7d8eafb48dbd7de6e024e4215f9d" +checksum = "64d1ec885c64d0457d564db4ec299b2dae3f9c02808b8ad9c3a089c591b18033" dependencies = [ "proc-macro2", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] @@ -2444,6 +2634,15 @@ dependencies = [ "unicode-width", ] +[[package]] +name = "proc-macro-crate" +version = "3.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecf48c7ca261d60b74ab1a7b20da18bede46776b2e55535cb958eb595c5fa7b" +dependencies = [ + "toml_edit", +] + [[package]] name = "proc-macro-error" version = "1.0.4" @@ -2470,18 +2669,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.69" +version = "1.0.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" +checksum = "f139b0662de085916d1fb67d2b4169d1addddda1919e696f3252b740b629986e" dependencies = [ "unicode-ident", ] [[package]] name = "prost" -version = "0.12.1" +version = "0.13.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4fdd22f3b9c31b53c060df4a0613a1c7f062d4115a2b984dd15b1858f7e340d" +checksum = "7b0487d90e047de87f984913713b85c601c05609aad5b0df4b4573fbf69aa13f" dependencies = [ "bytes", "prost-derive", @@ -2489,13 +2688,13 @@ dependencies = [ [[package]] name = "prost-build" -version = "0.12.1" +version = "0.13.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bdf592881d821b83d471f8af290226c8d51402259e9bb5be7f9f8bdebbb11ac" +checksum = "0c1318b19085f08681016926435853bbf7858f9c082d0999b80550ff5d9abe15" dependencies = [ "bytes", "heck", - "itertools 0.11.0", + "itertools", "log", "multimap", "once_cell", @@ -2504,22 +2703,21 @@ dependencies = [ "prost", "prost-types", "regex", - "syn 2.0.38", + "syn 2.0.85", "tempfile", - "which", ] [[package]] name = "prost-derive" -version = "0.12.1" +version = "0.13.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "265baba7fabd416cf5078179f7d2cbeca4ce7a9041111900675ea7c4cb8a4c32" +checksum = "e9552f850d5f0964a4e4d0bf306459ac29323ddfbae05e35a7c0d35cb0803cc5" dependencies = [ "anyhow", - "itertools 0.11.0", + "itertools", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] @@ -2534,22 +2732,48 @@ dependencies = [ [[package]] name = "prost-types" -version = "0.12.1" +version = "0.13.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e081b29f63d83a4bc75cfc9f3fe424f9156cf92d8a4f0c9407cce9a1b67327cf" +checksum = "4759aa0d3a6232fb8dbdb97b61de2c20047c68aca932c7ed76da9d788508d670" dependencies = [ "prost", ] +[[package]] +name = "ptr_meta" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0738ccf7ea06b608c10564b31debd4f5bc5e197fc8bfe088f68ae5ce81e7a4f1" +dependencies = [ + "ptr_meta_derive", +] + +[[package]] +name = "ptr_meta_derive" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "16b845dbfca988fa33db069c0e230574d15a3088f147a87b64c7589eb662c9ac" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "quote" -version = "1.0.33" +version = "1.0.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" +checksum = "b5b9d34b8991d19d98081b46eacdd8eb58c6f2b201139f7c5f643cc155a633af" dependencies = [ "proc-macro2", ] +[[package]] +name = "radium" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" + [[package]] name = "rand" version = "0.8.5" @@ -2604,11 +2828,11 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.3.5" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" +checksum = "9b6dfecf2c74bce2466cabf93f6664d6998a69eb21e39f4207930065b27b771f" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.6.0", ] [[package]] @@ -2624,14 +2848,14 @@ dependencies = [ [[package]] name = "regex" -version = "1.10.0" +version = "1.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d119d7c7ca818f8a53c300863d4f87566aac09943aef5b355bb83969dae75d87" +checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.4.1", - "regex-syntax 0.8.1", + "regex-automata 0.4.8", + "regex-syntax 0.8.5", ] [[package]] @@ -2645,13 +2869,13 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.1" +version = "0.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "465c6fc0621e4abc4187a2bda0937bfd4f722c2730b29562e19689ea796c9a4b" +checksum = "368758f23274712b504848e9d5a6f010445cc8b87a7cdb4d7cbee666c1288da3" dependencies = [ "aho-corasick", "memchr", - "regex-syntax 0.8.1", + "regex-syntax 0.8.5", ] [[package]] @@ -2662,23 +2886,17 @@ checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] name = "regex-syntax" -version = "0.8.1" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56d84fdd47036b038fc80dd333d10b6aab10d5d31f4a366e20014def75328d33" +checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" [[package]] -name = "ring" -version = "0.16.20" +name = "rend" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" +checksum = "71fe3824f5629716b1589be05dacd749f6aa084c87e00e016714a8cdfccc997c" dependencies = [ - "cc", - "libc", - "once_cell", - "spin 0.5.2", - "untrusted 0.7.1", - "web-sys", - "winapi", + "bytecheck", ] [[package]] @@ -2691,11 +2909,40 @@ dependencies = [ "cfg-if", "getrandom", "libc", - "spin 0.9.8", + "spin", "untrusted 0.9.0", "windows-sys 0.52.0", ] +[[package]] +name = "rkyv" +version = "0.7.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9008cd6385b9e161d8229e1f6549dd23c3d022f132a2ea37ac3a10ac4935779b" +dependencies = [ + "bitvec", + "bytecheck", + "bytes", + "hashbrown 0.12.3", + "ptr_meta", + "rend", + "rkyv_derive", + "seahash", + "tinyvec", + "uuid", +] + +[[package]] +name = "rkyv_derive" +version = "0.7.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "503d1d27590a2b0a3a4ca4c94755aa2875657196ecbf401a42eff41d7de532c0" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "rstack" version = "0.3.3" @@ -2710,18 +2957,34 @@ dependencies = [ [[package]] name = "run_script" -version = "0.10.1" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "829f98fdc58d78989dd9af83be28bc15c94a7d77f9ecdb54abbbc0b1829ba9c7" +checksum = "f20d7c40e6d6fc2ff69ad8e8bac4d39a5fc1874402647ac92b620954d56d5c3e" dependencies = [ "fsio", ] +[[package]] +name = "rust_decimal" +version = "1.36.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b082d80e3e3cc52b2ed634388d436fe1f4de6af5786cc2de9ba9737527bdf555" +dependencies = [ + "arrayvec", + "borsh", + "bytes", + "num-traits", + "rand", + "rkyv", + "serde", + "serde_json", +] + [[package]] name = "rustc-demangle" -version = "0.1.23" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" [[package]] name = "rustc-hash" @@ -2740,85 +3003,83 @@ dependencies = [ [[package]] name = "rustix" -version = "0.37.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fea8ca367a3a01fe35e6943c400addf443c0f57670e6ec51196f71a4b8762dd2" -dependencies = [ - "bitflags 1.3.2", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys 0.3.7", - "windows-sys 0.48.0", -] - -[[package]] -name = "rustix" -version = "0.38.21" +version = "0.38.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b426b0506e5d50a7d8dafcf2e81471400deb602392c7dd110815afb4eaf02a3" +checksum = "aa260229e6538e52293eeb577aabd09945a09d6d9cc0fc550ed7529056c2e32a" dependencies = [ - "bitflags 2.4.0", + "bitflags 2.6.0", "errno", "libc", - "linux-raw-sys 0.4.10", - "windows-sys 0.48.0", + "linux-raw-sys", + "windows-sys 0.52.0", ] [[package]] name = "rustls" -version = "0.21.12" +version = "0.23.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f56a14d1f48b391359b22f731fd4bd7e43c97f3c50eee276f3aa09c94784d3e" +checksum = "eee87ff5d9b36712a58574e12e9f0ea80f915a5b0ac518d322b24a465617925e" dependencies = [ - "log", - "ring 0.17.8", + "aws-lc-rs", + "once_cell", + "ring", + "rustls-pki-types", "rustls-webpki", - "sct", + "subtle", + "zeroize", ] [[package]] name = "rustls-native-certs" -version = "0.6.3" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9aace74cb666635c918e9c12bc0d348266037aa8eb599b5cba565709a8dff00" +checksum = "e5bfb394eeed242e909609f56089eecfe5fda225042e8b171791b9c95f5931e5" dependencies = [ "openssl-probe", "rustls-pemfile", + "rustls-pki-types", "schannel", "security-framework", ] [[package]] name = "rustls-pemfile" -version = "1.0.3" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" +checksum = "dce314e5fee3f39953d46bb63bb8a46d40c2f8fb7cc5a3b6cab2bde9721d6e50" dependencies = [ - "base64", + "rustls-pki-types", ] +[[package]] +name = "rustls-pki-types" +version = "1.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "16f1201b3c9a7ee8039bcadc17b7e605e2945b27eee7631788c1bd2b0643674b" + [[package]] name = "rustls-webpki" -version = "0.101.7" +version = "0.102.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b6275d1ee7a1cd780b64aca7726599a1dbc893b1e64144529e55c3c2f745765" +checksum = "64ca1bc8749bd4cf37b5ce386cc146580777b4e8572c7b97baf22c83f444bee9" dependencies = [ - "ring 0.17.8", + "aws-lc-rs", + "ring", + "rustls-pki-types", "untrusted 0.9.0", ] [[package]] name = "rustversion" -version = "1.0.14" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" +checksum = "0e819f2bc632f285be6d7cd36e25940d45b2391dd6d9b939e79de557f7014248" [[package]] name = "ryu" -version = "1.0.15" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" [[package]] name = "same-file" @@ -2845,14 +3106,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" [[package]] -name = "sct" -version = "0.7.0" +name = "seahash" +version = "4.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d53dcdb7c9f8158937a7981b48accfd39a43af418591a5d008c7b22b5e1b7ca4" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] +checksum = "1c107b6f4780854c8b126e228ea8869f4d7b71260f962fefb57b996b8959ba6b" [[package]] name = "security-framework" @@ -2879,37 +3136,38 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.22" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92d43fe69e652f3df9bdc2b85b2854a0825b86e4fb76bc44d945137d053639ca" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" [[package]] name = "serde" -version = "1.0.189" +version = "1.0.214" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e422a44e74ad4001bdc8eede9a4570ab52f71190e9c076d14369f38b9200537" +checksum = "f55c3193aca71c12ad7890f1785d2b73e1b9f63a0bbc353c08ef26fe03fc56b5" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.189" +version = "1.0.214" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e48d1f918009ce3145511378cf68d613e3b3d9137d67272562080d68a2b32d5" +checksum = "de523f781f095e28fa605cdce0f8307e451cc0fd14e2eb4cd2e98a355b147766" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "serde_json" -version = "1.0.107" +version = "1.0.132" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b420ce6e3d8bd882e9b243c6eed35dbc9a6110c9769e74b584e0d68d1f20c65" +checksum = "d726bfaff4b320266d395898905d0eba0345aae23b54aee3a737e260fd46db03" dependencies = [ "itoa", + "memchr", "ryu", "serde", ] @@ -2931,7 +3189,7 @@ checksum = "8725e1dfadb3a50f7e5ce0b1a540466f6ed3fe7a0fca2ac2b8b831d31316bd00" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] @@ -2952,11 +3210,11 @@ version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1ca3b16a3d82c4088f343b7480a93550b3eabe1a358569c2dfe38bbcead07237" dependencies = [ - "base64", + "base64 0.21.5", "chrono", "hex", "indexmap 1.9.3", - "indexmap 2.0.2", + "indexmap 2.6.0", "serde", "serde_json", "time", @@ -2964,11 +3222,11 @@ dependencies = [ [[package]] name = "serde_yaml" -version = "0.9.25" +version = "0.9.34+deprecated" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a49e178e4452f45cb61d0cd8cebc1b0fafd3e41929e996cef79aa3aca91f574" +checksum = "6a8b1a1a2ebf674015cc02edccce75287f1a0130d394307b36743c2f5d504b47" dependencies = [ - "indexmap 2.0.2", + "indexmap 2.6.0", "itoa", "ryu", "serde", @@ -2988,9 +3246,9 @@ dependencies = [ [[package]] name = "sharded-slab" -version = "0.1.4" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31" +checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6" dependencies = [ "lazy_static", ] @@ -3013,9 +3271,9 @@ dependencies = [ [[package]] name = "signal-hook-registry" -version = "1.4.1" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" dependencies = [ "libc", ] @@ -3041,6 +3299,12 @@ dependencies = [ "digest", ] +[[package]] +name = "simdutf8" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3a9fe34e3e7a50316060351f37187a3f546bce95496156754b601a5fa71b76e" + [[package]] name = "slab" version = "0.4.9" @@ -3052,50 +3316,39 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.1" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "snafu" -version = "0.7.5" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4de37ad025c587a29e8f3f5605c00f70b98715ef90b9061a815b9e59e9042d6" +checksum = "223891c85e2a29c3fe8fb900c1fae5e69c2e42415e3177752e8718475efa5019" dependencies = [ - "doc-comment", "snafu-derive", ] [[package]] name = "snafu-derive" -version = "0.7.5" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "990079665f075b699031e9c08fd3ab99be5029b96f3b78dc0709e8f77e4efebf" +checksum = "03c3c6b7927ffe7ecaa769ee0e3994da3b8cafc8f444578982c83ecb161af917" dependencies = [ "heck", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.85", ] [[package]] name = "socket2" -version = "0.4.10" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f7916fc008ca5542385b89a3d3ce689953c143e9304a9bf8beec1de48994c0d" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" dependencies = [ "libc", - "winapi", -] - -[[package]] -name = "socket2" -version = "0.5.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" -dependencies = [ - "libc", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -3103,7 +3356,7 @@ name = "spdk-rs" version = "0.2.0" dependencies = [ "async-trait", - "bindgen 0.69.4", + "bindgen 0.70.1", "cc", "futures", "nix", @@ -3116,12 +3369,6 @@ dependencies = [ "uuid", ] -[[package]] -name = "spin" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" - [[package]] name = "spin" version = "0.9.8" @@ -3140,34 +3387,34 @@ dependencies = [ [[package]] name = "strsim" -version = "0.10.0" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "strum" -version = "0.25.0" +version = "0.26.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "290d54ea6f91c969195bdbcd7442c8c2a2ba87da8bf60a7ee86a235d4bc1e125" +checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06" [[package]] name = "strum_macros" -version = "0.25.2" +version = "0.26.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad8d03b598d3d0fff69bf533ee3ef19b8eeb342729596df84bcc7e1f96ec4059" +checksum = "4c6bee85a5a24955dc440386795aa378cd9cf82acd5f764469152d2270e581be" dependencies = [ "heck", "proc-macro2", "quote", "rustversion", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "subtle" -version = "2.5.0" +version = "2.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" [[package]] name = "syn" @@ -3182,36 +3429,60 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.38" +version = "2.0.85" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e96b79aaa137db8f61e26363a0c9b47d8b4ec75da28b7d1d614c2303e232408b" +checksum = "5023162dfcd14ef8f32034d8bcd4cc5ddc61ef7a247c024a33e24e1f24d21b56" dependencies = [ "proc-macro2", "quote", "unicode-ident", ] +[[package]] +name = "syn_derive" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1329189c02ff984e9736652b1631330da25eaa6bc639089ed4915d25446cbe7b" +dependencies = [ + "proc-macro-error", + "proc-macro2", + "quote", + "syn 2.0.85", +] + [[package]] name = "sync_wrapper" version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" +[[package]] +name = "sync_wrapper" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" + [[package]] name = "sysfs" version = "1.0.0" +[[package]] +name = "tap" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" + [[package]] name = "tempfile" -version = "3.8.0" +version = "3.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb94d2f3cc536af71caac6b6fcebf65860b347e7ce0cc9ebe8f70d3e521054ef" +checksum = "f0f2c9fc62d0beef6951ccffd757e241266a2c833136efbe35af6cd2567dca5b" dependencies = [ "cfg-if", - "fastrand 2.0.0", - "redox_syscall", - "rustix 0.38.21", - "windows-sys 0.48.0", + "fastrand", + "once_cell", + "rustix", + "windows-sys 0.59.0", ] [[package]] @@ -3225,15 +3496,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "termcolor" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6093bad37da69aab9d123a8091e4be0aa4a03e4d601ec641c327398315f62b64" -dependencies = [ - "winapi-util", -] - [[package]] name = "thiserror" version = "1.0.40" @@ -3251,14 +3513,14 @@ checksum = "f9456a42c5b0d803c8cd86e73dd7cc9edd429499f37a3550d286d5e86720569f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] name = "thread_local" -version = "1.1.7" +version = "1.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdd6f064ccff2d6567adcb3873ca630700f00b5ad3f060c25b5dcfd9a4ce152" +checksum = "8b9ef9bad013ada3808854ceac7b46812a6465ba368859a37e2100283d2d719c" dependencies = [ "cfg-if", "once_cell", @@ -3266,12 +3528,14 @@ dependencies = [ [[package]] name = "time" -version = "0.3.29" +version = "0.3.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "426f806f4089c493dcac0d24c29c01e2c38baf8e30f1b716ee37e83d200b18fe" +checksum = "5dfd88e563464686c916c7e46e623e520ddc6d79fa6641390f2e3fa86e83e885" dependencies = [ "deranged", "itoa", + "num-conv", + "powerfmt", "serde", "time-core", "time-macros", @@ -3285,10 +3549,11 @@ checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" [[package]] name = "time-macros" -version = "0.2.15" +version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ad70d68dba9e1f8aceda7aa6711965dfec1cac869f311a51bd08b3a2ccbce20" +checksum = "3f252a68540fde3a3877aeea552b832b40ab9a69e318efd078774a01ddee1ccf" dependencies = [ + "num-conv", "time-core", ] @@ -3304,9 +3569,9 @@ dependencies = [ [[package]] name = "tinyvec" -version = "1.6.0" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" +checksum = "445e881f4f6d382d5f27c034e25eb92edd7c784ceab92a0937db7f2e9471b938" dependencies = [ "tinyvec_macros", ] @@ -3319,70 +3584,49 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.33.0" +version = "1.41.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f38200e3ef7995e5ef13baec2f432a6da0aa9ac495b2c0e8f3b7eec2c92d653" +checksum = "145f3413504347a2be84393cc8a7d2fb4d863b375909ea59f2158261aa258bbb" dependencies = [ "backtrace", "bytes", "libc", "mio", - "num_cpus", "parking_lot", "pin-project-lite", "signal-hook-registry", - "socket2 0.5.5", + "socket2", "tokio-macros", - "windows-sys 0.48.0", -] - -[[package]] -name = "tokio-io-timeout" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30b74022ada614a1b4834de765f9bb43877f910cc8ce4be40e89042c9223a8bf" -dependencies = [ - "pin-project-lite", - "tokio", + "windows-sys 0.52.0", ] [[package]] name = "tokio-macros" -version = "2.1.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" +checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", -] - -[[package]] -name = "tokio-retry" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f57eb36ecbe0fc510036adff84824dd3c24bb781e21bfa67b69d556aa85214f" -dependencies = [ - "pin-project", - "rand", - "tokio", + "syn 2.0.85", ] [[package]] name = "tokio-rustls" -version = "0.24.1" +version = "0.26.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" dependencies = [ "rustls", + "rustls-pki-types", "tokio", ] [[package]] name = "tokio-stream" -version = "0.1.14" +version = "0.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" +checksum = "4f4e6ce100d0eb49a2734f8c0812bcd324cf357d21810932c5df6b96ef2b86f1" dependencies = [ "futures-core", "pin-project-lite", @@ -3391,40 +3635,59 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.10" +version = "0.7.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5419f34732d9eb6ee4c3578b7989078579b7f039cbbb9ca2c4da015749371e15" +checksum = "61e7c3654c13bcd040d4a03abee2c75b1d14a37b423cf5a813ceae1cc903ec6a" dependencies = [ "bytes", "futures-core", "futures-sink", "pin-project-lite", "tokio", - "tracing", +] + +[[package]] +name = "toml_datetime" +version = "0.6.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" + +[[package]] +name = "toml_edit" +version = "0.22.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ae48d6208a266e853d946088ed816055e556cc6028c5e8e2b84d9fa5dd7c7f5" +dependencies = [ + "indexmap 2.6.0", + "toml_datetime", + "winnow", ] [[package]] name = "tonic" -version = "0.10.2" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d560933a0de61cf715926b9cac824d4c883c2c43142f787595e48280c40a1d0e" +checksum = "877c5b330756d856ffcc4553ab34a5684481ade925ecc54bcd1bf02b1d0d4d52" dependencies = [ "async-stream", "async-trait", "axum", - "base64", + "base64 0.22.1", "bytes", "h2", "http", "http-body", + "http-body-util", "hyper", "hyper-timeout", + "hyper-util", "percent-encoding", "pin-project", "prost", + "socket2", "tokio", "tokio-stream", - "tower", + "tower 0.4.13", "tower-layer", "tower-service", "tracing", @@ -3432,15 +3695,16 @@ dependencies = [ [[package]] name = "tonic-build" -version = "0.10.2" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d021fc044c18582b9a2408cd0dd05b1596e3ecdb5c4df822bb0183545683889" +checksum = "9557ce109ea773b399c9b9e5dca39294110b74f1f342cb347a80d1fce8c26a11" dependencies = [ "prettyplease", "proc-macro2", "prost-build", + "prost-types", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] @@ -3463,17 +3727,31 @@ dependencies = [ "tracing", ] +[[package]] +name = "tower" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2873938d487c3cfb9aed7546dc9f2711d867c9f90c46b889989a2cb84eba6b4f" +dependencies = [ + "futures-core", + "futures-util", + "pin-project-lite", + "sync_wrapper 0.1.2", + "tower-layer", + "tower-service", +] + [[package]] name = "tower-layer" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" +checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" [[package]] name = "tower-service" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" +checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" [[package]] name = "tracing" @@ -3481,7 +3759,6 @@ version = "0.1.40" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" dependencies = [ - "log", "pin-project-lite", "tracing-attributes", "tracing-core", @@ -3495,7 +3772,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", ] [[package]] @@ -3527,20 +3804,20 @@ dependencies = [ [[package]] name = "tracing-log" -version = "0.1.3" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" +checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3" dependencies = [ - "lazy_static", "log", + "once_cell", "tracing-core", ] [[package]] name = "tracing-subscriber" -version = "0.3.17" +version = "0.3.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" +checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b" dependencies = [ "matchers", "nu-ansi-term", @@ -3556,9 +3833,20 @@ dependencies = [ [[package]] name = "try-lock" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "tryhard" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c9f0a709784e86923586cff0d872dba54cd2d2e116b3bc57587d15737cfce9d" +dependencies = [ + "futures", + "pin-project-lite", + "tokio", +] [[package]] name = "typenum" @@ -3568,9 +3856,9 @@ checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" [[package]] name = "udev" -version = "0.8.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50051c6e22be28ee6f217d50014f3bc29e81c20dc66ff7ca0d5c5226e1dcc5a1" +checksum = "e3d5c197b95f1769931c89f85c33c407801d1fb7a311113bc0b39ad036f1bd81" dependencies = [ "io-lifetimes", "libc", @@ -3581,21 +3869,21 @@ dependencies = [ [[package]] name = "unicode-bidi" -version = "0.3.13" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" +checksum = "5ab17db44d7388991a428b2ee655ce0c212e862eff1768a455c58f9aad6e7893" [[package]] name = "unicode-ident" -version = "1.0.12" +version = "1.0.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +checksum = "e91b56cd4cadaeb79bbf1a5645f6b4f8dc5bde8834ad5894a8db35fda9efa1fe" [[package]] name = "unicode-normalization" -version = "0.1.22" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +checksum = "5033c97c4262335cded6d6fc3e5c18ab755e1a3dc96376350f3d8e9f009ad956" dependencies = [ "tinyvec", ] @@ -3608,9 +3896,9 @@ checksum = "0336d538f7abc86d282a4189614dfaa90810dfc2c6f6427eaf88e16311dd225d" [[package]] name = "unsafe-libyaml" -version = "0.2.10" +version = "0.2.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab4c90930b95a82d00dc9e9ac071b4991924390d46cbd0dfe566148667605e4b" +checksum = "673aac59facbab8a9007c7f6108d11f63b603f7cabff99fabf650fea5c32b861" [[package]] name = "untrusted" @@ -3647,9 +3935,9 @@ dependencies = [ [[package]] name = "url" -version = "2.4.1" +version = "2.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "143b538f18257fac9cad154828a57c6bf5157e1aa604d4816b5995bf6de87ae5" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" dependencies = [ "form_urlencoded", "idna", @@ -3658,21 +3946,21 @@ dependencies = [ [[package]] name = "utf8-width" -version = "0.1.6" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5190c9442dcdaf0ddd50f37420417d219ae5261bbf5db120d0f9bab996c9cba1" +checksum = "86bd8d4e895da8537e5315b8254664e6b769c4ff3db18321b297a1e7004392e3" [[package]] name = "utf8parse" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.4.1" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79daa5ed5740825c40b389c5e50312b9c86df53fccd33f281df655642b43869d" +checksum = "f8c5f0a0af699448548ad1a2fbf920fb4bee257eae39953ba95cb84891a0446a" dependencies = [ "getrandom", ] @@ -3693,15 +3981,9 @@ dependencies = [ [[package]] name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "waker-fn" -version = "1.1.0" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d5b2c62b4012a3e1eca5a7e077d13b3bf498c4073e33ccd58626607748ceeca" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" [[package]] name = "walkdir" @@ -3730,34 +4012,35 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.87" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" +checksum = "128d1e363af62632b8eb57219c8fd7877144af57558fb2ef0368d0087bddeb2e" dependencies = [ "cfg-if", + "once_cell", "wasm-bindgen-macro", ] [[package]] name = "wasm-bindgen-backend" -version = "0.2.87" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" +checksum = "cb6dd4d3ca0ddffd1dd1c9c04f94b868c37ff5fac97c30b97cff2d74fce3a358" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-macro" -version = "0.2.87" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" +checksum = "e79384be7f8f5a9dd5d7167216f022090cf1f9ec128e6e6a482a2cb5c5422c56" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -3765,22 +4048,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.87" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" +checksum = "26c6ab57572f7a24a4985830b120de1594465e5d500f24afe89e16b4e833ef68" dependencies = [ "proc-macro2", "quote", - "syn 2.0.38", + "syn 2.0.85", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.87" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" +checksum = "65fc09f10666a9f147042251e0dda9c18f166ff7de300607007e96bdebc1068d" [[package]] name = "web-sys" @@ -3801,7 +4084,7 @@ dependencies = [ "either", "home", "once_cell", - "rustix 0.38.21", + "rustix", ] [[package]] @@ -3836,12 +4119,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] -name = "windows" -version = "0.48.0" +name = "windows-core" +version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e686886bc078bc1b0b600cac0147aadb815089b6e4da64016cbd754b6342700f" +checksum = "33ab640c8d7e35bf8ba19b884ba838ceb4fba93a4e8c65a9059d08afcfc683d9" dependencies = [ - "windows-targets 0.48.5", + "windows-targets 0.52.6", ] [[package]] @@ -3859,7 +4142,16 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" dependencies = [ - "windows-targets 0.52.5", + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets 0.52.6", ] [[package]] @@ -3879,18 +4171,18 @@ dependencies = [ [[package]] name = "windows-targets" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", + "windows_aarch64_gnullvm 0.52.6", + "windows_aarch64_msvc 0.52.6", + "windows_i686_gnu 0.52.6", "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", + "windows_i686_msvc 0.52.6", + "windows_x86_64_gnu 0.52.6", + "windows_x86_64_gnullvm 0.52.6", + "windows_x86_64_msvc 0.52.6", ] [[package]] @@ -3901,9 +4193,9 @@ checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" [[package]] name = "windows_aarch64_msvc" @@ -3913,9 +4205,9 @@ checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" [[package]] name = "windows_aarch64_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" [[package]] name = "windows_i686_gnu" @@ -3925,15 +4217,15 @@ checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" [[package]] name = "windows_i686_gnu" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" [[package]] name = "windows_i686_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" [[package]] name = "windows_i686_msvc" @@ -3943,9 +4235,9 @@ checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" [[package]] name = "windows_i686_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" [[package]] name = "windows_x86_64_gnu" @@ -3955,9 +4247,9 @@ checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" [[package]] name = "windows_x86_64_gnu" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" [[package]] name = "windows_x86_64_gnullvm" @@ -3967,9 +4259,9 @@ checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" [[package]] name = "windows_x86_64_msvc" @@ -3979,18 +4271,57 @@ checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" [[package]] name = "windows_x86_64_msvc" -version = "0.52.5" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] -name = "yansi" +name = "winnow" +version = "0.6.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "36c1fec1a2bb5866f07c25f68c26e565c4c200aebb96d7e55710c19d3e8ac49b" +dependencies = [ + "memchr", +] + +[[package]] +name = "wyz" version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" +checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed" +dependencies = [ + "tap", +] + +[[package]] +name = "yansi" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfe53a6657fd280eaa890a3bc59152892ffa3e30101319d168b781ed6529b049" + +[[package]] +name = "zerocopy" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" +dependencies = [ + "byteorder", + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.85", +] [[package]] name = "zeroize" -version = "1.6.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" diff --git a/ci.nix b/ci.nix index 1864835b6..d95eb6a0d 100644 --- a/ci.nix +++ b/ci.nix @@ -33,7 +33,7 @@ let git gnuplot kubernetes-helm - nodejs-16_x + nodejs-18_x numactl pytest_inputs udev diff --git a/io-engine-bench/.cargo/config b/io-engine-bench/.cargo/config.toml similarity index 100% rename from io-engine-bench/.cargo/config rename to io-engine-bench/.cargo/config.toml diff --git a/io-engine-bench/Cargo.toml b/io-engine-bench/Cargo.toml index c106423e5..ced599721 100644 --- a/io-engine-bench/Cargo.toml +++ b/io-engine-bench/Cargo.toml @@ -6,20 +6,20 @@ edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dev-dependencies] -tokio = { version = "1.33.0", features = [ "full" ] } -chrono = "0.4.31" -env_logger = "0.10.0" -futures = "0.3.28" -once_cell = "1.18.0" -tonic = "0.10.2" -tracing = "0.1.37" -tracing-core = "0.1.31" +tokio = { version = "1.41.0", features = [ "full" ] } +chrono = "0.4.38" +env_logger = "0.11.5" +futures = "0.3.31" +once_cell = "1.20.2" +tonic = "0.12.3" +tracing = "0.1.40" +tracing-core = "0.1.32" tracing-futures = "0.2.5" -tracing-subscriber = "0.3.17" -url = "2.4.1" -crossbeam = "0.8.2" -uuid = { version = "1.4.1", features = ["v4"] } -run_script = "0.10.1" +tracing-subscriber = "0.3.18" +url = "2.5.2" +crossbeam = "0.8.4" +uuid = { version = "1.11.0", features = ["v4"] } +run_script = "0.11.0" io-engine-api = { path = "../utils/dependencies/apis/io-engine" } io-engine = { path = "../io-engine" } composer = { path = "../utils/dependencies/composer" } diff --git a/io-engine-tests/Cargo.toml b/io-engine-tests/Cargo.toml index 4db8ab82a..5e5211324 100644 --- a/io-engine-tests/Cargo.toml +++ b/io-engine-tests/Cargo.toml @@ -6,52 +6,52 @@ edition = "2018" [dependencies] ansi_term = "0.12.1" -async-channel = "1.9.0" -async-task = "4.4.1" -async-trait = "0.1.73" +async-channel = "2.3.1" +async-task = "4.7.1" +async-trait = "0.1.83" bincode = "1.3.3" -byte-unit = "4.0.19" -bytes = "1.5.0" -chrono = "0.4.31" -colored_json = "4.0.0" -crossbeam = "0.8.2" -derive_builder = "0.12.0" -etcd-client = "0.12.1" +byte-unit = "5.1.4" +bytes = "1.8.0" +chrono = "0.4.38" +colored_json = "5.0.0" +crossbeam = "0.8.4" +derive_builder = "0.20.2" +etcd-client = "0.14.0" function_name = "0.3.0" -futures = "0.3.28" +futures = "0.3.31" hex = "0.4.3" -http = "0.2.9" -io-uring = "0.6.2" +http = "1.1.0" +io-uring = "0.7.1" ioctl-gen = "0.1.1" jsonrpc = { path = "../jsonrpc"} -lazy_static = "1.4.0" -libc = "0.2.149" -log = "0.4.20" +lazy_static = "1.5.0" +libc = "0.2.161" +log = "0.4.22" md5 = "0.7.0" merge = "0.1.0" -nix = "0.27.1" -once_cell = "1.18.0" -parking_lot = "0.12.1" +nix = "0.29.0" +once_cell = "1.20.2" +parking_lot = "0.12.3" pin-utils = "0.1.0" -prost = "0.12.1" -prost-derive = "0.12.1" +prost = "0.13.3" +prost-derive = "0.13.3" rand = "0.8.5" rand_chacha = "0.3.1" -regex = "1.10.0" -run_script = "0.10.1" -serde_json = "1.0.107" -serde_yaml = "0.9.25" +regex = "1.11.1" +run_script = "0.11.0" +serde_json = "1.0.132" +serde_yaml = "0.9.34" sha2 = "0.10.8" signal-hook = "0.3.17" -snafu = "0.7.5" -tonic = "0.10.2" -tower = "0.4.13" -tracing = "0.1.37" -tracing-core = "0.1.31" -tracing-log = "0.1.3" -tracing-subscriber = "0.3.17" -udev = "0.8.0" -url = "2.4.1" +snafu = "0.8.5" +tonic = "0.12.3" +tower = "0.5.1" +tracing = "0.1.40" +tracing-core = "0.1.32" +tracing-log = "0.2.0" +tracing-subscriber = "0.3.18" +udev = "0.9.1" +url = "2.5.2" composer = { path = "../utils/dependencies/composer" } libnvme-rs = { path = "../libnvme-rs" } @@ -62,7 +62,7 @@ io-engine-tests-macros = { path = "./io-engine-tests-macros" } [dependencies.serde] features = ["derive"] -version = "1.0.188" +version = "1.0.214" [dependencies.spdk-rs] path = "../spdk-rs" @@ -72,8 +72,8 @@ path = "../sysfs" [dependencies.tokio] features = ["full"] -version = "1.33.0" +version = "1.41.0" [dependencies.uuid] features = ["v4"] -version = "1.4.1" +version = "1.11.0" diff --git a/io-engine-tests/io-engine-tests-macros/Cargo.toml b/io-engine-tests/io-engine-tests-macros/Cargo.toml index 12367c11b..25958ae47 100644 --- a/io-engine-tests/io-engine-tests-macros/Cargo.toml +++ b/io-engine-tests/io-engine-tests-macros/Cargo.toml @@ -7,6 +7,6 @@ edition = "2018" proc-macro = true [dependencies] -proc-macro2 = "1.0.69" -quote = "1.0.33" -syn = { version = "2.0.38", features = ["extra-traits"] } +proc-macro2 = "1.0.89" +quote = "1.0.37" +syn = { version = "2.0.85", features = ["extra-traits"] } diff --git a/io-engine-tests/src/compose/mod.rs b/io-engine-tests/src/compose/mod.rs index 3fdb363e1..40b00066d 100644 --- a/io-engine-tests/src/compose/mod.rs +++ b/io-engine-tests/src/compose/mod.rs @@ -144,7 +144,7 @@ impl<'a> MayastorTest<'a> { } } -impl<'a> Drop for MayastorTest<'a> { +impl Drop for MayastorTest<'_> { fn drop(&mut self) { self.reactor.send_future(async { mayastor_env_stop(0) }); // wait for mayastor to stop diff --git a/io-engine-tests/src/fio.rs b/io-engine-tests/src/fio.rs index be96566a2..a7c5288ec 100644 --- a/io-engine-tests/src/fio.rs +++ b/io-engine-tests/src/fio.rs @@ -333,7 +333,7 @@ impl Fio { if err == 0 { j.result = FioJobResult::Ok; } else { - j.result = FioJobResult::Error(Errno::from_i32(err)); + j.result = FioJobResult::Error(Errno::from_raw(err)); } } }); diff --git a/io-engine-tests/src/lib.rs b/io-engine-tests/src/lib.rs index 33f515cb8..175cb665e 100644 --- a/io-engine-tests/src/lib.rs +++ b/io-engine-tests/src/lib.rs @@ -228,8 +228,8 @@ pub fn fscheck(device: &str) { pub fn mkfs(path: &str, fstype: &str) -> bool { let (fs, args) = match fstype { - "xfs" => ("mkfs.xfs", ["-f", path]), - "ext4" => ("mkfs.ext4", ["-F", path]), + "xfs" => ("mkfs.xfs", vec!["-i", "nrext64=0", "-f", path]), + "ext4" => ("mkfs.ext4", vec!["-F", path]), _ => { panic!("unsupported fstype"); } diff --git a/io-engine/.cargo/config b/io-engine/.cargo/config.toml similarity index 100% rename from io-engine/.cargo/config rename to io-engine/.cargo/config.toml diff --git a/io-engine/Cargo.toml b/io-engine/Cargo.toml index 504b26f4e..18eb9f651 100644 --- a/io-engine/Cargo.toml +++ b/io-engine/Cargo.toml @@ -48,61 +48,61 @@ path = "examples/lvs-eval/main.rs" [dependencies] ansi_term = "0.12.1" -async-channel = "1.9.0" -async-task = "4.4.1" -async-trait = "0.1.73" -bit-vec = "0.6.3" +async-channel = "2.3.1" +async-task = "4.7.1" +async-trait = "0.1.83" +bit-vec = "0.8.0" bincode = "1.3.3" -byte-unit = "4.0.19" -bytes = "1.5.0" -chrono = "0.4.31" -clap = { version = "4.4.6", features = ["color", "derive", "string", "env"] } -colored_json = "4.0.0" -crossbeam = "0.8.2" -derive_builder = "0.12.0" -env_logger = "0.10.0" -etcd-client = "0.12.1" +byte-unit = "5.1.4" +bytes = "1.8.0" +chrono = "0.4.38" +clap = { version = "4.5.20", features = ["color", "derive", "string", "env"] } +colored_json = "5.0.0" +crossbeam = "0.8.4" +derive_builder = "0.20.2" +env_logger = "0.11.5" +etcd-client = "0.14.0" function_name = "0.3.0" -futures = "0.3.28" +futures = "0.3.31" hex = "0.4.3" -http = "0.2.9" +http = "1.1.0" humantime = "2.1.0" -io-uring = "0.6.2" +io-uring = "0.7.1" ioctl-gen = "0.1.1" -lazy_static = "1.4.0" -libc = "0.2.149" -log = "0.4.20" +lazy_static = "1.5.0" +libc = "0.2.161" +log = "0.4.22" md5 = "0.7.0" merge = "0.1.0" -nix = { version = "0.27.1", default-features = false, features = ["hostname", "net", "socket", "ioctl"] } -once_cell = "1.18.0" -parking_lot = "0.12.1" +nix = { version = "0.29.0", default-features = false, features = ["hostname", "net", "socket", "ioctl"] } +once_cell = "1.20.2" +parking_lot = "0.12.3" pin-utils = "0.1.0" -prost = "0.12.1" -prost-derive = "0.12.1" +prost = "0.13.3" +prost-derive = "0.13.3" rand = "0.8.5" -regex = "1.10.0" -serde_json = "1.0.107" -serde_yaml = "0.9.25" +regex = "1.11.1" +serde_json = "1.0.132" +serde_yaml = "0.9.34" sha2 = "0.10.8" signal-hook = "0.3.17" -snafu = "0.7.5" -strum = "0.25" -strum_macros = "0.25" -tonic = "0.10.2" -tower = "0.4.13" -tracing = "0.1.37" -tracing-core = "0.1.31" -tracing-log = "0.1.3" -tracing-subscriber = "0.3.17" -udev = "0.8.0" -url = "2.4.1" -gettid = "0.1.2" -async-process = { version = "1.8.1" } +snafu = "0.8.5" +strum = "0.26" +strum_macros = "0.26" +tonic = "0.12.3" +tower = "0.5.1" +tracing = "0.1.40" +tracing-core = "0.1.32" +tracing-log = "0.2.0" +tracing-subscriber = "0.3.18" +udev = "0.9.1" +url = "2.5.2" +gettid = "0.1.3" +async-process = { version = "2.3.0" } rstack = { version = "0.3.3" } -tokio-stream = "0.1.14" -rustls = "0.21.12" -either = "1.9.0" +tokio-stream = "0.1.16" +rustls = { version = "0.23.16", default-features = false, features = ["ring"] } +either = "1.13.0" devinfo = { path = "../utils/dependencies/devinfo" } jsonrpc = { path = "../jsonrpc" } @@ -116,19 +116,19 @@ tracing-filter = { path = "../utils/dependencies/tracing-filter" } [dependencies.serde] features = ["derive"] -version = "1.0.188" +version = "1.0.214" [dependencies.tokio] features = ["full"] -version = "1.33.0" +version = "1.41.0" [dependencies.uuid] features = ["v4"] -version = "1.4.1" +version = "1.11.0" [dev-dependencies] assert_matches = "1.5.0" io-engine-tests = { path = "../io-engine-tests" } libnvme-rs = { path = "../libnvme-rs", version = "0.1.0" } prettytable-rs = "0.10.0" -run_script = "0.10.1" +run_script = "0.11.0" diff --git a/io-engine/local-randrw-0-verify.state b/io-engine/local-randrw-0-verify.state new file mode 100644 index 000000000..9d3146c5d Binary files /dev/null and b/io-engine/local-randrw-0-verify.state differ diff --git a/io-engine/src/bdev/aio.rs b/io-engine/src/bdev/aio.rs index 72ac1c7f4..c9b7b752d 100644 --- a/io-engine/src/bdev/aio.rs +++ b/io-engine/src/bdev/aio.rs @@ -132,7 +132,7 @@ impl CreateDestroy for Aio { if errno != 0 { let err = BdevError::CreateBdevFailed { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), name: self.get_name(), }; @@ -206,7 +206,7 @@ impl Aio { if errno != 0 { let err = BdevError::ResizeBdevFailed { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), name: self.name.clone(), }; diff --git a/io-engine/src/bdev/device.rs b/io-engine/src/bdev/device.rs index 218b71749..7c8f41573 100644 --- a/io-engine/src/bdev/device.rs +++ b/io-engine/src/bdev/device.rs @@ -322,7 +322,7 @@ impl BlockDeviceHandle for SpdkBlockDeviceHandle { if rc < 0 { Err(CoreError::ReadDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset: offset_blocks, len: num_blocks, }) @@ -378,7 +378,7 @@ impl BlockDeviceHandle for SpdkBlockDeviceHandle { if rc < 0 { Err(CoreError::WriteDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset: offset_blocks, len: num_blocks, }) @@ -424,7 +424,7 @@ impl BlockDeviceHandle for SpdkBlockDeviceHandle { if rc < 0 { Err(CoreError::CompareDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset: offset_blocks, len: num_blocks, }) diff --git a/io-engine/src/bdev/lvs.rs b/io-engine/src/bdev/lvs.rs index 075650ae8..3784ec13f 100644 --- a/io-engine/src/bdev/lvs.rs +++ b/io-engine/src/bdev/lvs.rs @@ -85,14 +85,14 @@ impl TryFrom<&Url> for Lvol { message: "'size' is not specified".to_string(), }) .and_then(|size| { - byte_unit::Byte::from_str(size).map_err(|error| { + byte_unit::Byte::parse_str(&size, true).map_err(|error| { BdevError::InvalidUri { uri: uri.to_string(), message: format!("'size' is invalid: {error}"), } }) })? - .get_bytes() as u64; + .as_u64(); let lvs = parameters .remove("lvs") diff --git a/io-engine/src/bdev/malloc.rs b/io-engine/src/bdev/malloc.rs index cf509281f..5ab90754e 100644 --- a/io-engine/src/bdev/malloc.rs +++ b/io-engine/src/bdev/malloc.rs @@ -196,7 +196,7 @@ impl CreateDestroy for Malloc { if errno != 0 { let err = BdevError::CreateBdevFailed { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), name: self.name.clone(), }; @@ -272,7 +272,7 @@ impl Malloc { if errno != 0 { let err = BdevError::ResizeBdevFailed { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), name: self.name.clone(), }; diff --git a/io-engine/src/bdev/nexus/nexus_bdev.rs b/io-engine/src/bdev/nexus/nexus_bdev.rs index d921db057..a28c9d28d 100644 --- a/io-engine/src/bdev/nexus/nexus_bdev.rs +++ b/io-engine/src/bdev/nexus/nexus_bdev.rs @@ -288,7 +288,7 @@ pub struct Nexus<'n> { _pin: PhantomPinned, } -impl<'n> Debug for Nexus<'n> { +impl Debug for Nexus<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { let s = self.state.lock(); write!(f, "Nexus '{}' [{}]", self.name, s) @@ -797,7 +797,7 @@ impl<'n> Nexus<'n> { "{self:?}: failed to notify block cnt change on nexus" ); return Err(Error::NexusResize { - source: Errno::from_i32(rc), + source: Errno::from_raw(rc), name, }); } @@ -998,9 +998,8 @@ impl<'n> Nexus<'n> { _ => false, }; let evt = Event::event(self.deref(), EventAction::SubsystemResume); - self.io_subsystem_mut().resume(freeze).await.map(|value| { + self.io_subsystem_mut().resume(freeze).await.inspect(|_| { evt.generate(); - value }) } @@ -1360,7 +1359,7 @@ impl<'n> IoDevice for Nexus<'n> { impl IoDeviceChannelTraverse for Nexus<'_> {} unsafe fn unsafe_static_ptr(nexus: &Nexus) -> *mut Nexus<'static> { - let r = ::std::mem::transmute::<_, &'static Nexus>(nexus); + let r = ::std::mem::transmute::<&Nexus, &'static Nexus>(nexus); r as *const Nexus as *mut Nexus } diff --git a/io-engine/src/bdev/nexus/nexus_bdev_children.rs b/io-engine/src/bdev/nexus/nexus_bdev_children.rs index a6bab4cfd..96fc67ca6 100644 --- a/io-engine/src/bdev/nexus/nexus_bdev_children.rs +++ b/io-engine/src/bdev/nexus/nexus_bdev_children.rs @@ -766,7 +766,7 @@ impl<'n> Nexus<'n> { } } -impl<'n> DeviceEventListener for Nexus<'n> { +impl DeviceEventListener for Nexus<'_> { fn handle_device_event(&self, evt: DeviceEventType, dev_name: &str) { match evt { DeviceEventType::DeviceRemoved diff --git a/io-engine/src/bdev/nexus/nexus_bdev_rebuild.rs b/io-engine/src/bdev/nexus/nexus_bdev_rebuild.rs index 7dcde5a51..f90f8b18f 100644 --- a/io-engine/src/bdev/nexus/nexus_bdev_rebuild.rs +++ b/io-engine/src/bdev/nexus/nexus_bdev_rebuild.rs @@ -41,7 +41,7 @@ pub(crate) struct RebuildPauseGuard<'a> { _a: PhantomData<&'a ()>, } -impl<'a> Drop for RebuildPauseGuard<'a> { +impl Drop for RebuildPauseGuard<'_> { fn drop(&mut self) { assert!(self.restarted); } diff --git a/io-engine/src/bdev/nexus/nexus_channel.rs b/io-engine/src/bdev/nexus/nexus_channel.rs index 2cc82626f..ef700480b 100644 --- a/io-engine/src/bdev/nexus/nexus_channel.rs +++ b/io-engine/src/bdev/nexus/nexus_channel.rs @@ -28,7 +28,7 @@ pub struct NexusChannel<'n> { is_io_chan: bool, } -impl<'n> Debug for NexusChannel<'n> { +impl Debug for NexusChannel<'_> { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { write!( f, @@ -374,12 +374,9 @@ impl<'n> NexusChannel<'n> { child_device: &str, reason: FaultReason, ) -> Option { - let Some(io_log) = + let io_log = self.nexus_mut() - .retire_child_device(child_device, reason, true) - else { - return None; - }; + .retire_child_device(child_device, reason, true)?; self.reconnect_io_logs(); Some(io_log) } diff --git a/io-engine/src/bdev/nexus/nexus_child.rs b/io-engine/src/bdev/nexus/nexus_child.rs index c696d3cbd..247b7e6a9 100644 --- a/io-engine/src/bdev/nexus/nexus_child.rs +++ b/io-engine/src/bdev/nexus/nexus_child.rs @@ -814,14 +814,13 @@ impl<'c> NexusChild<'c> { let preempt_key = params.preempt_key.map(|k| k.get()); self.resv_acquire(&*hdl, resv_key, preempt_key, params.resv_type) .await - .map_err(|error| { + .inspect_err(|error| { warn!( "{:?}: failed to acquire reservation ({:?}): {}", self, params.resv_type, error.verbose() ); - error }) } diff --git a/io-engine/src/bdev/nexus/nexus_io.rs b/io-engine/src/bdev/nexus/nexus_io.rs index 317f18200..62ced7db6 100644 --- a/io-engine/src/bdev/nexus/nexus_io.rs +++ b/io-engine/src/bdev/nexus/nexus_io.rs @@ -79,7 +79,7 @@ pub(super) struct NioCtx<'n> { serial: u64, } -impl<'n> Debug for NioCtx<'n> { +impl Debug for NioCtx<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { #[cfg(feature = "nexus-io-tracing")] let serial = format!("#{s} {self:p} ", s = self.serial); @@ -112,7 +112,7 @@ impl<'n> Debug for NioCtx<'n> { #[derive(Clone)] pub(super) struct NexusBio<'n>(BdevIo>); -impl<'n> Debug for NexusBio<'n> { +impl Debug for NexusBio<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { write!( f, diff --git a/io-engine/src/bdev/nexus/nexus_io_subsystem.rs b/io-engine/src/bdev/nexus/nexus_io_subsystem.rs index 067030212..a02c2ee1a 100644 --- a/io-engine/src/bdev/nexus/nexus_io_subsystem.rs +++ b/io-engine/src/bdev/nexus/nexus_io_subsystem.rs @@ -55,7 +55,7 @@ pub(super) struct NexusIoSubsystem<'n> { pause_cnt: AtomicU32, } -impl<'n> Debug for NexusIoSubsystem<'n> { +impl Debug for NexusIoSubsystem<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { write!( f, diff --git a/io-engine/src/bdev/nexus/nexus_nbd.rs b/io-engine/src/bdev/nexus/nexus_nbd.rs index ff786d826..81dc2adf7 100644 --- a/io-engine/src/bdev/nexus/nexus_nbd.rs +++ b/io-engine/src/bdev/nexus/nexus_nbd.rs @@ -196,12 +196,11 @@ pub async fn start( .context(StartNbd { dev: device_path.to_owned(), }) - .map(|ok| { + .inspect(|_| { info!( "Nbd device {} for parent {} started", device_path, bdev_name ); - ok }) } diff --git a/io-engine/src/bdev/nexus/nexus_share.rs b/io-engine/src/bdev/nexus/nexus_share.rs index 114ce7346..4697b5362 100644 --- a/io-engine/src/bdev/nexus/nexus_share.rs +++ b/io-engine/src/bdev/nexus/nexus_share.rs @@ -16,7 +16,7 @@ use crate::core::{NvmfShareProps, Protocol, PtplProps, Share, UpdateProps}; /// protocol specifics and for bdevs the need for different endpoints /// is not implemented yet as the need for it has not arrived yet. #[async_trait(? Send)] -impl<'n> Share for Nexus<'n> { +impl Share for Nexus<'_> { type Error = Error; type Output = String; diff --git a/io-engine/src/bdev/null_bdev.rs b/io-engine/src/bdev/null_bdev.rs index b1ace5b36..aba4db74d 100644 --- a/io-engine/src/bdev/null_bdev.rs +++ b/io-engine/src/bdev/null_bdev.rs @@ -157,7 +157,7 @@ impl CreateDestroy for Null { if errno != 0 { return Err(BdevError::CreateBdevFailed { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), name: self.name.clone(), }); } diff --git a/io-engine/src/bdev/null_ng.rs b/io-engine/src/bdev/null_ng.rs index a09970a57..d7c469ca0 100644 --- a/io-engine/src/bdev/null_ng.rs +++ b/io-engine/src/bdev/null_ng.rs @@ -26,7 +26,7 @@ struct NullIoPollerData<'a> { // Required because `NullIoPollerData.iovs` contains `BdevIo`, which // contains NonNull, which is not Send. -unsafe impl<'a> Send for NullIoPollerData<'a> {} +unsafe impl Send for NullIoPollerData<'_> {} /// Per-core channel data. struct NullIoChannelData<'a> { @@ -121,7 +121,7 @@ impl<'a> BdevOps for NullIoDevice<'a> { } /// TODO -impl<'a> NullIoDevice<'a> { +impl NullIoDevice<'_> { /// TODO #[allow(dead_code)] fn create(name: &str) { diff --git a/io-engine/src/bdev/nvmx/controller.rs b/io-engine/src/bdev/nvmx/controller.rs index cc5aa94b5..b014ce83d 100644 --- a/io-engine/src/bdev/nvmx/controller.rs +++ b/io-engine/src/bdev/nvmx/controller.rs @@ -89,7 +89,7 @@ struct ShutdownCtx { static ADMINQ_CORE_SELECTOR: OnceCell> = OnceCell::new(); -impl<'a> NvmeControllerInner<'a> { +impl NvmeControllerInner<'_> { fn new( ctrlr: SpdkNvmeController, name: String, @@ -138,8 +138,8 @@ pub struct NvmeControllerInner<'a> { io_device: Arc, } -unsafe impl<'a> Send for NvmeControllerInner<'a> {} -unsafe impl<'a> Sync for NvmeControllerInner<'a> {} +unsafe impl Send for NvmeControllerInner<'_> {} +unsafe impl Sync for NvmeControllerInner<'_> {} /// NVME controller implementation. /// TODO @@ -156,7 +156,7 @@ pub struct NvmeController<'a> { pub(crate) timeout_config: NonNull, } -impl<'a> fmt::Debug for NvmeController<'a> { +impl fmt::Debug for NvmeController<'_> { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { f.debug_struct("NvmeController") .field("name", &self.name) @@ -166,10 +166,10 @@ impl<'a> fmt::Debug for NvmeController<'a> { } } -unsafe impl<'a> Send for NvmeController<'a> {} -unsafe impl<'a> Sync for NvmeController<'a> {} +unsafe impl Send for NvmeController<'_> {} +unsafe impl Sync for NvmeController<'_> {} -impl<'a> NvmeController<'a> { +impl NvmeController<'_> { /// Creates a new NVMe controller with the given name. pub fn new(name: &str, prchk_flags: u32) -> Option { let l = NvmeController { @@ -222,7 +222,7 @@ impl<'a> NvmeController<'a> { .as_ref() .expect("(BUG) no inner NVMe controller defined yet"); - if let Some(ns) = inner.namespaces.get(0) { + if let Some(ns) = inner.namespaces.first() { Some(ns.clone()) } else { debug!("no namespaces associated with the current controller"); @@ -731,7 +731,7 @@ impl<'a> NvmeController<'a> { } } -impl<'a> Drop for NvmeController<'a> { +impl Drop for NvmeController<'_> { fn drop(&mut self) { let curr_state = self.get_state(); debug!("{} dropping controller (state={:?})", self.name, curr_state); @@ -847,7 +847,7 @@ pub extern "C" fn nvme_poll_adminq(ctx: *mut c_void) -> i32 { "process adminq: {}: ctrl failed: {}, error: {}", context.name, context.is_failed(), - Errno::from_i32(result.abs()) + Errno::from_raw(result.abs()) ); info!("dispatching nexus fault and retire: {}", context.name); let dev_name = context.name.as_str(); @@ -1034,7 +1034,6 @@ pub(crate) mod options { /// structure that holds the default NVMe controller options. This is /// different from ['NvmeBdevOpts'] as it exposes more control over /// variables. - pub struct NvmeControllerOpts(spdk_nvme_ctrlr_opts); impl NvmeControllerOpts { pub fn as_ptr(&self) -> *const spdk_nvme_ctrlr_opts { @@ -1283,7 +1282,6 @@ pub(crate) mod transport { self } /// svcid (port) to connect to - pub fn with_svcid(mut self, svcid: &str) -> Self { self.svcid = svcid.to_string(); self diff --git a/io-engine/src/bdev/nvmx/controller_inner.rs b/io-engine/src/bdev/nvmx/controller_inner.rs index cff4b69f7..71b28bd50 100644 --- a/io-engine/src/bdev/nvmx/controller_inner.rs +++ b/io-engine/src/bdev/nvmx/controller_inner.rs @@ -180,7 +180,6 @@ impl TimeoutConfig { /// qpair is disconnected or if the controller is failed. Therefore, we /// must fail the controller as soon as possible to avoid the need to /// reset after the hot removal. - pub(crate) fn hot_remove(&mut self) { // cb invoked when the whole process is done. fn hot_remove_cb(success: bool, ctx: *mut c_void) { @@ -335,7 +334,7 @@ impl From<*mut spdk_nvme_ctrlr> for SpdkNvmeController { } // I/O device controller API. -impl<'a> DeviceIoController for NvmeController<'a> { +impl DeviceIoController for NvmeController<'_> { /// Get current I/O timeout action. fn get_timeout_action(&self) -> Result { Ok(unsafe { self.timeout_config.as_ref().get_timeout_action() }) @@ -355,7 +354,7 @@ impl<'a> DeviceIoController for NvmeController<'a> { } // I/O timeout handling for NVMe controller. -impl<'a> NvmeController<'a> { +impl NvmeController<'_> { extern "C" fn command_abort_handler( ctx: *mut c_void, cpl: *const spdk_nvme_cpl, diff --git a/io-engine/src/bdev/nvmx/controller_state.rs b/io-engine/src/bdev/nvmx/controller_state.rs index bad25f591..7cf457181 100644 --- a/io-engine/src/bdev/nvmx/controller_state.rs +++ b/io-engine/src/bdev/nvmx/controller_state.rs @@ -1,8 +1,6 @@ use crossbeam::atomic::AtomicCell; use snafu::Snafu; -use NvmeControllerState::*; - #[derive(Debug, PartialEq, Copy, Clone)] pub enum NvmeControllerState { New, @@ -19,43 +17,38 @@ pub enum ControllerFailureReason { NamespaceInit, } -impl ToString for NvmeControllerState { - fn to_string(&self) -> String { - match *self { +impl std::fmt::Display for NvmeControllerState { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + let state = match *self { Self::New => "New", Self::Initializing => "Initializing", Self::Running => "Running", Self::Unconfiguring => "Unconfiguring", Self::Unconfigured => "Unconfigured", Self::Faulted(_) => "Faulted", - } - .to_string() + }; + write!(f, "{state}") } } -#[derive(Eq, PartialEq, Copy, Clone, Debug)] +#[derive(Eq, PartialEq, Copy, Clone, Debug, strum_macros::Display)] pub enum ControllerFlag { ResetActive, } -impl ToString for ControllerFlag { - fn to_string(&self) -> String { - match *self { - ControllerFlag::ResetActive => "ResetActive", - } - .to_string() - } -} /// Entity that manages the following components of every NVMe controller: /// - controller states /// - controller flags /// -/// 1. Controller state checks. +/// 1. Controller state checks +/// /// Every NVMe controller passes through different states during its lifetime, /// which makes it important to control state transitions and disallow invalid /// state changes. Controller state machine enforces state checks based on the /// controller state diagram. -/// 2. Controller flags. +/// +/// 2. Controller flags +/// /// Controller flags are a set of boolean variables that carry some extra /// information required for the controller to operate properly. #[derive(Debug)] @@ -99,6 +92,7 @@ fn check_transition( from: NvmeControllerState, to: NvmeControllerState, ) -> bool { + use NvmeControllerState::*; match from { New => matches!(to, Initializing), Initializing => matches!(to, Running | Faulted(_)), @@ -114,7 +108,7 @@ impl ControllerStateMachine { pub fn new(name: &str) -> Self { Self { name: name.to_string(), - current_state: New, + current_state: NvmeControllerState::New, flag: AtomicCell::new(false), } } diff --git a/io-engine/src/bdev/nvmx/handle.rs b/io-engine/src/bdev/nvmx/handle.rs index 73a618dde..9277338ab 100644 --- a/io-engine/src/bdev/nvmx/handle.rs +++ b/io-engine/src/bdev/nvmx/handle.rs @@ -458,7 +458,7 @@ fn io_type_to_err( num_blocks: u64, ) -> CoreError { assert!(errno > 0, "Errno code must be provided"); - let source = Errno::from_i32(errno); + let source = Errno::from_raw(errno); match op { IoType::Read => CoreError::ReadDispatch { @@ -623,7 +623,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { if rc != 0 && rc != -libc::ENOMEM { error!("{} read failed: rc = {}", self.name, rc); return Err(CoreError::ReadDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset, len: buffer.len(), }); @@ -705,7 +705,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { if rc != 0 && rc != -libc::ENOMEM { error!("{} write failed: rc = {}", self.name, rc); return Err(CoreError::WriteDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset, len: buffer.len(), }); @@ -812,7 +812,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { if rc < 0 { Err(CoreError::ReadDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset: offset_blocks, len: num_blocks, }) @@ -898,7 +898,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { if rc < 0 { Err(CoreError::WriteDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset: offset_blocks, len: num_blocks, }) @@ -979,7 +979,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { if rc < 0 { Err(CoreError::CompareDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset: offset_blocks, len: num_blocks, }) @@ -1058,7 +1058,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { if rc < 0 { Err(CoreError::FlushDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), }) } else { Ok(()) @@ -1073,8 +1073,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { cb_arg: IoCompletionCallbackArg, ) -> Result<(), CoreError> { let num_ranges = - (num_blocks + SPDK_NVME_DATASET_MANAGEMENT_RANGE_MAX_BLOCKS - 1) - / SPDK_NVME_DATASET_MANAGEMENT_RANGE_MAX_BLOCKS; + num_blocks.div_ceil(SPDK_NVME_DATASET_MANAGEMENT_RANGE_MAX_BLOCKS); if num_ranges > SPDK_NVME_DATASET_MANAGEMENT_MAX_RANGES { return Err(CoreError::UnmapDispatch { @@ -1161,7 +1160,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { if rc < 0 { Err(CoreError::UnmapDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset: offset_blocks, len: num_blocks, }) @@ -1222,7 +1221,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { if rc < 0 { Err(CoreError::WriteZeroesDispatch { - source: Errno::from_i32(-rc), + source: Errno::from_raw(-rc), offset: offset_blocks, len: num_blocks, }) @@ -1300,7 +1299,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { ) } .to_result(|e| CoreError::NvmeAdminDispatch { - source: Errno::from_i32(e), + source: Errno::from_raw(e), opcode: cmd.opc(), })?; @@ -1317,7 +1316,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { error!("nvme_admin() failed, errno={status}"); Err(CoreError::NvmeAdminFailed { opcode: (*cmd).opc(), - source: Errno::from_i32(status as i32), + source: Errno::from_raw(status as i32), }) } } @@ -1490,7 +1489,7 @@ impl BlockDeviceHandle for NvmeDeviceHandle { ) } .to_result(|e| CoreError::NvmeIoPassthruDispatch { - source: Errno::from_i32(e), + source: Errno::from_raw(e), opcode: nvme_cmd.opc(), })?; diff --git a/io-engine/src/bdev/nvmx/mod.rs b/io-engine/src/bdev/nvmx/mod.rs index 84dbe5ded..238a5da2f 100644 --- a/io-engine/src/bdev/nvmx/mod.rs +++ b/io-engine/src/bdev/nvmx/mod.rs @@ -3,7 +3,7 @@ use std::{collections::HashMap, fmt::Display, sync::Arc}; use once_cell::sync::Lazy; use parking_lot::{Mutex, RwLock, RwLockReadGuard, RwLockWriteGuard}; -pub use channel::{NvmeControllerIoChannel, NvmeIoChannel, NvmeIoChannelInner}; +pub use channel::{NvmeIoChannel, NvmeIoChannelInner}; pub use controller::NvmeController; use controller_inner::SpdkNvmeController; pub use controller_state::NvmeControllerState; @@ -11,7 +11,7 @@ pub use device::{lookup_by_name, open_by_name, NvmeBlockDevice}; pub use handle::{nvme_io_ctx_pool_init, NvmeDeviceHandle}; pub use namespace::NvmeNamespace; use poll_group::PollGroup; -pub use qpair::{QPair, QPairState}; +pub use qpair::QPair; pub use snapshot::{NvmeSnapshotMessage, NvmeSnapshotMessageV1}; pub(crate) use uri::NvmfDeviceTemplate; @@ -109,7 +109,7 @@ impl<'a> NVMeCtlrList<'a> { } } -impl<'a> Default for NVMeCtlrList<'a> { +impl Default for NVMeCtlrList<'_> { fn default() -> Self { Self { entries: RwLock::new( diff --git a/io-engine/src/bdev/nvmx/qpair.rs b/io-engine/src/bdev/nvmx/qpair.rs index abaf17b3e..a9653300e 100644 --- a/io-engine/src/bdev/nvmx/qpair.rs +++ b/io-engine/src/bdev/nvmx/qpair.rs @@ -46,7 +46,9 @@ use crate::core::CoreError; use super::{nvme_bdev_running_config, SpdkNvmeController}; /// I/O QPair state. -#[derive(Debug, Serialize, Clone, Copy, PartialEq, PartialOrd)] +#[derive( + Debug, Serialize, Clone, Copy, PartialEq, PartialOrd, strum_macros::Display, +)] pub enum QPairState { /// QPair is not connected. Disconnected, @@ -59,19 +61,6 @@ pub enum QPairState { Dropped, } -impl ToString for QPairState { - fn to_string(&self) -> String { - match self { - QPairState::Disconnected => "Disconnected", - #[cfg(feature = "spdk-async-qpair-connect")] - QPairState::Connecting => "Connecting", - QPairState::Connected => "Connected", - QPairState::Dropped => "Dropped", - } - .to_string() - } -} - /// I/O QPair. pub struct QPair { inner: Rc>, @@ -376,7 +365,7 @@ impl Drop for Connection<'_> { } #[cfg(feature = "spdk-async-qpair-connect")] -impl<'a> Connection<'a> { +impl Connection<'_> { /// Creats a new async qpair connection, and returns a receiver to await the /// completion. fn create(inner: Rc>) -> Result { @@ -470,7 +459,7 @@ impl<'a> Connection<'a> { 1 => Ok(true), // Error occurred during polling. e => { - let e = Errno::from_i32(e.abs()); + let e = Errno::from_raw(e.abs()); error!(?self, "I/O qpair async connection polling error: {e}"); Err(e) } diff --git a/io-engine/src/bdev/nvmx/uri.rs b/io-engine/src/bdev/nvmx/uri.rs index 856b60655..1a9fcd513 100644 --- a/io-engine/src/bdev/nvmx/uri.rs +++ b/io-engine/src/bdev/nvmx/uri.rs @@ -209,7 +209,7 @@ pub(crate) struct NvmeControllerContext<'probe> { attached: bool, } -impl<'probe> NvmeControllerContext<'probe> { +impl NvmeControllerContext<'_> { pub fn new(template: &NvmfDeviceTemplate) -> NvmeControllerContext { let trid = controller::transport::Builder::new() .with_subnqn(&template.subnqn) diff --git a/io-engine/src/bdev/nx.rs b/io-engine/src/bdev/nx.rs index 16e42d637..c959990a7 100644 --- a/io-engine/src/bdev/nx.rs +++ b/io-engine/src/bdev/nx.rs @@ -67,12 +67,12 @@ impl TryFrom<&Url> for Nexus { uri.query_pairs().into_owned().collect(); let size: u64 = if let Some(value) = parameters.remove("size") { - byte_unit::Byte::from_str(value) + byte_unit::Byte::parse_str(&value, true) .map_err(|error| BdevError::InvalidUri { uri: uri.to_string(), message: format!("'size' is invalid: {error}"), })? - .get_bytes() as u64 + .as_u64() } else { return Err(BdevError::InvalidUri { uri: uri.to_string(), diff --git a/io-engine/src/bin/casperf.rs b/io-engine/src/bin/casperf.rs index 1ebb9dec7..164b58a30 100644 --- a/io-engine/src/bin/casperf.rs +++ b/io-engine/src/bin/casperf.rs @@ -87,8 +87,8 @@ unsafe impl Send for Job {} thread_local! { #[allow(clippy::vec_box)] - static JOBLIST: RefCell>> = RefCell::new(Vec::new()); - static PERF_TICK: RefCell>> = RefCell::new(None); + static JOBLIST: RefCell>> = const { RefCell::new(Vec::new()) }; + static PERF_TICK: RefCell>> = const { RefCell::new(None) }; } impl Job { @@ -380,7 +380,7 @@ fn main() { let io_size = match matches.get_one::("io-size") { Some(io_size) => { - byte_unit::Byte::from_str(io_size).unwrap().get_bytes() as u64 + byte_unit::Byte::parse_str(io_size, true).unwrap().as_u64() } None => IO_SIZE, }; diff --git a/io-engine/src/bin/io-engine-client/context.rs b/io-engine/src/bin/io-engine-client/context.rs index 067111d32..ab4459986 100644 --- a/io-engine/src/bin/io-engine-client/context.rs +++ b/io-engine/src/bin/io-engine-client/context.rs @@ -199,9 +199,15 @@ impl Context { pub(crate) fn units(&self, n: Byte) -> String { match self.units { - 'i' => n.get_appropriate_unit(true).to_string(), - 'd' => n.get_appropriate_unit(false).to_string(), - _ => n.get_bytes().to_string(), + 'i' | 'd' => format!( + "{:.2}", + n.get_appropriate_unit(if self.units == 'i' { + byte_unit::UnitType::Binary + } else { + byte_unit::UnitType::Decimal + }) + ), + _ => n.as_u64().to_string(), } } diff --git a/io-engine/src/bin/io-engine-client/main.rs b/io-engine/src/bin/io-engine-client/main.rs index 251fad384..15f3a5e5c 100644 --- a/io-engine/src/bin/io-engine-client/main.rs +++ b/io-engine/src/bin/io-engine-client/main.rs @@ -22,37 +22,46 @@ pub enum ClientError { #[snafu(display("gRPC status: {}", source))] GrpcStatus { source: tonic::Status, - backtrace: Backtrace, + backtrace: Option, }, #[snafu(display("gRPC status: {}", source))] GrpcParseStatus { source: ParseError, - backtrace: Backtrace, + backtrace: Option, }, #[snafu(display("Context building error: {}", source))] ContextCreate { source: context::Error, - backtrace: Backtrace, + backtrace: Option, }, #[snafu(display("Missing value for {}", field))] MissingValue { field: String }, } -type Result = std::result::Result; - pub(crate) fn parse_size(src: &str) -> Result { - Byte::from_str(src).map_err(|_| src.to_string()) + Byte::parse_str(src, true).map_err(|_| src.to_string()) } +type Result = std::result::Result; + #[tokio::main(worker_threads = 2)] -async fn main() -> crate::Result<()> { +async fn main() { env_logger::init(); - match std::env::var("API_VERSION").unwrap_or_default().as_str() { + let result = match std::env::var("API_VERSION").unwrap_or_default().as_str() + { "v0" => v0::main_().await, "v1" => v1::main_().await, "" => v1::main_().await, version => { panic!("Invalid Api version set: {}", version) } + }; + if let Err(error) = result { + eprintln!("{}", error); + use snafu::ErrorCompat; + if let Some(bt) = ErrorCompat::backtrace(&error) { + eprintln!("{:#?}", bt); + } + std::process::exit(1); } } diff --git a/io-engine/src/bin/io-engine-client/v0/nexus_cli.rs b/io-engine/src/bin/io-engine-client/v0/nexus_cli.rs index 29689374c..dc123762d 100644 --- a/io-engine/src/bin/io-engine-client/v0/nexus_cli.rs +++ b/io-engine/src/bin/io-engine-client/v0/nexus_cli.rs @@ -285,7 +285,7 @@ fn nexus_create_parse( })? .cloned() .collect(); - let size = size.get_bytes() as u64; + let size = size.as_u64(); Ok((uuid, size, children)) } @@ -471,7 +471,7 @@ async fn nexus_list( let table = nexus .iter() .map(|n| { - let size = ctx.units(Byte::from_bytes(n.size.into())); + let size = ctx.units(Byte::from_u64(n.size)); let state = nexus_state_to_str(n.state); let mut row = vec![ n.uuid.clone(), @@ -536,7 +536,7 @@ async fn nexus_list_v2( let table = nexus .iter() .map(|n| { - let size = ctx.units(Byte::from_bytes(n.size.into())); + let size = ctx.units(Byte::from_u64(n.size)); let state = nexus_state_to_str(n.state); let mut row = vec![ n.name.clone(), diff --git a/io-engine/src/bin/io-engine-client/v0/pool_cli.rs b/io-engine/src/bin/io-engine-client/v0/pool_cli.rs index 613d4eab5..5cafecd09 100644 --- a/io-engine/src/bin/io-engine-client/v0/pool_cli.rs +++ b/io-engine/src/bin/io-engine-client/v0/pool_cli.rs @@ -159,8 +159,8 @@ async fn list(mut ctx: Context, _matches: &ArgMatches) -> crate::Result<()> { let table = pools .iter() .map(|p| { - let cap = Byte::from_bytes(p.capacity.into()); - let used = Byte::from_bytes(p.used.into()); + let cap = Byte::from_u64(p.capacity); + let used = Byte::from_u64(p.used); let state = pool_state_to_str(p.state); vec![ p.name.clone(), diff --git a/io-engine/src/bin/io-engine-client/v0/replica_cli.rs b/io-engine/src/bin/io-engine-client/v0/replica_cli.rs index 576fea5b1..cde4bc694 100644 --- a/io-engine/src/bin/io-engine-client/v0/replica_cli.rs +++ b/io-engine/src/bin/io-engine-client/v0/replica_cli.rs @@ -198,7 +198,7 @@ async fn replica_create( pool, thin, share, - size: size.get_bytes() as u64, + size: size.as_u64(), allowed_hosts, }; let response = ctx.client.create_replica(rq).await.context(GrpcStatus)?; @@ -266,7 +266,7 @@ async fn replica_create_v2( pool, thin, share, - size: size.get_bytes() as u64, + size: size.as_u64(), allowed_hosts, }; let response = @@ -358,7 +358,7 @@ async fn replica_list( .iter() .map(|r| { let proto = replica_protocol_to_str(r.share); - let size = ctx.units(Byte::from_bytes(r.size.into())); + let size = ctx.units(Byte::from_u64(r.size)); vec![ r.pool.clone(), r.uuid.clone(), @@ -410,7 +410,7 @@ async fn replica_list2( .iter() .map(|r| { let proto = replica_protocol_to_str(r.share); - let size = ctx.units(Byte::from_bytes(r.size.into())); + let size = ctx.units(Byte::from_u64(r.size)); vec![ r.pool.clone(), r.name.clone(), @@ -506,10 +506,9 @@ async fn replica_stat( .iter() .map(|replica| { let stats = replica.stats.as_ref().unwrap(); - let read = - ctx.units(Byte::from_bytes(stats.bytes_read.into())); + let read = ctx.units(Byte::from_u64(stats.bytes_read)); let written = - ctx.units(Byte::from_bytes(stats.bytes_written.into())); + ctx.units(Byte::from_u64(stats.bytes_written)); vec![ replica.pool.clone(), replica.uuid.clone(), diff --git a/io-engine/src/bin/io-engine-client/v1/bdev_cli.rs b/io-engine/src/bin/io-engine-client/v1/bdev_cli.rs index db4bf67fe..236dffaf7 100644 --- a/io-engine/src/bin/io-engine-client/v1/bdev_cli.rs +++ b/io-engine/src/bin/io-engine-client/v1/bdev_cli.rs @@ -112,9 +112,8 @@ async fn list(mut ctx: Context, _args: &ArgMatches) -> crate::Result<()> { let table = bdevs .iter() .map(|bdev| { - let cap = Byte::from_bytes( - (bdev.num_blocks * bdev.blk_size as u64).into(), - ); + let cap = + Byte::from_u64(bdev.num_blocks * bdev.blk_size as u64); vec![ bdev.uuid.to_string(), bdev.num_blocks.to_string(), diff --git a/io-engine/src/bin/io-engine-client/v1/nexus_cli.rs b/io-engine/src/bin/io-engine-client/v1/nexus_cli.rs index cf89649f3..58e4e592c 100644 --- a/io-engine/src/bin/io-engine-client/v1/nexus_cli.rs +++ b/io-engine/src/bin/io-engine-client/v1/nexus_cli.rs @@ -272,7 +272,7 @@ fn nexus_create_parse( })? .cloned() .collect::>(); - let size = size.get_bytes() as u64; + let size = size.as_u64(); Ok((uuid, size, children)) } @@ -464,7 +464,7 @@ async fn nexus_list( let table = nexus .iter() .map(|n| { - let size = ctx.units(Byte::from_bytes(n.size.into())); + let size = ctx.units(Byte::from_u64(n.size)); let state = nexus_state_to_str(n.state); let mut row = vec![ n.name.clone(), @@ -601,7 +601,7 @@ async fn nexus_resize( .nexus .resize_nexus(v1::nexus::ResizeNexusRequest { uuid: uuid.clone(), - requested_size: requested_size.get_bytes() as u64, + requested_size: requested_size.as_u64(), }) .await .context(GrpcStatus)?; diff --git a/io-engine/src/bin/io-engine-client/v1/pool_cli.rs b/io-engine/src/bin/io-engine-client/v1/pool_cli.rs index 126ae4ad3..cfb7abb58 100644 --- a/io-engine/src/bin/io-engine-client/v1/pool_cli.rs +++ b/io-engine/src/bin/io-engine-client/v1/pool_cli.rs @@ -11,7 +11,7 @@ use io_engine_api::v1 as v1rpc; use snafu::ResultExt; use std::{convert::TryFrom, str::FromStr}; use strum::VariantNames; -use strum_macros::{AsRefStr, EnumString, EnumVariantNames}; +use strum_macros::{AsRefStr, EnumString, VariantNames}; use tonic::Status; pub fn subcommands() -> Command { @@ -232,7 +232,7 @@ async fn create(mut ctx: Context, matches: &ArgMatches) -> crate::Result<()> { let cluster_size = match matches.get_one::("cluster-size") { Some(s) => match parse_size(s) { - Ok(s) => Some(s.get_bytes() as u32), + Ok(s) => Some(s.as_u64() as u32), Err(err) => { return Err(Status::invalid_argument(format!( "Bad size '{err}'" @@ -290,7 +290,7 @@ async fn create(mut ctx: Context, matches: &ArgMatches) -> crate::Result<()> { Ok(()) } -#[derive(EnumString, EnumVariantNames, AsRefStr)] +#[derive(EnumString, VariantNames, AsRefStr)] #[strum(serialize_all = "camelCase")] pub(super) enum PoolType { Lvs, @@ -505,15 +505,15 @@ async fn list(mut ctx: Context, matches: &ArgMatches) -> crate::Result<()> { let table = pools .iter() .map(|p| { - let cap = Byte::from_bytes(p.capacity.into()); - let used = Byte::from_bytes(p.used.into()); + let cap = Byte::from_u64(p.capacity); + let used = Byte::from_u64(p.used); let state = pool_state_to_str(p.state); - let cluster = Byte::from_bytes(p.cluster_size.into()); + let cluster = Byte::from_u64(p.cluster_size.into()); let page_size = p .page_size - .map(|s| ctx.units(Byte::from_bytes(s.into()))) + .map(|s| ctx.units(Byte::from_u64(s.into()))) .unwrap_or("-".to_string()); - let disk_cap = Byte::from_bytes(p.disk_capacity.into()); + let disk_cap = Byte::from_u64(p.disk_capacity); let (md_page_size, md_pages, md_used_pages, md_usage) = if let Some(t) = p.md_info.as_ref() { diff --git a/io-engine/src/bin/io-engine-client/v1/replica_cli.rs b/io-engine/src/bin/io-engine-client/v1/replica_cli.rs index f1deade0a..3d180138c 100644 --- a/io-engine/src/bin/io-engine-client/v1/replica_cli.rs +++ b/io-engine/src/bin/io-engine-client/v1/replica_cli.rs @@ -214,7 +214,7 @@ async fn replica_create( pooluuid, thin, share, - size: size.get_bytes() as u64, + size: size.as_u64(), allowed_hosts, }; @@ -338,11 +338,11 @@ async fn replica_list( .map(|r| { let usage = r.usage.as_ref().unwrap(); let proto = replica_protocol_to_str(r.share); - let size = ctx.units(Byte::from_bytes(r.size.into())); - let capacity = ctx - .units(Byte::from_bytes(usage.capacity_bytes.into())); - let allocated = ctx - .units(Byte::from_bytes(usage.allocated_bytes.into())); + let size = ctx.units(Byte::from_u64(r.size)); + let capacity = + ctx.units(Byte::from_u64(usage.capacity_bytes)); + let allocated = + ctx.units(Byte::from_u64(usage.allocated_bytes)); vec![ r.poolname.clone(), r.name.clone(), @@ -485,7 +485,7 @@ async fn replica_resize( .replica .resize_replica(v1_rpc::replica::ResizeReplicaRequest { uuid: uuid.clone(), - requested_size: requested_size.get_bytes() as u64, + requested_size: requested_size.as_u64(), }) .await .context(GrpcStatus)?; @@ -534,10 +534,9 @@ async fn replica_stat( .iter() .map(|replica| { let stats = replica.stats.as_ref().unwrap(); - let read = - ctx.units(Byte::from_bytes(stats.bytes_read.into())); + let read = ctx.units(Byte::from_u64(stats.bytes_read)); let written = - ctx.units(Byte::from_bytes(stats.bytes_written.into())); + ctx.units(Byte::from_u64(stats.bytes_written)); vec![ replica.pool.clone(), replica.uuid.clone(), diff --git a/io-engine/src/bin/io-engine-client/v1/snapshot_cli.rs b/io-engine/src/bin/io-engine-client/v1/snapshot_cli.rs index e7a4b4827..07d4de208 100644 --- a/io-engine/src/bin/io-engine-client/v1/snapshot_cli.rs +++ b/io-engine/src/bin/io-engine-client/v1/snapshot_cli.rs @@ -369,7 +369,7 @@ async fn create_for_replica( r.snapshot_uuid.clone(), r.snapshot_name.clone(), r.snapshot_size.clone().to_string(), - r.timestamp.clone().unwrap_or_default().to_string(), + r.timestamp.unwrap_or_default().to_string(), r.num_clones.to_string(), r.source_uuid.clone(), r.source_size.to_string(), @@ -447,7 +447,7 @@ async fn list(mut ctx: Context, matches: &ArgMatches) -> crate::Result<()> { r.snapshot_uuid.clone(), r.snapshot_name.clone(), r.snapshot_size.to_string(), - r.timestamp.clone().unwrap_or_default().to_string(), + r.timestamp.unwrap_or_default().to_string(), r.num_clones.to_string(), r.source_uuid.clone(), r.source_size.to_string(), diff --git a/io-engine/src/bin/io-engine-client/v1/stats_cli.rs b/io-engine/src/bin/io-engine-client/v1/stats_cli.rs index db9b78f9f..96fe4e038 100644 --- a/io-engine/src/bin/io-engine-client/v1/stats_cli.rs +++ b/io-engine/src/bin/io-engine-client/v1/stats_cli.rs @@ -318,9 +318,9 @@ async fn reset(mut ctx: Context) -> crate::Result<()> { } fn adjust_bytes(bytes: u64) -> String { - let byte = Byte::from_bytes(bytes as u128); - let adjusted_byte = byte.get_appropriate_unit(true); - adjusted_byte.to_string() + let byte = Byte::from_u64(bytes); + let adjusted_byte = byte.get_appropriate_unit(byte_unit::UnitType::Binary); + format!("{adjusted_byte:.2}") } fn ticks_to_time(tick: u64, tick_rate: u64) -> u64 { diff --git a/io-engine/src/bin/io-engine-client/v1/test_cli.rs b/io-engine/src/bin/io-engine-client/v1/test_cli.rs index 2ee317754..46a02744d 100644 --- a/io-engine/src/bin/io-engine-client/v1/test_cli.rs +++ b/io-engine/src/bin/io-engine-client/v1/test_cli.rs @@ -12,7 +12,7 @@ use io_engine_api::v1 as v1_rpc; use snafu::ResultExt; use std::{convert::TryInto, str::FromStr}; use strum::VariantNames; -use strum_macros::{AsRefStr, EnumString, EnumVariantNames}; +use strum_macros::{AsRefStr, EnumString, VariantNames}; use tonic::Status; pub fn subcommands() -> Command { @@ -96,7 +96,7 @@ pub fn subcommands() -> Command { .subcommand(wipe) } -#[derive(EnumString, EnumVariantNames, AsRefStr)] +#[derive(EnumString, VariantNames, AsRefStr)] #[strum(serialize_all = "camelCase")] enum Resource { Replica, @@ -107,13 +107,13 @@ impl Resource { } } -#[derive(EnumString, EnumVariantNames)] +#[derive(EnumString, VariantNames)] #[strum(serialize_all = "PascalCase")] enum CheckSumAlg { Crc32c, } -#[derive(EnumString, EnumVariantNames, Clone, Copy)] +#[derive(EnumString, VariantNames, Clone, Copy)] #[strum(serialize_all = "PascalCase")] enum WipeMethod { None, @@ -243,7 +243,7 @@ async fn replica_wipe( method, ) as i32, }), - chunk_size: chunk_size.get_bytes() as u64, + chunk_size: chunk_size.as_u64(), }), }) .await @@ -253,10 +253,8 @@ async fn replica_wipe( fn bandwidth(response: &v1_rpc::test::WipeReplicaResponse) -> String { let unknown = String::new(); - let Some(Ok(elapsed)) = response - .since - .clone() - .map(TryInto::::try_into) + let Some(Ok(elapsed)) = + response.since.map(TryInto::::try_into) else { return unknown; }; @@ -265,17 +263,17 @@ async fn replica_wipe( return unknown; } - let bandwidth = (response.wiped_bytes as f64 / elapsed_f) as u128; + let bandwidth = (response.wiped_bytes as f64 / elapsed_f) as u64; format!( - "{}/s", - byte_unit::Byte::from_bytes(bandwidth).get_appropriate_unit(true) + "{:.2}/s", + Byte::from_u64(bandwidth) + .get_appropriate_unit(byte_unit::UnitType::Binary) ) } fn checksum(response: &v1_rpc::test::WipeReplicaResponse) -> String { response .checksum - .clone() .map(|c| match c { v1_rpc::test::wipe_replica_response::Checksum::Crc32(crc) => { format!("{crc:#x}") @@ -346,9 +344,9 @@ async fn replica_wipe( } fn adjust_bytes(bytes: u64) -> String { - let byte = Byte::from_bytes(bytes as u128); - let adjusted_byte = byte.get_appropriate_unit(true); - adjusted_byte.to_string() + let byte = Byte::from_u64(bytes); + let adjusted_byte = byte.get_appropriate_unit(byte_unit::UnitType::Binary); + format!("{adjusted_byte:.2}") } async fn injections( diff --git a/io-engine/src/core/block_device.rs b/io-engine/src/core/block_device.rs index 225e7178f..d0146a226 100644 --- a/io-engine/src/core/block_device.rs +++ b/io-engine/src/core/block_device.rs @@ -518,7 +518,7 @@ fn block_device_io_completion( /// TODO pub trait LbaRangeController {} -#[derive(Debug, PartialEq, Copy, Clone)] +#[derive(Debug, PartialEq, Copy, Clone, strum_macros::Display)] pub enum DeviceTimeoutAction { /// Abort I/O operation that times out. Abort, @@ -530,18 +530,6 @@ pub enum DeviceTimeoutAction { HotRemove, } -impl ToString for DeviceTimeoutAction { - fn to_string(&self) -> String { - match *self { - Self::Abort => "Abort", - Self::Reset => "Reset", - Self::Ignore => "Ignore", - Self::HotRemove => "HotRemove", - } - .to_string() - } -} - /// TODO pub trait DeviceIoController { /// TODO diff --git a/io-engine/src/core/env.rs b/io-engine/src/core/env.rs index 980d01a48..9c5197659 100644 --- a/io-engine/src/core/env.rs +++ b/io-engine/src/core/env.rs @@ -13,7 +13,7 @@ use std::{ time::Duration, }; -use byte_unit::{Byte, ByteUnit}; +use byte_unit::{Byte, Unit}; use clap::Parser; use events_api::event::EventAction; use futures::{channel::oneshot, future}; @@ -87,11 +87,11 @@ fn parse_mb(src: &str) -> Result { let has_unit = src.trim_end().chars().any(|c| c.is_alphabetic()); - if let Ok(val) = Byte::from_str(src) { + if let Ok(val) = Byte::parse_str(src, true) { let value = if has_unit { - val.get_adjusted_unit(ByteUnit::MiB).get_value() as i32 + val.get_adjusted_unit(Unit::MiB).get_value() as i32 } else { - val.get_bytes() as i32 + val.as_u64() as i32 }; Ok(value) } else { @@ -288,7 +288,7 @@ fn delay_compat(s: &str) -> Result { match s { "1" | "true" => Ok(true), "" | "0" | "false" => Ok(false), - _else => Err(format!("Must be one of: 1,true,0,false")), + _else => Err("Must be one of: 1,true,0,false".to_string()), } } @@ -852,7 +852,7 @@ impl MayastorEnvironment { None => Self::detect_pod_ip(), } }) - .map(|s| s.clone()) + .cloned() } /// Check if RDMA needs to be enabled for Mayastor nvmf target. diff --git a/io-engine/src/core/fault_injection/mod.rs b/io-engine/src/core/fault_injection/mod.rs index d3d3698b7..5f9dac674 100644 --- a/io-engine/src/core/fault_injection/mod.rs +++ b/io-engine/src/core/fault_injection/mod.rs @@ -34,7 +34,7 @@ pub enum FaultDomain { NexusChild, /// Fault injection on block device abstraction level. BlockDevice, - /// + /// TODO BdevIo, } diff --git a/io-engine/src/core/handle.rs b/io-engine/src/core/handle.rs index c86f9a375..3e69e9d4f 100644 --- a/io-engine/src/core/handle.rs +++ b/io-engine/src/core/handle.rs @@ -153,7 +153,7 @@ impl BdevHandle { if errno != 0 { return Err(CoreError::WriteDispatch { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), offset, len: buffer.len(), }); @@ -190,7 +190,7 @@ impl BdevHandle { if errno != 0 { return Err(CoreError::ReadDispatch { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), offset, len: buffer.len(), }); @@ -225,7 +225,7 @@ impl BdevHandle { if errno != 0 { return Err(CoreError::ResetDispatch { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), }); } @@ -255,7 +255,7 @@ impl BdevHandle { if errno != 0 { return Err(CoreError::WriteZeroesDispatch { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), offset, len, }); @@ -338,7 +338,7 @@ impl BdevHandle { if errno != 0 { return Err(CoreError::NvmeAdminDispatch { - source: Errno::from_i32(errno.abs()), + source: Errno::from_raw(errno.abs()), opcode: (*nvme_cmd).opc(), }); } diff --git a/io-engine/src/core/io_device.rs b/io-engine/src/core/io_device.rs index d2a3c6c9c..4a3c7417c 100644 --- a/io-engine/src/core/io_device.rs +++ b/io-engine/src/core/io_device.rs @@ -61,6 +61,7 @@ impl IoDevice { ctx_getter: impl Fn(*mut spdk_io_channel) -> &'static mut I + 'static, caller_ctx: T, ) { + #[allow(clippy::type_complexity)] struct TraverseCtx { channel_cb: Box i32 + 'static>, done_cb: Box, diff --git a/io-engine/src/core/lock.rs b/io-engine/src/core/lock.rs index 9490ba9a6..29bbc1f9f 100755 --- a/io-engine/src/core/lock.rs +++ b/io-engine/src/core/lock.rs @@ -98,15 +98,15 @@ struct LockStats { /// Lock manager which is used for protecting access to sensitive resources. /// The following hierarchical levels of resource protection are supported: -/// 1) Global - lock manager exposes one single lock which can be used as -/// the global lock to control access at the topmost level. +/// 1) Global - lock manager exposes one single lock which can be used as the +/// global lock to control access at the topmost level. /// 2) Subsystem - Subsystems group resources of the same type (examples are: -/// "nexus", "pool", etc). Every subsystem exposes the global, per-subsystem -/// lock to control resource access at the subsystem level. -/// Example: create/delete nexus operations must be globally serialized, -/// which can be achieved by locking the "nexus" subsystem. -/// 3) Resource - control access at per-object level. -/// Example: control access to a nexus instance whilst modifying nexus state. +/// "nexus", "pool", etc). Every subsystem exposes the global, per-subsystem +/// lock to control resource access at the subsystem level. Example: +/// create/delete nexus operations must be globally serialized, which can be +/// achieved by locking the "nexus" subsystem. +/// 3) Resource - control access at per-object level. Example: control access to +/// a nexus instance whilst modifying nexus state. pub struct ResourceLockManager { /// All known resource subsystems with locks. subsystems: Vec, diff --git a/io-engine/src/core/nic.rs b/io-engine/src/core/nic.rs index 0a349b2ce..a20061155 100644 --- a/io-engine/src/core/nic.rs +++ b/io-engine/src/core/nic.rs @@ -195,7 +195,7 @@ pub fn find_all_nics() -> Vec { .or_insert_with_key(|k| Interface::new(k)); if let Some(sock) = addr.address { if let Some(sock) = sock.as_sockaddr_in() { - nic.inet.addr = Some(sock.ip().into()); + nic.inet.addr = Some(sock.ip()); } if let Some(sock) = sock.as_sockaddr_in6() { nic.inet6.addr = Some(sock.ip()); @@ -207,7 +207,7 @@ pub fn find_all_nics() -> Vec { if let Some(sock) = addr.netmask { if let Some(sock) = sock.as_sockaddr_in() { - nic.inet.netmask = Some(sock.ip().into()); + nic.inet.netmask = Some(sock.ip()); } if let Some(sock) = sock.as_sockaddr_in6() { nic.inet6.netmask = Some(sock.ip()); diff --git a/io-engine/src/core/reactor.rs b/io-engine/src/core/reactor.rs index e93fac017..5caa0f8a5 100644 --- a/io-engine/src/core/reactor.rs +++ b/io-engine/src/core/reactor.rs @@ -240,7 +240,7 @@ impl Reactors { } else { error!("Failed to launch core #{}", core); Err(CoreError::ReactorConfigureFailed { - source: Errno::from_i32(rc), + source: Errno::from_raw(rc), }) }; } else { @@ -647,9 +647,9 @@ impl Reactor { /// master core is polled by the Future abstraction. There are two reasons for /// this /// -/// 1. The master core is the management core, it is the only core that handles -/// gRPC calls 2. The master core handles the setup and tear down of the slave -/// cores +/// 1. The master core is the management core, it is the only core that handles +/// gRPC calls +/// 2. The master core handles the setup and tear down of the slave cores impl Future for &'static Reactor { type Output = Result<(), ()>; fn poll(self: Pin<&mut Self>, cx: &mut Context) -> Poll { diff --git a/io-engine/src/core/segment_map.rs b/io-engine/src/core/segment_map.rs index c7d99c16c..ac9e75901 100644 --- a/io-engine/src/core/segment_map.rs +++ b/io-engine/src/core/segment_map.rs @@ -1,11 +1,6 @@ use bit_vec::{BitBlock, BitVec}; use std::fmt::{Debug, Formatter}; -// Returns ceil of an integer division. -fn div_ceil(a: u64, b: u64) -> u64 { - (a + b - 1) / b -} - /// Map of rebuild segments of a block device. /// It marks every segment as a clean (no need to rebuild, or already /// transferred), or dirty (need to transfer from a healthy device). @@ -40,7 +35,7 @@ impl Debug for SegmentMap { impl SegmentMap { /// Creates a new segment map with the given parameters. pub fn new(num_blocks: u64, block_len: u64, segment_size: u64) -> Self { - let num_segments = div_ceil(num_blocks * block_len, segment_size); + let num_segments = (num_blocks * block_len).div_ceil(segment_size); let mut segments = BitVec::::default(); segments.grow(num_segments as usize, false); Self { diff --git a/io-engine/src/core/wiper.rs b/io-engine/src/core/wiper.rs index 3fa3e35bf..37648ab14 100644 --- a/io-engine/src/core/wiper.rs +++ b/io-engine/src/core/wiper.rs @@ -124,10 +124,10 @@ impl FinalWipeStats { let elapsed = self.end - self.start; let elapsed_f = elapsed.as_secs_f64(); let bandwidth = if elapsed_f.is_normal() { - let bandwidth = (stats.total_bytes as f64 / elapsed_f) as u128; - byte_unit::Byte::from_bytes(bandwidth) - .get_appropriate_unit(true) - .to_string() + let bandwidth = (stats.total_bytes as f64 / elapsed_f) as u64; + let adjusted = byte_unit::Byte::from_u64(bandwidth) + .get_appropriate_unit(byte_unit::UnitType::Binary); + format!("{adjusted:.2}") } else { "??".to_string() }; diff --git a/io-engine/src/delay.rs b/io-engine/src/delay.rs index 745f9275c..63144ac82 100644 --- a/io-engine/src/delay.rs +++ b/io-engine/src/delay.rs @@ -8,7 +8,7 @@ use spdk_rs::libspdk::{ thread_local! { /// Delay poller pointer for unregistering the poller at the end - static DELAY_POLLER: RefCell> = RefCell::new(None); + static DELAY_POLLER: RefCell> = const { RefCell::new(None) }; } /// Delay function called from the spdk poller to prevent draining of cpu diff --git a/io-engine/src/eventing/host_events.rs b/io-engine/src/eventing/host_events.rs index 76d4b37ed..640908c67 100644 --- a/io-engine/src/eventing/host_events.rs +++ b/io-engine/src/eventing/host_events.rs @@ -21,7 +21,7 @@ pub(crate) trait HostTargetMeta { fn host_target_meta(&self, meta: EventMeta) -> EventMeta; } -impl<'n> HostTargetMeta for Nexus<'n> { +impl HostTargetMeta for Nexus<'_> { fn host_target_meta(&self, mut meta: EventMeta) -> EventMeta { if let Some(source) = meta.source { let event_source = diff --git a/io-engine/src/eventing/nexus_events.rs b/io-engine/src/eventing/nexus_events.rs index 7710d480f..ad1ae7444 100644 --- a/io-engine/src/eventing/nexus_events.rs +++ b/io-engine/src/eventing/nexus_events.rs @@ -45,7 +45,7 @@ impl EventMetaGen for NexusRebuildJob { } } -impl<'n> EventMetaGen for NexusChild<'n> { +impl EventMetaGen for NexusChild<'_> { fn meta(&self) -> EventMeta { let event_source = EventSource::new( MayastorEnvironment::global_or_default().node_name, @@ -89,7 +89,7 @@ pub(crate) fn subsystem_pause_event_meta( EventMeta::from_source(event_source) } -impl<'n> Event for nexus::Nexus<'n> { +impl Event for nexus::Nexus<'_> { fn event(&self, event_action: EventAction) -> EventMessage { let event_source = EventSource::new( MayastorEnvironment::global_or_default().node_name, @@ -103,7 +103,7 @@ impl<'n> Event for nexus::Nexus<'n> { } } -impl<'n> EventWithMeta for nexus::Nexus<'n> { +impl EventWithMeta for nexus::Nexus<'_> { fn event( &self, event_action: EventAction, diff --git a/io-engine/src/eventing/replica_events.rs b/io-engine/src/eventing/replica_events.rs index f9f7bc3bb..dae5cf564 100644 --- a/io-engine/src/eventing/replica_events.rs +++ b/io-engine/src/eventing/replica_events.rs @@ -49,7 +49,7 @@ pub(crate) fn state_change_event_meta( } /// Replica state change event. -impl<'n> EventWithMeta for NexusChild<'n> { +impl EventWithMeta for NexusChild<'_> { fn event( &self, event_action: EventAction, diff --git a/io-engine/src/grpc/controller_grpc.rs b/io-engine/src/grpc/controller_grpc.rs index bb9eee75d..71de9b608 100644 --- a/io-engine/src/grpc/controller_grpc.rs +++ b/io-engine/src/grpc/controller_grpc.rs @@ -13,7 +13,7 @@ pub struct NvmeControllerInfo { pub blk_size: u32, } -impl<'a> NvmeController<'a> { +impl NvmeController<'_> { fn to_info(&self) -> NvmeControllerInfo { let (size, blk_size) = self .namespace() diff --git a/io-engine/src/grpc/server.rs b/io-engine/src/grpc/server.rs index 03852059c..2a908bd8f 100644 --- a/io-engine/src/grpc/server.rs +++ b/io-engine/src/grpc/server.rs @@ -67,7 +67,7 @@ impl MayastorGrpcServer { rpc_addr: String, api_versions: Vec, ) -> Result<(), ()> { - let mut rcv_chan = Self::get_or_init().rcv_chan.clone(); + let mut rcv_chan = Box::pin(Self::get_or_init().rcv_chan.clone()); let address = Cow::from(rpc_addr); diff --git a/io-engine/src/grpc/v0/mayastor_grpc.rs b/io-engine/src/grpc/v0/mayastor_grpc.rs index 0d4601f84..9483d1be2 100644 --- a/io-engine/src/grpc/v0/mayastor_grpc.rs +++ b/io-engine/src/grpc/v0/mayastor_grpc.rs @@ -68,9 +68,6 @@ use std::{ time::Duration, }; use tonic::{Request, Response, Status}; -/// TODO -#[derive(Debug)] -struct UnixStream(tokio::net::UnixStream); use crate::core::{UpdateProps, VerboseError}; use ::function_name::named; @@ -438,7 +435,7 @@ impl From for BlockDevice { impl From for block_device::Filesystem { fn from(fs: blk_device::FileSystem) -> Self { - let mountpoint = fs.mountpoints.get(0).cloned().unwrap_or_default(); + let mountpoint = fs.mountpoints.first().cloned().unwrap_or_default(); Self { fstype: fs.fstype, label: fs.label, diff --git a/io-engine/src/grpc/v0/nexus_grpc.rs b/io-engine/src/grpc/v0/nexus_grpc.rs index 9e30e67d7..96e0a19b3 100644 --- a/io-engine/src/grpc/v0/nexus_grpc.rs +++ b/io-engine/src/grpc/v0/nexus_grpc.rs @@ -1,4 +1,4 @@ -///! Helpers related to nexus grpc methods. +//! Helpers related to nexus grpc methods. use io_engine_api::v0 as rpc; use rpc::{ChildState, ChildStateReason}; use std::{convert::From, pin::Pin}; diff --git a/io-engine/src/grpc/v1/nexus.rs b/io-engine/src/grpc/v1/nexus.rs index cfeef3867..a1c8629da 100644 --- a/io-engine/src/grpc/v1/nexus.rs +++ b/io-engine/src/grpc/v1/nexus.rs @@ -29,9 +29,6 @@ use tonic::{Request, Response, Status}; use io_engine_api::v1::nexus::*; -#[derive(Debug)] -struct UnixStream(tokio::net::UnixStream); - use crate::bdev::{dev::device_name, nexus::NexusPtpl, PtplFileOps}; use ::function_name::named; use events_api::event::EventAction; @@ -301,11 +298,10 @@ pub fn nexus_lookup<'n>( /// Destruction of the nexus. Returns NotFound error for invalid uuid. pub async fn nexus_destroy(uuid: &str) -> Result<(), nexus::Error> { - let n = nexus_lookup(uuid).map_err(|error| { + let n = nexus_lookup(uuid).inspect_err(|_| { if let Ok(uuid) = uuid::Uuid::parse_str(uuid) { NexusPtpl::new(uuid).destroy().ok(); } - error })?; n.destroy().await } @@ -330,7 +326,6 @@ impl<'n> nexus::Nexus<'n> { /// /// We cannot use From trait because it is not value to value conversion. /// All we have is a reference to nexus. - pub async fn into_grpc(&self) -> Nexus { let mut ana_state = NvmeAnaState::NvmeAnaInvalidState; diff --git a/io-engine/src/grpc/v1/pool.rs b/io-engine/src/grpc/v1/pool.rs index 75933201c..799ad0303 100644 --- a/io-engine/src/grpc/v1/pool.rs +++ b/io-engine/src/grpc/v1/pool.rs @@ -37,9 +37,6 @@ use io_engine_api::v1::{ use std::{convert::TryFrom, fmt::Debug, ops::Deref, panic::AssertUnwindSafe}; use tonic::{Request, Status}; -#[derive(Debug)] -struct UnixStream(tokio::net::UnixStream); - impl From for FindPoolArgs { fn from(value: DestroyPoolRequest) -> Self { Self::name_uuid(value.name, &value.uuid) diff --git a/io-engine/src/grpc/v1/replica.rs b/io-engine/src/grpc/v1/replica.rs index 687ca8377..d47c3fa05 100644 --- a/io-engine/src/grpc/v1/replica.rs +++ b/io-engine/src/grpc/v1/replica.rs @@ -462,7 +462,7 @@ impl ReplicaRpc for ReplicaService { .iter() .map(PoolBackend::try_from) .collect::, _>>()?; - let query = args.query.clone(); + let query = args.query; let fargs = ListReplicaArgs::from(args); for factory in diff --git a/io-engine/src/host/blk_device.rs b/io-engine/src/host/blk_device.rs index 4c0ea9e25..68bae2072 100644 --- a/io-engine/src/host/blk_device.rs +++ b/io-engine/src/host/blk_device.rs @@ -201,7 +201,7 @@ fn new_filesystem( None } else { // get fstype from the first mount - mountinfo.get(0).map(|m| m.fstype.clone()) + mountinfo.first().map(|m| m.fstype.clone()) } } diff --git a/io-engine/src/logger.rs b/io-engine/src/logger.rs index adf89fa30..06f04a606 100644 --- a/io-engine/src/logger.rs +++ b/io-engine/src/logger.rs @@ -206,7 +206,7 @@ where } // Display trace context (span) information -impl<'a, S, N> std::fmt::Display for CustomContext<'a, S, N> +impl std::fmt::Display for CustomContext<'_, S, N> where S: tracing_core::subscriber::Subscriber + for<'s> LookupSpan<'s>, N: for<'w> FormatFields<'w> + 'static, @@ -366,7 +366,7 @@ pub struct StringVisitor<'a> { string: &'a mut String, } -impl<'a> Visit for StringVisitor<'a> { +impl Visit for StringVisitor<'_> { fn record_debug(&mut self, field: &Field, value: &dyn fmt::Debug) { write!(self.string, "{} = {:?}; ", field.name(), value).unwrap(); } diff --git a/io-engine/src/lvm/cli.rs b/io-engine/src/lvm/cli.rs index 7ce4ec991..7b8bc0cef 100644 --- a/io-engine/src/lvm/cli.rs +++ b/io-engine/src/lvm/cli.rs @@ -341,7 +341,7 @@ pub(super) mod de { { struct CommaSeparated(PhantomData, PhantomData); - impl<'de, V, T> Visitor<'de> for CommaSeparated + impl Visitor<'_> for CommaSeparated where V: FromIterator, T: FromStr, diff --git a/io-engine/src/lvm/lv_replica.rs b/io-engine/src/lvm/lv_replica.rs index 8f64f23a1..e155e523d 100644 --- a/io-engine/src/lvm/lv_replica.rs +++ b/io-engine/src/lvm/lv_replica.rs @@ -647,10 +647,11 @@ impl LogicalVolume { /// 1. It uses Pin which is not required for our lvm /// 2. Some of the functions part of the Share trait are blocking but we're /// currently using a trampoline between tokio and spdk reactors which makes -/// this difficult. -/// todo: would reactor block on help here? -/// we could go the other way and use trampoline from spdk to tokio, but -/// then also hit the problem? +/// this difficult. +/// +/// todo: would reactor block on help here? we could go the +/// other way and use trampoline from spdk to tokio, but then also hit the +/// problem? impl LogicalVolume { pub(crate) fn bdev(uri: &str) -> Result { UntypedBdev::get_by_name(uri).map_err(|_| Error::BdevMissing {}) diff --git a/io-engine/src/lvs/lvol_snapshot.rs b/io-engine/src/lvs/lvol_snapshot.rs index 7819c06d9..e46e9b18b 100644 --- a/io-engine/src/lvs/lvol_snapshot.rs +++ b/io-engine/src/lvs/lvol_snapshot.rs @@ -106,6 +106,8 @@ pub trait LvolSnapshotOps { /// create replica snapshot inner function to call spdk snapshot create /// function. + /// # Safety + /// TODO unsafe fn create_snapshot_inner( &self, snap_param: &SnapshotParams, @@ -131,6 +133,8 @@ pub trait LvolSnapshotOps { ) -> Result<(), Self::Error>; /// Create clone inner function to call spdk clone function. + /// # Safety + /// TODO unsafe fn create_clone_inner( &self, clone_param: &CloneParams, @@ -634,7 +638,7 @@ impl LvolSnapshotOps for Lvol { Ok(lvol_ptr) } else { assert!(errno < 0); - let e = Errno::from_i32(-errno); + let e = Errno::from_raw(-errno); error!("Create snapshot failed with errno {errno}: {e}"); Err(e) }; @@ -766,7 +770,7 @@ impl LvolSnapshotOps for Lvol { Ok(lvol_ptr) } else { assert!(errno < 0); - let e = Errno::from_i32(-errno); + let e = Errno::from_raw(-errno); error!("Snapshot Clone failed with errno {errno}: {e}"); Err(e) }; diff --git a/io-engine/src/lvs/lvs_error.rs b/io-engine/src/lvs/lvs_error.rs index dda40e1ad..a76689ac7 100644 --- a/io-engine/src/lvs/lvs_error.rs +++ b/io-engine/src/lvs/lvs_error.rs @@ -81,7 +81,7 @@ impl BsError { /// Creates a `BsError` from a raw i32 errno value. pub fn from_i32(value: i32) -> Self { - let r = Errno::from_i32(value.abs()); + let r = Errno::from_raw(value.abs()); if value < 0 { warn!("Blob store: negative errno passed: {r}"); diff --git a/io-engine/src/lvs/lvs_lvol.rs b/io-engine/src/lvs/lvs_lvol.rs index 8777c2359..8fa080152 100644 --- a/io-engine/src/lvs/lvs_lvol.rs +++ b/io-engine/src/lvs/lvs_lvol.rs @@ -158,12 +158,13 @@ impl Debug for Lvol { fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { write!( f, - "Lvol '{}/{}/{}' [{}{}]", + "Lvol '{}/{}/{}' [{}{:.2}]", self.pool_name(), self.pool_uuid(), self.name(), if self.is_thin() { "thin " } else { "" }, - Byte::from(self.size()).get_appropriate_unit(true) + Byte::from(self.size()) + .get_appropriate_unit(byte_unit::UnitType::Binary) ) } } @@ -615,6 +616,8 @@ pub trait LvsLvol: LogicalVolume + Share { ) -> Option<*mut spdk_blob>; /// Get the next spdk_blob from the parent blob. + /// # Safety + /// TODO unsafe fn bs_iter_parent( &self, curr_blob: *mut spdk_blob, @@ -855,9 +858,7 @@ impl LvsLvol for Lvol { } PropName::AllowedHosts => { match unsafe { CStr::from_ptr(value).to_str() } { - Ok(list) if list.is_empty() => { - Ok(PropValue::AllowedHosts(vec![])) - } + Ok("") => Ok(PropValue::AllowedHosts(vec![])), Ok(list) => Ok(PropValue::AllowedHosts( list.split(',') .map(|s| s.to_string()) @@ -1057,6 +1058,8 @@ impl LvsLvol for Lvol { } /// Get the parent spdk_blob from the current blob. + /// # Safety + /// TODO unsafe fn bs_iter_parent( &self, curr_blob: *mut spdk_blob, diff --git a/io-engine/src/lvs/lvs_store.rs b/io-engine/src/lvs/lvs_store.rs index e6c3657da..4934fd5df 100644 --- a/io-engine/src/lvs/lvs_store.rs +++ b/io-engine/src/lvs/lvs_store.rs @@ -82,12 +82,14 @@ impl Debug for Lvs { fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { write!( f, - "Lvs '{}' [{}/{}] ({}/{})", + "Lvs '{}' [{}/{}] ({:.2}/{:.2})", self.name(), self.base_bdev().name(), self.base_bdev().uuid(), - Byte::from(self.available()).get_appropriate_unit(true), - Byte::from(self.capacity()).get_appropriate_unit(true) + Byte::from(self.available()) + .get_appropriate_unit(byte_unit::UnitType::Binary), + Byte::from(self.capacity()) + .get_appropriate_unit(byte_unit::UnitType::Binary) ) } } @@ -140,7 +142,7 @@ impl Lvs { .expect("receiver gone"); } else { sender - .send(Err(Errno::from_i32(errno.abs()))) + .send(Err(Errno::from_raw(errno.abs()))) .expect("receiver gone"); } } @@ -394,8 +396,9 @@ impl Lvs { .. } => Ok(parsed.get_name()), BdevError::CreateBdevInvalidParams { - source, .. - } if source == Errno::EEXIST => Ok(parsed.get_name()), + source: Errno::EEXIST, + .. + } => Ok(parsed.get_name()), _ => { tracing::error!("Failed to create pool bdev: {e:?}"); Err(LvsError::InvalidBdev { @@ -587,8 +590,9 @@ impl Lvs { .. } => Ok(bdev_ops.get_name()), BdevError::CreateBdevInvalidParams { - source, .. - } if source == Errno::EEXIST => Ok(bdev_ops.get_name()), + source: Errno::EEXIST, + .. + } => Ok(bdev_ops.get_name()), _ => { tracing::error!("Failed to create pool bdev: {e:?}"); Err(LvsError::InvalidBdev { @@ -604,8 +608,9 @@ impl Lvs { Ok(pool) => Ok(pool), // try to create the pool Err(LvsError::Import { - source, .. - }) if matches!(source, BsError::CannotImportLvs {}) => { + source: BsError::CannotImportLvs {}, + .. + }) => { match Self::create_from_args_inner(PoolArgs { disks: vec![bdev_name.clone()], ..args diff --git a/io-engine/src/lvs/mod.rs b/io-engine/src/lvs/mod.rs index 0c42c9318..c5a1657c5 100644 --- a/io-engine/src/lvs/mod.rs +++ b/io-engine/src/lvs/mod.rs @@ -344,9 +344,7 @@ impl IReplicaFactory for ReplLvsFactory { &self, bdev: crate::core::UntypedBdev, ) -> Option> { - let Some(lvol) = Lvol::ok_from(bdev) else { - return None; - }; + let lvol = Lvol::ok_from(bdev)?; if lvol.is_snapshot() { return None; } diff --git a/io-engine/src/rebuild/rebuild_descriptor.rs b/io-engine/src/rebuild/rebuild_descriptor.rs index e1b973335..9da58efa4 100644 --- a/io-engine/src/rebuild/rebuild_descriptor.rs +++ b/io-engine/src/rebuild/rebuild_descriptor.rs @@ -243,14 +243,10 @@ impl RebuildDescriptor { // Read from an unallocated block occured, no need to copy it. Err(CoreError::ReadFailed { - status, .. - }) if matches!( - status, - IoCompletionStatus::NvmeError(NvmeStatus::UNWRITTEN_BLOCK) - ) => - { - Ok(false) - } + status: + IoCompletionStatus::NvmeError(NvmeStatus::UNWRITTEN_BLOCK), + .. + }) => Ok(false), // Read error. Err(err) => Err(RebuildError::ReadIoFailed { diff --git a/io-engine/src/rebuild/rebuild_job_backend.rs b/io-engine/src/rebuild/rebuild_job_backend.rs index 360599d3d..d7c6f39f7 100644 --- a/io-engine/src/rebuild/rebuild_job_backend.rs +++ b/io-engine/src/rebuild/rebuild_job_backend.rs @@ -211,7 +211,7 @@ impl RebuildJobBackendManager { // todo: is there a bug here if we fail above? self.start_all_tasks(); - let mut recv = self.info_chan.recv_clone(); + let mut recv = Box::pin(self.info_chan.recv_clone()); while self.task_pool().running() { futures::select! { message = recv.next() => if !self.handle_message(message).await { @@ -227,7 +227,7 @@ impl RebuildJobBackendManager { } /// State Management - + /// /// Reconciles the pending state to the current and clear the pending. fn reconcile(&mut self) -> RebuildState { let (old, new) = { @@ -292,7 +292,7 @@ impl RebuildJobBackendManager { } /// Generic Rebuild Statistics - + /// /// Collects generic statistics from the job. pub fn stats(&self) -> RebuildStats { let descriptor = self.backend.common_desc(); @@ -348,7 +348,6 @@ impl RebuildJobBackendManager { } /// Rebuild Tasks Management - fn task_sync_fail(&mut self) { let active = self.task_pool().active; error!( diff --git a/io-engine/src/rebuild/rebuild_task.rs b/io-engine/src/rebuild/rebuild_task.rs index ab06d2261..542537329 100644 --- a/io-engine/src/rebuild/rebuild_task.rs +++ b/io-engine/src/rebuild/rebuild_task.rs @@ -144,7 +144,7 @@ impl RebuildTasks { } /// Await for one task to complete and update the task complete count. pub(super) async fn await_one_task(&mut self) -> Option { - self.channel.1.next().await.map(|f| { + self.channel.1.next().await.inspect(|f| { self.active -= 1; if f.error.is_none() { self.segments_done += 1; @@ -152,7 +152,6 @@ impl RebuildTasks { self.segments_transferred += 1; } } - f }) } /// Schedules the run of a task by its id. It will copy the segment size diff --git a/io-engine/src/subsys/config/opts.rs b/io-engine/src/subsys/config/opts.rs index 67b3a5166..aef697fc9 100644 --- a/io-engine/src/subsys/config/opts.rs +++ b/io-engine/src/subsys/config/opts.rs @@ -35,7 +35,7 @@ use std::{ }; use crate::core::MayastorEnvironment; -use strum_macros::{AsRefStr, EnumString, EnumVariantNames}; +use strum_macros::{AsRefStr, EnumString, VariantNames}; pub trait GetOpts { fn get(&self) -> Self; @@ -85,7 +85,7 @@ impl GetOpts for NexusOpts { /// Must be equal to the size of `spdk_nvmf_target_opts.crdt`. pub const TARGET_CRDT_LEN: usize = 3; -#[derive(Clone, Default, EnumString, EnumVariantNames, AsRefStr)] +#[derive(Clone, Default, EnumString, VariantNames, AsRefStr)] #[strum(serialize_all = "lowercase")] pub enum NvmfTgtTransport { Rdma, diff --git a/io-engine/src/subsys/nvmf/mod.rs b/io-engine/src/subsys/nvmf/mod.rs index 290c1f1df..dc31fd816 100644 --- a/io-engine/src/subsys/nvmf/mod.rs +++ b/io-engine/src/subsys/nvmf/mod.rs @@ -87,7 +87,7 @@ pub enum Error { } thread_local! { - pub (crate) static NVMF_PGS: RefCell> = RefCell::new(Vec::new()); + pub (crate) static NVMF_PGS: RefCell> = const { RefCell::new(Vec::new()) }; } impl Nvmf { diff --git a/io-engine/src/subsys/nvmf/subsystem.rs b/io-engine/src/subsys/nvmf/subsystem.rs index 6e96b4e87..22b7dc76e 100644 --- a/io-engine/src/subsys/nvmf/subsystem.rs +++ b/io-engine/src/subsys/nvmf/subsystem.rs @@ -484,7 +484,7 @@ impl NvmfSubsystem { unsafe { spdk_nvmf_subsystem_set_sn(ss.as_ptr(), sn.as_ptr()) } .to_result(|e| Error::Subsystem { - source: Errno::from_i32(e), + source: Errno::from_raw(e), nqn: uuid.into(), msg: "failed to set serial".into(), })?; @@ -492,7 +492,7 @@ impl NvmfSubsystem { let mn = CString::new(NVME_CONTROLLER_MODEL_ID).unwrap(); unsafe { spdk_nvmf_subsystem_set_mn(ss.as_ptr(), mn.as_ptr()) } .to_result(|e| Error::Subsystem { - source: Errno::from_i32(e), + source: Errno::from_raw(e), nqn: uuid.into(), msg: "failed to set model number".into(), })?; @@ -704,7 +704,7 @@ impl NvmfSubsystem { ) } .to_result(|errno| Error::Subsystem { - source: Errno::from_i32(errno), + source: Errno::from_raw(errno), nqn: self.get_nqn(), msg: format!("failed to add allowed host: {host:?}"), }) @@ -725,7 +725,7 @@ impl NvmfSubsystem { spdk_nvmf_subsystem_remove_host(self.0.as_ptr(), host.as_ptr()) } .to_result(|errno| Error::Subsystem { - source: Errno::from_i32(errno), + source: Errno::from_raw(errno), nqn: self.get_nqn(), msg: format!("failed to remove allowed host: {host:?}"), })?; @@ -752,7 +752,7 @@ impl NvmfSubsystem { r.await.expect("done_cb callback gone").to_result(|error| { Error::Subsystem { - source: Errno::from_i32(error), + source: Errno::from_raw(error), msg: "Failed to disconnect host".to_string(), nqn: host.to_owned(), } @@ -775,7 +775,7 @@ impl NvmfSubsystem { spdk_nvmf_subsystem_set_ana_reporting(self.0.as_ptr(), enable) } .to_result(|e| Error::Subsystem { - source: Errno::from_i32(e), + source: Errno::from_raw(e), nqn: self.get_nqn(), msg: format!("failed to set ANA reporting, enable {enable}"), })?; @@ -796,7 +796,7 @@ impl NvmfSubsystem { ) } .to_result(|e| Error::Subsystem { - source: Errno::from_i32(e), + source: Errno::from_raw(e), nqn: self.get_nqn(), msg: format!("failed to set controller ID range [{cntlid_min}, {cntlid_max}]"), })?; @@ -831,7 +831,7 @@ impl NvmfSubsystem { r.await.expect("listener callback gone").to_result(|e| { Error::Transport { - source: Errno::from_i32(e), + source: Errno::from_raw(e), msg: "Failed to add listener".to_string(), } }) @@ -888,7 +888,7 @@ impl NvmfSubsystem { match rc { 0 => r.await.unwrap().to_result(|e| Error::Subsystem { - source: Errno::from_i32(e), + source: Errno::from_raw(e), nqn: self.get_nqn(), msg: format!("{op} failed"), }), @@ -897,7 +897,7 @@ impl NvmfSubsystem { op: op.to_owned(), }), e => Err(Error::Subsystem { - source: Errno::from_i32(e), + source: Errno::from_raw(e), nqn: self.get_nqn(), msg: format!("failed to initiate {op}"), }), @@ -1033,7 +1033,7 @@ impl NvmfSubsystem { r.await .expect("Cancellation is not supported") .to_result(|e| Error::Subsystem { - source: Errno::from_i32(-e), + source: Errno::from_raw(-e), nqn: self.get_nqn(), msg: "failed to set_ana_state of the subsystem".to_string(), })?; @@ -1185,7 +1185,7 @@ pub enum NqnTarget<'a> { None, } -impl<'a> NqnTarget<'a> { +impl NqnTarget<'_> { pub fn lookup(nqn: &str) -> Self { let Some(bdev) = UntypedBdev::bdev_first() else { return Self::None; diff --git a/io-engine/src/subsys/nvmf/target.rs b/io-engine/src/subsys/nvmf/target.rs index e50151584..9e38f4c7e 100644 --- a/io-engine/src/subsys/nvmf/target.rs +++ b/io-engine/src/subsys/nvmf/target.rs @@ -386,7 +386,7 @@ impl Target { spdk_nvmf_subsystem_set_mn(discovery.0.as_ptr(), mn.as_ptr()) } .to_result(|e| Error::Subsystem { - source: Errno::from_i32(e), + source: Errno::from_raw(e), nqn: "discovery".into(), msg: "failed to set serial".into(), }) diff --git a/io-engine/src/subsys/registration/registration_grpc.rs b/io-engine/src/subsys/registration/registration_grpc.rs index 6d3818c91..404d8ad30 100644 --- a/io-engine/src/subsys/registration/registration_grpc.rs +++ b/io-engine/src/subsys/registration/registration_grpc.rs @@ -212,6 +212,7 @@ impl Registration { "Registering '{:?}' with grpc server {} ...", self.config.node, self.config.grpc_endpoint ); + let mut rcv_chan = Box::pin(self.rcv_chan.clone()); loop { match self.register().await { Ok(_) => { @@ -232,7 +233,7 @@ impl Registration { }; select! { _ = tokio::time::sleep(self.config.hb_interval_sec).fuse() => continue, - msg = self.rcv_chan.next().fuse() => { + msg = rcv_chan.next().fuse() => { match msg { Some(_) => info!("Messages have not been implemented yet"), _ => { diff --git a/io-engine/tests/nexus_create_destroy.rs b/io-engine/tests/nexus_create_destroy.rs index e747ebae8..836fbeb6b 100644 --- a/io-engine/tests/nexus_create_destroy.rs +++ b/io-engine/tests/nexus_create_destroy.rs @@ -67,7 +67,7 @@ async fn nexus_create_multiple_then_destroy() { let mut hdl = grpc.grpc_handle("ms1").await.unwrap(); let nexuses = create_nexuses(&mut hdl, NEXUS_COUNT).await; - for (_, nexus) in nexuses.iter().enumerate() { + for nexus in nexuses.iter() { hdl.mayastor .destroy_nexus(DestroyNexusRequest { uuid: nexus.uuid.clone(), diff --git a/io-engine/tests/nexus_rebuild.rs b/io-engine/tests/nexus_rebuild.rs index cf33f3f04..2b69c43e5 100644 --- a/io-engine/tests/nexus_rebuild.rs +++ b/io-engine/tests/nexus_rebuild.rs @@ -58,7 +58,7 @@ fn test_fini() { common::delete_file(&[get_disk(i)]); } } - +#[allow(static_mut_refs)] fn get_err_bdev() -> &'static mut Vec { unsafe { static mut ERROR_DEVICE_INDEXES: Vec = Vec::::new(); diff --git a/io-engine/tests/reactor.rs b/io-engine/tests/reactor.rs index bf573f56b..ffb71f718 100644 --- a/io-engine/tests/reactor.rs +++ b/io-engine/tests/reactor.rs @@ -44,10 +44,14 @@ fn reactor_start_stop() { assert_eq!(core, unsafe { libc::sched_getcpu() as u32 }); // global mutable state is unsafe - unsafe { WAIT_FOR.fetch_sub(1, Ordering::SeqCst) }; + #[allow(static_mut_refs)] + unsafe { + WAIT_FOR.fetch_sub(1, Ordering::SeqCst) + }; }); }); + #[allow(static_mut_refs)] while unsafe { WAIT_FOR.load(Ordering::SeqCst) } != 0 { Reactors::master().poll_once(); } diff --git a/io-engine/tests/replica_timeout.rs b/io-engine/tests/replica_timeout.rs index 58ccb7504..0c073ff12 100644 --- a/io-engine/tests/replica_timeout.rs +++ b/io-engine/tests/replica_timeout.rs @@ -111,7 +111,7 @@ async fn replica_stop_cont() { Command::new("../target/debug/initiator") .args([&nxuri, "read", "/tmp/tmpread"]) .stdout(Stdio::piped()) - .spawn() + .status() .expect("should send read from initiator"); println!("IO submitted unfreezing container..."); diff --git a/io-engine/tests/resource_stats.rs b/io-engine/tests/resource_stats.rs index b82c0dbef..dd85ae3d4 100644 --- a/io-engine/tests/resource_stats.rs +++ b/io-engine/tests/resource_stats.rs @@ -180,14 +180,14 @@ async fn test_resource_stats() { let repl_0_stat: &Vec = &repl_0_stat.get_ref().stats; let repl_1_stat: &Vec = &repl_1_stat.get_ref().stats; let repl_nex_stat: &Vec = &repl_nex_stat.get_ref().stats; - let nexus_stat = nexus_stat.get(0).unwrap(); - let pool_0_stat = pool_0_stat.get(0).unwrap(); - let pool_1_stat = pool_1_stat.get(0).unwrap(); - let repl_0_stat = repl_0_stat.get(0).unwrap(); + let nexus_stat = nexus_stat.first().unwrap(); + let pool_0_stat = pool_0_stat.first().unwrap(); + let pool_1_stat = pool_1_stat.first().unwrap(); + let repl_0_stat = repl_0_stat.first().unwrap(); let repl_0_stat = repl_0_stat.stats.clone().unwrap(); - let repl_1_stat = repl_1_stat.get(0).unwrap(); + let repl_1_stat = repl_1_stat.first().unwrap(); let repl_1_stat = repl_1_stat.stats.clone().unwrap(); - let repl_nex_stat = repl_nex_stat.get(0).unwrap(); + let repl_nex_stat = repl_nex_stat.first().unwrap(); let repl_nex_stat = repl_nex_stat.stats.clone().unwrap(); // Validate num_read/write_ops reset across resource. @@ -298,15 +298,15 @@ async fn test_resource_stats() { let repl_0_stat: &Vec = &repl_0_stat.get_ref().stats; let repl_1_stat: &Vec = &repl_1_stat.get_ref().stats; let repl_nex_stat: &Vec = &repl_nex_stat.get_ref().stats; - let nexus_stat = nexus_stat.get(0).unwrap(); - let pool_0_stat = pool_0_stat.get(0).unwrap(); - let pool_1_stat = pool_1_stat.get(0).unwrap(); - let pool_nex_stat = pool_nex_stat.get(0).unwrap(); - let repl_0_stat = repl_0_stat.get(0).unwrap(); + let nexus_stat = nexus_stat.first().unwrap(); + let pool_0_stat = pool_0_stat.first().unwrap(); + let pool_1_stat = pool_1_stat.first().unwrap(); + let pool_nex_stat = pool_nex_stat.first().unwrap(); + let repl_0_stat = repl_0_stat.first().unwrap(); let repl_0_stat = repl_0_stat.stats.clone().unwrap(); - let repl_1_stat = repl_1_stat.get(0).unwrap(); + let repl_1_stat = repl_1_stat.first().unwrap(); let repl_1_stat = repl_1_stat.stats.clone().unwrap(); - let repl_nex_stat = repl_nex_stat.get(0).unwrap(); + let repl_nex_stat = repl_nex_stat.first().unwrap(); let repl_nex_stat = repl_nex_stat.stats.clone().unwrap(); // Validate non zero num_write_ops. diff --git a/io-engine/tests/snapshot_lvol.rs b/io-engine/tests/snapshot_lvol.rs index 2735b8b66..eca69a9e8 100755 --- a/io-engine/tests/snapshot_lvol.rs +++ b/io-engine/tests/snapshot_lvol.rs @@ -1054,7 +1054,7 @@ async fn test_snapshot_clone() { assert_eq!(1, snapshot_list.len(), "Snapshot Count not matched!!"); let snapshot_lvol = UntypedBdev::lookup_by_uuid_str( snapshot_list - .get(0) + .first() .unwrap() .snapshot_params() .snapshot_uuid() @@ -1227,7 +1227,7 @@ async fn test_snapshot_attr() { assert_eq!(1, snapshot_list.len(), "Snapshot Count not matched!!"); let snapshot_lvol = UntypedBdev::lookup_by_uuid_str( snapshot_list - .get(0) + .first() .unwrap() .snapshot_params() .snapshot_uuid() @@ -1282,7 +1282,7 @@ async fn test_snapshot_attr() { let imported_snapshot_lvol = UntypedBdev::lookup_by_uuid_str( snapshot_list - .get(0) + .first() .unwrap() .snapshot_params() .snapshot_uuid() @@ -1352,8 +1352,7 @@ async fn test_delete_snapshot_with_valid_clone() { assert_eq!(1, snapshot_list.len(), "Snapshot Count not matched!!"); let snapshot_lvol = UntypedBdev::lookup_by_uuid_str( - snapshot_list - .get(0) + snapshot_list.first() .unwrap() .snapshot_params() .snapshot_uuid() @@ -1396,8 +1395,7 @@ async fn test_delete_snapshot_with_valid_clone() { snapshot_lvol.destroy_snapshot().await.ok(); let snapshot_list = Lvol::list_all_lvol_snapshots(None); let snapshot_lvol = UntypedBdev::lookup_by_uuid_str( - snapshot_list - .get(0) + snapshot_list.first() .unwrap() .snapshot_params() .snapshot_uuid() @@ -1477,8 +1475,7 @@ async fn test_delete_snapshot_with_valid_clone_fail_1() { assert_eq!(1, snapshot_list.len(), "Snapshot Count not matched!!"); let snapshot_lvol = UntypedBdev::lookup_by_uuid_str( - snapshot_list - .get(0) + snapshot_list.first() .unwrap() .snapshot_params() .snapshot_uuid() @@ -1506,8 +1503,7 @@ async fn test_delete_snapshot_with_valid_clone_fail_1() { snapshot_lvol.destroy_snapshot().await.ok(); let snapshot_list = Lvol::list_all_lvol_snapshots(None); let snapshot_lvol = UntypedBdev::lookup_by_uuid_str( - snapshot_list - .get(0) + snapshot_list.first() .unwrap() .snapshot_params() .snapshot_uuid() @@ -1666,7 +1662,7 @@ async fn test_snapshot_parent_usage_post_snapshot_destroy() { let snapshot_lvol = UntypedBdev::lookup_by_uuid_str( snapshot_list - .get(0) + .first() .unwrap() .snapshot_params() .snapshot_uuid() @@ -1752,7 +1748,7 @@ async fn test_clone_snapshot_usage_post_clone_destroy() { let snapshot_lvol = UntypedBdev::lookup_by_uuid_str( snapshot_list - .get(0) + .first() .unwrap() .snapshot_params() .snapshot_uuid() diff --git a/io-engine/tests/snapshot_nexus.rs b/io-engine/tests/snapshot_nexus.rs index f71a6886c..2b5b2726f 100755 --- a/io-engine/tests/snapshot_nexus.rs +++ b/io-engine/tests/snapshot_nexus.rs @@ -323,7 +323,7 @@ async fn test_replica_handle_snapshot() { check_replica_snapshot( &snapshot_params_clone, snapshots - .get(0) + .first() .expect("Snapshot is not created on remote replica"), ); } @@ -490,7 +490,7 @@ async fn test_nexus_snapshot() { check_replica_snapshot( &snapshot_params, snapshots - .get(0) + .first() .expect("Snapshot is not created on remote replica"), ); } @@ -579,7 +579,7 @@ async fn test_duplicated_snapshot_uuid_name() { check_replica_snapshot( &snapshot_params_clone, snapshots - .get(0) + .first() .expect("Snapshot is not created on remote replica"), ); } @@ -820,7 +820,7 @@ async fn test_snapshot_ancestor_usage() { 2, "Invalid number of snapshots reported for test volume" ); - let snap1 = snapshots.get(0).expect("Can't get the first sbapshot"); + let snap1 = snapshots.first().expect("Can't get the first sbapshot"); let snap2 = snapshots.get(1).expect("Can't get the second snaoshot"); let (oldest, newest) = if snap1.snapshot_name.eq(SNAP1_NAME) { diff --git a/jsonrpc/Cargo.toml b/jsonrpc/Cargo.toml index 2910b5457..e28562cc5 100644 --- a/jsonrpc/Cargo.toml +++ b/jsonrpc/Cargo.toml @@ -5,11 +5,11 @@ name = "jsonrpc" version = "1.0.0" [dependencies] -nix = "0.27.1" -serde = "1.0.188" -serde_derive = "1.0.188" -serde_json = "1.0.107" -tonic = "0.10.2" -tokio = { version = "1.33.0", features = ["full"] } -tracing = "0.1.37" +nix = "0.29.0" +serde = "1.0.214" +serde_derive = "1.0.214" +serde_json = "1.0.132" +tonic = "0.12.3" +tokio = { version = "1.41.0", features = ["full"] } +tracing = "0.1.40" diff --git a/jsonrpc/src/lib.rs b/jsonrpc/src/lib.rs index 56389ee8c..3eddfd665 100644 --- a/jsonrpc/src/lib.rs +++ b/jsonrpc/src/lib.rs @@ -116,7 +116,7 @@ where 32601 => RpcCode::MethodNotFound, 32602 => RpcCode::InvalidParams, 32603 => RpcCode::InternalError, - value => match Errno::from_i32(value) { + value => match Errno::from_raw(value) { Errno::ENOENT => RpcCode::NotFound, Errno::EEXIST => RpcCode::AlreadyExists, _ => { diff --git a/libnvme-rs/Cargo.toml b/libnvme-rs/Cargo.toml index 1fbf3cd94..288e5428a 100644 --- a/libnvme-rs/Cargo.toml +++ b/libnvme-rs/Cargo.toml @@ -6,25 +6,25 @@ edition = "2018" build = "build.rs" license = "Apache-2.0" authors = [ - "Jonathan Teh ", - "Jeffry Molanus ", + "Jonathan Teh ", + "Jeffry Molanus ", ] [build-dependencies] -bindgen = "0.68.1" -cc = "1.0.83" +bindgen = "0.70.1" +cc = "1.1.31" [dependencies] glob = "0.3.1" libc = "0.2" -snafu = "0.7.5" -url = "2.4.1" +snafu = "0.8.5" +url = "2.5.2" -[dependencies.mio08] +[dependencies.mio] package = "mio" features = ["os-ext"] -version = "0.8" +version = "1.0" [dependencies.udev] features = ["hwdb", "mio"] -version = "^0.8.0" +version = "^0.9.1" diff --git a/libnvme-rs/build.rs b/libnvme-rs/build.rs index 207684cad..b45896fa8 100644 --- a/libnvme-rs/build.rs +++ b/libnvme-rs/build.rs @@ -8,7 +8,7 @@ fn main() { let bindings = bindgen::Builder::default() .header("wrapper.h") - .parse_callbacks(Box::new(bindgen::CargoCallbacks)) + .parse_callbacks(Box::new(bindgen::CargoCallbacks::new())) .layout_tests(false) .generate() .expect("Unable to generate bindings"); diff --git a/libnvme-rs/src/nvme_tree.rs b/libnvme-rs/src/nvme_tree.rs index 26b4e0d8c..45111e716 100644 --- a/libnvme-rs/src/nvme_tree.rs +++ b/libnvme-rs/src/nvme_tree.rs @@ -35,7 +35,7 @@ impl<'a> NvmeHostIterator<'a> { } } -impl<'a> Iterator for NvmeHostIterator<'a> { +impl Iterator for NvmeHostIterator<'_> { type Item = *mut crate::bindings::nvme_host; fn next(&mut self) -> Option { diff --git a/libnvme-rs/src/nvme_uri.rs b/libnvme-rs/src/nvme_uri.rs index 7298011dc..7301371c8 100644 --- a/libnvme-rs/src/nvme_uri.rs +++ b/libnvme-rs/src/nvme_uri.rs @@ -2,7 +2,7 @@ use std::{convert::TryFrom, io, time::Duration}; use url::{ParseError, Url}; -use mio08::{Events, Interest, Poll, Token}; +use mio::{Events, Interest, Poll, Token}; use crate::{ error::NvmeError, diff --git a/scripts/pytest-tests.sh b/scripts/pytest-tests.sh index d0b5164ba..efd5081f9 100755 --- a/scripts/pytest-tests.sh +++ b/scripts/pytest-tests.sh @@ -36,6 +36,15 @@ function clean_all() echo "Done" } +function is_test() +{ + file="${1:-}" + if [ -d "$file" ] || [ -f "$file" ] || [ -f "${file%::*}" ]; then + return 0 + fi + return 1 +} + function run_tests() { while read name extra @@ -95,10 +104,13 @@ while [ "$#" -gt 0 ]; do *) set +e real_1="$(realpath $1 2>/dev/null)" + real_2="$(realpath $SRCDIR/test/python/$1 2>/dev/null)" set -e param="$1" - if [ -d "$real_1" ] || [ -f "$real_1" ] || [ -f "${real_1%::*}" ]; then + if is_test "$real_1"; then param="$real_1" + elif is_test "$real_2"; then + param="$real_2" else TEST_ARGS="${TEST_ARGS:-}$1" fi diff --git a/spdk-rs b/spdk-rs index 77bf9d3ba..d68d9f355 160000 --- a/spdk-rs +++ b/spdk-rs @@ -1 +1 @@ -Subproject commit 77bf9d3bad2441eb6bfba938687c5450de0ddb9b +Subproject commit d68d9f355c7c26386fc34d84ff79ebc61dcef052 diff --git a/sysfs/src/lib.rs b/sysfs/src/lib.rs index d3565dfbe..da94a02ea 100644 --- a/sysfs/src/lib.rs +++ b/sysfs/src/lib.rs @@ -1,10 +1,10 @@ -///! Utility functions for reading and modifying the state of sysfs -/// objects. -use std::path::Path; +//! Utility functions for reading and modifying the state of sysfs +//! objects. use std::{ collections::HashMap, fs, io::{BufRead, BufReader, Error, ErrorKind, Result}, + path::Path, str::FromStr, string, }; diff --git a/test/python/common/nvme.py b/test/python/common/nvme.py index d26455fa9..e0e85e752 100644 --- a/test/python/common/nvme.py +++ b/test/python/common/nvme.py @@ -68,6 +68,7 @@ def nvme_connect(uri, delay=10, tmo=600): command = ( f"nix-sudo nvme connect -t tcp -s {port} -a {host} -n {nqn} -c {delay} -l {tmo}" ) + print(command) subprocess.run(command, check=True, shell=True, capture_output=False) time.sleep(1) command = "nix-sudo nvme list -v -o json" @@ -97,6 +98,43 @@ def nvme_id_ctrl(device): return id_ctrl +def match_host_port(addr, host, port): + traddr = f"traddr={host}" + trsvcid = f"trsvcid={port}" + + return traddr in addr and trsvcid in addr + + +def nvme_find_ctrl(uri): + """Find controller from the device uri.""" + u = urlparse(uri) + port = u.port + host = u.hostname + nqn = u.path[1:] + + command = "nix-sudo nvme list -v -o json" + discover = json.loads( + subprocess.run( + command, shell=True, check=True, text=True, capture_output=True + ).stdout + ) + + # Finds correct Device + devs = list(filter(lambda d: nqn in d.get("SubsystemNQN"), discover.get("Devices"))) + assert len(devs) is 1, "Multiple devices with the same subnqn" + + # Find correct Controller + ctrls = list( + filter( + lambda d: match_host_port(d.get("Address"), host, port), + devs[0].get("Controllers"), + ) + ) + assert len(ctrls) is 1, "Multiple controllers with the same address" + + return ctrls[0].get("Controller") + + def nvme_resv_report(device): """Reservation report.""" command = "nix-sudo nvme resv-report {0} -c 1 -o json".format(device) @@ -129,18 +167,21 @@ def nvme_disconnect(uri): nqn = u.path[1:] command = "nix-sudo nvme disconnect -n {0}".format(nqn) + print(command) subprocess.run(command, check=True, shell=True, capture_output=True) def nvme_disconnect_controller(name): """Disconnect the given NVMe controller on this host.""" command = "nix-sudo nvme disconnect -d {0}".format(name) + print(command) subprocess.run(command, check=True, shell=True, capture_output=True) def nvme_disconnect_all(): """Disconnect from all connected nvme subsystems""" command = "nix-sudo nvme disconnect-all" + print(command) subprocess.run(command, check=True, shell=True, capture_output=True) diff --git a/test/python/pool/test_unmap.py b/test/python/pool/test_unmap.py index 85f27ef55..53d36794c 100644 --- a/test/python/pool/test_unmap.py +++ b/test/python/pool/test_unmap.py @@ -45,7 +45,7 @@ async def mkfs_on_target(target_vm, mayastors): print(await run_cmd_async_at(target_vm, "lsblk -o name,fstype -J")) for d in remote_devices: - await run_cmd_async_at(target_vm, f"sudo mkfs.xfs {d}") + await run_cmd_async_at(target_vm, f"sudo mkfs.xfs -i nrext64=0 {d}") for i in range(0, 15): dev = await nvme_remote_disconnect( diff --git a/test/python/tests/nexus_fault/test_nexus_fault.py b/test/python/tests/nexus_fault/test_nexus_fault.py index d3fd31534..c78e6fd25 100644 --- a/test/python/tests/nexus_fault/test_nexus_fault.py +++ b/test/python/tests/nexus_fault/test_nexus_fault.py @@ -16,7 +16,12 @@ from common.command import run_cmd from common.fio import Fio from common.mayastor import container_mod, mayastor_mod -from common.nvme import nvme_connect, nvme_disconnect, nvme_disconnect_controller +from common.nvme import ( + nvme_connect, + nvme_disconnect, + nvme_disconnect_controller, + nvme_find_ctrl, +) import nexus_pb2 as pb @@ -46,7 +51,7 @@ def _(connect_nexus_1): """a filesystem is placed on top of the connected device.""" device = connect_nexus_1 print(device) - run_cmd(f"sudo mkfs.xfs -f {device}") + run_cmd(f"nix-sudo mkfs.xfs -i nrext64=0 -f {device}") @given( @@ -119,13 +124,12 @@ def _(recreate_pool, republish_nexus_ana): @when("the initiator swaps the nexuses") -def _(recreate_pool, republish_nexus_ana): +def _(publish_nexus, recreate_pool, republish_nexus_ana): """the initiator swaps the nexuses.""" print(republish_nexus_ana) - device = nvme_connect(republish_nexus_ana) - # disconnect previous nexus: /dev/nvme*n* - split_dev = device.split("n") - nvme_disconnect_controller(f"{split_dev[0]}n{split_dev[1]}") + prev_ctrl = nvme_find_ctrl(publish_nexus) + nvme_connect(republish_nexus_ana) + nvme_disconnect_controller(f"/dev/{prev_ctrl}") @then("the fio workload should complete gracefully") diff --git a/utils/dependencies b/utils/dependencies index 0fea7bf87..af74cfcb9 160000 --- a/utils/dependencies +++ b/utils/dependencies @@ -1 +1 @@ -Subproject commit 0fea7bf8744eb51915a2e9d1468a4acf7c61bcdb +Subproject commit af74cfcb94e3eb4071b29a6f09b1adbda15df718