Skip to content

Instantly share code, notes, and snippets.

@keteracel
keteracel / elasticsearch
Created May 11, 2011 22:05
Elastic search start script with fixes under cygwin
#!/bin/sh
# OPTIONS:
# -f: start in the foreground
# -p <filename>: log the pid to a file (useful to kill it later)
# CONTROLLING STARTUP:
#
# This script relies on few environment variables to determine startup
# behavior, those variables are:
@keteracel
keteracel / _cluster state
Created May 8, 2011 18:03
The indices and mappings
"indices" : {
"i3" : {
"state" : "open",
"settings" : {
"index.analysis.analyzer.ascii_edge_ngram.filter.1" : "lowercase",
"index.analysis.analyzer.ascii_std.filter.1" : "lowercase",
"index.analysis.analyzer.ascii_ngram.type" : "custom",
"index.analysis.analyzer.ascii_edge_ngram.filter.2" : "asciifolding",
"index.analysis.analyzer.ascii_std.filter.2" : "asciifolding",
"index.analysis.analyzer.ascii_ngram.filter.0" : "standard",
@keteracel
keteracel / es_mapping_issue
Created May 8, 2011 17:49
Mappings don't seem to work as expected
curl -XPUT 'http://127.0.0.1:9200/i1/?pretty=1' -d '
{
"settings" : {
"analysis" : {
"filter" : {
"edge_ngram" : {
"side" : "front",
"max_gram" : 20,
"min_gram" : 1,
"type" : "edgeNGram"