Closed Bug 572929 Opened 14 years ago Closed 14 years ago

[k] Can delete entire forum by deleting the thread containing the last post

Categories

(support.mozilla.org :: Forum, task, P1)

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: jsocol, Assigned: rrosario)

Details

STR:

1) Create a new forum in the admin.
2) Create a new thread.
3) Delete the thread.

Expected:

Forum is empty.

Actual: 

Forum is gone!


Ricky, you figured this out when there was another deleting issue so I'm hoping this has a similar fix.
Looks like deleting the last post also causes this.
This only happens in the Master/Slave database scenario. Once the pinning db router lands, I think this will be fixed. We need to make sure that the router pins all reads on the initial POST in addition to requests after (within X seconds).

Django has this feature that you can't turn off:
"When Django deletes an object, it emulates the behavior of the SQL constraint ON DELETE CASCADE -- in other words, any objects which had foreign keys pointing at the object to be deleted will be deleted along with it."

We need to make sure that the reads it makes for this behavior are all pinned to the master through the db router.
Same fix as bug 572930
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Verified in support-stage-new, deleting threads and posts.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.