WPSOLR replaces the WordPress search by a faster and more accurate search powered by Elasticsearch, Apache Solr, Algolia, Opensearch, Weaviate or Google for retail.
The WPSOLR user guide will guide you through the configuration process.
The guide is shared by WPSOLR and WPSOLR PRO, and therefore some steps are not available to WPSOLR.
Step by step, you will be able to:
- Understand the general ideas driving the WordPress and Elasticsearch / Apache Solr integration
- Activate your license
- Install your desired compatible search engine on a separate server.
- Let WPSOLR handle Elasticsearch index creation and setup. Or create your Apache Solr index(es) with WPSOLR’s solrconfig.xml and schema.xml configuration files
- Configure your search results
- Configure the data you want to index
- Configure search weights (boosts)
- Configure search facets (filters)
- Configure Search sorts
- Configure localisations
- Activate and configure extensions
- Index your data with the batch
Architecture
In the follow diagram you can see the architecture of a WordPress website that’s equipped with WPSolr to integrate search engines.
- WordPress server :
- WP Media library : WordPress stores its images, videos and any other type of media in the media library on the server.
- WPSolr plugin : the WPSolr WordPress plugin acts as a bridge between the WordPress server and the search engine(s). It will send the WP data to the search engines and send queries to fetch objects from the search engine index.
- SQL database : stores the WordPress posts data and metadata.
- Search engine(s) : you can have either one or multiple search engines using the WPSolr “views” extension. Each one has it’s own index.
Indexing process
This is how WPSolr indexes the WordPress data :
- in the case of a traditional keyword search (Apache Solr, ElasticSearch, Opensearch, Algolia), WPSolr plugin fetches the Worpdress data and sends it to the different search engines. The search engines then store the data in their respective index.
- in the case of a vector search (in this case Weaviate), the data will be sent to the Weaviate but instead of directly storing the data, it will be sent to a transformers model (in a separate container) that will convert it into vectors. If you want to learn how to use any Huggingface transformers model as your Weaviate vectorizer, you can use the following guide : https://colab.research.google.com/drive/1UVlxl9BDtfeC7yHeQ98-Ihl4DtIrFqWQ?usp=sharing.