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

Documents search with self hosted elasticsearch V8.12 #3816

Closed
1 task done
Serverfox opened this issue Jan 21, 2024 · 4 comments · Fixed by #3844
Closed
1 task done

Documents search with self hosted elasticsearch V8.12 #3816

Serverfox opened this issue Jan 21, 2024 · 4 comments · Fixed by #3844
Assignees
Labels
Milestone

Comments

@Serverfox
Copy link

Describe your question

Thank you for supporting ElasticPress, a great enhancement for WP search.

I'm running a self hosted ES instance in V8.12.0 which is doing a great job in my blog https://schulblog.net/fus/

I wonder, if there is a way to activate Documents Search in EP. At this point in time EP blocked this feature as the Attachement Ingest Plugin is not installed, being included by default in ES since V8. Is there a workaround to enable Documents anyway?

Thanks for your help and best regards

Jürgen

Code of Conduct

  • I agree to follow this project's Code of Conduct
@Serverfox
Copy link
Author

I found a filter like below described in #1020 (comment) but it wouldnt help in my case:

Anyone who finds this and doesn't want to edit the ElasticPress source, they've included a filter that thus far seems to be sufficient. I'll update if I have any issues. Keep in mind this is only helpful if you do, in fact, have the ingest attachment plugin setup on your ES instance and it isn't being reported properly, as is the case with AWS right now.

add_filter( 'ep_elasticsearch_plugins', function( $plugins ) {
    $plugins['ingest-attachment'] = true;
    return $plugins;
});

I wonder if there is a simple solution like the above.

@jerasokcm
Copy link

I faced a similar problem, using a dockerized instance of Elasticsearch 8.7.1, which also includes in the core the functionality provided by the ingest document plugin.
In my case, I used the filter mentioned by @Serverfox and then could index the documents without any issues, avoiding modifications of the Elasticpress code.

@Serverfox
Copy link
Author

Hi @jerasokcm , thanks for your confirmation. How did you employ this filter? Can you share details? Thank you

@felipeelia felipeelia added this to the 5.1.0 milestone Feb 6, 2024
@jerasokcm
Copy link

Hi @jerasokcm , thanks for your confirmation. How did you employ this filter? Can you share details? Thank you

I just copied that snippet and pasted in the functions.php file of my theme.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants