Created
January 26, 2015 04:27
-
-
Save anonymous/3f07f1bd9f0598bb5a0b to your computer and use it in GitHub Desktop.
Kibana is giving the error -- TypeError: Cannot read property 'length' of undefined -- This is a search generated by kibana for the panel receiving error, it is working for me in the terminal for both remote and local curl requests generating the expected results.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#Dependencies elasticsearch on port 9200,kibana | |
cd ~ && mkdir KibanaElasticChapOne | |
wget http://www.elasticsearch.org/guide/en/kibana/current/snippets/shakespeare.json | |
curl -XPUT localhost:9200/_bulk --data-binary @shakespeare.json | |
curl -XGET 'localhost:9200/_all/_search?pretty' -d '{ | |
"facets": { | |
"terms": { | |
"terms": { | |
"field": "_type", | |
"size": 10, | |
"order": "count", | |
"exclude": [] | |
}, | |
"facet_filter": { | |
"fquery": { | |
"query": { | |
"filtered": { | |
"query": { | |
"bool": { | |
"should": [ | |
{ | |
"query_string": { | |
"query": "*" | |
} | |
} | |
] | |
} | |
}, | |
"filter": { | |
"bool": { | |
"must": [ | |
{ | |
"match_all": {} | |
}, | |
{ | |
"bool": { | |
"must": [ | |
{ | |
"match_all": {} | |
} | |
] | |
} | |
} | |
] | |
} | |
} | |
} | |
} | |
} | |
} | |
} | |
}, | |
"size": 0 | |
}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http://s3.postimg.org/q1s9kt4fn/Err_Img.png |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment