Skip to content

Delta Migration Feature#1044

Open
yashin4112 wants to merge 3 commits intodevfrom
feature/delta
Open

Delta Migration Feature#1044
yashin4112 wants to merge 3 commits intodevfrom
feature/delta

Conversation

@yashin4112
Copy link
Copy Markdown
Contributor

No description provided.

@yashin4112 yashin4112 closed this Apr 20, 2026
@yashin4112 yashin4112 reopened this Apr 20, 2026
@yashin4112 yashin4112 marked this pull request as ready for review April 20, 2026 11:59
@yashin4112 yashin4112 requested a review from a team as a code owner April 20, 2026 11:59
@umesh-more-cstk umesh-more-cstk requested a review from Copilot April 20, 2026 12:05
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Implements “delta migration” support by introducing an iteration counter, restart flow, and per-iteration mapping/UID persistence so subsequent runs can selectively recreate content types, deduplicate assets, and update existing entries.

Changes:

  • Replaces upload-api runtime config import with a JSON-backed config file and adds a helper to refresh/update config at runtime.
  • Adds “Restart Migration” UX + iteration tracking in UI (stepper/header/logs) and introduces an Entry Mapper table for iteration > 1.
  • Adds API support for iteration-scoped LowDB files (content types, fields, entries, uid-mapper) plus delta helpers (asset dedup + entry update script + restart endpoint).

Reviewed changes

Copilot reviewed 50 out of 55 changed files in this pull request and generated 9 comments.

Show a summary per file
File Description
upload-api/src/services/fileProcessing.ts Reads refreshed config during file validation/processing.
upload-api/src/services/aws/client.ts Switches AWS config source to JSON config file.
upload-api/src/routes/index.ts Refreshes config per request and returns sanitized config via /config.
upload-api/src/helper/index.ts Adds updateConfigFile helper for JSON config read/write.
upload-api/src/controllers/sitecore/index.ts Invokes Sitecore extractEntries during mapper creation.
upload-api/src/config/index.ts Removes TS-based config module.
upload-api/src/config/index.json Adds JSON-based config template.
upload-api/package.json Formatting-only change.
upload-api/migration-wordpress/libs/extractEntries.ts Adds WordPress entry extraction to build entryMapping.
upload-api/migration-sitecore/libs/extractEntries.js Adds Sitecore entry extraction to build entryMapping.
upload-api/migration-sitecore/index.js Exposes extractEntries from migration-sitecore package entrypoint.
upload-api/migration-drupal/libs/extractEntries.js Adds Drupal DB entry extraction to build entryMapping.
upload-api/migration-drupal/libs/createInitialMapper.js Attaches Drupal entryMapping into initial mapper output.
upload-api/migration-drupal/index.js Exposes extractEntries from migration-drupal package entrypoint.
upload-api/migration-contentful/libs/extractEntries.js Adds Contentful export entry extraction grouped by content type.
upload-api/migration-contentful/libs/createInitialMapper.js Attaches Contentful entryMapping into initial mapper output.
upload-api/migration-contentful/index.js Exposes extractEntries from migration-contentful package entrypoint.
upload-api/migration-aem/package-lock.json Lockfile updates (types/undici-types).
ui/src/services/api/migration.service.ts Adds restart + entry-mapping API calls for delta migration UI.
ui/src/pages/Migration/index.tsx Adds “Restart Migration” execution path and iteration increment.
ui/src/context/app/app.interface.ts Adds iteration and stepValue to migration state and defaults.
ui/src/components/Stepper/HorizontalStepper/HorizontalStepper.tsx Resets stepper state on restart/iteration increment.
ui/src/components/MigrationFlowHeader/index.tsx Derives CTA label (“Restart Migration”, etc.) into Redux state.
ui/src/components/LogScreen/MigrationLogViewer.tsx Avoids duplicate completion notifications; sets “Restart Migration” CTA.
ui/src/components/LegacyCms/legacyCms.scss Adds layout styles for editable local-path display.
ui/src/components/LegacyCms/Actions/LoadUploadFile.tsx Adds inline editing UX for local path in restart iterations.
ui/src/components/ContentMapper/index.tsx Switches to Entry Mapper view when iteration > 1; refetches on iteration change.
ui/src/components/ContentMapper/index.scss Scopes table wrapper styles under .content-mapper-container.
ui/src/components/ContentMapper/entryMapper.tsx New Entry Mapper table for selecting entries to update in delta runs.
ui/src/components/ContentMapper/contentMapper.interface.ts Adds EntryMapperType interface for entry-mapping table rows.
ui/package.json Formatting-only change.
package.json Formatting-only change.
api/src/utils/package.json Adds a package.json under src/utils (appears unrelated to runtime).
api/src/utils/field-attacher.utils.ts Makes content type creation conditional based on iteration and prior existence.
api/src/utils/entry-update.utils.ts Adds logic to remove/update entries and build update config for CLI script.
api/src/utils/entry-update-script.cjs Adds CLI migration script to update existing entries (incl. asset resolution).
api/src/utils/entry-duplicate.utils.ts Flags duplicate entries in entry mapper DB.
api/src/utils/content-type-checker.utils.ts Adds helper to skip content type creation if created in prior iterations.
api/src/utils/asset-update.utils.ts Adds asset dedup logic across iterations and ref replacement in entry JSON.
api/src/services/updateEntryCli.service.ts Adds service to run CLI “update entries” script after delta import.
api/src/services/runCli.service.ts Persists uid-mapping output into iteration-scoped LowDB (uid-mapper.json).
api/src/services/projects.service.ts Stores iteration on project creation; uses iteration-scoped DBs on delete.
api/src/services/migration.service.ts Adds restart endpoint + delta pre/post steps (asset dedup + entry updates).
api/src/services/contentMapper.service.ts Adds iteration-scoped DB access + entry-mapping endpoints + uid enrichment.
api/src/routes/migration.routes.ts Adds POST /restart/:orgId/:projectId route.
api/src/routes/contentMapper.routes.ts Adds entry mapping GET + entry status update PUT routes.
api/src/models/uidMapper.ts Adds iteration-scoped LowDB model for combined asset/entry uid mapping.
api/src/models/project-lowdb.ts Adds iteration field to Project model.
api/src/models/contentTypesMapper-lowdb.ts Converts content type mapper DB to iteration-scoped per-project storage.
api/src/models/FieldMapper.ts Converts field mapper DB to iteration-scoped per-project storage.
api/src/models/EntryMapper.ts Adds iteration-scoped LowDB model for entry mapper rows.
api/src/controllers/projects.contentMapper.controller.ts Exposes entry mapping + update status endpoints from controller.
api/src/controllers/migration.controller.ts Exposes restart migration endpoint from controller.
api/package.json Bumps CLI dependencies for migration/update flows.
Files not reviewed (1)
  • upload-api/migration-aem/package-lock.json: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread api/src/utils/entry-update.utils.ts
Comment thread api/src/utils/asset-update.utils.ts Outdated
Comment thread api/src/services/migration.service.ts Outdated
Comment thread upload-api/src/helper/index.ts
Comment thread api/src/services/updateEntryCli.service.ts Outdated
Comment thread api/src/utils/entry-update.utils.ts Outdated
Comment thread api/src/utils/entry-update.utils.ts Outdated
Comment thread api/src/routes/contentMapper.routes.ts
Comment thread ui/src/components/LegacyCms/Actions/LoadUploadFile.tsx Outdated
Comment thread api/src/services/contentMapper.service.ts Outdated
Comment thread api/src/services/contentMapper.service.ts Outdated
Comment thread api/src/services/contentMapper.service.ts Outdated
Comment thread api/src/services/contentMapper.service.ts Outdated
Comment thread api/src/services/contentMapper.service.ts Outdated
Comment thread upload-api/migration-drupal/libs/extractEntries.js Outdated
Comment thread upload-api/migration-drupal/libs/extractEntries.js Outdated
Comment thread upload-api/migration-sitecore/libs/extractEntries.js Outdated
Comment thread upload-api/migration-sitecore/libs/extractEntries.js Outdated
Comment thread upload-api/migration-sitecore/libs/extractEntries.js Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants