Skip to content

[Enhancement] Allow continue-on-error when insert duplicate records #71

@tamnguyenvt

Description

@tamnguyenvt

In mongodb i created an unique index on collection. This is to make sure we dont have duplicated records on database when logstash reprocess a file. But currently we cant do this silently and logstash keeps throwing error sth like An unexpected error occurred! {:error=>#<Mongo::Error::OperationFailure: E11000 duplicate key error collection:
This can be fixed by this solution. https://stackoverflow.com/questions/34153058/mongodb-multi-document-insert-ignore-custom-duplicate-field-error

Please can this be improved because its really helpful ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions