Skip to content
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

Add locales support #160

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

daggerjames
Copy link

Add locale support for city_name and country_name etc.

@daggerjames daggerjames changed the title Add locales support on Add locales support Dec 13, 2019
@daggerjames
Copy link
Author

I have signed CLA :)

@kaisecheng
Copy link
Contributor

Thanks for submitting this enhancement. It is a valid idea to support multilingual names in this plugin.
Instead of having a city name in one language, enrich the event with multiple languages that user interest.
config

geoip {
  locales => [en, de, ja]
}

output

"geo" => {
    "timezone" => "America/Chicago",
    "country_name" => "United States",
    "location" => {
        "lat" => 37.751,
        "lon" => -97.822
    },
    "continent_code" => "NA",
    "country_iso_code" => "US"
    "name_with_locales" => {
        "country_name" => {
            "en" => "United States",
            "de" => "USA",
            "ja" => "アメリカ"
        }
    }
}

The above proposal keeps the structure backward compatible with Elastic Common Schema, which has assigned geo.* for Geo Fields. Keeping geo.country_name in English make search result in Kibana or Elasticsearch more predictable.

This proposal needs wider discussion with the team. I will keep this thread updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants