0
我在我的機器上一個運行兩個elasticsearch版本是1.7等2.3 我能指數1.7版本的文檔,但相同的索引的語句拋出u'caused_by': {u'reason': u'Java heap space', u'type': u'out_of_memory_error'}
在2.3。Elasticsearch 2.3 VS elasticsearch 1.7 Java堆空間
映射爲Elasticsearch 2.3
{
"id": {
"type": "integer",
"store": "yes",
"index": "analyzed"
},
"field1": {
"type": "integer",
"store": "yes",
"index": "no"
},
"field2": {
"type": "integer",
"store": "yes",
"index": "no"
},
"field3": {
"type": "string",
"store": "yes",
"index": "no"
},
"field4": {
"type": "geo_shape",
"tree": "legacyquadtree",
"precision": "1mm"
}
}
映射爲Elasticsearch 1.7
{
"id": {
"type": "integer",
"store": "yes",
"index": "analyzed"
},
"field1": {
"type": "integer",
"store": "yes",
"index": "no"
},
"field2": {
"type": "integer",
"store": "yes",
"index": "no"
},
"field3": {
"type": "string",
"store": "yes",
"index": "no"
},
"field4": {
"type": "geo_shape",
"tree": "quadtree",
"precision": "1mm"
}
}
其被用於索引的文檔結構是(兩者相同2.3和1.7 )
{
"field4":
{"type": "envelope", "coordinates":
data},
"id": id,
"field1": val1,
"field2": val2,
"field3": val3
}
指定的JAVA_HEAP_SIZE
是兩個版本的默認值。