Just an update, If we use the op_type=create in the index request, will probably discard the duplicate document. But, in the case where we do a bulk operation will it stop the bulk upload? or will generate the error and move on to the next document?
thanks On Saturday, 15 February 2014 16:53:20 UTC+2, Thomas wrote: > > Hi, > > First of all congrats for the 1.0 release!! Thumbs up for the aggregation > framework :) > > I'm trying to build a system which is kind of querying for analytics. I > have a document called *event*, and I have events of specific type (e.g. > click open etc.) per page. So per page i might have for example an *open > event*. The thing is that I might as well take the open event *more than > once*, but I want to count it only once. So I use the versioning API and > I provide the same document id having as a result the version to increase. > > In my queries I use the _timestamp field to determine the last document > that I counted. But my problem is that since ES reindex the document, it > updates _timestamp so it seems as recent document, and in my queries I > count it again. > > Is there a way to simply *discard* the document if the document with the > same id exists, without stopping the bulk operation of uploading documents? > > Thanks > Thomas > -- You received this message because you are subscribed to the Google Groups "elasticsearch" group. To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/dbf19235-5b76-4a09-8b86-9a0fbf7e8d1c%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.