Closed Bug 1492436 Opened 4 years ago Closed 3 years ago

Delete a recurring item if deleting the last occurrence


(Calendar :: Dialogs, enhancement)

Lightning 6.2
Not set


(Not tracked)



(Reporter: MakeMyDay, Assigned: MakeMyDay)



(1 file)

When deleting occurences of recurring events, the user currently can end up to have all occurences deleted, but the parent item stays in the calendar (however not accessible to the user anymore).

We should delete the recurring event if we delete the last occurrence of a recurring event.

As a folow up, we should over a cleanup job to remove recurring events without occurrences from the users calandars.
This seems easy to do if the rule is finite, especially so if it has a COUNT component since we can just compare the number of exdates. For those with UNTIL however, we'd have to iterate all the occurrences until rule end while removing from a Set with the exdates. For a very long running rule I think this could have a performance impact.

The same goes for the cleanup job, I think this could impact performance as well. We also need to figure out how to message this, because if it is a meeting event then deleting it may cause emails to be sent out.

Don't get me wrong though, I think it would be great to do this!
For the cleanup, I will file a separate bug.
Attachment #9010218 - Flags: review?(philipp)
Attachment #9010218 - Flags: approval-calendar-esr?(philipp)
Attachment #9010218 - Flags: approval-calendar-beta?(philipp)
Of cause this is just for finite rule or an rdate collection, since for infinte rules, you never get to have a last occurrence.

Performace might be an issue for the cleanup, that should be a background operation once all calendars have been loaded and TB is more or less ideling.
See my previous report for this: bug 351850.
Comment on attachment 9010218 [details] [diff] [review]

Review of attachment 9010218 [details] [diff] [review]:

Ok, lets take this. I'm a bit cautious still because I don't want to regress performance, so maybe we can run this on beta a bit to get a feel for it, and then reconsider for ESR.
Attachment #9010218 - Flags: review?(philipp)
Attachment #9010218 - Flags: review+
Attachment #9010218 - Flags: approval-calendar-esr?(philipp)
Attachment #9010218 - Flags: approval-calendar-esr-
Attachment #9010218 - Flags: approval-calendar-beta?(philipp)
Attachment #9010218 - Flags: approval-calendar-beta+
Sure, there's no need to rush. So let's let it bake a while on beta.
Keywords: checkin-needed
Pushed by
Delete a recurring item if the last occurrence is deleted; r=philipp
Closed: 3 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → 6.8
You need to log in before you can comment on or make changes to this bug.