KV writes int as text - is it an ES dynamic mapping issue?
Posted: Sun Feb 15, 2015 6:31 am
Hi, I have a problem that has been talked about a lot with the ELK stack but I can't find any guidance here on it. I have used kv in my filters to split out an unknown number of key/value pairs from my logs (from the extension in CEF messages) and when I look at the raw output I can see what should be integers returned surrounded by quotes.
Now, I can fix this with specific grok filters but CEF messages are all different and neither the actual fields or their order are explicitly controlled. Thus, kv offers me the only way to combat this.
Other ELK forums have said to enable dynamic mapping within ES so it detects the type when first stored. This would solve my issue but of course the issue with ES is changing types later - if it detects an integer first then a character in that field in later messages will break it.
I believe kibana, being json based, doesn't care if numbers are quoted and will graph anything you tell it to. I suspect NLS UI would do the same, I think that the issue is the type detection only allowing me to choose bar, table or pie for a text field.
Any advice gladly received.
Thanks, --Chris
(If Nagios Support are reading this, its probably worth mentioning that I am doing a pre-sale eval on this at the moment vs Splunk and that this ability to graph CEF values is a must have for me)
Now, I can fix this with specific grok filters but CEF messages are all different and neither the actual fields or their order are explicitly controlled. Thus, kv offers me the only way to combat this.
Other ELK forums have said to enable dynamic mapping within ES so it detects the type when first stored. This would solve my issue but of course the issue with ES is changing types later - if it detects an integer first then a character in that field in later messages will break it.
I believe kibana, being json based, doesn't care if numbers are quoted and will graph anything you tell it to. I suspect NLS UI would do the same, I think that the issue is the type detection only allowing me to choose bar, table or pie for a text field.
Any advice gladly received.
Thanks, --Chris
(If Nagios Support are reading this, its probably worth mentioning that I am doing a pre-sale eval on this at the moment vs Splunk and that this ability to graph CEF values is a must have for me)