Mongodb - MongoDB Input threw an exception, restarting {:exception=>#<BSON::ObjectId::Invalid: '003cd541-2dd3-4a8e-89b0-595c74a9e4f9' is an invalid ObjectID

Hi I am getting this error during creation of index from mongodb input plugin.
I have also integrate filter and remove _id filed but still getting same error.


input {
mongodb{
        uri => "mongodb+srv://localhost:27017/mydb?ssl=false"
	        placeholder_db_dir => "/opt/logstash-mongodb/"
        placeholder_db_name => "logstash_sqlite2.db"
        collection => "transaction"
        batch_size => 5000
}
}

filter {
mutate {
copy => { "_id" => "[@metadata][_id]"}
remove_field => ["_id"]

}
}



output {
elasticsearch {
hosts => ["http://localhost:9200"]
index => "transaction-logs-new-%{+dd.MM.YYYY}"
}

stdout {}
}

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.