-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Security Solution][DQD] add nested field items for incompatible and … #184657
[Security Solution][DQD] add nested field items for incompatible and … #184657
Conversation
…same family fields Addresses elastic#184037 - Add `incompatibleFieldItems` and `sameFamilyFieldItems` as nested fields with required attributes.
Pinging @elastic/security-threat-hunting-explore (Team:Threat Hunting:Explore) |
Pinging @elastic/security-threat-hunting (Team:Threat Hunting) |
/ci |
@elasticmachine merge upstream |
💛 Build succeeded, but was flaky
Failed CI StepsMetrics [docs]
History
To update your PR or re-run it, just comment with: cc @kapral18 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From this mapping I can see we have expectedValue
and actualValue
Please correct me I am wrong, it seemed that we miss the information for expectedType
and actualType
In the incompatible field, it could be incompatible mapping or incompatible values
To create an index contains incompatible field types:
PUT auditbeat-custom-index-1
PUT auditbeat-custom-index-1/_mapping
{
"properties": {
"@timestamp": {
"type": "date"
},
"event.category": {
"type": "keyword",
"ignore_above": 1024
}
}
}
POST auditbeat-custom-index-1/_doc
{
"@timestamp": "2024-06-03T09:41:49.668Z",
"host": {
"name": "foo"
},
"event": {
"category": "an_invalid_category"
},
"some.field": "this",
"source": {
"port": 90210,
"ip": "10.1.2.3"
}
}
POST auditbeat-custom-index-1/_doc
{
"@timestamp": "2024-06-03T09:42:22.123Z",
"host": {
"name": "bar"
},
"event": {
"category": "an_invalid_category"
},
"some.field": "space",
"source": {
"port": 867,
"ip": "10.9.8.7"
}
}
POST auditbeat-custom-index-1/_doc
{
"@timestamp": "2024-06-03T09:43:35.456Z",
"host": {
"name": "baz"
},
"event": {
"category": "theory"
},
"some.field": "for",
"source": {
"port": 5,
"ip": "10.4.6.6"
}
}
POST auditbeat-custom-index-1/_doc
{
"@timestamp": "2024-06-03T09:44:36.700Z",
"host": {
"name": "@baz"
},
"event": {
"category": "malware"
},
"some.field": "rent",
"source": {
"port": 309,
"ip": "10.1.1.1"
}
}
To create an index with incompatible value:
PUT auditbeat-custom-index-2
PUT auditbeat-custom-index-2/_mapping
{
"properties": {
"@timestamp": {
"type": "date"
},
"event.category": {
"type": "keyword",
"ignore_above": 1024
}
}
}
POST auditbeat-custom-index-2/_doc
{
"@timestamp": "2024-06-03T09:41:49.668Z",
"host": {
"name": "foo"
},
"event": {
"category": "an_invalid_category"
},
"some.field": "this",
"source": {
"port": 90210,
"ip": "10.1.2.3"
}
}
Here is a PR explains the basic functionality of data quality dashboard: #150063 |
@angorayc The plan was to use the
This way we don't store undefined values, but I agree that we can also have |
Thanks for the clarification @semd. I didn't understand properly of how the data was stored, but I am happy with the existing mapping after understanding how it works. |
…same family fields
Addresses #184037
incompatibleFieldItems
andsameFamilyFieldItems
as nested fields with required attributes.Steps to verify the change:
GET .kibana-data-quality-dashboard-results-default/_mapping
incompatibleFieldItems
andsameFamilyFieldItems
new fields