string

string #

CategoryScope
Parsingrecord

The “string” pipeline processor: the Graylog string-function toolbox as one processor (substring, prefix/suffix/ contains tests, split/join/concat, abbreviate, regex replace).

Configuration #

FieldTypeDefaultDescription
sourcestringSource field to read from.
target_fieldstringDestination field to write the result to.
substringlistint[start, end]
lengthstringtarget field for char count
starts_withstringOnly match strings starting with this prefix.
ends_withstringOnly match strings ending with this suffix.
containsstringOnly match strings containing this substring.
capitalizeboolCapitalize the resulting string.
swapcaseboolSwap the case of every character.
abbreviateintMaximum string length before it is abbreviated.
splitstringSplit the string on this separator.
split_limitintMaximum number of parts produced by the split.
joinstringSeparator used when joining parts.
concatliststringParts concatenated into the result.
replaceliststring[regex, replacement]
ignore_missingboolDo not fail when the source field is missing.
tag_on_failurestringTag appended when processing fails.

Example #

processor:
  - string:
      source: "message"
      target_field: "parsed"
      substring: []
      length: "length"
      starts_with: "starts_with"
Edit Edit this page