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

VERIFIED FIXED in 2.1

Status

support.mozilla.org
Forum
P1
blocker
VERIFIED FIXED
8 years ago
8 years ago

People

(Reporter: jsocol, Assigned: rrosario)

Tracking

unspecified

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

8 years ago
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.
(Reporter)

Comment 1

8 years ago
Looks like deleting the last post also causes this.
(Assignee)

Comment 2

8 years ago
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.
(Assignee)

Comment 3

8 years ago
Same fix as bug 572930
Status: NEW → RESOLVED
Last Resolved: 8 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.