Page MenuHomePhabricator

If you somehow create a draft with an enormous version, it can get stuck in the database for a very long time
Closed, ResolvedPublic

Description

This probably won't happen on any real install, but if you do something like this:

  • Type some comments on Txxx after thousands of transactions have happened.
  • Truncate your entire transaction table.
  • Interact with Txxx again.

...you can end up with a very sticky draft with an internal ID like 7000 when new transaction IDs aren't that high. It will stick around until the transaction count catches up again.

To reproduce more simply, set the version for any draft_versioneddraft row to a bazillion and then interact with the object.

A possible fix is just to make purgeDrafts() delete everything (i.e., remove the version clause). It's not clear why this clause exists, and it was introduced with everything else in D14640.

Revisions and Commits

Restricted Differential Revision

Event Timeline

epriestley triaged this task as Wishlist priority.Feb 11 2018, 2:03 AM
epriestley created this task.
epriestley added a revision: Restricted Differential Revision.Feb 11 2018, 1:52 PM
epriestley closed this task as Resolved by committing Restricted Diffusion Commit.Feb 11 2018, 2:01 PM
epriestley added a commit: Restricted Diffusion Commit.