Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor Unique Field Data Migration #31313

Open
jdotcms opened this issue Feb 6, 2025 · 1 comment · May be fixed by #31338
Open

Refactor Unique Field Data Migration #31313

jdotcms opened this issue Feb 6, 2025 · 1 comment · May be fixed by #31338

Comments

@jdotcms
Copy link
Contributor

jdotcms commented Feb 6, 2025

Parent Issue

No response

Task

Currently unique fields does the most of the migration work based on db; this means the start up is lock until the query gets done for a while.
As a Saas we need to do the migration in background, be not eager on resources (lock tables for a while or use intensive gpu), also the tracking is not possible since the query run as an one unit, the process one by one give us more logs and granularity about any error for a single contentlet (for instance if a contentlet unique field generations fails, we can track and continue with others)

  1. The proposal will use a Thread pool with two thread max, in order to run 2 content types at the same time.
  2. The proposal will have more logs, so we can see the progress or how is it going
  3. The proposal could be fire automatically or by demand, it allow us to do not need to restart the server in case we need to dry run and re-run (aka run by rest only ADMIN)
  4. The proposal will use a batches of 100 contentlets per read per thread to avoid the intensive usage of the cpu and memory
  5. In order to avoid the starvation, we need to sleep the two threads any time a batch is processed by one second (configurable) this will allow other threads in competition to do their work

Proposed Objective

Core Features

Proposed Priority

Priority 3 - Average

Acceptance Criteria

No response

External Links... Slack Conversations, Support Tickets, Figma Designs, etc.

No response

Assumptions & Initiation Needs

No response

Quality Assurance Notes & Workarounds

No response

Sub-Tasks & Estimates

No response

Copy link

@jdotcms jdotcms linked a pull request Feb 10, 2025 that will close this issue
@john-thomas-dotcms john-thomas-dotcms changed the title Refactor Unique Field Refactor Unique Field Data Migration Feb 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: New
Development

Successfully merging a pull request may close this issue.

2 participants