I'm wondering if anyone has a solution for the huge bulk_docs performance hit incurred when using javascript validate_doc_update functions ~100k docs (2.6MB of json) log_level info without validation: 0m2.663s log_level info and validation: 0m30.778s (yes, it went from 2 seconds to 30 seconds when I added a validation function) validation function: ddoc.validate_doc_update = function (newDoc, oldDoc, userCtx) { if (newDoc._deleted === true && userCtx.roles.indexOf('_admin') === -1) { throw "Only admin can delete documents on this database."; } }; is it possible to write these functions in erlang? max