juju.txns.stash never cleaned
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Fix Released
|
High
|
John A Meinel |
Bug Description
When documents are Removed by mgo/txn they are staged into txn.stash (in case something would cause the transaction to abort, they can't be removed yet). And the transaction that moves them into the stash cannot actually delete them (for the same reason that it leaves its own txn identifier in the txn-queue).
However, there is no process by which removed items are ever purged from the txns.stash. Which means if you ever have a database that creates and deletes lots of documents, the txns.stash collection will fill up with removed documents.
Juju was updated to purge transactions that are no longer referenced, but this is a whole collection that will always just keep filling up and referencing transactions that we won't be able to ever delete.
We should include a step that walks the documents in txns.stash and ensures that for any document, all of its transactions are flagged as completed (or aborted?), and then remove the actual document from the stash.
Changed in juju: | |
status: | Triaged → In Progress |
tags: | added: canonical-is |
Changed in juju: | |
status: | Fix Committed → Fix Released |
https:/ /github. com/juju/ juju/pull/ 7224