Get a Geo-Point from a nested field


(Adde) #1

Hello, I'm looking for a solution to get from my data a geo-point. I don't know how I can change the type. I tied it with a mapping, but it doesn't work.

Here is my .conf-File:
input {
kafka {
bootstrap_servers => "localhost:9092"
topics => ["flink_to_apama"]
}
}
filter {
json {
source => "message"
}
split {
field => "Impacts"
}
mutate {
rename => { "[Impacts][Location]" => "[Ort]"}
}
split {
field => "[Ort][StageLocation]"
}
mutate {
rename => { "[Ort][StageLocation]" => "[alllocations]"}
rename => { "[alllocations][GPSLatitude]" => "[location][lat]"}
rename => { "[alllocations][GPSLongitude]" => "[location][long]"}

}
geoip { source => "clientip" }
}
output {
elasticsearch {
hosts => ["localhost:9200"]
index => "addestryforalocation"
template => "logs_kafka_template.json"
template_name => "kafka-logstash-template"
}
}
This is the Mapping of "location" what shows me Kibana.

"location": {
"properties": {
"lat": {
"type": "float"
},
"long": {
"type": "float"
}
}
},
Can someone help me to find my mistake to make a locationmap in Kibana?


(Jon Budzenski) #2

Hey, this looks close. I think we'll want to rename long to lon, ref.

After this is done the mappings will still be float unfortunately, to change mappings we'll need to reindex or start from a fresh index.


(system) #3

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.