Commit e61ed61c authored by Jérome Perrin's avatar Jérome Perrin

Hack: Serialize document module

When running multiple parralel ingestion updating documents inplace,
manage_delObjects complains that object is already removed (which is not the
case)
parent 4130b11d
......@@ -634,6 +634,9 @@ class Document(DocumentExtensibleTraversableMixin, XMLObject, UrlMixin,
if k not in FIXED_PROPERTY_IDS and self.hasProperty(k):
update_kw[k] = self.getProperty(k)
existing_document.edit(**update_kw)
self.getParentValue().serialize()
import transaction
transaction.savepoint(optimistic=True)
# Erase self
self.getParentValue().manage_delObjects([self.getId(),])
return document
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment