Skip to content

[app] deleting source with incomplete message downloads should abort and delete cleanly #3132

@vickiniu

Description

@vickiniu

In the case where we receive a new source with many messages (tested with 5000) but want to actually delete this source before all messages finish downloading, we would expect that:

  • Messages queued for download/decryption should be removed from the queue on the pending deletion event
  • All messages should eventually be submitted through sync for deletion by the server
  • Pending deleted messages should not be re-downloaded in the interim time

Related to #3030

This means that we should:

  • Update an item's fetch_progress to be some new state like SCHEDULED_DELETION
  • Check all item fetch_progress before incrementing or taking up work + drop
  • Only queue N number of items for processing at a time, and enqueue more during sync as needed
  • Check that items are not already pending deletion when receiving new sync message

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Ready to go

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions