feat: batch sync content using action scheduler#247
Open
Kallyan01 wants to merge 31 commits into
Open
Conversation
…tion Scheduler and added db cleanup code
… asynchronous processing
…ement , improved sync UI
…g on history table
… in CI
Strauss 0.27.0 validates the GitHub OAuth token format, but the
GITHUB_TOKEN provided by GitHub Actions uses the ghs_* format
(contains underscores) which fails Strauss's regex validation.
Fix: run `composer install --no-scripts` to skip post-install-cmd,
then run `composer run prefix-namespaces` in a separate step with
`COMPOSER_AUTH: '{}'` to prevent Strauss from reading the invalid token.
Applies to both reusable-phpcs.yml and reusable-phpstan.yml.
Co-authored-by: Kallyan01 <48629100+Kallyan01@users.noreply.github.com>
…nd PHP compatibility - Add mock for /re-index/status fetch that fires on component mount - Update re-index modal test to use Close button and check dialog removal - Mock fetchHistory calls for modal open and reindex handler flows - Fix add_option deprecated empty string autoload parameter (use false) - Guard direct SQL query with prepare result type check - Update PHPStan types and ActionScheduler stub - Use COMPOSER_HOME isolation for strauss to avoid CI token validation failure - Upgrade strauss from 0.27.0 to 0.27.3 - Use overlayClassName on Modal with CSS :has() instead of wrapper div blur - Fix CSS formatting inconsistencies
…ent on SiteIndexableEntities component
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #247 +/- ##
=============================================
- Coverage 86.46% 67.34% -19.12%
- Complexity 543 969 +426
=============================================
Files 22 31 +9
Lines 1988 3859 +1871
=============================================
+ Hits 1719 2599 +880
- Misses 269 1260 +991
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Implements a full asynchronous batch sync/reindex system using Action Scheduler. Reindexing no longer runs synchronously in a single request; it now fans out into parent/child jobs that process in the background with progress tracking, retry logic, cancellation, and job history.
Why
The existing synchronous reindex blocked PHP execution and timed out on large sites with many posts or many child sites, which could not reliably complete a reindex. Moving to Action Scheduler lets each sync batch run independently, survive failures via exponential-backoff retries, and report real-time progress back to the admin UI.
Related Issue(s):
How
AI Disclosure
Took the help of the Claude Sonnet 4.6 model to verify future scalability issues and testcases.
Testing Instructions
Validate the reindexing process using a large dataset and ensure that the entire reindex operation completes successfully without failures.
Screenshots
Additional Info
Checklist