vector_config_common/lib.rs
1#![deny(warnings)]
2
3// TODO: `darling` is currently strict about accepting only matching literal types for scalar fields i.e. a `f64` field
4// can only be parsed from a string or float literal, but not an integer literal... and float literals have to be in the
5// form of `1000.0`, not `1000`.
6//
7// This means we need to use float numbers for range validation if the field it's applied to is an integer.. which is
8// not great from a UX perspective. `darling` lacks the ability to incrementally parse a field to avoid having to
9// expose a custom type that gets used downstream...
10//
11// TODO: we should add a shorthand validator for "not empty". right now, for strings, we have to say
12// `#[configurable(validation(length(min = 1)))]` to indicate the string cannot be empty, when
13// something like `#[configurable(validation(not_empty)]` is a bit more self-evident, and shorter to boot
14
15pub mod attributes;
16pub mod constants;
17pub mod human_friendly;
18pub mod num;
19pub mod schema;
20pub mod validation;