Apache Solr – Search Engine Basics
A Search Engine refers to a huge database of Internet resources such as web pages, newsgroups, programs, images, etc. It helps to locate information on the World Wide Web.
Users can search for information by passing queries into the Search Engine (using Solr) in the form of keywords or phrases. The Search Engine then searches its database and returns relevant links to the user.
Search Engine Components
Generally, there are three basic components of a search engine listed below −
- Web Crawler − Web crawlers are also called spiders or bots. It is a software component that traverses the web to gather information.
- Database − All the information on the Web is stored in databases. They contain a huge volume of web resources.
- Search Interfaces − This component is an interface between the user and the database. It helps the user to search through the database.
How do Search Engines Work?
Any search application is required to perform some or all of the following operations:
- Acquire Raw Content: The first step of any search application is to collect the target contents on which search is to be conducted.
- Build the document: The next step is to build the document(s) from the raw contents which the search application can understand and interpret easily.
- Analyze the document: Before indexing can start, the document is to be analyzed.
- Indexing the document: Once the documents are built and analyzed, the next step is to index them. This way document can be retrieved based on certain keys, instead of the whole contents of the document.
Indexing is similar to the indexes that we have at the end of a book. Common words are shown with their page numbers so that these words can be tracked quickly. This prevents the searching of the complete book.
- User Interface for Search: Once a database of indexes is ready, then the application can perform search operations. To help the user make a search, the application must provide a user interface. The place where the user can enter text and initiate the search process.
- Build Query: Once the user makes a request to search a text, the application should prepare a query object using that text. This can then be used to inquire the index database to get relevant details.
- Search Query: Using the query object, the index database is checked to get the relevant details and the content documents.
- Render Results: The application should decide how to display the results to the user using its User Interface.
Apart from these basic operations, search applications can also provide an administration-user interface. This helps the administrators control the level of search based on the user profiles. Analytics of search result is another important and advanced aspect of any search application.
Take a look at the following illustration. It shows an overall view of how Search Engines function.
The Layman Says, “It is a difficult task to move forward with something so new and fresh. Especially when we try and learn by implementing things on our own. With the help of basic tutorials and insights, I believe this is the easiest approach to have a good understanding about Solr. Every blog that you come across in this website is tailor made for the masses. I am no expert but by the end of each post, you’ll be sound in SOLR.”
Reference : https://www.tutorialspoint.com