We had an incorrect Elasticsearch index on our install. I ran ./bin/search init and this fixed it, but why does this happen?
Before
josh@ip-10-178-162-119:~$ curl http://localhost:9200/_mapping/?pretty=true
{
"phabricator" : {
"mappings" : {
"BOOK" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"proj" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"ATOM" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"book" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"clos" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"open" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"WIKI" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"auth" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"clos" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"open" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"subs" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"CMIT" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"auth" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"proj" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"repo" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"subs" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"MOCK" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"auth" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"subs" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"CDTL" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"clos" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"open" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"TASK" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"auth" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"clos" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"open" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"ownr" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"proj" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"subs" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"unow" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"PROJ" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"clos" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"open" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"subs" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"USER" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"clos" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"open" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"DREV" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"auth" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"clos" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"open" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"ownr" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"proj" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"subs" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"unow" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
}
}
}
}
josh@ip-10-178-162-119:~$ curl http://localhost:9200/_settings/?pretty=true
{
"phabricator" : {
"settings" : {
"index" : {
"creation_date" : "1434493425446",
"uuid" : "ehll6uMuQgGk2IJnr2_YFg",
"number_of_replicas" : "1",
"number_of_shards" : "5",
"version" : {
"created" : "1050299"
}
}
}
}
}After
josh@ip-10-178-162-119:~$ curl http://localhost:9200/_mappings/?pretty=true
{
"phabricator" : {
"mappings" : {
"CDTL" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"MOCK" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"CEVT" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"QUES" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"PROJ" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"WIKI" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"TASK" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"ATOM" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"USER" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"CMIT" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"BOOK" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"DREV" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
},
"type" : {
"type" : "string"
}
}
},
"relationship" : {
"properties" : {
"auth" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"open" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "long"
}
}
},
"ownr" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
},
"subs" : {
"properties" : {
"phid" : {
"type" : "string"
},
"phidType" : {
"type" : "string"
},
"when" : {
"type" : "string"
}
}
}
}
},
"title" : {
"type" : "string"
},
"url" : {
"type" : "string"
}
}
},
"FITV" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
},
"CONP" : {
"properties" : {
"dateCreated" : {
"type" : "string"
},
"field" : {
"properties" : {
"corpus" : {
"type" : "string",
"analyzer" : "custom_trigrams"
}
}
}
}
}
}
}
}
josh@ip-10-178-162-119:~$ curl http://localhost:9200/_settings/?pretty=true
{
"phabricator" : {
"settings" : {
"index" : {
"creation_date" : "1434605498512",
"auto_expand_replicas" : "0-2",
"uuid" : "sks9-McTQsCWQa18VGySaA",
"number_of_replicas" : "0",
"analysis" : {
"filter" : {
"trigrams_filter" : {
"min_gram" : "3",
"type" : "ngram",
"max_gram" : "3"
}
},
"analyzer" : {
"custom_trigrams" : {
"type" : "custom",
"filter" : [ "lowercase", "kstem", "trigrams_filter" ],
"tokenizer" : "standard"
}
}
},
"number_of_shards" : "5",
"version" : {
"created" : "1050299"
}
}
}
}
}