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

Introducing partial reindexes (BC Break) #460

Merged
merged 13 commits into from
Dec 18, 2024

Conversation

Toflar
Copy link
Member

@Toflar Toflar commented Nov 21, 2024

BC Breaks

To upgrade add the new ReindexConfig parameter to the your ReindexProvider:

-    public function provide(): \Generator
+    public function provide(ReindexConfig $reindexConfig): \Generator
+$reindexConfig = ReindexConfig::create()
+    ->withIndex('blog')
+    ->withDrop(true)
+    ->withBulkSize(100);

 $engine->reindex(
     iterable $reindexProviders,
+    $reindexConfig,
-    string|null $index = null,
-    bool $dropIndex = false,
-    int $bulkSize = 100,
     callable|null $progressCallback = null,
 );

@alexander-schranz alexander-schranz added this to the 1.0.0 milestone Nov 21, 2024
@alexander-schranz alexander-schranz added features New feature or request SEAL Core Seal Core related issue Integration: Symfony Symfony related issue Integration: Laravel Laravel related issue Integration: Spiral Spiral related issue Integration: Mezzio Mezzio related issue labels Nov 21, 2024
@Toflar Toflar marked this pull request as ready for review December 13, 2024 15:11
@alexander-schranz
Copy link
Member

Still unsure about the ReindexConfig but I think we can currently go with it.

@alexander-schranz alexander-schranz merged commit 4f765ab into PHP-CMSIG:0.6 Dec 18, 2024
32 checks passed
leofeyer pushed a commit to contao/contao that referenced this pull request Dec 19, 2024
Description
-----------

This PR brings two changes. It refactors to the new re-index framework in SEAL that was merged yesterday (PHP-CMSIG/search#460) and uses the new `bulk()` endpoints. Indexing will now be way faster 😊 

Also, now that we are on the SEAL framework, the temporary `contao:backend-search:index` has been dropped and we are now fully on the SEAL framework, meaning you have to run `cmsig:seal:reindex` instead 😎

Commits
-------

ccf7dd5 Refactor to PHP CMS-IG SEAL
933ce35 Adjust depcheck
d8209d9 Adjust depcheck
8573b7f Adjust depcheck
f2c1b75 WIP
733dc7b Switch to new SEAL ReindexProvider framework
a153665 Missing test and CS
leofeyer pushed a commit to contao/core-bundle that referenced this pull request Dec 19, 2024
Description
-----------

This PR brings two changes. It refactors to the new re-index framework in SEAL that was merged yesterday (PHP-CMSIG/search#460) and uses the new `bulk()` endpoints. Indexing will now be way faster 😊 

Also, now that we are on the SEAL framework, the temporary `contao:backend-search:index` has been dropped and we are now fully on the SEAL framework, meaning you have to run `cmsig:seal:reindex` instead 😎

Commits
-------

ccf7dd54 Refactor to PHP CMS-IG SEAL
933ce355 Adjust depcheck
d8209d9d Adjust depcheck
8573b7fa Adjust depcheck
f2c1b75f WIP
733dc7b7 Switch to new SEAL ReindexProvider framework
a1536658 Missing test and CS
alexander-schranz pushed a commit that referenced this pull request Dec 27, 2024
Fix and add missing parts of
#460
alexander-schranz pushed a commit to PHP-CMSIG/seal-symfony-bundle that referenced this pull request Dec 27, 2024
alexander-schranz pushed a commit to PHP-CMSIG/seal-spiral-bridge that referenced this pull request Dec 27, 2024
alexander-schranz pushed a commit to PHP-CMSIG/seal-laravel-package that referenced this pull request Dec 27, 2024
alexander-schranz pushed a commit to PHP-CMSIG/seal-mezzio-module that referenced this pull request Dec 27, 2024
alexander-schranz pushed a commit to PHP-CMSIG/seal-yii-module that referenced this pull request Dec 27, 2024
@alexander-schranz alexander-schranz changed the title Introducing partial reindexes Introducing partial reindexes (BC Breaks) Dec 27, 2024
@alexander-schranz alexander-schranz changed the title Introducing partial reindexes (BC Breaks) Introducing partial reindexes (BC Break) Dec 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
features New feature or request Integration: Laravel Laravel related issue Integration: Mezzio Mezzio related issue Integration: Spiral Spiral related issue Integration: Symfony Symfony related issue SEAL Core Seal Core related issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants