-
Notifications
You must be signed in to change notification settings - Fork 6
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
Move partial index into the typo3 database #138
base: master
Are you sure you want to change the base?
Conversation
.github/workflows/ci.yml
Outdated
tags: | ||
- '*' | ||
pull_request: | ||
branches: | ||
- master | ||
- '*' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These changes seem unrelated and unnecessary, please revert them again.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Without the change we have no CI on the pull request as it does not target the master branch.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case please add your temporary target branch instead. This ensures that there is no issue if this forgotten and merged as is.
@@ -0,0 +1,55 @@ | |||
<?php | |||
|
|||
return [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We actually don't need any TCA for this table if we don't use the Extbase persistence.
} | ||
} | ||
|
||
public function pendingUpdates(string $type = null): array |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Personally I'd do this via IteratorAggregate::getIterator()
instead. Then check if we can yield from
the DBAL result. This would allow for consuming code to do this:
foreach ($this->updateQueue as $update) { ... }
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As it needs to be filterable by type I think the current implementation is cleaner than the alternatives.
Using a Generator or passing the fetchAssociative directly (not a big fan) would be an option. But as it is only used in the preparation step to collect the to update uids and because of needed deduplication it should only a have minor impacts
@@ -0,0 +1,70 @@ | |||
<?php | |||
namespace PAGEmachine\Searchable\Domain\Repository; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Domain may be OK but it's not a repository anymore, so it should be moved somewhere else.
.github/workflows/ci.yml
Outdated
tags: | ||
- '*' | ||
pull_request: | ||
branches: | ||
- master | ||
- master | ||
- ES7V2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you rebase on master
and drop these changes? #136 was merged. :-)
By moving the partial index from elasticsearch to typo3 it decouples the typo3 save process from elasticsearch. The current implementation results in long saving times in the typo3 backend if the Elasticsearch server was responding slow.