Problem/Motivation

From https://www.drupal.org/project/lingotek/issues/3055788#comment-13389986:

lingotek_post_update_lingotek_content_metadata_job_id() crashed our updb because LingotekContentMetadata::loadMultiple() tries to load like 100,000 entities. However, we also only have NULL job_id, so it doesn't do anything in our case. Instead of loading all lingotek content metadata, we should filter it down ahead of time, and probably use some batch processing.

Also worried about whether I have too much lingotek content metadata, and whether I should have job_ids.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

Comments

penyaskito created an issue. See original summary.

penyaskito’s picture

penyaskito’s picture

Issue summary: View changes
charginghawk’s picture

Status: Active » Needs review
StatusFileSize
new911 bytes

Here's an initial stab at a solution. My database doesn't actually have any of the bad job IDs, so I don't know if it solves that problem, but it doesn't try to load all entities any more.

penyaskito’s picture

StatusFileSize
new5.17 KB

@charginghawk Thanks for the patch! Looks like the regex query is not working.

I've created a patch that process them in batches, and the same for the other related post-update function for config.

penyaskito’s picture

Status: Needs review » Reviewed & tested by the community

Tests passed as expected.

  • penyaskito committed b34fc84 on 8.x-2.x
    Issue #3100900 by penyaskito, charginghawk:...
penyaskito’s picture

Status: Reviewed & tested by the community » Fixed

Committed b34fc84 and pushed to 8.x-2.x. Thanks!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.