-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Remove Lucene from built-in recipes (Lombiq Technologies: OCORE-84) #11328
Conversation
Two tests don't work anymore because the base Blog recipe doesn't contain Lucene anymore. What should I do with them? Can I delete them? |
The tests need to be kept but modify them that they can utilize the new factored out recipes. |
src/OrchardCore.Themes/TheBlogTheme/Recipes/blog.lucene.setup.recipe.json
Outdated
Show resolved
Hide resolved
src/OrchardCore.Themes/TheBlogTheme/Recipes/blog.lucene.setup.recipe.json
Outdated
Show resolved
Hide resolved
src/OrchardCore.Themes/TheBlogTheme/Recipes/blog.lucene.recipe.json
Outdated
Show resolved
Hide resolved
src/OrchardCore.Themes/TheBlogTheme/Recipes/blog.lucene.query.recipe.json
Show resolved
Hide resolved
Co-authored-by: Zoltán Lehóczky <[email protected]>
Could you please also do a review now, @Skrypt? |
Co-authored-by: Zoltán Lehóczky <[email protected]>
I will do it tomorrow. |
Thanks! |
@@ -44,6 +44,7 @@ public async Task ExecuteAsync(RecipeExecutionContext context) | |||
{ | |||
luceneIndexSettings.Value.IndexName = luceneIndexSettings.Key; | |||
await _luceneIndexingService.CreateIndexAsync(luceneIndexSettings.Value); | |||
await _luceneIndexingService.ProcessContentItemsAsync(luceneIndexSettings.Key); |
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.
This can cause a request timeout which is why it was not added. In this case, if the recipe fails to execute then executing it a second time would probably not work.
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.
It should be a fire and forget type of execution here. Start the indexing background task for example.
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.
Looks good except the recipe step should not process the content items. Also, it may fail to index these Blog Posts since they are probably not added yet to the IndexingTask table.
Can you assert that the IndexingTask table has records before executing the recipes? Else, we will need a method to resync the already created content items in that table. |
Ok, this works with TheBlog recipe because we enable the Lucene feature from the setup. But let's say we do the same but with the SaaS recipe then. I'm pretty sure that the IndexingTask table will not be there. So, if we create content items before enabling the Lucene feature then these content items will not be added to the IndexingTask table. I'm ok to merge the current PR as is since this is a known issue that needs to be fixed. But we could fix it with a different PR. |
Fixes #11203