Olivier Dony
authored
When deleting filesystem-backed attachements, the deletion on the file-system is not transactional. In the event of a transaction rollback, the file deletion would not be rolled back, which is a dangerous side-effect. This can happen for example when several transactions try to delete the same file(s) at the same time. The duplicate deletions might be detected by the database (being concurrent update errors), and rolled back at the point of the DELETE query, to be retried. If the files have already been deleted in the file system it before the rollback, it leaves the system in an inconsistent state, at least temporarily. One case where we have seen it is when web bundles are loaded by many web users at the same time, right after being updated (and thus invalidated). As they are currently cached as ir.attachment records, this often causes a corruption of the cache.
Name | Last commit | Last update |
---|---|---|
.. | ||
addons | ||
cli | ||
conf | ||
modules | ||
osv | ||
report | ||
service | ||
tests | ||
tools | ||
workflow | ||
PKG-INFO | ||
__init__.py | ||
api.py | ||
exceptions.py | ||
fields.py | ||
http.py | ||
import_xml.rng | ||
loglevels.py | ||
models.py | ||
netsvc.py | ||
pooler.py | ||
release.py | ||
sql_db.py |