Dot Case
Synopsis
Converts strings to dot.case format.
Schema
- dotcase:
field: <ident>
target_field: <ident>
fields: <array>
exclude: <array>
description: <text>
if: <script>
ignore_failure: <boolean>
ignore_missing: <boolean>
on_failure: <processor[]>
on_success: <processor[]>
tag: <string>
Configuration
The following fields are used to define the processor:
| Field | Required | Default | Description |
|---|---|---|---|
field | N | - | Selects value mode: converts the value of this field to dot.case. The value must be a string or an array of strings. Mutually exclusive with fields — when field is set, fields and exclude are ignored |
target_field | N | Same as field | Where the converted value is written in value mode. Ignored in name mode |
fields | N | ["*"] | Selects name mode: glob patterns matching field names to rename to dot.case. The values are left untouched. a.* renames the keys inside object a, *.* those of every root object. Omitting both field and fields renames every root-level field name; names beginning with _ are never renamed |
exclude | N | - | Field names to leave alone in name mode. Has no effect in value mode |
description | N | - | Explanatory note |
if | N | - | Condition to run |
ignore_failure | N | false | Continue processing if conversion fails |
ignore_missing | N | false | Skip processing if referenced field doesn't exist |
on_failure | N | - | See Handling Failures |
on_success | N | - | See Handling Success |
tag | N | - | Identifier |
disabled | N | false | When true, the processor is skipped and the event continues to the next one. Lets you take a processor out of the path without removing its configuration |
Details
Converts string values to dot.case format by replacing spaces, hyphens, underscores, and other separators with dots, then converting all characters to lowercase. This format is commonly used in configuration files, namespacing, and object notation.
The processor handles various input formats and normalizes them to the consistent dot.case style with lowercase letters separated by dots.
dot.case format uses dots as separators and converts all text to lowercase, resulting in format like "user.name", "api.response.data", or "system.config.value".
The processor preserves the logical word boundaries from the input while standardizing the format for consistent usage in configuration systems or hierarchical naming.
Excessive dots or special characters in the input may result in multiple consecutive dots in the output. The processor does not automatically clean up redundant separators.
Examples
Basic Conversion
Converting field name to dot.case... | |
converts to dot notation: | |
Mixed Separators
Normalizing mixed separators to dots... | |
standardizes all separators to dots: | |
Configuration Namespace
Creating configuration namespace format... | |
creates namespace-style identifier: | |
Multiple Fields
Converting multiple fields to dot.case... | |
renames the matched names; the values are unchanged: | |