Problem/Motivation

Follow up of https://www.drupal.org/project/paragraphs/issues/2764681#comment-14623940
When deleting an existing paragraph type, some content might already exist and should be deleted before the type deletion.
For now this process exists but is not batched, and can lead to time outs and memory limits when too many content have to be deleted.
When this situation happen, then it's simply impossible to delete the paragraph type without messing with the database itself.

Steps to reproduce

  • Create a paragraph type
  • Create 10 000 paragraph content of this type
  • Delete the paragraph type
  • Timeout/memory limit will happen

Proposed resolution

Define a batch process for the content deletion to avoid memory limit and timeouts.

Remaining tasks

Create a patch

User interface changes

A batch process will be launched after clicking on the "Delete X paragraphs" button.

API changes

None

Data model changes

None

Issue fork paragraphs-3299701

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Renrhaf created an issue. See original summary.

renrhaf’s picture

Status: Active » Needs review
berdir’s picture

Status: Needs review » Needs work

Tests failed.

ssd2698 made their first commit to this issue’s fork.