Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): Update VRL to 0.8.1 #19011

Merged
merged 6 commits into from
Nov 2, 2023
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
370 changes: 287 additions & 83 deletions Cargo.lock

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ members = [
]

[workspace.dependencies]
vrl = { version = "0.7.0", features = ["cli"] }
vrl = { version = "0.8.1", features = ["cli"] }

pin-project = { version = "1.1.3", default-features = false }

Expand Down Expand Up @@ -274,7 +274,7 @@ http-body = { version = "0.4.5", default-features = false }
hyper = { version = "0.14.27", default-features = false, features = ["client", "runtime", "http1", "http2", "server", "stream"] }
hyper-openssl = { version = "0.9.2", default-features = false }
hyper-proxy = { version = "0.9.1", default-features = false, features = ["openssl-tls"] }
indexmap = { version = "~2.0.2", default-features = false, features = ["serde", "std"] }
indexmap = { version = "2.1.0", default-features = false, features = ["serde", "std"] }
infer = { version = "0.15.0", default-features = false, optional = true}
indoc = { version = "2.0.4", default-features = false }
inventory = { version = "0.3.12", default-features = false }
Expand Down Expand Up @@ -369,7 +369,7 @@ tokio = { version = "1.33.0", features = ["test-util"] }
tokio-test = "0.4.3"
tower-test = "0.4.0"
vector-lib = { path = "lib/vector-lib", default-features = false, features = ["vrl", "test"] }
vrl = { version = "0.7.0", features = ["cli", "test", "test_framework", "arbitrary"] }
vrl = { version = "0.8.1", features = ["cli", "test", "test_framework", "arbitrary"] }

wiremock = "0.5.19"
zstd = { version = "0.13.0", default-features = false }
Expand Down
2 changes: 1 addition & 1 deletion lib/codecs/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ futures = { version = "0.3", default-features = false }
indoc = { version = "2", default-features = false }
tokio = { version = "1", features = ["test-util"] }
similar-asserts = "1.5.0"
vrl = { version = "0.7.0", features = ["cli", "test", "test_framework", "arbitrary"] }
vrl = { version = "0.8.1", features = ["cli", "test", "test_framework", "arbitrary"] }
vector-core = { path = "../vector-core", default-features = false, features = ["test"] }

[features]
Expand Down

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

2 changes: 1 addition & 1 deletion lib/file-source/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ default-features = false
features = []

[dependencies.indexmap]
version = "~2.0.2"
version = "2.1.0"
default-features = false
features = ["serde"]

Expand Down
2 changes: 1 addition & 1 deletion lib/prometheus-parser/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ license = "MPL-2.0"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
indexmap = "~2.0.2"
indexmap = "2.1.0"
nom = "7.1.3"
num_enum = "0.7.1"
prost = "0.12"
Expand Down
2 changes: 1 addition & 1 deletion lib/vector-common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ chrono = { version = "0.4", default-features = false, optional = true, features
crossbeam-utils = { version = "0.8.16", default-features = false }
derivative = { version = "2.2.0", default-features = false }
futures = { version = "0.3.29", default-features = false, features = ["std"] }
indexmap = { version = "~2.0.2", default-features = false, features = ["std"] }
indexmap = { version = "2.1.0", default-features = false, features = ["std"] }
metrics = "0.21.1"
nom = { version = "7", optional = true }
ordered-float = { version = "4.1.1", default-features = false }
Expand Down
2 changes: 1 addition & 1 deletion lib/vector-config/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ path = "tests/integration/lib.rs"
chrono = { version = "0.4.31", default-features = false }
chrono-tz = { version = "0.8.4", default-features = false }
encoding_rs = { version = "0.8", default-features = false, features = ["alloc", "serde"] }
indexmap = { version = "2.0", default-features = false, features = ["std"] }
indexmap = { version = "2.1.0", default-features = false, features = ["std"] }
inventory = { version = "0.3" }
no-proxy = { version = "0.3.4", default-features = false, features = ["serialize"] }
num-traits = { version = "0.2.17", default-features = false }
Expand Down
4 changes: 2 additions & 2 deletions lib/vector-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ futures-util = { version = "0.3.29", default-features = false, features = ["std"
headers = { version = "0.3.9", default-features = false }
http = { version = "0.2.9", default-features = false }
hyper-proxy = { version = "0.9.1", default-features = false, features = ["openssl-tls"] }
indexmap = { version = "~2.0.2", default-features = false, features = ["serde", "std"] }
indexmap = { version = "2.1.0", default-features = false, features = ["serde", "std"] }
lookup = { package = "vector-lookup", path = "../vector-lookup" }
metrics = "0.21.1"
metrics-tracing-context = { version = "0.14.0", default-features = false }
Expand Down Expand Up @@ -91,7 +91,7 @@ rand = "0.8.5"
rand_distr = "0.4.3"
tracing-subscriber = { version = "0.3.17", default-features = false, features = ["env-filter", "fmt", "ansi", "registry"] }
vector-common = { path = "../vector-common", default-features = false, features = ["test"] }
vrl = { version = "0.7.0", features = ["cli", "test", "test_framework", "arbitrary"] }
vrl = { version = "0.8.1", features = ["cli", "test", "test_framework", "arbitrary"] }

[features]
api = ["dep:async-graphql"]
Expand Down
2 changes: 1 addition & 1 deletion lib/vector-vrl/tests/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ publish = false

[dependencies]
enrichment = { path = "../../enrichment" }
vrl = { version = "0.7.0", features = ["test", "test_framework"] }
vrl = { version = "0.8.1", features = ["test", "test_framework"] }
vector-vrl-functions = { path = "../../vector-vrl/functions" }

ansi_term = "0.12"
Expand Down
2 changes: 2 additions & 0 deletions website/cue/reference/remap.cue
Original file line number Diff line number Diff line change
Expand Up @@ -247,10 +247,12 @@ remap: #Remap & {
│ │ │
│ │ this expression is fallible
│ │ update the expression to be infallible
│ │ note if an argument type is invalid it can render a function fallible
│ or change this to an infallible assignment:
│ structured, err = parse_key_value(.message)
= see documentation about error handling at https://errors.vrl.dev/#handling
= see functions characteristics documentation at https://vrl.dev/expressions/#function-call-characteristics
= learn more about error code 103 at https://errors.vrl.dev/103
= see language documentation at https://vrl.dev
= try your code in the VRL REPL, learn more at https://vrl.dev/examples
Expand Down
49 changes: 49 additions & 0 deletions website/cue/reference/remap/functions/contains_all.cue
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
package metadata

remap: functions: contains_all: {
category: "String"
description: """
Determines whether the `value` string contains all the specified `substrings`.
"""

arguments: [
{
name: "value"
description: "The text to search."
required: true
type: ["string"]
},
{
name: "substrings"
description: "An array of substrings to search for in `value`."
required: true
type: ["array"]
},
{
name: "case_sensitive"
description: "Whether the match should be case sensitive."
required: false
type: ["boolean"]
},
]
internal_failure_reasons: []
return: types: ["boolean"]

examples: [
{
title: "String contains all"
source: #"""
contains_all("The Needle In The Haystack", ["Needle", "Haystack"])
"""#
return: true
},
{
title: "String contains all (case sensitive)"
source: #"""
contains_all("the NEEDLE in the haystack", ["needle", "haystack"])
"""#
return: false
},
]

}
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ remap: functions: from_unix_timestamp: {
seconds: "Express Unix time in seconds"
milliseconds: "Express Unix time in milliseconds"
nanoseconds: "Express Unix time in nanoseconds"
microseconds: "Express Unix time in microseconds"
}
default: "seconds"
},
Expand Down
38 changes: 38 additions & 0 deletions website/cue/reference/remap/functions/parse_float.cue
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
package metadata

remap: functions: parse_float: {
category: "String"
description: """
Parses the string `value` representing a floating point number in base 10 to a float.
"""

arguments: [
{
name: "value"
description: "The string to parse."
required: true
type: ["string"]
},
]
internal_failure_reasons: []
return: types: ["float"]

examples: [
{
title: "Parse negative integer"
source: #"parse_float!("-42")"#
return: -42.0
},
{
title: "Parse negative integer"
source: #"parse_float!("42.38")"#
return: 42.38
},
{
title: "Scientific notation"
source: #"parse_float!("2.5e3")"#
return: 2500.0
},
]

}