diff --git a/Cargo.lock b/Cargo.lock index 5ebbda6..164f02d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4,11 +4,11 @@ version = 3 [[package]] name = "actix-codec" -version = "0.5.1" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "617a8268e3537fe1d8c9ead925fca49ef6400927ee7bc26750e90ecee14ce4b8" +checksum = "5f7b0a21988c1bf877cf4759ef5ddaac04c1c9fe808c9142ecb78ba97d97a28a" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", "bytes", "futures-core", "futures-sink", @@ -36,9 +36,9 @@ dependencies = [ [[package]] name = "actix-http" -version = "3.5.1" +version = "3.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "129d4c88e98860e1758c5de288d1632b07970a16d59bdf7b8d66053d582bb71f" +checksum = "d223b13fd481fc0d1f83bb12659ae774d9e3601814c68a0bc539731698cca743" dependencies = [ "actix-codec", "actix-rt", @@ -80,7 +80,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e01ed3140b2f8d422c68afa1ed2e85d996ea619c988ac834d255db32138655cb" dependencies = [ "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -146,9 +146,9 @@ dependencies = [ [[package]] name = "actix-web" -version = "4.4.1" +version = "4.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e43428f3bf11dee6d166b00ec2df4e3aa8cc1606aaa0b7433c146852e2f4e03b" +checksum = "43a6556ddebb638c2358714d853257ed226ece6023ef9364f23f0c70737ea984" dependencies = [ "actix-codec", "actix-http", @@ -193,7 +193,7 @@ dependencies = [ "actix-router", "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -213,9 +213,9 @@ checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" [[package]] name = "ahash" -version = "0.8.7" +version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77c3a9648d43b9cd48db467b3f87fdd6e146bcc88ab0180006cef2179fe11d01" +checksum = "42cd52102d3df161c77a887b608d7a4897d7cc112886a9537b738a887a03aaff" dependencies = [ "cfg-if", "getrandom", @@ -332,9 +332,9 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.4" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87" +checksum = "8901269c6307e8d93993578286ac0edf7f195079ffff5ebdeea6a59ffb7e36bc" [[package]] name = "anyhow" @@ -355,13 +355,13 @@ dependencies = [ [[package]] name = "async-channel" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ca33f4bc4ed1babef42cad36cc1f51fa88be00420404e5b1e80ab1b18f7678c" +checksum = "f28243a43d821d11341ab73c80bed182dc015c514b951616cf79bd4af39af0c3" dependencies = [ "concurrent-queue", - "event-listener 4.0.3", - "event-listener-strategy", + "event-listener 5.0.0", + "event-listener-strategy 0.5.0", "futures-core", "pin-project-lite", ] @@ -386,9 +386,9 @@ version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "05b1b633a2115cd122d73b955eadd9916c18c8f510ec9cd1686404c60ad1c29c" dependencies = [ - "async-channel 2.1.1", + "async-channel 2.2.0", "async-executor", - "async-io 2.3.0", + "async-io 2.3.1", "async-lock 3.3.0", "blocking", "futures-lite 2.2.0", @@ -428,9 +428,9 @@ dependencies = [ [[package]] name = "async-io" -version = "2.3.0" +version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb41eb19024a91746eba0773aa5e16036045bbf45733766661099e182ea6a744" +checksum = "8f97ab0c5b00a7cdbe5a371b9a782ee7be1316095885c8a4ea1daf490eb0ef65" dependencies = [ "async-lock 3.3.0", "cfg-if", @@ -438,8 +438,8 @@ dependencies = [ "futures-io", "futures-lite 2.2.0", "parking", - "polling 3.3.2", - "rustix 0.38.30", + "polling 3.4.0", + "rustix 0.38.31", "slab", "tracing", "windows-sys 0.52.0", @@ -461,7 +461,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d034b430882f8381900d3fe6f0aaa3ad94f2cb4ac519b429692a1bc2dda4ae7b" dependencies = [ "event-listener 4.0.3", - "event-listener-strategy", + "event-listener-strategy 0.4.0", "pin-project-lite", ] @@ -496,7 +496,7 @@ checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -513,7 +513,7 @@ checksum = "c980ee35e870bd1a4d2c8294d4c04d0499e67bca1e4b5cefcc693c2fa00caea9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -529,7 +529,7 @@ dependencies = [ "alcoholic_jwt", "async-trait", "configs", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "reqwest", "serde", "serde_json", @@ -545,9 +545,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "aws-config" -version = "1.1.4" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b30c39ebe61f75d1b3785362b1586b41991873c9ab3e317a9181c246fb71d82" +checksum = "7af266887e24cd5f6d2ea7433cacd25dcd4773b7f70e488701968a7cdf51df57" dependencies = [ "aws-credential-types", "aws-runtime", @@ -575,9 +575,9 @@ dependencies = [ [[package]] name = "aws-credential-types" -version = "1.1.4" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33cc49dcdd31c8b6e79850a179af4c367669150c7ac0135f176c61bec81a70f7" +checksum = "2d56f287a9e65e4914bfedb5b22c056b65e4c232fca512d5509a9df36386759f" dependencies = [ "aws-smithy-async", "aws-smithy-runtime-api", @@ -587,9 +587,9 @@ dependencies = [ [[package]] name = "aws-runtime" -version = "1.1.4" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb031bff99877c26c28895766f7bb8484a05e24547e370768d6cc9db514662aa" +checksum = "2d6a29eca8ea8982028a4df81883e7001e250a21d323b86418884b5345950a4b" dependencies = [ "aws-credential-types", "aws-sigv4", @@ -610,9 +610,9 @@ dependencies = [ [[package]] name = "aws-sdk-secretsmanager" -version = "1.14.0" +version = "1.15.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a0b64e61e7d632d9df90a2e0f32630c68c24960cab1d27d848718180af883d3" +checksum = "91a897659278e06f6feaa5fa982b3774ddb593adeec1f7780cfb970cc0b69ef5" dependencies = [ "aws-credential-types", "aws-runtime", @@ -633,9 +633,9 @@ dependencies = [ [[package]] name = "aws-sdk-sso" -version = "1.12.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f486420a66caad72635bc2ce0ff6581646e0d32df02aa39dc983bfe794955a5b" +checksum = "e2d7f527c7b28af1a641f7d89f9e6a4863e8ec00f39d2b731b056fc5ec5ce829" dependencies = [ "aws-credential-types", "aws-runtime", @@ -655,9 +655,9 @@ dependencies = [ [[package]] name = "aws-sdk-ssooidc" -version = "1.12.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39ddccf01d82fce9b4a15c8ae8608211ee7db8ed13a70b514bbfe41df3d24841" +checksum = "0d0be3224cd574ee8ab5fd7c32087876f25c134c27ac603fcb38669ed8d346b0" dependencies = [ "aws-credential-types", "aws-runtime", @@ -677,9 +677,9 @@ dependencies = [ [[package]] name = "aws-sdk-sts" -version = "1.12.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a591f8c7e6a621a501b2b5d2e88e1697fcb6274264523a6ad4d5959889a41ce" +checksum = "5b3167c60d82a13bbaef569da06041644ff41e85c6377e5dad53fa2526ccfe9d" dependencies = [ "aws-credential-types", "aws-runtime", @@ -700,9 +700,9 @@ dependencies = [ [[package]] name = "aws-sigv4" -version = "1.1.4" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c371c6b0ac54d4605eb6f016624fb5c7c2925d315fdf600ac1bf21b19d5f1742" +checksum = "54b1cbe0eee57a213039088dbdeca7be9352f24e0d72332d961e8a1cb388f82d" dependencies = [ "aws-credential-types", "aws-smithy-http", @@ -723,9 +723,9 @@ dependencies = [ [[package]] name = "aws-smithy-async" -version = "1.1.4" +version = "1.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ee2d09cce0ef3ae526679b522835d63e75fb427aca5413cd371e490d52dcc6" +checksum = "8ec441341e019c441aa78472ed6d206cfe198026c495277a95ac5bebda520742" dependencies = [ "futures-util", "pin-project-lite", @@ -734,9 +734,9 @@ dependencies = [ [[package]] name = "aws-smithy-http" -version = "0.60.4" +version = "0.60.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dab56aea3cd9e1101a0a999447fb346afb680ab1406cebc44b32346e25b4117d" +checksum = "85d6a0619f7b67183067fa3b558f94f90753da2df8c04aeb7336d673f804b0b8" dependencies = [ "aws-smithy-runtime-api", "aws-smithy-types", @@ -754,18 +754,18 @@ dependencies = [ [[package]] name = "aws-smithy-json" -version = "0.60.4" +version = "0.60.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd3898ca6518f9215f62678870064398f00031912390efd03f1f6ef56d83aa8e" +checksum = "a1c1b5186b6f5c579bf0de1bcca9dd3d946d6d51361ea1d18131f6a0b64e13ae" dependencies = [ "aws-smithy-types", ] [[package]] name = "aws-smithy-query" -version = "0.60.4" +version = "0.60.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda4b1dfc9810e35fba8a620e900522cd1bd4f9578c446e82f49d1ce41d2e9f9" +checksum = "1c0a2ce65882e788d2cf83ff28b9b16918de0460c47bf66c5da4f6c17b4c9694" dependencies = [ "aws-smithy-types", "urlencoding", @@ -773,9 +773,9 @@ dependencies = [ [[package]] name = "aws-smithy-runtime" -version = "1.1.4" +version = "1.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fafdab38f40ad7816e7da5dec279400dd505160780083759f01441af1bbb10ea" +checksum = "3b36f1f98c8d7b6256b86d4a3c8c4abb120670267baa9712a485ba477eaac9e9" dependencies = [ "aws-smithy-async", "aws-smithy-http", @@ -791,21 +791,22 @@ dependencies = [ "once_cell", "pin-project-lite", "pin-utils", - "rustls", + "rustls 0.21.10", "tokio", "tracing", ] [[package]] name = "aws-smithy-runtime-api" -version = "1.1.4" +version = "1.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c18276dd28852f34b3bf501f4f3719781f4999a51c7bff1a5c6dc8c4529adc29" +checksum = "180898ed701a773fb3fadbd94b9e9559125cf88eeb1815ab99e35d4f5f34f7fb" dependencies = [ "aws-smithy-async", "aws-smithy-types", "bytes", "http 0.2.11", + "http 1.0.0", "pin-project-lite", "tokio", "tracing", @@ -814,9 +815,9 @@ dependencies = [ [[package]] name = "aws-smithy-types" -version = "1.1.4" +version = "1.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb3e134004170d3303718baa2a4eb4ca64ee0a1c0a7041dca31b38be0fb414f3" +checksum = "897f1db4020ad91f2c2421945ec49b7e3eb81cc3fea99e8b5dd5be721e697fed" dependencies = [ "base64-simd", "bytes", @@ -837,18 +838,18 @@ dependencies = [ [[package]] name = "aws-smithy-xml" -version = "0.60.4" +version = "0.60.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8604a11b25e9ecaf32f9aa56b9fe253c5e2f606a3477f0071e96d3155a5ed218" +checksum = "d16f94c9673412b7a72e3c3efec8de89081c320bf59ea12eed34c417a62ad600" dependencies = [ "xmlparser", ] [[package]] name = "aws-types" -version = "1.1.4" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "789bbe008e65636fe1b6dbbb374c40c8960d1232b96af5ff4aec349f9c4accf4" +checksum = "0ff7e122ee50ca962e9de91f5850cc37e2184b1219611eef6d44aa85929b54f6" dependencies = [ "aws-credential-types", "aws-smithy-async", @@ -977,7 +978,7 @@ version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6a37913e8dc4ddcc604f0c6d3bf2887c995153af3611de9e23c352b44c1b9118" dependencies = [ - "async-channel 2.1.1", + "async-channel 2.2.0", "async-lock 3.3.0", "async-task", "fastrand 2.0.1", @@ -1010,9 +1011,9 @@ dependencies = [ [[package]] name = "bumpalo" -version = "3.14.0" +version = "3.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f30e7476521f6f8af1a1c4c0b8cc94f0bee37d91763d0ca2665f299b6cd8aec" +checksum = "d32a994c2b3ca201d9b263612a374263f05e7adde37c4707f693dcd375076d1f" [[package]] name = "byteorder" @@ -1075,9 +1076,9 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "chrono" -version = "0.4.33" +version = "0.4.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f13690e35a5e4ace198e7beea2895d29f3a9cc55015fcebe6336bd2010af9eb" +checksum = "5bc015644b92d5890fab7489e49d21f879d5c990186827d42ec511919404f38b" dependencies = [ "android-tzdata", "iana-time-zone", @@ -1180,9 +1181,9 @@ dependencies = [ [[package]] name = "crc32fast" -version = "1.3.2" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" +checksum = "b3855a8a784b474f333699ef2bbca9db2c4a1f6d9088a90a2d25b1eb53111eaa" dependencies = [ "cfg-if", ] @@ -1307,27 +1308,6 @@ dependencies = [ "subtle", ] -[[package]] -name = "dirs" -version = "5.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44c45a9d03d6676652bcb5e724c7e988de1acad23a711b5217ab9cbecbec2225" -dependencies = [ - "dirs-sys", -] - -[[package]] -name = "dirs-sys" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "520f05a5cbd335fae5a99ff7a6ab8627577660ee5cfd6a94a6a929b52ff0321c" -dependencies = [ - "libc", - "option-ext", - "redox_users", - "windows-sys 0.48.0", -] - [[package]] name = "doc-comment" version = "0.3.3" @@ -1348,9 +1328,9 @@ checksum = "1435fa1053d8b2fbbe9be7e97eca7f33d37b28409959813daefc1446a14247f1" [[package]] name = "either" -version = "1.9.0" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "11157ac094ffbdde99aa67b23417ebdd801842852b500e395a45a9c0aac03e4a" [[package]] name = "encoding_rs" @@ -1394,6 +1374,17 @@ dependencies = [ "pin-project-lite", ] +[[package]] +name = "event-listener" +version = "5.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b72557800024fabbaa2449dd4bf24e37b93702d457a4d4f2b0dd1f0f039f20c1" +dependencies = [ + "concurrent-queue", + "parking", + "pin-project-lite", +] + [[package]] name = "event-listener-strategy" version = "0.4.0" @@ -1404,6 +1395,16 @@ dependencies = [ "pin-project-lite", ] +[[package]] +name = "event-listener-strategy" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "feedafcaa9b749175d5ac357452a9d41ea2911da598fde46ce1fe02c37751291" +dependencies = [ + "event-listener 5.0.0", + "pin-project-lite", +] + [[package]] name = "executor-trait" version = "2.1.0" @@ -1603,7 +1604,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -1697,7 +1698,7 @@ dependencies = [ "futures-sink", "futures-util", "http 0.2.11", - "indexmap 2.1.0", + "indexmap 2.2.3", "slab", "tokio", "tokio-util", @@ -1729,6 +1730,20 @@ dependencies = [ "hashbrown 0.14.3", ] +[[package]] +name = "health-http-server" +version = "0.1.0" +dependencies = [ + "actix-web", + "configs", + "health-readiness", + "http-components", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", + "prometheus", + "thiserror", + "tracing", +] + [[package]] name = "health-readiness" version = "0.1.0" @@ -1743,9 +1758,9 @@ dependencies = [ [[package]] name = "hermit-abi" -version = "0.3.4" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d3d0e0f38255e7fa3cf31335b3a56f05febd18025f4db5ef7a0cfb4f8da651f" +checksum = "bd5256b483761cd23699d0da46cc6fd2ee3be420bbe6d020ae4a091e70b7e9fd" [[package]] name = "hex" @@ -1805,7 +1820,7 @@ dependencies = [ "auth", "futures-util", "health-readiness", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "opentelemetry-prometheus", "opentelemetry-semantic-conventions", "otel", @@ -1826,7 +1841,7 @@ dependencies = [ "configs", "health-readiness", "http-components", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "serde", "serde_json", "thiserror", @@ -1881,10 +1896,10 @@ dependencies = [ "http 0.2.11", "hyper", "log", - "rustls", + "rustls 0.21.10", "rustls-native-certs", "tokio", - "tokio-rustls", + "tokio-rustls 0.24.1", ] [[package]] @@ -1914,9 +1929,9 @@ dependencies = [ [[package]] name = "iana-time-zone" -version = "0.1.59" +version = "0.1.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6a67363e2aa4443928ce15e57ebae94fd8949958fd1223c4cfc0cd473ad7539" +checksum = "e7ffbb5a1b541ea2561f8c41c087286cc091e21e556a4f09a8f6cbf17b69b141" dependencies = [ "android_system_properties", "core-foundation-sys", @@ -1973,9 +1988,9 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.1.0" +version = "2.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" +checksum = "233cf39063f058ea2caae4091bf4a3ef70a653afbc026f5c4a4135d114e3c177" dependencies = [ "equivalent", "hashbrown 0.14.3", @@ -2035,18 +2050,18 @@ checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" [[package]] name = "jobserver" -version = "0.1.27" +version = "0.1.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c37f63953c4c63420ed5fd3d6d398c719489b9f872b9fa683262f8edd363c7d" +checksum = "ab46a6e9526ddef3ae7f787c06f0f2600639ba80ea3eade3d8e670a2230f51d6" dependencies = [ "libc", ] [[package]] name = "js-sys" -version = "0.3.67" +version = "0.3.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a1d36f1235bc969acba30b7f5990b864423a6068a10f7c90ae8f0112e3a59d1" +checksum = "406cda4b368d531c842222cf9d2600a9a4acce8d29423695379c6868a143a9ee" dependencies = [ "wasm-bindgen", ] @@ -2058,7 +2073,7 @@ dependencies = [ "async-trait", "configs", "messaging", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "rdkafka", "tokio", "tracing", @@ -2100,20 +2115,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "libc" -version = "0.2.152" +version = "0.2.153" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13e3bf6590cbc649f4d1a3eefc9d5d6eb746f5200ffb04e5e142700b8faa56e7" - -[[package]] -name = "libredox" -version = "0.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85c833ca1e66078851dba29046874e38f08b2c883700aa29a03ddd3b23814ee8" -dependencies = [ - "bitflags 2.4.2", - "libc", - "redox_syscall", -] +checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" [[package]] name = "libsqlite3-sys" @@ -2222,7 +2226,7 @@ version = "0.1.0" dependencies = [ "async-trait", "mockall", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "thiserror", ] @@ -2231,15 +2235,15 @@ name = "metrics" version = "0.1.0" dependencies = [ "configs", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "opentelemetry-otlp", "opentelemetry-prometheus", "opentelemetry-stdout", - "opentelemetry_sdk", + "opentelemetry_sdk 0.21.2 (registry+https://github.com/rust-lang/crates.io-index)", "prometheus", "thiserror", "tokio", - "tonic", + "tonic 0.11.0", "tracing", ] @@ -2280,9 +2284,9 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" +checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7" dependencies = [ "adler", ] @@ -2323,7 +2327,7 @@ dependencies = [ "cfg-if", "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -2336,7 +2340,7 @@ dependencies = [ "futures-util", "messaging", "mockall", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "paho-mqtt", "serde", "serde_json", @@ -2384,21 +2388,26 @@ dependencies = [ "winapi", ] +[[package]] +name = "num-conv" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" + [[package]] name = "num-integer" -version = "0.1.45" +version = "0.1.46" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" dependencies = [ - "autocfg", "num-traits", ] [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "da0df0e5185db44f69b44f26786fe401b6c293d1907744beaa7fa62b2e5a517a" dependencies = [ "autocfg", ] @@ -2472,7 +2481,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -2501,7 +2510,22 @@ checksum = "1e32339a5dc40459130b3bd269e9892439f55b33e772d2a9d402a789baaf4e8a" dependencies = [ "futures-core", "futures-sink", - "indexmap 2.1.0", + "indexmap 2.2.3", + "js-sys", + "once_cell", + "pin-project-lite", + "thiserror", + "urlencoding", +] + +[[package]] +name = "opentelemetry" +version = "0.21.0" +source = "git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2#ff64e214064df438a09a5c1695ec73866925f981" +dependencies = [ + "futures-core", + "futures-sink", + "indexmap 2.2.3", "js-sys", "once_cell", "pin-project-lite", @@ -2512,31 +2536,29 @@ dependencies = [ [[package]] name = "opentelemetry-otlp" version = "0.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f24cda83b20ed2433c68241f918d0f6fdec8b1d43b7a9590ab4420c5095ca930" +source = "git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2#ff64e214064df438a09a5c1695ec73866925f981" dependencies = [ "async-trait", "futures-core", "http 0.2.11", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "opentelemetry-proto", "opentelemetry-semantic-conventions", - "opentelemetry_sdk", - "prost", + "opentelemetry_sdk 0.21.2 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", + "prost 0.11.9", "thiserror", "tokio", - "tonic", + "tonic 0.9.2", ] [[package]] name = "opentelemetry-prometheus" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f8f082da115b0dcb250829e3ed0b8792b8f963a1ad42466e48422fbe6a079bd" +version = "0.14.0" +source = "git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2#ff64e214064df438a09a5c1695ec73866925f981" dependencies = [ "once_cell", - "opentelemetry", - "opentelemetry_sdk", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", + "opentelemetry_sdk 0.21.2 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "prometheus", "protobuf", ] @@ -2544,35 +2566,32 @@ dependencies = [ [[package]] name = "opentelemetry-proto" version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2e155ce5cc812ea3d1dffbd1539aed653de4bf4882d60e6e04dcf0901d674e1" +source = "git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2#ff64e214064df438a09a5c1695ec73866925f981" dependencies = [ - "opentelemetry", - "opentelemetry_sdk", - "prost", - "tonic", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", + "opentelemetry_sdk 0.21.2 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", + "prost 0.11.9", + "tonic 0.9.2", ] [[package]] name = "opentelemetry-semantic-conventions" version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5774f1ef1f982ef2a447f6ee04ec383981a3ab99c8e77a1a7b30182e65bbc84" +source = "git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2#ff64e214064df438a09a5c1695ec73866925f981" dependencies = [ - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", ] [[package]] name = "opentelemetry-stdout" version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c13b2df4cd59c176099ac82806725ba340c8fa7b1a7004c0912daad30470f63e" +source = "git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2#ff64e214064df438a09a5c1695ec73866925f981" dependencies = [ "async-trait", "chrono", "futures-util", - "opentelemetry", - "opentelemetry_sdk", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", + "opentelemetry_sdk 0.21.2 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "ordered-float", "serde", "serde_json", @@ -2591,7 +2610,7 @@ dependencies = [ "futures-util", "glob", "once_cell", - "opentelemetry", + "opentelemetry 0.21.0 (registry+https://github.com/rust-lang/crates.io-index)", "ordered-float", "percent-encoding", "rand", @@ -2601,10 +2620,25 @@ dependencies = [ ] [[package]] -name = "option-ext" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" +name = "opentelemetry_sdk" +version = "0.21.2" +source = "git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2#ff64e214064df438a09a5c1695ec73866925f981" +dependencies = [ + "async-trait", + "crossbeam-channel", + "futures-channel", + "futures-executor", + "futures-util", + "glob", + "once_cell", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", + "ordered-float", + "percent-encoding", + "rand", + "thiserror", + "tokio", + "tokio-stream", +] [[package]] name = "ordered-float" @@ -2619,7 +2653,7 @@ dependencies = [ name = "otel" version = "0.1.0" dependencies = [ - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", ] [[package]] @@ -2753,7 +2787,7 @@ checksum = "266c042b60c9c76b8d53061e52b2e0d1116abc57cefc8c5cd671619a56ac3690" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -2793,9 +2827,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2900ede94e305130c13ddd391e0ab7cbaeb783945ae07a279c268cb05109c6cb" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" [[package]] name = "polling" @@ -2815,14 +2849,14 @@ dependencies = [ [[package]] name = "polling" -version = "3.3.2" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "545c980a3880efd47b2e262f6a4bb6daad6555cf3367aa9c4e52895f69537a41" +checksum = "30054e72317ab98eddd8561db0f6524df3367636884b7b21b703e4b280a84a14" dependencies = [ "cfg-if", "concurrent-queue", "pin-project-lite", - "rustix 0.38.30", + "rustix 0.38.31", "tracing", "windows-sys 0.52.0", ] @@ -2964,6 +2998,15 @@ dependencies = [ "prost-derive", ] +[[package]] +name = "prost" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "146c289cda302b98a28d40c8b3b90498d6e526dd24ac2ecea73e4e491685b94a" +dependencies = [ + "bytes", +] + [[package]] name = "prost-derive" version = "0.11.9" @@ -3002,7 +3045,7 @@ dependencies = [ "lapin", "messaging", "mockall", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "serde", "serde_json", "thiserror", @@ -3101,17 +3144,6 @@ dependencies = [ "bitflags 1.3.2", ] -[[package]] -name = "redox_users" -version = "0.4.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a18479200779601e498ada4e8c1e1f50e3ee19deb0259c25825a98b5603b2cb4" -dependencies = [ - "getrandom", - "libredox", - "thiserror", -] - [[package]] name = "regex" version = "1.10.3" @@ -3149,9 +3181,9 @@ checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" [[package]] name = "reqwest" -version = "0.11.23" +version = "0.11.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37b1ae8d9ac08420c66222fb9096fc5de435c3c48542bc5336c51892cffafb41" +checksum = "c6920094eb85afde5e4a138be3f2de8bbdf28000f0029e72c45025a56b042251" dependencies = [ "base64 0.21.7", "bytes", @@ -3171,9 +3203,11 @@ dependencies = [ "once_cell", "percent-encoding", "pin-project-lite", + "rustls-pemfile 1.0.4", "serde", "serde_json", "serde_urlencoded", + "sync_wrapper", "system-configuration", "tokio", "tokio-native-tls", @@ -3233,8 +3267,7 @@ dependencies = [ "proc-macro2", "quote", "rust-embed-utils", - "shellexpand", - "syn 2.0.48", + "syn 2.0.49", "walkdir", ] @@ -3279,9 +3312,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.30" +version = "0.38.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "322394588aaf33c24007e8bb3238ee3e4c5c09c084ab32bc73890b99ff326bca" +checksum = "6ea3e1a662af26cd7a3ba09c0297a31af215563ecf42817c98df621387f4e949" dependencies = [ "bitflags 2.4.2", "errno", @@ -3298,10 +3331,24 @@ checksum = "f9d5a6813c0759e4609cd494e8e725babae6a2ca7b62a5536a13daaec6fcb7ba" dependencies = [ "log", "ring", - "rustls-webpki", + "rustls-webpki 0.101.7", "sct", ] +[[package]] +name = "rustls" +version = "0.22.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e87c9956bd9807afa1f77e0f7594af32566e830e088a5576d27c5b6f30f49d41" +dependencies = [ + "log", + "ring", + "rustls-pki-types", + "rustls-webpki 0.102.2", + "subtle", + "zeroize", +] + [[package]] name = "rustls-connector" version = "0.18.5" @@ -3309,9 +3356,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "25da151615461c7347114b1ad1a7458b4cdebc69cb220cd140cd5cb324b1dd37" dependencies = [ "log", - "rustls", + "rustls 0.21.10", "rustls-native-certs", - "rustls-webpki", + "rustls-webpki 0.101.7", ] [[package]] @@ -3321,7 +3368,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a9aace74cb666635c918e9c12bc0d348266037aa8eb599b5cba565709a8dff00" dependencies = [ "openssl-probe", - "rustls-pemfile", + "rustls-pemfile 1.0.4", "schannel", "security-framework", ] @@ -3335,6 +3382,22 @@ dependencies = [ "base64 0.21.7", ] +[[package]] +name = "rustls-pemfile" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c333bb734fcdedcea57de1602543590f545f127dc8b533324318fd492c5c70b" +dependencies = [ + "base64 0.21.7", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "048a63e5b3ac996d78d402940b5fa47973d2d080c6c6fffa1d0f19c4445310b7" + [[package]] name = "rustls-webpki" version = "0.101.7" @@ -3345,6 +3408,17 @@ dependencies = [ "untrusted", ] +[[package]] +name = "rustls-webpki" +version = "0.102.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "faaa0a62740bedb9b2ef5afa303da42764c012f743917351dc9a237ea1663610" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + [[package]] name = "rustversion" version = "1.0.14" @@ -3451,14 +3525,14 @@ checksum = "33c85360c95e7d137454dc81d9a4ed2b8efd8fbe19cee57357b32b9771fccb67" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] name = "serde_json" -version = "1.0.112" +version = "1.0.113" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d1bd37ce2324cf3bf85e5a25f96eb4baf0d5aa6eba43e7ae8958870c4ec48ed" +checksum = "69801b70b1c3dac963ecb03a364ba0ceda9cf60c71cfe475e99864759c8b8a79" dependencies = [ "itoa", "ryu", @@ -3508,15 +3582,6 @@ dependencies = [ "lazy_static", ] -[[package]] -name = "shellexpand" -version = "3.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da03fa3b94cc19e3ebfc88c4229c49d8f08cdbd1228870a45f0ffdf84988e14b" -dependencies = [ - "dirs", -] - [[package]] name = "signal-hook-registry" version = "1.4.1" @@ -3618,9 +3683,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.48" +version = "2.0.49" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "915aea9e586f80826ee59f8453c1101f9d1c4b3964cd2460185ee8e299ada496" dependencies = [ "proc-macro2", "quote", @@ -3663,19 +3728,18 @@ dependencies = [ "cfg-if", "p12", "rustls-connector", - "rustls-pemfile", + "rustls-pemfile 1.0.4", ] [[package]] name = "tempfile" -version = "3.9.0" +version = "3.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01ce4141aa927a6d1bd34a041795abd0db1cccba5d5f24b009f694bdf3a1f3fa" +checksum = "a365e8cd18e44762ef95d87f284f4b5cd04107fec2ff3052bd6a3e6069669e67" dependencies = [ "cfg-if", "fastrand 2.0.1", - "redox_syscall", - "rustix 0.38.30", + "rustix 0.38.31", "windows-sys 0.52.0", ] @@ -3687,22 +3751,22 @@ checksum = "3369f5ac52d5eb6ab48c6b4ffdc8efbcad6b89c765749064ba298f2c68a16a76" [[package]] name = "thiserror" -version = "1.0.56" +version = "1.0.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d54378c645627613241d077a3a79db965db602882668f9136ac42af9ecb730ad" +checksum = "1e45bcbe8ed29775f228095caf2cd67af7a4ccf756ebff23a306bf3e8b47b24b" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.56" +version = "1.0.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa0faa943b50f3db30a20aa7e265dbc66076993efed8463e8de414e5d06d3471" +checksum = "a953cb265bef375dae3de6663da4d3804eee9682ea80d8e2542529b73c531c81" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -3717,12 +3781,13 @@ dependencies = [ [[package]] name = "time" -version = "0.3.31" +version = "0.3.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f657ba42c3f86e7680e53c8cd3af8abbe56b5491790b46e22e19c0d57463583e" +checksum = "c8248b6521bb14bc45b4067159b9b6ad792e2d6d754d6c41fb50e29fefe38749" dependencies = [ "deranged", "itoa", + "num-conv", "powerfmt", "serde", "time-core", @@ -3737,27 +3802,14 @@ checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" [[package]] name = "time-macros" -version = "0.2.16" +version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26197e33420244aeb70c3e8c78376ca46571bc4e701e4791c2cd9f57dcb3a43f" +checksum = "7ba3a3ef41e6672a2f0f001392bb5dcd3ff0a9992d618ca761a11c3121547774" dependencies = [ + "num-conv", "time-core", ] -[[package]] -name = "tiny-server" -version = "0.1.0" -dependencies = [ - "actix-web", - "configs", - "health-readiness", - "http-components", - "opentelemetry", - "prometheus", - "thiserror", - "tracing", -] - [[package]] name = "tinyvec" version = "1.6.0" @@ -3775,9 +3827,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.35.1" +version = "1.36.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c89b4efa943be685f629b149f53829423f8f5531ea21249408e8e2f8671ec104" +checksum = "61285f6515fa018fb2d1e46eb21223fff441ee8db5d0f1435e8ab4f5cdb80931" dependencies = [ "backtrace", "bytes", @@ -3809,7 +3861,7 @@ checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -3854,7 +3906,18 @@ version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" dependencies = [ - "rustls", + "rustls 0.21.10", + "tokio", +] + +[[package]] +name = "tokio-rustls" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "775e0c0f0adb3a2f22a00c4745d728b479985fc15ee7ca6a2608388c5569860f" +dependencies = [ + "rustls 0.22.2", + "rustls-pki-types", "tokio", ] @@ -3895,7 +3958,7 @@ version = "0.19.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" dependencies = [ - "indexmap 2.1.0", + "indexmap 2.2.3", "toml_datetime", "winnow", ] @@ -3920,11 +3983,41 @@ dependencies = [ "hyper-timeout", "percent-encoding", "pin-project", - "prost", + "prost 0.11.9", "rustls-native-certs", - "rustls-pemfile", + "rustls-pemfile 1.0.4", + "tokio", + "tokio-rustls 0.24.1", + "tokio-stream", + "tower", + "tower-layer", + "tower-service", + "tracing", +] + +[[package]] +name = "tonic" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76c4eb7a4e9ef9d4763600161f12f5070b92a578e1b634db88a6887844c91a13" +dependencies = [ + "async-stream", + "async-trait", + "axum", + "base64 0.21.7", + "bytes", + "h2", + "http 0.2.11", + "http-body", + "hyper", + "hyper-timeout", + "percent-encoding", + "pin-project", + "prost 0.12.3", + "rustls-pemfile 2.1.0", + "rustls-pki-types", "tokio", - "tokio-rustls", + "tokio-rustls 0.25.0", "tokio-stream", "tower", "tower-layer", @@ -3969,14 +4062,14 @@ name = "traces" version = "0.1.0" dependencies = [ "configs", - "opentelemetry", + "opentelemetry 0.21.0 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "opentelemetry-otlp", "opentelemetry-stdout", - "opentelemetry_sdk", + "opentelemetry_sdk 0.21.2 (git+ssh://git@github.com/open-telemetry/opentelemetry-rust.git?rev=v0.21.2)", "serde", "thiserror", "tokio", - "tonic", + "tonic 0.11.0", "tracing", ] @@ -4000,7 +4093,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] @@ -4138,7 +4231,7 @@ version = "4.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "272ebdfbc99111033031d2f10e018836056e4d2c8e2acda76450ec7974269fa7" dependencies = [ - "indexmap 2.1.0", + "indexmap 2.2.3", "serde", "serde_json", "utoipa-gen", @@ -4154,14 +4247,14 @@ dependencies = [ "proc-macro2", "quote", "regex", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] name = "utoipa-swagger-ui" -version = "5.0.0" +version = "6.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f839caa8e09dddc3ff1c3112a91ef7da0601075ba5025d9f33ae99c4cb9b6e51" +checksum = "0b39868d43c011961e04b41623e050aedf2cc93652562ff7935ce0f819aaf2da" dependencies = [ "actix-web", "mime_guess", @@ -4287,9 +4380,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.90" +version = "0.2.91" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1223296a201415c7fad14792dbefaace9bd52b62d33453ade1c5b5f07555406" +checksum = "c1e124130aee3fb58c5bdd6b639a0509486b0338acaaae0c84a5124b0f588b7f" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -4297,24 +4390,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.90" +version = "0.2.91" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcdc935b63408d58a32f8cc9738a0bffd8f05cc7c002086c6ef20b7312ad9dcd" +checksum = "c9e7e1900c352b609c8488ad12639a311045f40a35491fb69ba8c12f758af70b" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.40" +version = "0.4.41" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde2032aeb86bdfaecc8b261eef3cba735cc426c1f3a3416d1e0791be95fc461" +checksum = "877b9c3f61ceea0e56331985743b13f3d25c406a7098d45180fb5f09bc19ed97" dependencies = [ "cfg-if", "js-sys", @@ -4324,9 +4417,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.90" +version = "0.2.91" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e4c238561b2d428924c49815533a8b9121c664599558a5d9ec51f8a1740a999" +checksum = "b30af9e2d358182b5c7449424f017eba305ed32a7010509ede96cdc4696c46ed" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -4334,28 +4427,28 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.90" +version = "0.2.91" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bae1abb6806dc1ad9e560ed242107c0f6c84335f1749dd4e8ddb012ebd5e25a7" +checksum = "642f325be6301eb8107a83d12a8ac6c1e1c54345a7ef1a9261962dfefda09e66" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.90" +version = "0.2.91" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d91413b1c31d7539ba5ef2451af3f0b833a005eb27a631cec32bc0635a8602b" +checksum = "4f186bd2dcf04330886ce82d6f33dd75a7bfcf69ecf5763b89fcde53b6ac9838" [[package]] name = "web-sys" -version = "0.3.67" +version = "0.3.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58cd2333b6e0be7a39605f0e255892fd7418a682d8da8fe042fe25128794d2ed" +checksum = "96565907687f7aceb35bc5fc03770a8a0471d82e479f25832f54a0e3f4b28446" dependencies = [ "js-sys", "wasm-bindgen", @@ -4545,9 +4638,9 @@ checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" [[package]] name = "winnow" -version = "0.5.35" +version = "0.5.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1931d78a9c73861da0134f453bb1f790ce49b2e30eba8410b4b79bac72b46a2d" +checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" dependencies = [ "memchr", ] @@ -4591,7 +4684,7 @@ checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.49", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 9cb79b5..9143db9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -7,17 +7,27 @@ members = [ "messaging", "rabbitmq", "kafka", - "auth", - "health_readiness", "http_components", + "health_readiness", + "health_http_server", "http_server", - "tiny_server", "logging", "metrics", "migrator", "mqtt", - "otel", "secrets_manager", "sql_pool", "traces", -] \ No newline at end of file + "auth", +] + +[workspace.dependencies] +thiserror = { version = "1.0.57" } +serde = { version = "1.0.196" } +serde_json = { version = "1.0.113" } +tokio = { version = "1.36.0" } +async-trait = { version = "0.1.77" } +tracing = { version = "0.1.40" } +opentelemetry = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2" } +opentelemetry_sdk = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2" } +tonic = { version = "0.11.0" } \ No newline at end of file diff --git a/auth/Cargo.toml b/auth/Cargo.toml index 6490055..a44970e 100644 --- a/auth/Cargo.toml +++ b/auth/Cargo.toml @@ -6,11 +6,11 @@ edition = "2021" [dependencies] configs = { path = "../configs" } -serde = { version = "1.0.196", features = ["derive"] } -serde_json = { version = "1.0.112" } -tracing = { version = "0.1.40" } -async-trait = { version = "0.1.77" } -opentelemetry = { version = "0.21.0" } -alcoholic_jwt = { version = "4091.0.0 " } -tokio = { version = "1.35.1", features = ["sync"] } -reqwest = { version = "0.11.23", features = ["json"] } \ No newline at end of file +serde = { workspace = true, features = ["derive"] } +serde_json = { workspace = true } +tracing = { workspace = true } +async-trait = { workspace = true } +opentelemetry = { workspace = true } +tokio = { workspace = true, features = ["sync"] } +alcoholic_jwt = { version = "4091.0.0" } +reqwest = { version = "0.11.24", features = ["json"] } \ No newline at end of file diff --git a/configs/src/environment.rs b/configs/src/environment.rs index 788348e..ab88454 100644 --- a/configs/src/environment.rs +++ b/configs/src/environment.rs @@ -51,13 +51,4 @@ impl Environment { pub fn is_prod(&self) -> bool { self == &Environment::Prod } - - pub fn filename(&self) -> String { - match *self { - Environment::Local => ".env.local".into(), - Environment::Dev => ".env.develop".into(), - Environment::Staging => ".env.staging".into(), - Environment::Prod => ".env.prod".into(), - } - } } diff --git a/configs_builder/Cargo.toml b/configs_builder/Cargo.toml index b1602a7..3fe955a 100644 --- a/configs_builder/Cargo.toml +++ b/configs_builder/Cargo.toml @@ -8,7 +8,7 @@ configs = { path = "../configs" } secrets-manager = { path = "../secrets_manager" } logging = { path = "../logging" } +thiserror = { workspace = true } +tracing = { workspace = true } dotenvy = { version = "0.15.7" } base64 = { version = "0.21.7" } -tracing = { version = "0.1.40" } -thiserror = { version = "1.0.56" } diff --git a/configs_builder/src/configs_builder.rs b/configs_builder/src/configs_builder.rs index fc46909..bb7afb3 100644 --- a/configs_builder/src/configs_builder.rs +++ b/configs_builder/src/configs_builder.rs @@ -3,22 +3,22 @@ use crate::{ APP_NAME_ENV_KEY, APP_PORT_ENV_KEY, AUTH0_AUDIENCE_ENV_KEY, AUTH0_CLIENT_ID_ENV_KEY, AUTH0_CLIENT_SECRET_ENV_KEY, AUTH0_DOMAIN_ENV_KEY, AUTH0_GRANT_TYPE_ENV_KEY, AUTH0_ISSUER_ENV_KEY, AWS_DEFAULT_REGION, AWS_IAM_ACCESS_KEY_ID, AWS_IAM_SECRET_ACCESS_KEY, - DYNAMO_ENDPOINT_ENV_KEY, DYNAMO_EXPIRE_ENV_KEY, DYNAMO_REGION_ENV_KEY, + DEV_ENV_FILE_NAME, DYNAMO_ENDPOINT_ENV_KEY, DYNAMO_EXPIRE_ENV_KEY, DYNAMO_REGION_ENV_KEY, DYNAMO_TABLE_ENV_KEY, ENABLE_HEALTH_READINESS_ENV_KEY, ENABLE_METRICS_ENV_KEY, ENABLE_TRACES_ENV_KEY, HEALTH_READINESS_PORT_ENV_KEY, HOST_NAME_ENV_KEY, KAFKA_HOST_ENV_KEY, KAFKA_PASSWORD_ENV_KEY, KAFKA_PORT_ENV_KEY, KAFKA_SASL_MECHANISMS_ENV_KEY, KAFKA_SECURITY_PROTOCOL_ENV_KEY, KAFKA_TIMEOUT_ENV_KEY, - KAFKA_USER_ENV_KEY, LOG_LEVEL_ENV_KEY, METRIC_ACCESS_KEY_ENV_KEY, METRIC_EXPORTER_ENV_KEY, - METRIC_EXPORT_RATE_BASE_ENV_KEY, METRIC_EXPORT_TIMEOUT_ENV_KEY, + KAFKA_USER_ENV_KEY, LOCAL_ENV_FILE_NAME, LOG_LEVEL_ENV_KEY, METRIC_ACCESS_KEY_ENV_KEY, + METRIC_EXPORTER_ENV_KEY, METRIC_EXPORT_RATE_BASE_ENV_KEY, METRIC_EXPORT_TIMEOUT_ENV_KEY, METRIC_HEADER_ACCESS_KEY_ENV_KEY, METRIC_HOST_ENV_KEY, METRIC_SERVICE_TYPE_ENV_KEY, MQTT_BROKER_KIND_ENV_KEY, MQTT_CA_CERT_PATH_ENV_KEY, MQTT_HOST_ENV_KEY, MQTT_PASSWORD_ENV_KEY, MQTT_PORT_ENV_KEY, MQTT_TRANSPORT_ENV_KEY, MQTT_USER_ENV_KEY, POSTGRES_DB_ENV_KEY, POSTGRES_HOST_ENV_KEY, POSTGRES_PASSWORD_ENV_KEY, - POSTGRES_PORT_ENV_KEY, POSTGRES_USER_ENV_KEY, RABBITMQ_HOST_ENV_KEY, + POSTGRES_PORT_ENV_KEY, POSTGRES_USER_ENV_KEY, PROD_FILE_NAME, RABBITMQ_HOST_ENV_KEY, RABBITMQ_PASSWORD_ENV_KEY, RABBITMQ_PORT_ENV_KEY, RABBITMQ_USER_ENV_KEY, RABBITMQ_VHOST_ENV_KEY, SECRET_KEY_ENV_KEY, SECRET_MANAGER_ENV_KEY, SECRET_PREFIX, - SQLITE_FILE_NAME_ENV_KEY, TRACE_ACCESS_KEY_ENV_KEY, TRACE_EXPORTER_ENV_KEY, - TRACE_EXPORT_RATE_BASE_ENV_KEY, TRACE_EXPORT_TIMEOUT_ENV_KEY, + SQLITE_FILE_NAME_ENV_KEY, STAGING_FILE_NAME, TRACE_ACCESS_KEY_ENV_KEY, + TRACE_EXPORTER_ENV_KEY, TRACE_EXPORT_RATE_BASE_ENV_KEY, TRACE_EXPORT_TIMEOUT_ENV_KEY, TRACE_HEADER_ACCESS_KEY_ENV_KEY, TRACE_HOST_ENV_KEY, TRACE_SERVICE_TYPE_ENV_KEY, }, errors::ConfigsError, @@ -33,8 +33,9 @@ use secrets_manager::{AWSSecretClientBuilder, FakeSecretClient, SecretClient}; use std::{env, str::FromStr, sync::Arc}; use tracing::error; +#[derive(Default)] pub struct ConfigBuilder { - client: Arc, + client: Option>, mqtt: bool, rabbitmq: bool, kafka: bool, @@ -45,25 +46,12 @@ pub struct ConfigBuilder { metric: bool, trace: bool, health: bool, - identity: bool, + auth0: bool, } impl ConfigBuilder { pub fn new() -> ConfigBuilder { - ConfigBuilder { - client: Arc::new(FakeSecretClient::new()), - mqtt: false, - rabbitmq: false, - kafka: false, - postgres: false, - sqlite: false, - aws: false, - dynamo: false, - metric: false, - trace: false, - health: false, - identity: false, - } + ConfigBuilder::default() } pub fn mqtt(mut self) -> Self { @@ -116,8 +104,8 @@ impl ConfigBuilder { self } - pub fn identity(mut self) -> Self { - self.identity = true; + pub fn auth0(mut self) -> Self { + self.auth0 = true; self } @@ -126,7 +114,20 @@ impl ConfigBuilder { T: DynamicConfigs, { let env = Environment::from_rust_env(); - from_filename(format!("./{}", env.filename())).ok(); + match env { + Environment::Prod => { + from_filename(PROD_FILE_NAME).ok(); + } + Environment::Staging => { + from_filename(STAGING_FILE_NAME).ok(); + } + Environment::Dev => { + from_filename(DEV_ENV_FILE_NAME).ok(); + } + _ => { + from_filename(LOCAL_ENV_FILE_NAME).ok(); + } + } let mut cfg = Configs::::default(); self.fill_app(&mut cfg); @@ -138,40 +139,40 @@ impl ConfigBuilder { cfg.dynamic.load(); - self.get_secret_client(&cfg.app).await?; + self.client = self.get_secret_client(&cfg.app).await?; for (key, value) in env::vars() { - if self.identity && self.fill_identity(&mut cfg, &key, &value) { + if self.fill_auth0(&mut cfg, &key, &value) { continue; }; - if self.mqtt && self.fill_mqtt(&mut cfg, &key, &value) { + if self.fill_mqtt(&mut cfg, &key, &value) { continue; }; - if self.rabbitmq && self.fill_rabbitmq(&mut cfg, &key, &value) { + if self.fill_rabbitmq(&mut cfg, &key, &value) { continue; }; - if self.kafka && self.fill_kafka(&mut cfg, &key, &value) { + if self.fill_kafka(&mut cfg, &key, &value) { continue; }; - if self.trace && self.fill_trace(&mut cfg, &key, &value) { + if self.fill_trace(&mut cfg, &key, &value) { continue; } - if self.metric && self.fill_metric(&mut cfg, &key, &value) { + if self.fill_metric(&mut cfg, &key, &value) { continue; } - if self.postgres && self.fill_postgres(&mut cfg, &key, &value) { + if self.fill_postgres(&mut cfg, &key, &value) { continue; }; - if self.dynamo && self.fill_dynamo(&mut cfg, &key, &value) { + if self.fill_dynamo(&mut cfg, &key, &value) { continue; }; - if self.aws && self.fill_aws(&mut cfg, &key, &value) { + if self.fill_aws(&mut cfg, &key, &value) { continue; }; - if self.health && self.fill_health_readiness(&mut cfg, &key, &value) { + if self.fill_health_readiness(&mut cfg, &key, &value) { continue; }; - if self.sqlite && self.fill_sqlite(&mut cfg, &key, &value) { + if self.fill_sqlite(&mut cfg, &key, &value) { continue; }; } @@ -181,10 +182,13 @@ impl ConfigBuilder { } impl ConfigBuilder { - async fn get_secret_client(&mut self, app_cfg: &AppConfigs) -> Result<(), ConfigsError> { + async fn get_secret_client( + &self, + app_cfg: &AppConfigs, + ) -> Result>, ConfigsError> { match app_cfg.secret_manager { SecretsManagerKind::None => { - return Ok(()); + return Ok(Some(Arc::new(FakeSecretClient::new()))); } SecretsManagerKind::AWSSecretManager => { @@ -194,10 +198,7 @@ impl ConfigBuilder { .build() .await { - Ok(c) => { - self.client = Arc::new(c); - Ok(()) - } + Ok(c) => Ok(Some(Arc::new(c))), Err(err) => { error!(error = err.to_string(), "error to create aws secret client"); Err(ConfigsError::SecretLoadingError(err.to_string())) @@ -222,7 +223,7 @@ impl ConfigBuilder { .parse() .unwrap_or_default(); let log_level = env::var(LOG_LEVEL_ENV_KEY).unwrap_or("debug".into()); - let secret_manager = env::var(SECRET_MANAGER_ENV_KEY).unwrap_or("NONE".into()); + let secret_manager = env::var(SECRET_MANAGER_ENV_KEY).unwrap_or("None".into()); cfg.app = AppConfigs { enable_external_creates_logging: false, @@ -246,37 +247,37 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - ENABLE_METRICS_ENV_KEY => { + ENABLE_METRICS_ENV_KEY if self.metric => { cfg.metric.enable = self.get_from_secret(value.into(), false); true } - METRIC_EXPORTER_ENV_KEY => { + METRIC_EXPORTER_ENV_KEY if self.metric => { cfg.metric.exporter = self.get_from_secret(value.into(), MetricExporterKind::Stdout); true } - METRIC_HOST_ENV_KEY => { + METRIC_HOST_ENV_KEY if self.metric => { cfg.metric.host = self.get_from_secret(value.into(), "localhost".into()); true } - METRIC_HEADER_ACCESS_KEY_ENV_KEY => { + METRIC_HEADER_ACCESS_KEY_ENV_KEY if self.metric => { cfg.metric.header_access_key = self.get_from_secret(value.into(), "api-key".into()); true } - METRIC_ACCESS_KEY_ENV_KEY => { + METRIC_ACCESS_KEY_ENV_KEY if self.metric => { cfg.metric.access_key = self.get_from_secret(value.into(), "key".into()); true } - METRIC_SERVICE_TYPE_ENV_KEY => { + METRIC_SERVICE_TYPE_ENV_KEY if self.metric => { cfg.metric.service_type = self.get_from_secret(value.into(), "service".into()); true } - METRIC_EXPORT_TIMEOUT_ENV_KEY => { + METRIC_EXPORT_TIMEOUT_ENV_KEY if self.metric => { let k: String = value.into(); cfg.metric.export_timeout = self.get_from_secret(k.clone(), 30); true } - METRIC_EXPORT_RATE_BASE_ENV_KEY => { + METRIC_EXPORT_RATE_BASE_ENV_KEY if self.metric => { cfg.metric.export_rate_base = self.get_from_secret(value.into(), 0.8); true } @@ -294,36 +295,36 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - ENABLE_TRACES_ENV_KEY => { + ENABLE_TRACES_ENV_KEY if self.trace => { cfg.trace.enable = self.get_from_secret(value.into(), false); true } - TRACE_EXPORTER_ENV_KEY => { + TRACE_EXPORTER_ENV_KEY if self.trace => { cfg.trace.exporter = self.get_from_secret(value.into(), TraceExporterKind::Stdout); true } - TRACE_HOST_ENV_KEY => { + TRACE_HOST_ENV_KEY if self.trace => { cfg.trace.host = self.get_from_secret(value.into(), "localhost".into()); true } - TRACE_HEADER_ACCESS_KEY_ENV_KEY => { + TRACE_HEADER_ACCESS_KEY_ENV_KEY if self.trace => { cfg.trace.header_access_key = self.get_from_secret(value.into(), "api-key".into()); true } - TRACE_ACCESS_KEY_ENV_KEY => { + TRACE_ACCESS_KEY_ENV_KEY if self.trace => { cfg.trace.access_key = self.get_from_secret(value.into(), "key".into()); true } - TRACE_SERVICE_TYPE_ENV_KEY => { + TRACE_SERVICE_TYPE_ENV_KEY if self.trace => { cfg.trace.service_type = self.get_from_secret(value.into(), "service".into()); true } - TRACE_EXPORT_TIMEOUT_ENV_KEY => { + TRACE_EXPORT_TIMEOUT_ENV_KEY if self.trace => { let k: String = value.into(); cfg.trace.export_timeout = self.get_from_secret(k.clone(), 30); true } - TRACE_EXPORT_RATE_BASE_ENV_KEY => { + TRACE_EXPORT_RATE_BASE_ENV_KEY if self.trace => { cfg.trace.export_rate_base = self.get_from_secret(value.into(), 0.8); true } @@ -331,7 +332,7 @@ impl ConfigBuilder { } } - fn fill_identity( + fn fill_auth0( &self, cfg: &mut Configs, key: impl Into, @@ -341,28 +342,28 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - AUTH0_DOMAIN_ENV_KEY => { + AUTH0_DOMAIN_ENV_KEY if self.auth0 => { cfg.auth0.domain = self.get_from_secret(value.into(), "localhost".into()); true } - AUTH0_AUDIENCE_ENV_KEY => { + AUTH0_AUDIENCE_ENV_KEY if self.auth0 => { cfg.auth0.audience = self.get_from_secret(value.into(), "localhost".into()); true } - AUTH0_ISSUER_ENV_KEY => { + AUTH0_ISSUER_ENV_KEY if self.auth0 => { cfg.auth0.issuer = self.get_from_secret(value.into(), "localhost".into()); true } - AUTH0_GRANT_TYPE_ENV_KEY => { + AUTH0_GRANT_TYPE_ENV_KEY if self.auth0 => { cfg.auth0.grant_type = self.get_from_secret(value.into(), "client_credentials".into()); true } - AUTH0_CLIENT_ID_ENV_KEY => { + AUTH0_CLIENT_ID_ENV_KEY if self.auth0 => { cfg.auth0.client_id = self.get_from_secret(value.into(), "".into()); true } - AUTH0_CLIENT_SECRET_ENV_KEY => { + AUTH0_CLIENT_SECRET_ENV_KEY if self.auth0 => { cfg.auth0.client_secret = self.get_from_secret(value.into(), "".into()); true } @@ -380,33 +381,33 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - MQTT_BROKER_KIND_ENV_KEY => { + MQTT_BROKER_KIND_ENV_KEY if self.mqtt => { let kind = self.get_from_secret::(value.into(), "SELF_HOSTED".into()); cfg.mqtt.broker_kind = MQTTBrokerKind::from(&kind); true } - MQTT_HOST_ENV_KEY => { + MQTT_HOST_ENV_KEY if self.mqtt => { cfg.mqtt.host = self.get_from_secret(value.into(), "localhost".into()); true } - MQTT_TRANSPORT_ENV_KEY => { + MQTT_TRANSPORT_ENV_KEY if self.mqtt => { let transport = self.get_from_secret::(value.into(), "tcp".into()); cfg.mqtt.transport = MQTTTransport::from(&transport); true } - MQTT_PORT_ENV_KEY => { + MQTT_PORT_ENV_KEY if self.mqtt => { cfg.mqtt.port = self.get_from_secret(value.into(), 1883); true } - MQTT_USER_ENV_KEY => { + MQTT_USER_ENV_KEY if self.mqtt => { cfg.mqtt.user = self.get_from_secret(value.into(), "mqtt".into()); true } - MQTT_PASSWORD_ENV_KEY => { + MQTT_PASSWORD_ENV_KEY if self.mqtt => { cfg.mqtt.password = self.get_from_secret(value.into(), "password".into()); true } - MQTT_CA_CERT_PATH_ENV_KEY => { + MQTT_CA_CERT_PATH_ENV_KEY if self.mqtt => { cfg.mqtt.root_ca_path = self.get_from_secret(value.into(), "".into()); true } @@ -424,23 +425,23 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - RABBITMQ_HOST_ENV_KEY => { + RABBITMQ_HOST_ENV_KEY if self.rabbitmq => { cfg.rabbitmq.host = self.get_from_secret(value.into(), "localhost".into()); true } - RABBITMQ_PORT_ENV_KEY => { + RABBITMQ_PORT_ENV_KEY if self.rabbitmq => { cfg.rabbitmq.port = self.get_from_secret(value.into(), 5672); true } - RABBITMQ_USER_ENV_KEY => { + RABBITMQ_USER_ENV_KEY if self.rabbitmq => { cfg.rabbitmq.user = self.get_from_secret(value.into(), "guest".into()); true } - RABBITMQ_PASSWORD_ENV_KEY => { + RABBITMQ_PASSWORD_ENV_KEY if self.rabbitmq => { cfg.rabbitmq.password = self.get_from_secret(value.into(), "guest".into()); true } - RABBITMQ_VHOST_ENV_KEY => { + RABBITMQ_VHOST_ENV_KEY if self.rabbitmq => { cfg.rabbitmq.vhost = self.get_from_secret(value.into(), "".into()); true } @@ -458,31 +459,31 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - KAFKA_HOST_ENV_KEY => { + KAFKA_HOST_ENV_KEY if self.kafka => { cfg.kafka.host = self.get_from_secret(value.into(), "localhost".into()); true } - KAFKA_PORT_ENV_KEY => { + KAFKA_PORT_ENV_KEY if self.kafka => { cfg.kafka.port = self.get_from_secret(value.into(), 9094); true } - KAFKA_TIMEOUT_ENV_KEY => { + KAFKA_TIMEOUT_ENV_KEY if self.kafka => { cfg.kafka.timeout = self.get_from_secret(value.into(), 6000); true } - KAFKA_SECURITY_PROTOCOL_ENV_KEY => { + KAFKA_SECURITY_PROTOCOL_ENV_KEY if self.kafka => { cfg.kafka.security_protocol = self.get_from_secret(value.into(), "SASL_SSL".into()); true } - KAFKA_SASL_MECHANISMS_ENV_KEY => { + KAFKA_SASL_MECHANISMS_ENV_KEY if self.kafka => { cfg.kafka.sasl_mechanisms = self.get_from_secret(value.into(), "PLAIN".into()); true } - KAFKA_USER_ENV_KEY => { + KAFKA_USER_ENV_KEY if self.kafka => { cfg.kafka.user = self.get_from_secret(value.into(), "user".into()); true } - KAFKA_PASSWORD_ENV_KEY => { + KAFKA_PASSWORD_ENV_KEY if self.kafka => { cfg.kafka.password = self.get_from_secret(value.into(), "password".into()); true } @@ -500,23 +501,23 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - POSTGRES_HOST_ENV_KEY => { + POSTGRES_HOST_ENV_KEY if self.postgres => { cfg.postgres.host = self.get_from_secret(value.into(), "localhost".into()); true } - POSTGRES_USER_ENV_KEY => { + POSTGRES_USER_ENV_KEY if self.postgres => { cfg.postgres.user = self.get_from_secret(value.into(), "postgres".into()); true } - POSTGRES_PASSWORD_ENV_KEY => { + POSTGRES_PASSWORD_ENV_KEY if self.postgres => { cfg.postgres.password = self.get_from_secret(value.into(), "postgres".into()); true } - POSTGRES_PORT_ENV_KEY => { + POSTGRES_PORT_ENV_KEY if self.postgres => { cfg.postgres.port = self.get_from_secret(value.into(), 5432); true } - POSTGRES_DB_ENV_KEY => { + POSTGRES_DB_ENV_KEY if self.postgres => { cfg.postgres.db = self.get_from_secret(value.into(), "hdr".into()); true } @@ -534,19 +535,19 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - DYNAMO_ENDPOINT_ENV_KEY => { + DYNAMO_ENDPOINT_ENV_KEY if self.dynamo => { cfg.dynamo.endpoint = self.get_from_secret(value.into(), "localhost".into()); true } - DYNAMO_TABLE_ENV_KEY => { + DYNAMO_TABLE_ENV_KEY if self.dynamo => { cfg.dynamo.table = self.get_from_secret(value.into(), "table".into()); true } - DYNAMO_REGION_ENV_KEY => { + DYNAMO_REGION_ENV_KEY if self.dynamo => { cfg.dynamo.region = self.get_from_secret(value.into(), AWS_DEFAULT_REGION.into()); true } - DYNAMO_EXPIRE_ENV_KEY => { + DYNAMO_EXPIRE_ENV_KEY if self.dynamo => { cfg.dynamo.expire = self.get_from_secret(value.into(), 31536000); true } @@ -564,11 +565,11 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - AWS_IAM_ACCESS_KEY_ID => { + AWS_IAM_ACCESS_KEY_ID if self.aws => { cfg.aws.access_key_id = Some(self.get_from_secret(value.into(), "key".into())); true } - AWS_IAM_SECRET_ACCESS_KEY => { + AWS_IAM_SECRET_ACCESS_KEY if self.aws => { cfg.aws.secret_access_key = Some(self.get_from_secret(value.into(), "secret".into())); true @@ -587,11 +588,11 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - HEALTH_READINESS_PORT_ENV_KEY => { + HEALTH_READINESS_PORT_ENV_KEY if self.health => { cfg.health_readiness.port = self.get_from_secret(value.into(), 8888); true } - ENABLE_HEALTH_READINESS_ENV_KEY => { + ENABLE_HEALTH_READINESS_ENV_KEY if self.health => { cfg.health_readiness.enable = self.get_from_secret(value.into(), false); true } @@ -609,15 +610,15 @@ impl ConfigBuilder { T: DynamicConfigs, { match key.into().as_str() { - SQLITE_FILE_NAME_ENV_KEY => { + SQLITE_FILE_NAME_ENV_KEY if self.sqlite => { cfg.sqlite.file = self.get_from_secret(value.into(), "local.db".into()); true } - "SQLITE_USER" => { + "SQLITE_USER" if self.sqlite => { cfg.sqlite.user = self.get_from_secret(value.into(), "user".into()); true } - "SQLITE_PASSWORD" => { + "SQLITE_PASSWORD" if self.sqlite => { cfg.sqlite.password = self.get_from_secret(value.into(), "password".into()); true } @@ -627,21 +628,21 @@ impl ConfigBuilder { } impl ConfigBuilder { - fn get_from_secret(&self, value: String, default: T) -> T + fn get_from_secret(&self, key: String, default: T) -> T where T: FromStr, { - if !value.starts_with(SECRET_PREFIX) { - return value.parse().unwrap_or(default); + if !key.starts_with(SECRET_PREFIX) { + return key.parse().unwrap_or(default); } - let Ok(secret) = self.client.clone().get_by_key(&value) else { - error!(secret_key = value, "secret key was not found"); + let Ok(v) = self.client.clone().unwrap().get_by_key(&key) else { + error!(key = key, "secret key was not found"); return default; }; - secret.parse().unwrap_or_else(|_| { - error!(secret_key = value, secret = secret, "parse went wrong"); + v.parse().unwrap_or_else(|_| { + error!(key = key, value = v, "parse went wrong"); return default; }) } diff --git a/configs_builder/src/env_keys.rs b/configs_builder/src/env_keys.rs index d98fa03..b1999c3 100644 --- a/configs_builder/src/env_keys.rs +++ b/configs_builder/src/env_keys.rs @@ -1,3 +1,8 @@ +pub const LOCAL_ENV_FILE_NAME: &str = "./.env.local"; +pub const DEV_ENV_FILE_NAME: &str = "./.env.develop"; +pub const STAGING_FILE_NAME: &str = "./.env.staging"; +pub const PROD_FILE_NAME: &str = "./.env.prod"; + pub const SECRET_PREFIX: &str = "!"; pub const SECRET_PREFIX_TO_DECODE: &str = "!!"; diff --git a/health_readiness/Cargo.toml b/health_readiness/Cargo.toml index da153c0..bbcb339 100644 --- a/health_readiness/Cargo.toml +++ b/health_readiness/Cargo.toml @@ -9,12 +9,12 @@ rabbitmq = ["dep:lapin"] postgres = ["dep:deadpool-postgres"] [dependencies] -async-trait = { version = "0.1.77" } -tracing = { version = "0.1.40" } -thiserror = { version = "1.0.56" } +async-trait = { workspace = true } +tracing = { workspace = true } +thiserror = { workspace = true } # mqtt -paho-mqtt = { version = "0.12.1", optional = true } +paho-mqtt = { version = "0.12.3", optional = true } # rabbitmq lapin = { version = "2.3.1", optional = true } diff --git a/http_components/Cargo.toml b/http_components/Cargo.toml index 29176bb..ab5b5b9 100644 --- a/http_components/Cargo.toml +++ b/http_components/Cargo.toml @@ -12,14 +12,14 @@ validator = ["dep:validator"] health = ["dep:health-readiness"] [dependencies] -actix-web = { version = "4.4.1" } -actix-http = { version = "3.5.1" } +actix-web = { version = "4.5.1" } +actix-http = { version = "3.6.0" } actix-cors = { version = "0.7.0" } -serde = { version = "1.0.196", features = ["derive"] } -serde_json = { version = "1.0.94" } -tracing = { version = "0.1.40" } futures-util = { version = "0.3.30" } -opentelemetry = { version = "0.21.0" } +serde = { workspace = true, features = ["derive"] } +serde_json = { workspace = true } +tracing = { workspace = true } +opentelemetry = { workspace = true } # openapi utoipa = { version = "4.2.0", optional = true } @@ -34,8 +34,8 @@ auth = { path = "../auth", optional = true } otel = { path = "../otel", optional = true } # metrics -opentelemetry-semantic-conventions = { version = "0.13.0", optional = true } -opentelemetry-prometheus = { version = "0.14.1", optional = true } +opentelemetry-semantic-conventions = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2", optional = true } +opentelemetry-prometheus = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2", optional = true } prometheus = { version = "0.13.3", optional = true } # health diff --git a/http_server/Cargo.toml b/http_server/Cargo.toml index 16cc8ff..5c37291 100644 --- a/http_server/Cargo.toml +++ b/http_server/Cargo.toml @@ -12,13 +12,13 @@ http-components = { path = '../http_components', features = ["tracing", "metrics health-readiness = { path = '../health_readiness' } auth = { path = "../auth" } -thiserror = { version = "1.0.56" } -actix-web = { version = "4.4.1" } -serde = { version = "1.0.196", features = ["derive"] } -serde_json = { version = "1.0.112" } -tracing = { version = "0.1.40" } -opentelemetry = { version = "0.21.0" } +actix-web = { version = "4.5.1" } +thiserror = { workspace = true } +serde = { workspace = true, features = ["derive"] } +serde_json = { workspace = true } +tracing = { workspace = true } +opentelemetry = { workspace = true } # Swagger -utoipa = { version = "4.1.0", features = ["actix_extras"], optional = true } -utoipa-swagger-ui = { version = "5.0.0", features = ["actix-web"], optional = true } +utoipa = { version = "4.2.0", features = ["actix_extras"], optional = true } +utoipa-swagger-ui = { version = "6.0.0", features = ["actix-web"], optional = true } diff --git a/http_server/src/server/server.rs b/http_server/src/server/server.rs index 5c9eeed..92f8704 100644 --- a/http_server/src/server/server.rs +++ b/http_server/src/server/server.rs @@ -9,7 +9,6 @@ use auth::jwt_manager::JwtManager; use configs::AppConfigs; use health_readiness::{HealthReadinessService, HealthReadinessServiceImpl}; use http_components::{ - handlers::health_handler, middlewares, middlewares::otel::{HTTPOtelMetrics, HTTPOtelTracing}, CustomServiceConfigure, @@ -17,15 +16,15 @@ use http_components::{ use opentelemetry::global; use std::{sync::Arc, time::Duration}; use tracing::error; -#[cfg(openapi)] +#[cfg(feature = "openapi")] use utoipa::openapi::OpenApi; -#[cfg(openapi)] +#[cfg(feature = "openapi")] use utoipa_swagger_ui::SwaggerUi; pub struct HTTPServer { addr: String, services: Vec>, - #[cfg(openapi)] + #[cfg(feature = "openapi")] openapi: Option, jwt_manager: Option>, health_check: Option>, @@ -36,7 +35,7 @@ impl HTTPServer { HTTPServer { addr: cfg.app_addr(), services: vec![], - #[cfg(openapi)] + #[cfg(feature = "openapi")] openapi: None, jwt_manager: None, health_check: None, @@ -55,7 +54,7 @@ impl HTTPServer { self } - #[cfg(openapi)] + #[cfg(feature = "openapi")] pub fn openapi(mut self, openapi: &OpenApi) -> Self { self.openapi = Some(openapi.to_owned()); self @@ -68,7 +67,7 @@ impl HTTPServer { pub async fn start(&self) -> Result<(), HTTPServerError> { ActixHttpServer::new({ - #[cfg(openapi)] + #[cfg(feature = "openapi")] let openapi = self.openapi.clone(); let jwt_manager = self.jwt_manager.clone(); @@ -106,7 +105,7 @@ impl HTTPServer { } }); - #[cfg(openapi)] + #[cfg(feature = "openapi")] if openapi.is_some() { app = app.service( SwaggerUi::new("/docs/{_:.*}") @@ -114,8 +113,7 @@ impl HTTPServer { ); } - app.service(health_handler) - .default_service(web::to(middlewares::not_found::not_found)) + app.default_service(web::to(middlewares::not_found::not_found)) .wrap(actix_middleware::Logger::default()) } }) diff --git a/kafka/Cargo.toml b/kafka/Cargo.toml index fe5cc4f..6630656 100644 --- a/kafka/Cargo.toml +++ b/kafka/Cargo.toml @@ -8,7 +8,7 @@ configs = { path = "../configs" } messaging = { path = "../messaging" } rdkafka = { version = "0.36.2" } -async-trait = { version = "0.1.77" } -opentelemetry = { version = "0.21.0" } -tracing = { version = "0.1.40" } -tokio = { version = "1.35.1", features = ["default"] } +async-trait = { workspace = true } +opentelemetry = { workspace = true } +tracing = { workspace = true } +tokio = { workspace = true, features = ["default"] } diff --git a/logging/Cargo.toml b/logging/Cargo.toml index a5e380f..f018408 100644 --- a/logging/Cargo.toml +++ b/logging/Cargo.toml @@ -9,5 +9,5 @@ configs = { path = "../configs" } tracing-bunyan-formatter = { version = "0.3.9" } tracing-subscriber = { version = "0.3.18" } tracing-log = { version = "0.2.0" } -tracing = { version = "0.1.40" } -thiserror = { version = "1.0.56" } \ No newline at end of file +tracing = { workspace = true } +thiserror = { workspace = true } \ No newline at end of file diff --git a/messaging/Cargo.toml b/messaging/Cargo.toml index c7f8bef..6aeffd6 100644 --- a/messaging/Cargo.toml +++ b/messaging/Cargo.toml @@ -7,12 +7,12 @@ edition = "2021" mocks = ["dep:mockall"] [dependencies] -opentelemetry = { version = "0.21.0" } -async-trait = { version = "0.1.77" } -thiserror = { version = "1.0.56" } +opentelemetry = { workspace = true } +async-trait = { workspace = true } +thiserror = { workspace = true } # mock -mockall = { version = "0.12.0", optional = true } +mockall = { version = "0.12.1", optional = true } [dev-dependencies] -mockall = { version = "0.12.0" } +mockall = { version = "0.12.1" } diff --git a/metrics/Cargo.toml b/metrics/Cargo.toml index 03bea49..6266580 100644 --- a/metrics/Cargo.toml +++ b/metrics/Cargo.toml @@ -11,19 +11,19 @@ stdout = ["dep:opentelemetry-stdout", "dep:tokio"] [dependencies] configs = { path = "../configs" } -opentelemetry = { version = "0.21.0", features = ["metrics"] } +opentelemetry = { workspace = true, features = ["metrics"] } opentelemetry_sdk = { version = "0.21.2", features = ["metrics", "rt-tokio"] } -tracing = { version = "0.1.40" } -thiserror = { version = "1.0.56" } +tracing = { workspace = true } +thiserror = { workspace = true } # OTLP Featue -tonic = { version = "0.9.2", features = ["tls"], optional = true } -tokio = { version = "1.35.1", features = ["default"], optional = true } -opentelemetry-otlp = { version = "0.14.0", features = ["tonic", "metrics", "grpc-tonic" , "tls", "tls-roots"], optional = true } +tonic = { workspace = true, features = ["tls"], optional = true } +tokio = { workspace = true, features = ["default"], optional = true } +opentelemetry-otlp = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2", features = ["tonic", "metrics", "grpc-tonic" , "tls", "tls-roots"], optional = true } # Prometheus Feature prometheus = { version = "0.13.3" } -opentelemetry-prometheus = { version = "0.14.1", optional = true } +opentelemetry-prometheus = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2", optional = true } # Stdout -opentelemetry-stdout = { version = "0.2.0", features = ["metrics"], optional = true } \ No newline at end of file +opentelemetry-stdout = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2", features = ["metrics"], optional = true } \ No newline at end of file diff --git a/metrics/src/provider.rs b/metrics/src/provider.rs index 5403ed2..0033a9d 100644 --- a/metrics/src/provider.rs +++ b/metrics/src/provider.rs @@ -4,10 +4,10 @@ use prometheus::Registry; use std::sync::Arc; use tracing::{debug, error}; -#[cfg(all(feature = "otlp", feature = "prometheus", feature = "stdout"))] +#[cfg(any(feature = "otlp", feature = "prometheus", feature = "stdout"))] use crate::exporters; -#[cfg(all(feature = "otlp", feature = "prometheus", feature = "stdout"))] +#[cfg(any(feature = "otlp", feature = "prometheus", feature = "stdout"))] use opentelemetry::global; pub fn init(cfg: &Configs) -> Result>, MetricsError> diff --git a/migrator/Cargo.toml b/migrator/Cargo.toml index dac8e53..6d68554 100644 --- a/migrator/Cargo.toml +++ b/migrator/Cargo.toml @@ -11,9 +11,9 @@ sqlite = ["dep:deadpool-sqlite"] configs = { path = "../configs" } logging = { path = "../logging" } -async-trait = { version = "0.1.77" } -tracing = { version = "0.1.40" } -thiserror = { version = "1.0.56" } +async-trait = { workspace = true } +tracing = { workspace = true } +thiserror = { workspace = true } deadpool-postgres = { version = "0.12.1", optional = true } deadpool-sqlite = { version = "0.7.0", optional = true } \ No newline at end of file diff --git a/mqtt/Cargo.toml b/mqtt/Cargo.toml index 68d28e7..8d6a753 100644 --- a/mqtt/Cargo.toml +++ b/mqtt/Cargo.toml @@ -11,21 +11,21 @@ configs = { path = "../configs" } traces = { path = "../traces" } messaging = { path = "../messaging" } -opentelemetry = { version = "0.21.0" } -tracing = { version = "0.1.40" } -async-trait = { version = "0.1.77" } +opentelemetry = { workspace = true } +tracing = { workspace = true } +async-trait = { workspace = true } bytes = { version = "1.5.0", features = ["serde"] } paho-mqtt = { version = "0.12.3" } -serde = { version = "1.0.196", features = ["derive"] } -serde_json = { version = "1.0.112" } -futures-util = { version = "0.3.26" } -thiserror = { version = "1.0.56" } +serde = { workspace = true, features = ["derive"] } +serde_json = { workspace = true } +futures-util = { version = "0.3.30" } +thiserror = { workspace = true } # Used only with feature mock -mockall = { version = "0.12.0", optional = true } +mockall = { version = "0.12.1", optional = true } [dev-dependencies] messaging = { path = "../messaging", features = ["mocks"] } -mockall = { version = "0.12.0" } -tokio = { version = "1.35.1" } \ No newline at end of file +mockall = { version = "0.12.1" } +tokio = { workspace = true } \ No newline at end of file diff --git a/otel/Cargo.toml b/otel/Cargo.toml index e3e72dc..3c4bd98 100644 --- a/otel/Cargo.toml +++ b/otel/Cargo.toml @@ -4,4 +4,4 @@ version = "0.1.0" edition = "2021" [dependencies] -opentelemetry = { version = "0.21.0" } \ No newline at end of file +opentelemetry = { workspace = true } \ No newline at end of file diff --git a/rabbitmq/Cargo.toml b/rabbitmq/Cargo.toml index f086346..bf8d2b5 100644 --- a/rabbitmq/Cargo.toml +++ b/rabbitmq/Cargo.toml @@ -9,15 +9,15 @@ messaging = { path = "../messaging" } traces = { path = "../traces" } lapin = { version = "2.3.1" } -opentelemetry = { version = "0.21.0" } +opentelemetry = { workspace = true } uuid = { version = "1.7.0", features = ["v4"] } -async-trait = { version = "0.1.77" } -tracing = { version = "0.1.40" } -serde_json = { version = "1.0.112" } -serde = { version = "1.0.196", features = ["derive"] } -tokio = { version = "1.35.1", features = ["default"] } +async-trait = { workspace = true } +tracing = { workspace = true } +serde_json = { workspace = true } +serde = { workspace = true, features = ["derive"] } +tokio = { workspace = true, features = ["default"] } futures-util = { version = "0.3.30"} -thiserror = { version = "1.0.56" } +thiserror = { workspace = true } [dev-dependencies] -mockall = { version = "0.12.0" } +mockall = { version = "0.12.1" } diff --git a/secrets_manager/Cargo.toml b/secrets_manager/Cargo.toml index 6962414..cb26011 100644 --- a/secrets_manager/Cargo.toml +++ b/secrets_manager/Cargo.toml @@ -7,16 +7,16 @@ edition = "2021" mocks = ["dep:mockall"] [dependencies] -async-trait = { version = "0.1.77" } -tracing = { version = "0.1.40" } -aws-config = { version = "1.1.3" } -aws-sdk-secretsmanager = { version = "1.13.0" } -serde_json = { version = "1.0.112" } -thiserror = { version = "1.0.56" } +async-trait = { workspace = true } +tracing = { workspace = true } +aws-config = { version = "1.1.5" } +aws-sdk-secretsmanager = { version = "1.15.1" } +serde_json = { workspace = true } +thiserror = { workspace = true } # Used only with feature mock -mockall = { version = "0.12.0", optional = true } +mockall = { version = "0.12.1", optional = true } [dev-dependencies] -mockall = { version = "0.12.0" } -tokio = { version = "1.35.1", features = ["macros"] } +mockall = { version = "0.12.1" } +tokio = { workspace = true, features = ["macros"] } diff --git a/sql_pool/Cargo.toml b/sql_pool/Cargo.toml index e3c43cf..8714cdc 100644 --- a/sql_pool/Cargo.toml +++ b/sql_pool/Cargo.toml @@ -10,8 +10,8 @@ sqlite = ["dep:deadpool-sqlite"] [dependencies] configs = { path = "../configs" } -tracing = { version = "0.1.40" } -thiserror = { version = "1.0.56" } +tracing = { workspace = true } +thiserror = { workspace = true } # PostgreSQL dep deadpool-postgres = { version = "0.12.1", optional = true } diff --git a/traces/Cargo.toml b/traces/Cargo.toml index 17fc8cd..f74f3d7 100644 --- a/traces/Cargo.toml +++ b/traces/Cargo.toml @@ -10,14 +10,14 @@ stdout = ["dep:opentelemetry-stdout"] [dependencies] configs = { path = "../configs" } -opentelemetry = { version = "0.21.0" } -opentelemetry_sdk = { version = "0.21.2", features = ["rt-tokio"]} -tracing = { version = "0.1.40" } -thiserror = { version = "1.0.56" } -serde = { version = "1.0.196", features = ["derive"] } -tonic = { version = "0.9.2", features = ["tls"] } -tokio = { version = "1.35.1", features = ["default"] } +opentelemetry = { workspace = true } +opentelemetry_sdk = { workspace = true, features = ["rt-tokio"]} +tracing = { workspace = true } +thiserror = { workspace = true } +serde = { workspace = true, features = ["derive"] } +tonic = { workspace = true, features = ["tls"] } +tokio = { workspace = true, features = ["default"] } -opentelemetry-otlp = { version = "0.14.0", features = ["tonic", "tls", "tls-roots"], optional = true } +opentelemetry-otlp = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2", features = ["tonic", "tls", "tls-roots"], optional = true } -opentelemetry-stdout = { version = "0.2.0", features = ["trace"], optional = true } \ No newline at end of file +opentelemetry-stdout = { git = "ssh://git@github.com/open-telemetry/opentelemetry-rust.git", rev = "v0.21.2", features = ["trace"], optional = true } \ No newline at end of file diff --git a/traces/src/provider.rs b/traces/src/provider.rs index 5a462e5..c3e130c 100644 --- a/traces/src/provider.rs +++ b/traces/src/provider.rs @@ -8,7 +8,7 @@ use opentelemetry_sdk::{ use std::vec; use tracing::{debug, error}; -#[cfg(all(feature = "otlp", feature = "stdout"))] +#[cfg(any(feature = "otlp", feature = "stdout"))] use crate::exporters; pub fn init(cfg: &Configs) -> Result<(), TracesError>