diff --git a/Cargo.lock b/Cargo.lock index ccd015a475768..879b7663d3b1b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1452,6 +1452,12 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d27c3610c36aee21ce8ac510e6224498de4228ad772a171ed65643a24693a5a8" +[[package]] +name = "base16ct" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf" + [[package]] name = "base64" version = "0.13.1" @@ -2500,6 +2506,18 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" +[[package]] +name = "crypto-bigint" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "740fe28e594155f10cfc383984cbefd529d7396050557148f79cb0f621204124" +dependencies = [ + "generic-array", + "rand_core 0.6.4", + "subtle", + "zeroize", +] + [[package]] name = "crypto-common" version = "0.1.6" @@ -2570,6 +2588,7 @@ dependencies = [ "platforms 3.1.2", "rustc_version 0.4.0", "subtle", + "zeroize", ] [[package]] @@ -2715,9 +2734,9 @@ checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" [[package]] name = "data-url" -version = "0.2.0" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d7439c3735f405729d52c3fbbe4de140eaf938a1fe47d227c27f8254d4302a5" +checksum = "41b319d1b62ffbd002e057f36bebd1f42b9f97927c9577461d855f3513c4289f" [[package]] name = "db-key" @@ -2825,6 +2844,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ "block-buffer", + "const-oid", "crypto-common", "subtle", ] @@ -2957,12 +2977,27 @@ version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "23d2f3407d9a573d666de4b5bdf10569d73ca9478087346697dcbae6244bfbcd" +[[package]] +name = "ecdsa" +version = "0.16.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4b1e0c257a9e9f25f90ff76d7a68360ed497ee519c8e428d1825ef0000799d4" +dependencies = [ + "der", + "digest", + "elliptic-curve", + "rfc6979", + "signature", + "spki", +] + [[package]] name = "ed25519" version = "2.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "115531babc129696a58c64a4fef0a8bf9e9698629fb97e9e40767d235cfbcd53" dependencies = [ + "pkcs8", "signature", ] @@ -2974,8 +3009,10 @@ checksum = "7277392b266383ef8396db7fdeb1e77b6c52fed775f5df15bb24f35b72156980" dependencies = [ "curve25519-dalek", "ed25519", + "serde", "sha2", "signature", + "zeroize", ] [[package]] @@ -2984,6 +3021,27 @@ version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +[[package]] +name = "elliptic-curve" +version = "0.13.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d97ca172ae9dc9f9b779a6e3a65d308f2af74e5b8c921299075bdb4a0370e914" +dependencies = [ + "base16ct", + "crypto-bigint", + "digest", + "ff", + "generic-array", + "group", + "hkdf", + "pem-rfc7468", + "pkcs8", + "rand_core 0.6.4", + "sec1", + "subtle", + "zeroize", +] + [[package]] name = "ena" version = "0.14.2" @@ -3246,6 +3304,16 @@ version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" +[[package]] +name = "ff" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" +dependencies = [ + "rand_core 0.6.4", + "subtle", +] + [[package]] name = "fiat-crypto" version = "0.2.2" @@ -3709,6 +3777,17 @@ dependencies = [ "onig", ] +[[package]] +name = "group" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" +dependencies = [ + "ff", + "rand_core 0.6.4", + "subtle", +] + [[package]] name = "h2" version = "0.3.21" @@ -3966,6 +4045,15 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +[[package]] +name = "hkdf" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" +dependencies = [ + "hmac", +] + [[package]] name = "hmac" version = "0.12.1" @@ -4630,7 +4718,7 @@ dependencies = [ "k8s-openapi 0.18.0", "kube-core", "openssl", - "pem", + "pem 1.1.1", "pin-project", "secrecy", "serde", @@ -4741,6 +4829,9 @@ name = "lazy_static" version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +dependencies = [ + "spin 0.5.2", +] [[package]] name = "libc" @@ -5483,6 +5574,23 @@ dependencies = [ "num-traits", ] +[[package]] +name = "num-bigint-dig" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc84195820f291c7697304f3cbdadd1cb7199c0efc917ff5eafd71225c136151" +dependencies = [ + "byteorder", + "lazy_static", + "libm", + "num-integer", + "num-iter", + "num-traits", + "rand 0.8.5", + "smallvec", + "zeroize", +] + [[package]] name = "num-complex" version = "0.4.4" @@ -5513,6 +5621,17 @@ dependencies = [ "num-traits", ] +[[package]] +name = "num-iter" +version = "0.1.43" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d03e6c028c5dc5cac6e2dec0efda81fc887605bb3d884578bb6d6bf7514e252" +dependencies = [ + "autocfg", + "num-integer", + "num-traits", +] + [[package]] name = "num-rational" version = "0.3.2" @@ -5742,26 +5861,31 @@ dependencies = [ [[package]] name = "openidconnect" -version = "2.5.1" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98dd5b7049bac4fdd2233b8c9767d42c05da8006fdb79cc903258556d2b18009" +checksum = "62d6050f6a84b81f23c569f5607ad883293e57491036e318fafe6fc4895fadb1" dependencies = [ "base64 0.13.1", "chrono", + "dyn-clone", + "ed25519-dalek", + "hmac", "http", "itertools 0.10.5", "log", - "num-bigint", "oauth2", + "p256", + "p384", "rand 0.8.5", - "ring 0.16.20", + "rsa", "serde", "serde-value", "serde_derive", "serde_json", "serde_path_to_error", "serde_plain", - "serde_with 1.14.0", + "serde_with 3.4.0", + "sha2", "subtle", "thiserror", "url", @@ -5912,6 +6036,30 @@ dependencies = [ "supports-color", ] +[[package]] +name = "p256" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c9863ad85fa8f4460f9c48cb909d38a0d689dba1f6f6988a5e3e0d31071bcd4b" +dependencies = [ + "ecdsa", + "elliptic-curve", + "primeorder", + "sha2", +] + +[[package]] +name = "p384" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70786f51bcc69f6a4c0360e063a4cac5419ef7c5cd5b3c99ad70f3be5ba79209" +dependencies = [ + "ecdsa", + "elliptic-curve", + "primeorder", + "sha2", +] + [[package]] name = "pad" version = "0.1.6" @@ -5995,6 +6143,16 @@ dependencies = [ "base64 0.13.1", ] +[[package]] +name = "pem" +version = "3.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3163d2912b7c3b52d651a055f2c7eec9ba5cd22d26ef75b8dd3a59980b185923" +dependencies = [ + "base64 0.21.5", + "serde", +] + [[package]] name = "pem-rfc7468" version = "0.7.0" @@ -6167,6 +6325,17 @@ dependencies = [ "futures-io", ] +[[package]] +name = "pkcs1" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c8ffb9f10fa047879315e6625af03c164b16962a5368d724ed16323b68ace47f" +dependencies = [ + "der", + "pkcs8", + "spki", +] + [[package]] name = "pkcs8" version = "0.10.2" @@ -6422,6 +6591,15 @@ dependencies = [ "unicode-width", ] +[[package]] +name = "primeorder" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c2fcef82c0ec6eefcc179b978446c399b3cdf73c392c35604e399eee6df1ee3" +dependencies = [ + "elliptic-curve", +] + [[package]] name = "proc-macro-crate" version = "0.1.5" @@ -6682,9 +6860,9 @@ dependencies = [ [[package]] name = "pulsar" -version = "6.0.1" +version = "6.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6eb95b2e36b92d3e0536be87eaf7accb17db39f5a44452759b43f1328e82dc9" +checksum = "5d21c6a837986cf25d22ac5b951c267d95808f3c830ff009c2879fff259a0268" dependencies = [ "async-trait", "bit-vec", @@ -6702,7 +6880,7 @@ dependencies = [ "nom", "oauth2", "openidconnect", - "pem", + "pem 3.0.2", "prost 0.11.9", "prost-build 0.11.9", "prost-derive 0.11.9", @@ -6716,7 +6894,7 @@ dependencies = [ "tokio-util", "url", "uuid", - "zstd 0.11.2+zstd.1.5.2", + "zstd 0.12.4", ] [[package]] @@ -6743,9 +6921,9 @@ dependencies = [ [[package]] name = "quanta" -version = "0.12.0" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4966e46e3f559f8681bf8203b5e0e2421ebf6de5dd8b59f2ec8fa91acc028a19" +checksum = "577c55a090a94ed7da0e6580cc38a553558e2d736398b5d8ebf81bc9880f8acd" dependencies = [ "crossbeam-utils", "libc", @@ -7242,6 +7420,16 @@ version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8c31b5c4033f8fdde8700e4657be2c497e7288f01515be52168c631e2e4d4086" +[[package]] +name = "rfc6979" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" +dependencies = [ + "hmac", + "subtle", +] + [[package]] name = "ring" version = "0.16.20" @@ -7368,6 +7556,26 @@ dependencies = [ "xmlparser", ] +[[package]] +name = "rsa" +version = "0.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "86ef35bf3e7fe15a53c4ab08a998e42271eab13eb0db224126bc7bc4c4bad96d" +dependencies = [ + "const-oid", + "digest", + "num-bigint-dig", + "num-integer", + "num-traits", + "pkcs1", + "pkcs8", + "rand_core 0.6.4", + "signature", + "spki", + "subtle", + "zeroize", +] + [[package]] name = "rstest" version = "0.18.2" @@ -7656,6 +7864,20 @@ version = "4.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1c107b6f4780854c8b126e228ea8869f4d7b71260f962fefb57b996b8959ba6b" +[[package]] +name = "sec1" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3e97a565f76233a6003f9f5c54be1d9c5bdfa3eccfb189469f11ec4901c47dc" +dependencies = [ + "base16ct", + "der", + "generic-array", + "pkcs8", + "subtle", + "zeroize", +] + [[package]] name = "secrecy" version = "0.8.0" @@ -8053,6 +8275,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8fe458c98333f9c8152221191a77e2a44e8325d0193484af2e9421a53019e57d" dependencies = [ "digest", + "rand_core 0.6.4", ] [[package]] @@ -9584,7 +9807,6 @@ name = "vdev" version = "0.1.0" dependencies = [ "anyhow", - "atty", "cached", "chrono", "clap 4.4.7", @@ -9634,7 +9856,6 @@ dependencies = [ "async-nats", "async-stream", "async-trait", - "atty", "aws-config", "aws-credential-types", "aws-sdk-cloudwatch", @@ -10001,7 +10222,7 @@ dependencies = [ "prost 0.12.1", "prost-build 0.12.1", "prost-types 0.12.1", - "quanta 0.12.0", + "quanta 0.12.1", "quickcheck", "quickcheck_macros", "rand 0.8.5", @@ -10774,15 +10995,6 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" -[[package]] -name = "zstd" -version = "0.11.2+zstd.1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20cc960326ece64f010d2d2107537f26dc589a6573a316bd5b1dba685fa5fde4" -dependencies = [ - "zstd-safe 5.0.2+zstd.1.5.2", -] - [[package]] name = "zstd" version = "0.12.4" @@ -10801,16 +11013,6 @@ dependencies = [ "zstd-safe 7.0.0", ] -[[package]] -name = "zstd-safe" -version = "5.0.2+zstd.1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d2a5585e04f9eea4b2a3d1eca508c4dee9592a89ef6f450c11719da0726f4db" -dependencies = [ - "libc", - "zstd-sys", -] - [[package]] name = "zstd-safe" version = "6.0.6" diff --git a/Cargo.toml b/Cargo.toml index 0e5e4083f12f7..287624f94bf50 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -292,7 +292,7 @@ ordered-float = { version = "4.1.1", default-features = false } paste = "1.0.14" percent-encoding = { version = "2.3.0", default-features = false } postgres-openssl = { version = "0.5.0", default-features = false, features = ["runtime"], optional = true } -pulsar = { version = "6.0.1", default-features = false, features = ["tokio-runtime", "auth-oauth2", "flate2", "lz4", "snap", "zstd"], optional = true } +pulsar = { version = "6.1.0", default-features = false, features = ["tokio-runtime", "auth-oauth2", "flate2", "lz4", "snap", "zstd"], optional = true } rand = { version = "0.8.5", default-features = false, features = ["small_rng"] } rand_distr = { version = "0.4.3", default-features = false } rdkafka = { version = "0.34.0", default-features = false, features = ["tokio", "libz", "ssl", "zstd"], optional = true } @@ -332,7 +332,6 @@ mlua = { version = "0.9.1", default-features = false, features = ["lua54", "send windows-service = "0.6.0" [target.'cfg(unix)'.dependencies] -atty = { version = "0.2.14", default-features = false } nix = { version = "0.26.2", default-features = false, features = ["socket", "signal"] } [build-dependencies] diff --git a/LICENSE-3rdparty.csv b/LICENSE-3rdparty.csv index 777205b541122..89d67a55e6ea5 100644 --- a/LICENSE-3rdparty.csv +++ b/LICENSE-3rdparty.csv @@ -84,6 +84,7 @@ backoff,https://github.com/ihrwein/backoff,MIT OR Apache-2.0,Tibor Benke backtrace,https://github.com/rust-lang/backtrace-rs,MIT OR Apache-2.0,The Rust Project Developers base16,https://github.com/thomcc/rust-base16,CC0-1.0,Thom Chiovoloni +base16ct,https://github.com/RustCrypto/formats/tree/master/base16ct,Apache-2.0 OR MIT,RustCrypto Developers base64,https://github.com/marshallpierce/rust-base64,MIT OR Apache-2.0,"Alice Maz , Marshall Pierce " base64-simd,https://github.com/Nugine/simd,MIT,The base64-simd Authors base64ct,https://github.com/RustCrypto/formats/tree/master/base64ct,Apache-2.0 OR MIT,RustCrypto Developers @@ -152,6 +153,7 @@ crossbeam-queue,https://github.com/crossbeam-rs/crossbeam,MIT OR Apache-2.0,The crossbeam-utils,https://github.com/crossbeam-rs/crossbeam,MIT OR Apache-2.0,The crossbeam-utils Authors crossterm,https://github.com/crossterm-rs/crossterm,MIT,T. Post crossterm_winapi,https://github.com/crossterm-rs/crossterm-winapi,MIT,T. Post +crypto-bigint,https://github.com/RustCrypto/crypto-bigint,Apache-2.0 OR MIT,RustCrypto Developers crypto-common,https://github.com/RustCrypto/traits,MIT OR Apache-2.0,RustCrypto Developers crypto_secretbox,https://github.com/RustCrypto/nacl-compat/tree/master/crypto_secretbox,Apache-2.0 OR MIT,RustCrypto Developers csv,https://github.com/BurntSushi/rust-csv,Unlicense OR MIT,Andrew Gallant @@ -176,9 +178,11 @@ dirs-sys-next,https://github.com/xdg-rs/dirs/tree/master/dirs-sys,MIT OR Apache- dns-lookup,https://github.com/keeperofdakeys/dns-lookup,MIT OR Apache-2.0,Josh Driver doc-comment,https://github.com/GuillaumeGomez/doc-comment,MIT,Guillaume Gomez dyn-clone,https://github.com/dtolnay/dyn-clone,MIT OR Apache-2.0,David Tolnay +ecdsa,https://github.com/RustCrypto/signatures/tree/master/ecdsa,Apache-2.0 OR MIT,RustCrypto Developers ed25519,https://github.com/RustCrypto/signatures/tree/master/ed25519,Apache-2.0 OR MIT,RustCrypto Developers ed25519-dalek,https://github.com/dalek-cryptography/ed25519-dalek,BSD-3-Clause,"isis lovecruft , Tony Arcieri , Michael Rosenberg " either,https://github.com/bluss/either,MIT OR Apache-2.0,bluss +elliptic-curve,https://github.com/RustCrypto/traits/tree/master/elliptic-curve,Apache-2.0 OR MIT,RustCrypto Developers encode_unicode,https://github.com/tormol/encode_unicode,Apache-2.0 OR MIT,Torbjørn Birch Moltu encoding_rs,https://github.com/hsivonen/encoding_rs,(Apache-2.0 OR MIT) AND BSD-3-Clause,Henri Sivonen endian-type,https://github.com/Lolirofle/endian-type,MIT,Lolirofle @@ -198,6 +202,7 @@ extend,https://github.com/davidpdrsn/ext,MIT,David Pedersen fallible-iterator,https://github.com/sfackler/rust-fallible-iterator,MIT OR Apache-2.0,Steven Fackler fastrand,https://github.com/smol-rs/fastrand,Apache-2.0 OR MIT,Stjepan Glavina +ff,https://github.com/zkcrypto/ff,MIT OR Apache-2.0,"Sean Bowe , Jack Grigg " fiat-crypto,https://github.com/mit-plv/fiat-crypto,MIT OR Apache-2.0 OR BSD-1-Clause,Fiat Crypto library authors filetime,https://github.com/alexcrichton/filetime,MIT OR Apache-2.0,Alex Crichton finl_unicode,https://github.com/dahosek/finl_unicode,MIT OR Apache-2.0,The finl_unicode Authors @@ -236,6 +241,7 @@ graphql_query_derive,https://github.com/graphql-rust/graphql-client,Apache-2.0 O greptime-proto,https://github.com/GreptimeTeam/greptime-proto,Apache-2.0,The greptime-proto Authors greptimedb-client,https://github.com/GreptimeTeam/greptimedb-client-rust,Apache-2.0,The greptimedb-client Authors grok,https://github.com/daschl/grok,Apache-2.0,Michael Nitschinger +group,https://github.com/zkcrypto/group,MIT OR Apache-2.0,"Sean Bowe , Jack Grigg " h2,https://github.com/hyperium/h2,MIT,"Carl Lerche , Sean McArthur " hash_hasher,https://github.com/Fraser999/Hash-Hasher,Apache-2.0 OR MIT,Fraser Hutchison hashbrown,https://github.com/rust-lang/hashbrown,MIT OR Apache-2.0,Amanieu d'Antras @@ -245,6 +251,7 @@ heim,https://github.com/heim-rs/heim,Apache-2.0 OR MIT,svartalf +hkdf,https://github.com/RustCrypto/KDFs,MIT OR Apache-2.0,RustCrypto Developers hmac,https://github.com/RustCrypto/MACs,MIT OR Apache-2.0,RustCrypto Developers home,https://github.com/rust-lang/cargo,MIT OR Apache-2.0,Brian Anderson hostname,https://github.com/svartalf/hostname,MIT,"fengcen , svartalf " @@ -350,8 +357,10 @@ ntapi,https://github.com/MSxDOS/ntapi,Apache-2.0 OR MIT,MSxDOS , Josh Triplett , The Nushell Project Developers" nuid,https://github.com/casualjim/rs-nuid,Apache-2.0,Ivan Porto Carrero num-bigint,https://github.com/rust-num/num-bigint,MIT OR Apache-2.0,The Rust Project Developers +num-bigint-dig,https://github.com/dignifiedquire/num-bigint,MIT OR Apache-2.0,"dignifiedquire , The Rust Project Developers" num-format,https://github.com/bcmyers/num-format,MIT OR Apache-2.0,Brian Myers num-integer,https://github.com/rust-num/num-integer,MIT OR Apache-2.0,The Rust Project Developers +num-iter,https://github.com/rust-num/num-iter,MIT OR Apache-2.0,The Rust Project Developers num-rational,https://github.com/rust-num/num-rational,MIT OR Apache-2.0,The Rust Project Developers num-traits,https://github.com/rust-num/num-traits,MIT OR Apache-2.0,The Rust Project Developers num_cpus,https://github.com/seanmonstar/num_cpus,MIT OR Apache-2.0,Sean McArthur @@ -374,6 +383,8 @@ openssl-sys,https://github.com/sfackler/rust-openssl,MIT,"Alex Crichton , Matt Brubeck " outref,https://github.com/Nugine/outref,MIT,The outref Authors overload,https://github.com/danaugrs/overload,MIT,Daniel Salvadori +p256,https://github.com/RustCrypto/elliptic-curves/tree/master/p256,Apache-2.0 OR MIT,RustCrypto Developers +p384,https://github.com/RustCrypto/elliptic-curves/tree/master/p384,Apache-2.0 OR MIT,"RustCrypto Developers, Frank Denis " pad,https://github.com/ogham/rust-pad,MIT,Ben S parking,https://github.com/smol-rs/parking,Apache-2.0 OR MIT,"Stjepan Glavina , The Rust Project Developers" parking_lot,https://github.com/Amanieu/parking_lot,MIT OR Apache-2.0,Amanieu d'Antras @@ -391,6 +402,7 @@ pin-project-lite,https://github.com/taiki-e/pin-project-lite,Apache-2.0 OR MIT,T pin-utils,https://github.com/rust-lang-nursery/pin-utils,MIT OR Apache-2.0,Josef Brandl pinky-swear,https://github.com/amqp-rs/pinky-swear,BSD-2-Clause,Marc-Antoine Perennou piper,https://github.com/notgull/piper,MIT OR Apache-2.0,"Stjepan Glavina , John Nunley " +pkcs1,https://github.com/RustCrypto/formats/tree/master/pkcs1,Apache-2.0 OR MIT,RustCrypto Developers pkcs8,https://github.com/RustCrypto/formats/tree/master/pkcs8,Apache-2.0 OR MIT,RustCrypto Developers platforms,https://github.com/RustSec/platforms-crate,Apache-2.0 OR MIT,Tony Arcieri polling,https://github.com/smol-rs/polling,Apache-2.0 OR MIT,Stjepan Glavina @@ -405,6 +417,7 @@ ppv-lite86,https://github.com/cryptocorrosion/cryptocorrosion,MIT OR Apache-2.0, pretty_assertions,https://github.com/rust-pretty-assertions/rust-pretty-assertions,MIT OR Apache-2.0,"Colin Kiegel , Florent Fayolle , Tom Milligan " prettydiff,https://github.com/romankoblov/prettydiff,MIT,Roman Koblov prettytable-rs,https://github.com/phsym/prettytable-rs,BSD-3-Clause,Pierre-Henri Symoneaux +primeorder,https://github.com/RustCrypto/elliptic-curves/tree/master/primeorder,Apache-2.0 OR MIT,RustCrypto Developers proc-macro-crate,https://github.com/bkchr/proc-macro-crate,Apache-2.0 OR MIT,Bastian Köcher proc-macro-crate,https://github.com/bkchr/proc-macro-crate,MIT OR Apache-2.0,Bastian Köcher proc-macro-error,https://gitlab.com/CreepySkeleton/proc-macro-error,MIT OR Apache-2.0,CreepySkeleton @@ -447,6 +460,7 @@ rend,https://github.com/djkoloski/rend,MIT,David Koloski reqwest,https://github.com/seanmonstar/reqwest,MIT OR Apache-2.0,Sean McArthur resolv-conf,http://github.com/tailhook/resolv-conf,MIT OR Apache-2.0,paul@colomiets.name retain_mut,https://github.com/upsuper/retain_mut,MIT,Xidorn Quan +rfc6979,https://github.com/RustCrypto/signatures/tree/master/rfc6979,Apache-2.0 OR MIT,RustCrypto Developers ring,https://github.com/briansmith/ring,ISC AND Custom,Brian Smith rkyv,https://github.com/rkyv/rkyv,MIT,David Koloski rle-decode-fast,https://github.com/WanzenBug/rle-decode-helper,MIT OR Apache-2.0,Moritz Wanzenböck @@ -456,6 +470,7 @@ rmpv,https://github.com/3Hren/msgpack-rust,MIT,Evgeny Safronov , Kerollmops " roxmltree,https://github.com/RazrFalcon/roxmltree,MIT OR Apache-2.0,Evgeniy Reizner roxmltree,https://github.com/RazrFalcon/roxmltree,MIT OR Apache-2.0,Yevhenii Reizner +rsa,https://github.com/RustCrypto/RSA,MIT OR Apache-2.0,"RustCrypto Developers, dignifiedquire " rust_decimal,https://github.com/paupino/rust-decimal,MIT,Paul Mason rustc-demangle,https://github.com/alexcrichton/rustc-demangle,MIT OR Apache-2.0,Alex Crichton rustc-hash,https://github.com/rust-lang-nursery/rustc-hash,Apache-2.0 OR MIT,The Rust Project Developers @@ -479,6 +494,7 @@ scoped-tls,https://github.com/alexcrichton/scoped-tls,MIT OR Apache-2.0,Alex Cri scopeguard,https://github.com/bluss/scopeguard,MIT OR Apache-2.0,bluss sct,https://github.com/rustls/sct.rs,Apache-2.0 OR ISC OR MIT,Joseph Birr-Pixton seahash,https://gitlab.redox-os.org/redox-os/seahash,MIT,"ticki , Tom Almeida " +sec1,https://github.com/RustCrypto/formats/tree/master/sec1,Apache-2.0 OR MIT,RustCrypto Developers secrecy,https://github.com/iqlusioninc/crates/tree/main/secrecy,Apache-2.0 OR MIT,Tony Arcieri security-framework,https://github.com/kornelski/rust-security-framework,MIT OR Apache-2.0,"Steven Fackler , Kornel " semver,https://github.com/dtolnay/semver,MIT OR Apache-2.0,David Tolnay diff --git a/distribution/kubernetes/vector-agent/README.md b/distribution/kubernetes/vector-agent/README.md index 1f30588427223..939f7714c3da3 100644 --- a/distribution/kubernetes/vector-agent/README.md +++ b/distribution/kubernetes/vector-agent/README.md @@ -1,6 +1,6 @@ The kubernetes manifests found in this directory have been automatically generated from the [helm chart `vector/vector`](https://github.com/vectordotdev/helm-charts/tree/master/charts/vector) -version 0.26.0 with the following `values.yaml`: +version 0.27.0 with the following `values.yaml`: ```yaml role: Agent diff --git a/distribution/kubernetes/vector-agent/configmap.yaml b/distribution/kubernetes/vector-agent/configmap.yaml index 94407e828a61c..c4299683bb0c5 100644 --- a/distribution/kubernetes/vector-agent/configmap.yaml +++ b/distribution/kubernetes/vector-agent/configmap.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Agent - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" data: agent.yaml: | data_dir: /vector-data-dir diff --git a/distribution/kubernetes/vector-agent/daemonset.yaml b/distribution/kubernetes/vector-agent/daemonset.yaml index 308d933740752..32b6528bf007a 100644 --- a/distribution/kubernetes/vector-agent/daemonset.yaml +++ b/distribution/kubernetes/vector-agent/daemonset.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Agent - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" annotations: {} spec: selector: @@ -30,7 +30,7 @@ spec: dnsPolicy: ClusterFirst containers: - name: vector - image: "timberio/vector:0.33.0-distroless-libc" + image: "timberio/vector:0.33.1-distroless-libc" imagePullPolicy: IfNotPresent args: - --config-dir diff --git a/distribution/kubernetes/vector-agent/rbac.yaml b/distribution/kubernetes/vector-agent/rbac.yaml index 5219e22ae7d10..20bd8bbf9d1ce 100644 --- a/distribution/kubernetes/vector-agent/rbac.yaml +++ b/distribution/kubernetes/vector-agent/rbac.yaml @@ -10,7 +10,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Agent - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" rules: - apiGroups: - "" @@ -31,7 +31,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Agent - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" roleRef: apiGroup: rbac.authorization.k8s.io kind: ClusterRole diff --git a/distribution/kubernetes/vector-agent/service-headless.yaml b/distribution/kubernetes/vector-agent/service-headless.yaml index 51fb0e8333709..0d06fe5cebcdb 100644 --- a/distribution/kubernetes/vector-agent/service-headless.yaml +++ b/distribution/kubernetes/vector-agent/service-headless.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Agent - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" annotations: spec: clusterIP: None diff --git a/distribution/kubernetes/vector-agent/serviceaccount.yaml b/distribution/kubernetes/vector-agent/serviceaccount.yaml index 933f7830ef0fd..cd9f5cdbb0ae7 100644 --- a/distribution/kubernetes/vector-agent/serviceaccount.yaml +++ b/distribution/kubernetes/vector-agent/serviceaccount.yaml @@ -8,5 +8,5 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Agent - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" automountServiceAccountToken: true diff --git a/distribution/kubernetes/vector-aggregator/README.md b/distribution/kubernetes/vector-aggregator/README.md index 521f96c5b15f9..170b612d48050 100644 --- a/distribution/kubernetes/vector-aggregator/README.md +++ b/distribution/kubernetes/vector-aggregator/README.md @@ -1,6 +1,6 @@ The kubernetes manifests found in this directory have been automatically generated from the [helm chart `vector/vector`](https://github.com/vectordotdev/helm-charts/tree/master/charts/vector) -version 0.26.0 with the following `values.yaml`: +version 0.27.0 with the following `values.yaml`: ```yaml diff --git a/distribution/kubernetes/vector-aggregator/configmap.yaml b/distribution/kubernetes/vector-aggregator/configmap.yaml index 0667a598a98be..f9df937ddd605 100644 --- a/distribution/kubernetes/vector-aggregator/configmap.yaml +++ b/distribution/kubernetes/vector-aggregator/configmap.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" data: aggregator.yaml: | data_dir: /vector-data-dir diff --git a/distribution/kubernetes/vector-aggregator/service-headless.yaml b/distribution/kubernetes/vector-aggregator/service-headless.yaml index 859b2ace30656..66e4bb4d442d1 100644 --- a/distribution/kubernetes/vector-aggregator/service-headless.yaml +++ b/distribution/kubernetes/vector-aggregator/service-headless.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" annotations: spec: clusterIP: None diff --git a/distribution/kubernetes/vector-aggregator/service.yaml b/distribution/kubernetes/vector-aggregator/service.yaml index 37edcdac34240..34667af203521 100644 --- a/distribution/kubernetes/vector-aggregator/service.yaml +++ b/distribution/kubernetes/vector-aggregator/service.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" annotations: spec: ports: diff --git a/distribution/kubernetes/vector-aggregator/serviceaccount.yaml b/distribution/kubernetes/vector-aggregator/serviceaccount.yaml index 7ad9ef88f674b..3b68c1aea6ea8 100644 --- a/distribution/kubernetes/vector-aggregator/serviceaccount.yaml +++ b/distribution/kubernetes/vector-aggregator/serviceaccount.yaml @@ -8,5 +8,5 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" automountServiceAccountToken: true diff --git a/distribution/kubernetes/vector-aggregator/statefulset.yaml b/distribution/kubernetes/vector-aggregator/statefulset.yaml index 08a32f381e5b6..44c97b2b98324 100644 --- a/distribution/kubernetes/vector-aggregator/statefulset.yaml +++ b/distribution/kubernetes/vector-aggregator/statefulset.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" annotations: {} spec: replicas: 1 @@ -32,7 +32,7 @@ spec: dnsPolicy: ClusterFirst containers: - name: vector - image: "timberio/vector:0.33.0-distroless-libc" + image: "timberio/vector:0.33.1-distroless-libc" imagePullPolicy: IfNotPresent args: - --config-dir diff --git a/distribution/kubernetes/vector-stateless-aggregator/README.md b/distribution/kubernetes/vector-stateless-aggregator/README.md index 1326577dc7f27..2d79c50dce1f1 100644 --- a/distribution/kubernetes/vector-stateless-aggregator/README.md +++ b/distribution/kubernetes/vector-stateless-aggregator/README.md @@ -1,6 +1,6 @@ The kubernetes manifests found in this directory have been automatically generated from the [helm chart `vector/vector`](https://github.com/vectordotdev/helm-charts/tree/master/charts/vector) -version 0.26.0 with the following `values.yaml`: +version 0.27.0 with the following `values.yaml`: ```yaml role: Stateless-Aggregator diff --git a/distribution/kubernetes/vector-stateless-aggregator/configmap.yaml b/distribution/kubernetes/vector-stateless-aggregator/configmap.yaml index e94f3cdbf7843..42996822c7a14 100644 --- a/distribution/kubernetes/vector-stateless-aggregator/configmap.yaml +++ b/distribution/kubernetes/vector-stateless-aggregator/configmap.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Stateless-Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" data: aggregator.yaml: | data_dir: /vector-data-dir diff --git a/distribution/kubernetes/vector-stateless-aggregator/deployment.yaml b/distribution/kubernetes/vector-stateless-aggregator/deployment.yaml index f185c5e506579..afa41bfdb064d 100644 --- a/distribution/kubernetes/vector-stateless-aggregator/deployment.yaml +++ b/distribution/kubernetes/vector-stateless-aggregator/deployment.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Stateless-Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" annotations: {} spec: replicas: 1 @@ -30,7 +30,7 @@ spec: dnsPolicy: ClusterFirst containers: - name: vector - image: "timberio/vector:0.33.0-distroless-libc" + image: "timberio/vector:0.33.1-distroless-libc" imagePullPolicy: IfNotPresent args: - --config-dir diff --git a/distribution/kubernetes/vector-stateless-aggregator/service-headless.yaml b/distribution/kubernetes/vector-stateless-aggregator/service-headless.yaml index 03bb1741b9f1f..e347ff6f684dd 100644 --- a/distribution/kubernetes/vector-stateless-aggregator/service-headless.yaml +++ b/distribution/kubernetes/vector-stateless-aggregator/service-headless.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Stateless-Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" annotations: spec: clusterIP: None diff --git a/distribution/kubernetes/vector-stateless-aggregator/service.yaml b/distribution/kubernetes/vector-stateless-aggregator/service.yaml index dc0c0fc46738a..620bf3300c35a 100644 --- a/distribution/kubernetes/vector-stateless-aggregator/service.yaml +++ b/distribution/kubernetes/vector-stateless-aggregator/service.yaml @@ -8,7 +8,7 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Stateless-Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" annotations: spec: ports: diff --git a/distribution/kubernetes/vector-stateless-aggregator/serviceaccount.yaml b/distribution/kubernetes/vector-stateless-aggregator/serviceaccount.yaml index bc5e31ee010da..bb2d476b431c2 100644 --- a/distribution/kubernetes/vector-stateless-aggregator/serviceaccount.yaml +++ b/distribution/kubernetes/vector-stateless-aggregator/serviceaccount.yaml @@ -8,5 +8,5 @@ metadata: app.kubernetes.io/name: vector app.kubernetes.io/instance: vector app.kubernetes.io/component: Stateless-Aggregator - app.kubernetes.io/version: "0.33.0-distroless-libc" + app.kubernetes.io/version: "0.33.1-distroless-libc" automountServiceAccountToken: true diff --git a/docs/DEPRECATIONS.md b/docs/DEPRECATIONS.md index 87244948d94f6..e369cab36de8f 100644 --- a/docs/DEPRECATIONS.md +++ b/docs/DEPRECATIONS.md @@ -7,9 +7,11 @@ See [DEPRECATION.md](docs/DEPRECATION.md#process) for the process for updating t ## To be removed ### 0.34.0 -* Support for `v1` series endpoint in the `datadog_metrics` sink should be removed. + * legacy_openssl_provider v0.34.0 OpenSSL legacy provider flag should be removed * armv7_rpm v0.34.0 The armv7 RPM packages should be removed (replaced by armv7hl) -### 0.35.0 +### 0.35.0 + * `requests_completed_total`, `request_duration_seconds`, and `requests_received_total` internal metrics +* datadog_v1_metrics v0.35.0 Support for `v1` series endpoint in the `datadog_metrics` sink should be removed. diff --git a/lib/vector-core/Cargo.toml b/lib/vector-core/Cargo.toml index d42279dcf5a3d..d870bf075ed31 100644 --- a/lib/vector-core/Cargo.toml +++ b/lib/vector-core/Cargo.toml @@ -37,7 +37,7 @@ pin-project.workspace = true proptest = { version = "1.3", optional = true } prost-types = { version = "0.12", default-features = false } prost = { version = "0.12", default-features = false, features = ["std"] } -quanta = { version = "0.12.0", default-features = false } +quanta = { version = "0.12.1", default-features = false } regex = { version = "1.10.2", default-features = false, features = ["std", "perf"] } ryu = { version = "1", default-features = false } serde = { version = "1.0.190", default-features = false, features = ["derive", "rc"] } diff --git a/src/cli.rs b/src/cli.rs index 794ca3ade12e0..54ec9cbb747c4 100644 --- a/src/cli.rs +++ b/src/cli.rs @@ -333,7 +333,10 @@ impl Color { pub fn use_color(&self) -> bool { match self { #[cfg(unix)] - Color::Auto => atty::is(atty::Stream::Stdout), + Color::Auto => { + use std::io::IsTerminal; + std::io::stdout().is_terminal() + } #[cfg(windows)] Color::Auto => false, // ANSI colors are not supported by cmd.exe Color::Always => true, diff --git a/src/sources/gcp_pubsub.rs b/src/sources/gcp_pubsub.rs index 083de69108a4e..52ca0e50621f3 100644 --- a/src/sources/gcp_pubsub.rs +++ b/src/sources/gcp_pubsub.rs @@ -131,9 +131,11 @@ static CLIENT_ID: Lazy = Lazy::new(|| uuid::Uuid::new_v4().to_string()); #[serde(deny_unknown_fields)] pub struct PubsubConfig { /// The project name from which to pull logs. + #[configurable(metadata(docs::examples = "my-log-source-project"))] pub project: String, /// The subscription within the project which is configured to receive logs. + #[configurable(metadata(docs::examples = "my-vector-source-subscription"))] pub subscription: String, /// The endpoint from which to pull data. diff --git a/src/sources/journald.rs b/src/sources/journald.rs index a8f926907746c..2c599b165f293 100644 --- a/src/sources/journald.rs +++ b/src/sources/journald.rs @@ -209,6 +209,13 @@ pub struct JournaldConfig { #[configurable(metadata(docs::hidden))] #[serde(default)] log_namespace: Option, + + /// Whether to emit the [__CURSOR field][cursor]. See also [sd_journal_get_cursor][get_cursor]. + /// + /// [cursor]: https://www.freedesktop.org/software/systemd/man/latest/systemd.journal-fields.html#Address%20Fields + /// [get_cursor]: https://www.freedesktop.org/software/systemd/man/latest/sd_journal_get_cursor.html + #[serde(default = "crate::serde::default_false")] + emit_cursor: bool, } const fn default_batch_size() -> usize { @@ -308,6 +315,7 @@ impl Default for JournaldConfig { acknowledgements: Default::default(), remap_priority: false, log_namespace: None, + emit_cursor: false, } } } @@ -377,6 +385,7 @@ impl SourceConfig for JournaldConfig { acknowledgements, starter, log_namespace, + emit_cursor: self.emit_cursor, } .run_shutdown(cx.shutdown), )) @@ -404,6 +413,7 @@ struct JournaldSource { acknowledgements: bool, starter: StartJournalctl, log_namespace: LogNamespace, + emit_cursor: bool, } impl JournaldSource { @@ -554,7 +564,11 @@ impl<'a> Batch<'a> { Some(Ok(bytes)) => { match decode_record(&bytes, self.source.remap_priority) { Ok(mut record) => { - if let Some(tmp) = record.remove(CURSOR) { + if self.source.emit_cursor { + if let Some(tmp) = record.get(CURSOR) { + self.cursor = Some(tmp.clone()); + } + } else if let Some(tmp) = record.remove(CURSOR) { self.cursor = Some(tmp); } @@ -1089,13 +1103,14 @@ mod tests { async fn run_with_units(iunits: &[&str], xunits: &[&str], cursor: Option<&str>) -> Vec { let include_matches = create_unit_matches(iunits.to_vec()); let exclude_matches = create_unit_matches(xunits.to_vec()); - run_journal(include_matches, exclude_matches, cursor).await + run_journal(include_matches, exclude_matches, cursor, false).await } async fn run_journal( include_matches: Matches, exclude_matches: Matches, checkpoint: Option<&str>, + emit_cursor: bool, ) -> Vec { assert_source_compliance(&["protocol"], async move { let (tx, rx) = SourceSender::new_test_finalize(EventStatus::Delivered); @@ -1128,6 +1143,7 @@ mod tests { data_dir: Some(tempdir), remap_priority: true, acknowledgements: false.into(), + emit_cursor, ..Default::default() }; let source = config.build(cx).await.unwrap(); @@ -1207,10 +1223,18 @@ mod tests { ); } + #[tokio::test] + async fn emits_cursor() { + let received = run_journal(Matches::new(), Matches::new(), None, true).await; + assert_eq!(cursor(&received[0]), Value::Bytes("1".into())); + assert_eq!(cursor(&received[3]), Value::Bytes("4".into())); + assert_eq!(cursor(&received[7]), Value::Bytes("8".into())); + } + #[tokio::test] async fn includes_matches() { let matches = create_matches(vec![("PRIORITY", "ERR")]); - let received = run_journal(matches, HashMap::new(), None).await; + let received = run_journal(matches, HashMap::new(), None, false).await; assert_eq!(received.len(), 2); assert_eq!( message(&received[0]), @@ -1227,7 +1251,7 @@ mod tests { #[tokio::test] async fn includes_kernel() { let matches = create_matches(vec![("_TRANSPORT", "kernel")]); - let received = run_journal(matches, HashMap::new(), None).await; + let received = run_journal(matches, HashMap::new(), None, false).await; assert_eq!(received.len(), 1); assert_eq!(timestamp(&received[0]), value_ts(1578529839, 140006000)); assert_eq!(message(&received[0]), Value::Bytes("audit log".into())); @@ -1236,7 +1260,7 @@ mod tests { #[tokio::test] async fn excludes_matches() { let matches = create_matches(vec![("PRIORITY", "INFO"), ("PRIORITY", "DEBUG")]); - let received = run_journal(HashMap::new(), matches, None).await; + let received = run_journal(HashMap::new(), matches, None, false).await; assert_eq!(received.len(), 5); assert_eq!(timestamp(&received[0]), value_ts(1578529839, 140003000)); assert_eq!(timestamp(&received[1]), value_ts(1578529839, 140004000)); @@ -1515,6 +1539,10 @@ mod tests { event.as_log()[log_schema().timestamp_key().unwrap().to_string()].clone() } + fn cursor(event: &Event) -> Value { + event.as_log()[CURSOR].clone() + } + fn value_ts(secs: i64, usecs: u32) -> Value { Value::Timestamp( chrono::Utc diff --git a/src/test_util/mod.rs b/src/test_util/mod.rs index ff3cc3d5fbee8..3b4e705e67f3c 100644 --- a/src/test_util/mod.rs +++ b/src/test_util/mod.rs @@ -122,7 +122,10 @@ pub fn next_addr_v6() -> SocketAddr { pub fn trace_init() { #[cfg(unix)] - let color = atty::is(atty::Stream::Stdout); + let color = { + use std::io::IsTerminal; + std::io::stdout().is_terminal() + }; // Windows: ANSI colors are not supported by cmd.exe // Color is false for everything except unix. #[cfg(not(unix))] diff --git a/vdev/Cargo.toml b/vdev/Cargo.toml index 4264cec8ebcd8..f11dd3200adde 100644 --- a/vdev/Cargo.toml +++ b/vdev/Cargo.toml @@ -9,7 +9,6 @@ publish = false [dependencies] anyhow = "1.0.75" -atty = "0.2.14" cached = "0.46.0" chrono = { version = "0.4.31", default-features = false, features = ["serde", "clock"] } clap = { version = "4.4.7", features = ["derive"] } diff --git a/vdev/src/util.rs b/vdev/src/util.rs index 306ccd9c1c1b8..e559b20f496dd 100644 --- a/vdev/src/util.rs +++ b/vdev/src/util.rs @@ -1,4 +1,5 @@ use std::ffi::{OsStr, OsString}; +use std::io::IsTerminal; use std::process::{Command, Output}; use std::{collections::BTreeMap, fmt::Debug, fs, io::ErrorKind, path::Path}; @@ -7,7 +8,7 @@ use once_cell::sync::Lazy; use serde::Deserialize; use serde_json::Value; -pub static IS_A_TTY: Lazy = Lazy::new(|| atty::is(atty::Stream::Stdout)); +pub static IS_A_TTY: Lazy = Lazy::new(|| std::io::stdout().is_terminal()); #[derive(Deserialize)] pub struct CargoTomlPackage { diff --git a/website/content/en/docs/setup/installation/manual/vector-installer.md b/website/content/en/docs/setup/installation/manual/vector-installer.md index 4091c023979c2..370f5f558c468 100644 --- a/website/content/en/docs/setup/installation/manual/vector-installer.md +++ b/website/content/en/docs/setup/installation/manual/vector-installer.md @@ -6,7 +6,7 @@ short: Vector installer The Vector installer enables you to install Vector using a platform-agnostic installation script: ```shell -curl --proto '=https' --tlsv1.2 -sSf https://sh.vector.dev | bash +curl --proto '=https' --tlsv1.2 -sSfL https://sh.vector.dev | bash ``` ## Management diff --git a/website/content/en/docs/setup/quickstart.md b/website/content/en/docs/setup/quickstart.md index 864b5bb527866..e2808b6e5bee9 100644 --- a/website/content/en/docs/setup/quickstart.md +++ b/website/content/en/docs/setup/quickstart.md @@ -18,7 +18,7 @@ We can install Vector using an installation script or Docker: {{< tab title="Script" >}} ```shell -curl --proto '=https' --tlsv1.2 -sSf https://sh.vector.dev | bash +curl --proto '=https' --tlsv1.2 -sSfL https://sh.vector.dev | bash ``` {{< /tab >}} diff --git a/website/content/en/guides/getting-started/getting-started.md b/website/content/en/guides/getting-started/getting-started.md index 59454b6e20999..f88023741739e 100644 --- a/website/content/en/guides/getting-started/getting-started.md +++ b/website/content/en/guides/getting-started/getting-started.md @@ -17,7 +17,7 @@ and create our first observability data pipeline so you can begin to see what Ve Installing Vector is quick and easy. We can use this handy installation script: ```shell -curl --proto '=https' --tlsv1.2 -sSf https://sh.vector.dev | bash +curl --proto '=https' --tlsv1.2 -sSfL https://sh.vector.dev | bash ``` Or you can [choose your preferred installation method][docs.installation]. diff --git a/website/content/en/highlights/2020-07-09-add-musl-and-glibc-support-to-install-sh.md b/website/content/en/highlights/2020-07-09-add-musl-and-glibc-support-to-install-sh.md index f47a075504eae..b37f371518db3 100644 --- a/website/content/en/highlights/2020-07-09-add-musl-and-glibc-support-to-install-sh.md +++ b/website/content/en/highlights/2020-07-09-add-musl-and-glibc-support-to-install-sh.md @@ -43,7 +43,7 @@ You **should not need to do anything**. If you are using a normal, recommended m If you're provisioning Vector, the best way to make sure you get the most up to date stable version is to run this: ```bash title="provision_vector.sh" -curl --proto '=https' --tlsv1.2 -sSf https://sh.vector.dev | bash -s -- -y +curl --proto '=https' --tlsv1.2 -sSfL https://sh.vector.dev | bash -s -- -y ``` If you don't need the latest and greatest, **check your official distribution repository.** Some distributions, such as [NixOS][urls.nixos], have official Vector packages. You can also find Vector packages in the official [FreeBSD][urls.freebsd] repositories. diff --git a/website/cue/reference/administration/example_docker_install_commands.cue b/website/cue/reference/administration/example_docker_install_commands.cue index 271c4d0510f14..83cce8fc0301c 100644 --- a/website/cue/reference/administration/example_docker_install_commands.cue +++ b/website/cue/reference/administration/example_docker_install_commands.cue @@ -9,6 +9,6 @@ package metadata administration: { example_docker_install_commands: [#Command, ...#Command] & [{ title: "Docker example" - command: "RUN apk add --no-cache curl bash && \\ \n curl --proto '=https' --tlsv1.2 -sSf https://sh.vector.dev | bash -s -- -y --prefix /usr/local" + command: "RUN apk add --no-cache curl bash && \\ \n curl --proto '=https' --tlsv1.2 -sSfL https://sh.vector.dev | bash -s -- -y --prefix /usr/local" }] } diff --git a/website/cue/reference/administration/install_commands.cue b/website/cue/reference/administration/install_commands.cue index ec6afaa49f161..ea79c8648f78e 100644 --- a/website/cue/reference/administration/install_commands.cue +++ b/website/cue/reference/administration/install_commands.cue @@ -10,11 +10,11 @@ administration: { install_commands: [#Command, ...#Command] & [ { title: "For humans" - command: "curl --proto '=https' --tlsv1.2 -sSf https://sh.vector.dev | bash" + command: "curl --proto '=https' --tlsv1.2 -sSfL https://sh.vector.dev | bash" }, { title: "For machines" - command: "curl --proto '=https' --tlsv1.2 -sSf https://sh.vector.dev | bash -s -- -y" + command: "curl --proto '=https' --tlsv1.2 -sSfL https://sh.vector.dev | bash -s -- -y" }, ] } diff --git a/website/cue/reference/administration/interfaces/vector_installer.cue b/website/cue/reference/administration/interfaces/vector_installer.cue index 44c8fed8328d7..350e95cd70d91 100644 --- a/website/cue/reference/administration/interfaces/vector_installer.cue +++ b/website/cue/reference/administration/interfaces/vector_installer.cue @@ -18,7 +18,7 @@ administration: interfaces: vector_installer: { role_implementations: [Name=string]: { commands: { - install: "curl --proto '=https' --tlsv1.2 -sSf https://sh.vector.dev | bash" + install: "curl --proto '=https' --tlsv1.2 -sSfL https://sh.vector.dev | bash" logs: null reload: "killall -s SIGHUP vector" restart: null diff --git a/website/cue/reference/components/sources/base/gcp_pubsub.cue b/website/cue/reference/components/sources/base/gcp_pubsub.cue index 0b1914852cef4..5e9adedbdac9d 100644 --- a/website/cue/reference/components/sources/base/gcp_pubsub.cue +++ b/website/cue/reference/components/sources/base/gcp_pubsub.cue @@ -356,7 +356,7 @@ base: components: sources: gcp_pubsub: configuration: { project: { description: "The project name from which to pull logs." required: true - type: string: {} + type: string: examples: ["my-log-source-project"] } retry_delay_seconds: { deprecated: true @@ -376,7 +376,7 @@ base: components: sources: gcp_pubsub: configuration: { subscription: { description: "The subscription within the project which is configured to receive logs." required: true - type: string: {} + type: string: examples: ["my-vector-source-subscription"] } tls: { description: "TLS configuration." diff --git a/website/cue/reference/components/sources/base/journald.cue b/website/cue/reference/components/sources/base/journald.cue index 321ab7442c522..0224f4d213041 100644 --- a/website/cue/reference/components/sources/base/journald.cue +++ b/website/cue/reference/components/sources/base/journald.cue @@ -49,6 +49,16 @@ base: components: sources: journald: configuration: { required: false type: string: examples: ["/var/lib/vector"] } + emit_cursor: { + description: """ + Whether to emit the [__CURSOR field][cursor]. See also [sd_journal_get_cursor][get_cursor]. + + [cursor]: https://www.freedesktop.org/software/systemd/man/latest/systemd.journal-fields.html#Address%20Fields + [get_cursor]: https://www.freedesktop.org/software/systemd/man/latest/sd_journal_get_cursor.html + """ + required: false + type: bool: default: false + } exclude_matches: { description: """ A list of sets of field/value pairs that, if any are present in a journal entry,