📜  Apache Solr-搜索引擎基础知识

📅  最后修改于: 2020-12-02 05:42:25             🧑  作者: Mango


搜索引擎是指庞大的Internet资源数据库,例如网页,新闻组,程序,图像等。它有助于在Internet上定位信息。

用户可以通过将查询以关键字或短语的形式传递到搜索引擎中来搜索信息。然后,搜索引擎在其数据库中搜索并将相关链接返回给用户。

谷歌搜索

搜索引擎组件

通常,搜索引擎包含以下三个基本组成部分-

  • Web爬虫-Web爬虫也称为蜘蛛机器人。它是遍历网络以收集信息的软件组件。

  • 数据库-Web上的所有信息都存储在数据库中。它们包含大量的Web资源。

  • 搜索接口-该组件是用户和数据库之间的接口。它可以帮助用户搜索数据库。

搜索引擎如何工作?

任何搜索应用程序都需要执行以下一些或全部操作。

Step Title Description

1

Acquire Raw Content

The very first step of any search application is to collect the target contents on which search is to be conducted.

2

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.

3

Analyze the document

Before indexing can start, the document is to be analyzed.

4

Indexing the document

Once the documents are built and analyzed, the next step is to index them so that this 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 where common words are shown with their page numbers so that these words can be tracked quickly, instead of searching the complete book.

5

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 where the user can enter text and initiate the search process

6

Build Query

Once the user makes a request to search a text, the application should prepare a query object using that text, which can then be used to inquire the index database to get relevant details.

7

Search Query

Using the query object, the index database is checked to get the relevant details and the content documents.

8

Render Results

Once the required result is received, the application should decide how to display the results to the user using its User Interface.

看一下下图。它显示的搜索引擎如何函数的总体视图。

搜索引擎

除了这些基本操作,搜索应用程序还可以提供管理用户界面,以帮助管理员基于用户配置文件控制搜索级别。搜索结果的分析是任何搜索应用程序的另一个重要且高级的方面。