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

In Pie chart, terms of 2 words are considered as 2 different labels #302

Closed
pvledoux opened this issue Jul 30, 2013 · 6 comments
Closed
Labels
notabug When the issue is closed this label Indicates that it wasn't a bug

Comments

@pvledoux
Copy link

Hi,

I'm testing Kibana to do some analytics and I saw that terms of 2 words in Pie chart are displayed as 2 different label:

screen shot 2013-07-30 at 10 58 12

"Internet Explorer" as Internet and Explorer

screen shot 2013-07-26 at 17 29 54

"Mac Os x" as "Mac" "OS" "x"

Is there a way to keep those terms in one words?

Cheers,

@electrical
Copy link

You will need to set the field type in Elasticsearch to non_analyzed.
This can be done in templates ( see http://elasticsearch.org/guide/reference/api/admin-indices-templates/ )

@rashidkpc please correct me if i'm wrong :-)

@pvledoux
Copy link
Author

Well, I tried with the following mappings, but no luck:

{
    "trackedData": {
        "properties": {
            "user.agent.vendor": {
                "type":"string",
                "properties": {
                    "index": "not_analysed"
                }
            },
            "user.agent.platform": {
                "type":"string",
                "properties": {
                    "index": "not_analysed"
                }
            }
        }
    }
}

I also tried to declare user and agent as nested, but in that case, the pie chart is totally empty.

@dadoonet
Copy link
Member

What happens if you set it like this:

{
    "trackedData": {
        "properties": {
            "user.agent.vendor": {
                "type":"string",
                "index": "not_analyzed"
            },
            "user.agent.platform": {
                "type":"string",
                "index": "not_analyzed"
            }
        }
    }
}

@rashidkpc
Copy link
Contributor

Also note that you'll need to reindex your data after applying a mapping. Closing as notabug

@pvledoux
Copy link
Author

@dadoonet Merci David! Thanks @rashidkpc!

@SYNchroACK
Copy link

Hi guys,

I still had the same problem with Pie Dashboards. I tried a lot of possibilities and nothing. Please, can you check this following configuration:

------------------- LogStash configuration -------------------

input {
    tcp {
        port => 4000
        type => syslog
    }
}
filter {
    kv {
        field_split => ","
        value_split => "="
    }
}
output {
    stdout { debug => true debug_format => "json"}
    elasticsearch { embedded => true index => "mysystem" }
}

------------------- Mapping ElasticSearch -------------------

curl -XPUT http://localhost:9200/mysystem -d '{
    "settings" : {
        "number_of_shards" : 1
    },
    "mappings" : {
        "mysystem" : {
            "properties" : {
                "@fields" : {
                    "type" : "object",
                    "dynamic": true,
                    "path": "full",
                    "properties" : {
                        "as_name" : {"type" : "string", "index" : "not_analyzed"},
                        "asn" : {"type" : "integer"},
                        "ip" :{"type" : "string"}
                    }
                }
            }
        }
    }
}
'

------------------- Events to Insert -------------------

asn="1930",as_name="Portugal Network",ip="193.136.110.110"
asn="1930",as_name="Portugal Network",ip="193.136.120.120"
asn="1930",as_name="Other",ip="193.136.100.100"

Thank you,
Cheers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
notabug When the issue is closed this label Indicates that it wasn't a bug
Projects
None yet
Development

No branches or pull requests

5 participants