where indexName represent the index name and type is inexType which came
from other side.when i execute this query,i assume that indextype is
deleted as well as all document which depend on indexType,but when i try to
index a document with same indexType and document id,i got the following
error:
org.elasticsearch.index.engine.DocumentAlreadyExistsEngineException:
[idx_masterdatabase][4] [type_testtable][3]: document already exists
at
org.elasticsearch.index.engine.robin.RobinEngine.innerCreate(RobinEngine.java:349)
at
org.elasticsearch.index.engine.robin.RobinEngine.create(RobinEngine.java:266)
at
org.elasticsearch.index.shard.service.InternalIndexShard.create(InternalIndexShard.java:272)
at
org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:418)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.access$100(TransportShardReplicationOperationAction.java:233)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:331)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
where indexName represent the index name and type is inexType which came
from other side.when i execute this query,i assume that indextype is
deleted as well as all document which depend on indexType,but when i try to
index a document with same indexType and document id,i got the following
error:
org.elasticsearch.index.engine.DocumentAlreadyExistsEngineException:
[idx_masterdatabase][4] [type_testtable][3]: document already exists
at
org.elasticsearch.index.engine.robin.RobinEngine.innerCreate(RobinEngine.java:349)
at
org.elasticsearch.index.engine.robin.RobinEngine.create(RobinEngine.java:266)
at
org.elasticsearch.index.shard.service.InternalIndexShard.create(InternalIndexShard.java:272)
at
org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:418)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.access$100(TransportShardReplicationOperationAction.java:233)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:331)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
where indexName represent the index name and type is inexType which came
from other side.when i execute this query,i assume that indextype is
deleted as well as all document which depend on indexType,but when i try to
index a document with same indexType and document id,i got the following
error:
org.elasticsearch.index.engine.DocumentAlreadyExistsEngineException:
[idx_masterdatabase][4] [type_testtable][3]: document already exists
at
org.elasticsearch.index.engine.robin.RobinEngine.innerCreate(RobinEngine.java:349)
at
org.elasticsearch.index.engine.robin.RobinEngine.create(RobinEngine.java:266)
at
org.elasticsearch.index.shard.service.InternalIndexShard.create(InternalIndexShard.java:272)
at
org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:418)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.access$100(TransportShardReplicationOperationAction.java:233)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:331)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
where indexName represent the index name and type is inexType which came
from other side.when i execute this query,i assume that indextype is
deleted as well as all document which depend on indexType,but when i try to
index a document with same indexType and document id,i got the following
error:
org.elasticsearch.index.engine.DocumentAlreadyExistsEngineException:
[idx_masterdatabase][4] [type_testtable][3]: document already exists
at
org.elasticsearch.index.engine.robin.RobinEngine.innerCreate(RobinEngine.java:349)
at
org.elasticsearch.index.engine.robin.RobinEngine.create(RobinEngine.java:266)
at
org.elasticsearch.index.shard.service.InternalIndexShard.create(InternalIndexShard.java:272)
at
org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:418)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.access$100(TransportShardReplicationOperationAction.java:233)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:331)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
Hmm, that would only work if there exist document of the TYPE. See "Using
Java API, how do I find out whether a given type exists in the index?" for
a better answer.
Op zaterdag 19 januari 2013 12:50:53 UTC+1 schreef Edward Smit het volgende:
You could fire a query for documents of the TYPE.
Op zaterdag 19 januari 2013 00:39:34 UTC+1 schreef Mxims het volgende:
Hi -
Is there a method (Java API) to check whether the TYPE exists before we
try to delete its mapping?
On Friday, April 27, 2012 1:49:49 AM UTC-7, kimchy wrote:
In the Java API, you have the option ot delete a mapping with its data,
client.admin().indices().prepareDeleteMapping
where indexName represent the index name and type is inexType which
came from other side.when i execute this query,i assume that indextype is
deleted as well as all document which depend on indexType,but when i try to
index a document with same indexType and document id,i got the following
error:
org.elasticsearch.index.engine.DocumentAlreadyExistsEngineException:
[idx_masterdatabase][4] [type_testtable][3]: document already exists
at
org.elasticsearch.index.engine.robin.RobinEngine.innerCreate(RobinEngine.java:349)
at
org.elasticsearch.index.engine.robin.RobinEngine.create(RobinEngine.java:266)
at
org.elasticsearch.index.shard.service.InternalIndexShard.create(InternalIndexShard.java:272)
at
org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:418)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.access$100(TransportShardReplicationOperationAction.java:233)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:331)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
On Saturday, January 19, 2013 3:54:12 AM UTC-8, Edward Smit wrote:
Hmm, that would only work if there exist document of the TYPE. See "Using
Java API, how do I find out whether a given type exists in the index?" for
a better answer.
Op zaterdag 19 januari 2013 12:50:53 UTC+1 schreef Edward Smit het
volgende:
You could fire a query for documents of the TYPE.
Op zaterdag 19 januari 2013 00:39:34 UTC+1 schreef Mxims het volgende:
Hi -
Is there a method (Java API) to check whether the TYPE exists before we
try to delete its mapping?
On Friday, April 27, 2012 1:49:49 AM UTC-7, kimchy wrote:
In the Java API, you have the option ot delete a mapping with its data,
client.admin().indices().prepareDeleteMapping
where indexName represent the index name and type is inexType which
came from other side.when i execute this query,i assume that indextype is
deleted as well as all document which depend on indexType,but when i try to
index a document with same indexType and document id,i got the following
error:
org.elasticsearch.index.engine.DocumentAlreadyExistsEngineException:
[idx_masterdatabase][4] [type_testtable][3]: document already exists
at
org.elasticsearch.index.engine.robin.RobinEngine.innerCreate(RobinEngine.java:349)
at
org.elasticsearch.index.engine.robin.RobinEngine.create(RobinEngine.java:266)
at
org.elasticsearch.index.shard.service.InternalIndexShard.create(InternalIndexShard.java:272)
at
org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:418)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.access$100(TransportShardReplicationOperationAction.java:233)
at
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:331)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.