The most basic query is composed of a
value but can also contains a field
and its value, in the form of
field:value. When only specifying the value,
all fields are tested against it.
A query can use any field, visible or not, to match a value, such as:
special characters are available to use exclusively with
. - Matches any single character.
dc:a.stria matches the datacenter austria.
* - Matches the preceding character 0 or more times.
dc:can* matches the datacenters canada and vatican, but
+ - Matches the preceding character 1 or more times.
dc:ira+ matches the datacenters iran and iraq, but not
? - Matches the preceding character 0 or 1 time.
dc:oc?o matches the datacenter cameroon, but not morocco.
^ - Matches beginning of input.
dc:^por matches the datacenter portgual, but not
$ - Matches end of input.
dc:nea$ matches the datacenter guinea, but not
^((?!string).)*$ - Does not match the provided string.
check:^((?!check_critical).)*$ does not match the check
check_critical but does match check_warning.
client:^((?!foo).)*$ does not match the client
foo but does match bar.
When using negative lookahead, the field name must be unique within the object. The check and client field names can be used for this reason instead of name.
See the RegExp Object documentation for possible quantifiers.