Skip to content

Instantly share code, notes, and snippets.

curl -XPUT localhost:9200/test -d '{
"settings" : {
"analysis": {
"analyzer" : {
"name_nGram" : {
"tokenizer" : "standard",
"filter" : "standard,lowercase,name_nGram"
},
"name_edgeNGram" : {
"tokenizer" : "standard",
curl -XPOST 'http://localhost:9200/twitter/_optimize?max_num_segments=2'
curl -XPUT 'http://localhost:9200/_template/template_logstash/' -d '
{
"template": "logstash-*",
"mappings": {
"_default_": {
"_source": { "compress": "true" },
"_all" : {"enabled" : false}
}
}
}'
curl -XPUT 'http://localhost:9200/_template/template_logstash/' -d '
{
"template": "logstash-*",
"mappings": {
"_default_": { "_source": { "compress": "true" } }
}
}'
Index: src/main/java/org/elasticsearch/index/query/CustomFiltersScoreQueryParser.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- src/main/java/org/elasticsearch/index/query/CustomFiltersScoreQueryParser.java (date 1324946452000)
+++ src/main/java/org/elasticsearch/index/query/CustomFiltersScoreQueryParser.java (revision )
@@ -21,7 +21,6 @@
import org.apache.lucene.search.Filter;
curl -XPUT localhost:9200/test/type/1 -d '{
"a" : {
"x" : "aaa"
},
"b" : {
"x" : "bbb"
}
}'
curl -XPUT localhost:9200/test/type/2 -d '{
curl -XPUT localhost:9200/test -d '{
"mappings" : {
"type1" : {
"properties" : {
"linkImgUrl":{"type":"string", index:"not_analyzed"}
}
}
}
}'
curl -XPUT localhost:9200/test/type1/1 -d '{
a : [
{ x:1, y:2 },
{ x:2, y:3 }
]
}'
curl -XPOST localhost:9200/test/_refresh
curl 'localhost:9200/test/_search?q=*&fields=a.x'
index:
analysis:
analyzer:
string_lowercase:
tokenizer: keyword
filter: lowercase
curl -XPUT 'http://localhost:9200/_percolator/sp6/mehtryx' -d '{"request":{"id":139051389555982340,"from":"PythiaTest","sent":"Tue, 22 Nov 2011 18:43:29 +0000","message":"@AskPythia Toronto Maple Leafs"},"query":{"bool":{"must":[{"query_string":{"query":"Toronto Maple Leafs","default_operator":"AND"}},{"term":{"type":"STRY"}}]}}}'