You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
By default, OpenSearch replaces null values with a hyphen, for better human-readable format on visualizations and dashboards. The field is shown a null in the JSON representation of the document. The default replacement (hyphen) can be customized per field, allowing us to add any default value we see fit when there is no data for such field.
In the image below, we can see how fields using the null value are shown with a hyphen, making it clear that there is no value for such field, while fields whose value uses an empty string show nothing, which tend to be misleading as one could think something is broken in the visualization.
The goal of the issue is to ensure that any value indexed follows these criteria:
No empty values allowed.
When there is no value for such a field, null is used instead.
Functional requirements
The Wazuh Agent sends data to the Indexer, through the Wazuh Server, with no empty values.
The Wazuh Engine sends data to the Indexer, through the Indexer Connector, with no empty values.
The Wazuh Server sends data to the Indexer, through the API on port 9200, with no empty values.
Every component sending data to the Indexer ensures that empty values, if present, are properly replaced with null beforehand.
Implementation restrictions
We are referring explicitly to the null value, not the "null" string.
By empty values, we refer to empty instances of:
String: "" --> null.
Arrays: [] --> null or [null].
Empty values must either be replaced by null or not indexed.
Plan
Validation of data sent by the Agent to replace empty values.
Owner: @wazuh/devel-xdrsiem-agent
Teams involved: @wazuh/devel-xdrsiem-indexer @wazuh/devel-xdrsiem-server @wazuh/devel-xdrsiem-dashboard
Validation of data sent by the Engine to replace empty values.
Owner: @wazuh/devel-xdrsiem-server
Teams involved: @wazuh/devel-xdrsiem-indexer @wazuh/devel-xdrsiem-dashboard
Validation of data sent by the Server to replace empty values.
Owner: @wazuh/devel-xdrsiem-server
Teams involved: @wazuh/devel-xdrsiem-indexer @wazuh/devel-xdrsiem-dashboard
Proposal of null_value parameter in the index’s mappings
Owner: @wazuh/devel-xdrsiem-indexer
Teams involved: @wazuh/devel-xdrsiem-indexer @wazuh/devel-xdrsiem-dashboard @wazuh/devel-xdrsiem-server @wazuh/devel-xdrsiem-agent
The text was updated successfully, but these errors were encountered:
Description
Avoid indexing void data, such as empty strings, using
null
instead. Null values can become searchable by defining a replacement on the index mappings. See https://opensearch.org/docs/latest/field-types/supported-field-types/index/#null-valueBy default, OpenSearch replaces
null
values with a hyphen, for better human-readable format on visualizations and dashboards. The field is shown anull
in the JSON representation of the document. The default replacement (hyphen) can be customized per field, allowing us to add any default value we see fit when there is no data for such field.In the image below, we can see how fields using the
![Image](https://private-user-images.githubusercontent.com/15186973/407700390-93fc690c-1976-470f-88b9-aa7c7c858c68.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyNDMwMTMsIm5iZiI6MTczOTI0MjcxMywicGF0aCI6Ii8xNTE4Njk3My80MDc3MDAzOTAtOTNmYzY5MGMtMTk3Ni00NzBmLTg4YjktYWE3YzdjODU4YzY4LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjExVDAyNTgzM1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWUyOTAwODRjMjZjYTA0OTNkN2QyYzAzMzJhMWU5ZTQ3ODNhOThlNTRjMTVhNmRiMWM0Mzk3NjlhZjhiNDQ4MmUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.FKN97-Gv00sjNPJ9OfD37tn7XP9V7N4QS115Ghf3VP4)
null
value are shown with a hyphen, making it clear that there is no value for such field, while fields whose value uses an empty string show nothing, which tend to be misleading as one could think something is broken in the visualization.The goal of the issue is to ensure that any value indexed follows these criteria:
null
is used instead.Functional requirements
null
beforehand.Implementation restrictions
null
value, not the"null"
string.""
-->null
.[]
-->null
or[null]
.null
or not indexed.Plan
null_value
parameter in the index’s mappingsThe text was updated successfully, but these errors were encountered: