CN111931033A - Retrieval method, retrieval device and server - Google Patents
Retrieval method, retrieval device and server Download PDFInfo
- Publication number
- CN111931033A CN111931033A CN202010802421.1A CN202010802421A CN111931033A CN 111931033 A CN111931033 A CN 111931033A CN 202010802421 A CN202010802421 A CN 202010802421A CN 111931033 A CN111931033 A CN 111931033A
- Authority
- CN
- China
- Prior art keywords
- retrieval
- cluster
- function
- node
- target
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 39
- 230000006870 function Effects 0.000 claims description 130
- 239000003795 chemical substances by application Substances 0.000 claims description 57
- 238000004590 computer program Methods 0.000 claims description 18
- 238000012545 processing Methods 0.000 claims description 11
- 239000000945 filler Substances 0.000 claims 1
- 230000008569 process Effects 0.000 description 8
- 238000004364 calculation method Methods 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 230000009286 beneficial effect Effects 0.000 description 2
- 238000004891 communication Methods 0.000 description 2
- 238000003491 array Methods 0.000 description 1
- 238000004422 calculation algorithm Methods 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 239000000284 extract Substances 0.000 description 1
- 230000010365 information processing Effects 0.000 description 1
- 230000000977 initiatory effect Effects 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/953—Querying, e.g. by the use of web search engines
- G06F16/9532—Query formulation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/953—Querying, e.g. by the use of web search engines
Landscapes
- Engineering & Computer Science (AREA)
- Databases & Information Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Mathematical Physics (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The application discloses a retrieval method, a retrieval device, a server and a computer readable storage medium. The retrieval method comprises the following steps: when an agent cluster of a server receives a retrieval request, filling contents to be retrieved carried by the retrieval request into a target retrieval function, wherein the agent cluster comprises at least one agent node; the agent cluster issues the filled target retrieval function to a retrieval cluster of the server, wherein the retrieval cluster comprises at least one retrieval node; and the retrieval cluster executes the filled target retrieval function to obtain a retrieval result. Through this application scheme, can promote retrieval efficiency to a certain extent.
Description
Technical Field
The present application belongs to the field of information processing technologies, and in particular, relates to a retrieval method, a retrieval apparatus, a server, and a computer-readable storage medium.
Background
In current mainstream online retrieval and calculation, an upper layer service usually obtains a final result by initiating a request to a node of a downstream server by using a Socket (Socket) and then performing calculation on the current upper layer service after acquiring data. That is, the current online retrieval calculation is mainly completed by an upper layer service, and data needs to be uploaded to the upper layer service, which places a heavy burden on a network Input/Output (IO) and a Central Processing Unit (CPU), resulting in low retrieval efficiency.
Disclosure of Invention
The application provides a retrieval method, a retrieval device, a server and a computer readable storage medium, which can improve the retrieval efficiency to a certain extent.
In a first aspect, the present application provides a retrieval method, applied to a server, including:
when an agent Cluster of a server receives a retrieval request, filling contents to be retrieved carried by the retrieval request into a target retrieval function, wherein the agent Cluster (Proxy Cluster, PC) comprises at least one agent Node (Proxy Node, PN);
the agent Cluster issues the filled target retrieval function to a retrieval Cluster (SC) of the server, wherein the retrieval Cluster comprises at least one retrieval Node (SN);
and the retrieval cluster executes the filled target retrieval function to obtain a retrieval result.
In a second aspect, the present application provides a retrieval apparatus, applied to a server, including:
the system comprises a filling unit, a searching unit and a searching unit, wherein the filling unit is used for filling contents to be searched carried by a searching request to a target searching function when the agent cluster of a server receives the searching request, the agent cluster comprises at least one agent node, and the target searching function adopts SQL-like syntax;
the issuing unit is used for the agent cluster to issue the filled target retrieval function to a retrieval cluster of the server, wherein the retrieval cluster comprises at least one retrieval node;
and the retrieval unit is used for executing the filled target retrieval function by the retrieval cluster to obtain a retrieval result.
In a third aspect, the present application provides a server comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method according to the first aspect when executing the computer program.
In a fourth aspect, the present application provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method of the first aspect.
In a fifth aspect, the present application provides a computer program product comprising a computer program which, when executed by one or more processors, performs the steps of the method of the first aspect as described above.
Compared with the prior art, the application has the beneficial effects that: when the server processes the retrieval request of the user, the server does not perform real retrieval operation based on the retrieval request at an upper node (namely, a proxy cluster) any more, but fills a target retrieval function according to the retrieval request, and then issues the target retrieval function to a lower node (namely, a retrieval cluster), and the lower node performs the real retrieval operation according to the filled target retrieval function, so that the calculation sinks to the lower node, the burden on network IO and CPU is reduced, and the retrieval efficiency is improved to a certain extent. It is understood that the beneficial effects of the second aspect to the fifth aspect can be referred to the related description of the first aspect, and are not described herein again.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments or the prior art descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts.
Fig. 1 is a schematic flowchart of a retrieval method provided in an embodiment of the present application;
FIG. 2 is a schematic diagram of an architecture of a server provided in an embodiment of the present application;
FIG. 3 is a schematic diagram of a search node in an initialization phase according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of a retrieval apparatus provided in an embodiment of the present application;
fig. 5 is a schematic structural diagram of a server according to an embodiment of the present application.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
In order to explain the technical solution proposed in the present application, the following description will be given by way of specific examples.
Referring to fig. 1, fig. 1 shows a searching method provided in the embodiment of the present application, which is detailed as follows:
in the embodiment of the application, at least one agent cluster is pre-configured in a server, wherein each agent cluster comprises at least one agent node. The retrieval request initiated by the user through the terminal used by the user is sent to the upper node of the server, that is, the proxy cluster, specifically to one proxy node in the proxy cluster.
When a proxy cluster receives a retrieval request initiated by a user, the proxy cluster can determine a target retrieval function in a plurality of acquired retrieval functions, wherein the target retrieval function refers to a retrieval function matched with the retrieval request; that is, a search function capable of processing the search request is determined as the target search function. For example, when a proxy cluster receives a retrieval request, the service type to which the retrieval request belongs is determined, and then the proxy cluster may determine a retrieval function associated with the service type as a target retrieval function. It should be noted that all the search functions are User Defined Functions (UDF), and they all use Structured Query Language (SQL) syntax to solve the constraint specification problem of the upper and lower nodes.
After the target retrieval function is determined, the agent cluster extracts the content to be retrieved from the retrieval request and fills the content to be retrieved into the determined target retrieval function; namely, the content to be retrieved is taken as an input parameter of the target retrieval function.
For example, the target retrieval function after filling may be:
SELECT name,distance(lat,lon)FROM tourism_index WHERE price>=500and lbs(lat,lon)<10000ORDER BY distance(lat,lon)
wherein, price > 500and lbs (lat, lon) <10000 are the filled contents to be retrieved. The meaning expressed by the target retrieval function after filling is as follows: and finding out hotel names and actual distances with the prices larger than 500 yuan and within 10 kilometers of the user in a touriss _ index database, and sorting according to the actual distances from near to far.
In some embodiments, different ranking strategies may be required for different application scenarios, such as sug page searches and result page searches. Based on this, the server can use different sorting operators of ORDER BY in syntax to meet the requirements of the related services. For example, in the example of the target search function given above, it is sorted from near to far according to the actual distance BY ORDER BY distance (lat, lon).
102, the agent cluster issues the filled target retrieval function to a retrieval cluster of the server;
in this embodiment of the present application, the server is further preconfigured with at least one search cluster, where each search cluster includes at least one search node. The agent cluster may issue the filled target retrieval function to a lower node of the server, that is, a retrieval cluster, specifically, to at least one retrieval node in the retrieval cluster.
In the embodiment of the present application, after receiving the filled target retrieval function, a retrieval node in the retrieval cluster may execute the filled target retrieval function. For example, the filled search function is SELECT name, distance (lat, lon) FROM root cause _ index WHERE price > -500 and lbs (lat, lon) <10000ORDER BY distance (lat, lon), and the specific search operation is price > -500 and lbs (lat, lon) <10000, and the search operation is executed in the search cluster to obtain the search result.
In some embodiments, considering that the result of the search cluster obtained by executing the populated target search function may be repeated, the above step 103 may be embodied as: one or more retrieval nodes in the retrieval cluster execute the filled target retrieval function to obtain at least one execution result; and then the retrieval cluster can send the execution results obtained according to the filled target retrieval function to the proxy cluster, and the proxy cluster performs merging processing on the execution results, wherein the result obtained after merging is the final retrieval result. The retrieval cluster can send the final retrieval result to a terminal used by the user for the user to consult.
In some embodiments, the server may also interact with a pre-defined registration server RegServer. The registration server is typically lightweight and may be deployed on a docker container or a low-provisioned physical machine. Referring to fig. 2, fig. 2 shows an architecture of a server according to an embodiment of the present application. Limited to space, only one agent cluster and one retrieval cluster are shown in FIG. 2; in practical application, no limitation is made on the number of the agent clusters and the number of the retrieval clusters, and no limitation is made on the number of the agent nodes included in the agent clusters and the number of the retrieval nodes included in the retrieval clusters. The registration server is mainly used for registering each retrieval node in the retrieval cluster, so that the proxy cluster can discover the retrieval nodes in time.
For each search node in the search cluster, a C + + implementation is employed due to high concurrency. The registration operation of the search node is executed in an initialization stage, specifically: and registering at least one retrieval function configured by the retrieval node and the node information of the retrieval node to the registration server. The node information includes, but is not limited to, the following: the IP address, the flow control information and/or the registration time of the retrieval node, where the flow control information refers to the processing traffic that can be carried by the retrieval node and has a unit of QPS (Queries-per-second). In this way, after the registration of each search node is completed, the proxy cluster can read the node information of each search node which is currently registered and the search function configured by each search node through the registration server.
In some embodiments, there are other operations in addition to the registration operation in the initialization phase of the retrieval node, as explained below: referring to fig. 3, the following units may be configured in the search node: the system comprises a file acquisition unit, a function loading unit and a node registration unit. The file acquisition unit is a trigger, and the retrieval node can acquire the configured retrieval functions from a preset configuration server through the file acquisition unit, wherein the presentation forms of the retrieval functions are files, namely, the retrieval function files are acquired from the configuration server. It should be noted that, the retrieval functions of all services may be configured in the same retrieval function file, or each service may be associated with one retrieval function file, that is, the retrieval functions belonging to the same service are configured in one retrieval function file, and different services correspond to different retrieval function files, which is not limited herein. Subsequently, the retrieval node can execute a dlopen function through the function acquisition unit, eliminate the problem of dependency library conflict, and open the acquired retrieval function file to really obtain at least one retrieval function. Then, the retrieval node can load at least one retrieval function obtained through the function loading unit to form an object method of the UDF, which can be used for business calculation and execution to realize the configuration of the retrieval function of the retrieval node. In order to make the upper-layer proxy cluster also know the condition of the search node, the search node is finally registered in the registration server through the node registration unit for each proxy node in the proxy cluster to call. Based on the structure, the retrieval node can update the dynamic library in a hot mode through a double-buffer hot loading mechanism without restarting the retrieval node.
In some embodiments, the agent cluster may further obtain a configured issuing policy from a preset configuration center, and step 102 may be specifically expressed as: the method comprises the steps that an agent cluster firstly determines target retrieval nodes through an issuing strategy configured by a preset configuration center, wherein the number of the target retrieval nodes is not limited in the embodiment of the application; and then the agent cluster can issue the filled target retrieval function to the target retrieval node. Generally, the configuration center may solidify its issuing policy, i.e. the issuing policy does not change frequently. For example only, the issuing policy may be a polling policy or a consistent hash policy, and the like, which is not limited herein. It should be noted that, in general, even if the agent cluster determines that there is an idle search node at present, the agent cluster does not directly issue the filled target search function to the idle search node, because the idle search is relative to the Linux time-sharing system; the issuing strategy adopted by the server is generally equal distribution, although occasionally, the processing time is long, and the overall processing efficiency is not influenced under the multi-core CPU processing.
In some embodiments, in consideration of the situation that there may be insufficient recalling in the retrieval process, the server may also rewrite the content to be retrieved input by the user when there is insufficient recalling, so as to improve the retrieval efficiency and directly improve the user experience. For example, assuming that the user needs to retrieve "liu de hua sleet" according to the retrieval request initiated by the user, the server may generate three contents to be retrieved, namely "liu de hua and sleet", "sleet" and "liu de hua", based on the rewriting. It is assumed that the confidence based on "Liu De Hua and ice rain" is 0.99, the confidence based on "ice rain" is 0.8, and the confidence based on "Liu De Hua" is 0.6; in the past, the agent cluster firstly issues corresponding target retrieval sentences to the retrieval cluster for retrieval based on Liu Dehua and ice rain, and then issues corresponding target retrieval sentences to the retrieval cluster for retrieval based on ice rain when the number of recalls is small, and so on. The above process is accompanied by network requests and there is logic to unpack and package, affecting performance. In the embodiment of the present application, the server generates a rewrite statement, which may be understood as that the server lists all possible search terms in a permutation and combination manner based on the search request to obtain at least one content to be searched, and generates the rewrite statement based on the at least one content to be searched. By way of example only, the rewrite statement may be: confirm ((query1 and query2) × score1, query2 × score2, query3 × score 3). The rewritten sentences can be spliced with the target retrieval function, and the proxy cluster issues the spliced target retrieval sentences to the retrieval cluster. By rewriting the statements, frequent interactions between the agent cluster and the retrieval cluster may be eliminated.
As can be seen from the above, in the embodiment of the present application, when a server processes a retrieval request of a user, a real retrieval operation is no longer performed at an upper node (i.e., a proxy cluster) based on the retrieval request, but a target retrieval function is filled according to the retrieval request, and then the target retrieval function is issued to a lower node (i.e., a retrieval cluster), and the lower node performs the real retrieval operation according to the filled target retrieval function, so that the computation is sunk to the lower node, the burden on the network IO and the CPU is reduced, and the retrieval efficiency is improved to a certain extent.
Corresponding to the search method proposed above, an embodiment of the present application provides a search apparatus, which is integrated in a server. Referring to fig. 4, a search apparatus 400 according to an embodiment of the present application includes:
a filling unit 401, configured to fill, when an agent cluster of a server receives a retrieval request, content to be retrieved carried by the retrieval request to a target retrieval function, where the agent cluster includes at least one agent node;
an issuing unit 402, configured to issue the filled target retrieval function to a retrieval cluster of the server by the proxy cluster, where the retrieval cluster includes at least one retrieval node;
a retrieving unit 403, configured to execute the filled target retrieving function by the retrieving cluster to obtain a retrieving result.
Optionally, the filling unit 401 includes:
a type judgment subunit, configured to, when the proxy cluster receives a retrieval request, judge a service type to which the retrieval request belongs;
a function determining subunit, configured to determine, by the proxy cluster, a retrieval function associated with the service type as the target retrieval function;
and the function filling subunit is used for filling the content to be retrieved carried by the retrieval request into the target retrieval function by the proxy cluster.
Optionally, the issuing unit 402 includes:
a node determining subunit, configured to determine a target retrieval node by the agent cluster according to an issuing policy configured in a preset configuration center;
and the function issuing subunit is used for the agent cluster to issue the filled target retrieval function to the target retrieval node.
Optionally, the retrieving unit 403 includes:
a result obtaining subunit, configured to execute the filled target retrieval function by the retrieval cluster to obtain at least one execution result;
a result sending subunit, configured to send, by the search cluster, the at least one execution result to the proxy cluster;
and a result merging subunit, configured to merge the at least one execution result by the proxy cluster to obtain the search result.
Optionally, each search node of the search apparatus 400 includes:
and the node registration unit is used for registering at least one retrieval function configured by the retrieval node and the node information of the retrieval node to a preset registration server.
Optionally, each search node of the search apparatus 400 further includes:
the file acquisition unit is used for acquiring a configured retrieval function file from a preset configuration server;
a function obtaining unit, configured to open the search function file to obtain at least one search function;
and the function loading unit is used for loading the at least one retrieval function so as to realize the configuration of the retrieval function of the retrieval node.
As can be seen from the above, according to the embodiment of the present application, when the retrieval device processes the retrieval request of the user, the retrieval device does not perform a real retrieval operation based on the retrieval request at the upper node (i.e., the proxy cluster) any more, but fills the target retrieval function according to the retrieval request, and then issues the target retrieval function to the lower node (i.e., the retrieval cluster), and the lower node performs the real retrieval operation according to the filled target retrieval function, so that the computation sinks to the lower node, the burden on the network IO and the CPU is reduced, and the retrieval efficiency is improved to a certain extent.
An embodiment of the present application further provides a server, please refer to fig. 5, where the server 5 in the embodiment of the present application includes: a memory 501, one or more processors 502 (only one shown in fig. 5), and a computer program stored on the memory 501 and executable on the processors. Wherein: the memory 501 is used for storing software programs and units, and the processor 502 executes various functional applications and data processing by running the software programs and units stored in the memory 501, so as to acquire resources corresponding to the preset events. Specifically, the processor 502 realizes the following steps by running the above-mentioned computer program stored in the memory 501:
when an agent cluster of a server receives a retrieval request, filling contents to be retrieved carried by the retrieval request into a target retrieval function, wherein the agent cluster comprises at least one agent node;
the agent cluster issues the filled target retrieval function to a retrieval cluster of the server, wherein the retrieval cluster comprises at least one retrieval node;
and the retrieval cluster executes the filled target retrieval function to obtain a retrieval result.
Assuming that the above is the first possible implementation manner, in a second possible implementation manner provided on the basis of the first possible implementation manner, when the proxy cluster of the server receives a retrieval request, the populating a target retrieval function with content to be retrieved carried by the retrieval request includes:
when the agent cluster receives a retrieval request, judging the service type of the retrieval request;
the agent cluster determines a retrieval function associated with the service type as the target retrieval function;
and the agent cluster fills the content to be retrieved carried by the retrieval request into the target retrieval function.
In a third possible implementation manner provided on the basis of the first possible implementation manner, the issuing, by the proxy cluster, the target search function after the padding to the search cluster of the server includes:
the agent cluster determines a target retrieval node through an issuing strategy configured in a preset configuration center;
and the agent cluster issues the filled target retrieval function to the target retrieval node.
In a fourth possible implementation manner provided on the basis of the first possible implementation manner, the performing, by the search cluster, the target search function after the padding to obtain a search result includes:
the retrieval cluster executes the filled target retrieval function to obtain at least one execution result;
the retrieval cluster sends the at least one execution result to the agent cluster;
and the agent cluster performs merging processing on the at least one execution result to obtain the retrieval result.
In a fifth possible implementation manner provided on the basis of the first possible implementation manner, the second possible implementation manner, the third possible implementation manner, or the fourth possible implementation manner, before the proxy cluster of the server receives a retrieval request, the processor 502 further implements, by running the computer program stored in the memory 501, the following steps for each retrieval node in the retrieval cluster:
and registering at least one retrieval function configured by the retrieval node and the node information of the retrieval node to a preset registration server.
In a sixth possible implementation manner provided on the basis of the fifth possible implementation manner, for each search node in the search cluster, the processor 502 further implements the following steps when executing the computer program stored in the memory 501:
the retrieval node acquires a configured retrieval function file from a preset configuration server;
the retrieval node opens the retrieval function file to obtain at least one retrieval function;
and the retrieval node loads the at least one retrieval function to realize the configuration of the retrieval function of the retrieval node.
It should be understood that in the embodiments of the present Application, the Processor 502 may be a CPU, and the Processor may be other general processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field-Programmable Gate arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components, and the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
As can be seen from the above, according to the embodiment of the present application, when a server processes a retrieval request of a user, the server does not perform a real retrieval operation based on the retrieval request at an upper node (i.e., a proxy cluster) any more, but fills a target retrieval function according to the retrieval request, and then issues the target retrieval function to a lower node (i.e., a retrieval cluster), and the lower node performs the real retrieval operation according to the filled target retrieval function, so that the computation sinks to the lower node, the burden on the network IO and the CPU is reduced, and the retrieval efficiency is improved to a certain extent.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned functions may be distributed as different functional units and modules according to needs, that is, the internal structure of the apparatus may be divided into different functional units or modules to implement all or part of the above-mentioned functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the system may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art would appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of external device software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described system embodiments are merely illustrative, and for example, the division of the above-described modules or units is only one logical functional division, and in actual implementation, there may be another division, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
The integrated unit may be stored in a computer-readable storage medium if it is implemented in the form of a software functional unit and sold or used as a separate product. Based on such understanding, all or part of the flow in the method of the embodiments described above can be realized by a computer program, which can be stored in a computer-readable storage medium and can realize the steps of the embodiments of the methods described above when the computer program is executed by a processor. The computer program includes computer program code, and the computer program code may be in a source code form, an object code form, an executable file or some intermediate form. The computer-readable storage medium may include: any entity or device capable of carrying the above-described computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer readable Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signal, telecommunication signal, software distribution medium, etc. It should be noted that the computer readable storage medium may contain other contents which can be appropriately increased or decreased according to the requirements of the legislation and the patent practice in the jurisdiction, for example, in some jurisdictions, the computer readable storage medium does not include an electrical carrier signal and a telecommunication signal according to the legislation and the patent practice.
The above embodiments are only used to illustrate the technical solutions of the present application, and not to limit the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present application and are intended to be included within the scope of the present application.
Claims (10)
1. A retrieval method is applied to a server and comprises the following steps:
when an agent cluster of a server receives a retrieval request, filling contents to be retrieved carried by the retrieval request into a target retrieval function, wherein the agent cluster comprises at least one agent node;
the agent cluster issues the filled target retrieval function to a retrieval cluster of the server, wherein the retrieval cluster comprises at least one retrieval node;
and the retrieval cluster executes the filled target retrieval function to obtain a retrieval result.
2. The retrieval method of claim 1, wherein when the proxy cluster of the server receives a retrieval request, populating a target retrieval function with content to be retrieved carried by the retrieval request, comprises:
when the agent cluster receives a retrieval request, judging the service type of the retrieval request;
the agent cluster determines a retrieval function associated with the service type as the target retrieval function;
and the proxy cluster fills the content to be retrieved carried by the retrieval request into the target retrieval function.
3. The retrieval method of claim 1, wherein the sending the populated target retrieval function to the retrieval cluster of the server by the proxy cluster comprises:
the agent cluster determines a target retrieval node through an issuing strategy configured in a preset configuration center;
and the agent cluster issues the filled target retrieval function to the target retrieval node.
4. The retrieval method of claim 1, wherein the retrieval cluster executing the populated target retrieval function to obtain a retrieval result comprises:
the retrieval cluster executes the filled target retrieval function to obtain at least one execution result;
the retrieval cluster sends the at least one execution result to the agent cluster;
and the agent cluster carries out merging processing on the at least one execution result to obtain the retrieval result.
5. The retrieval method of any one of claims 1 to 4, wherein, prior to the proxy cluster of servers receiving the retrieval request, for each retrieval node in the retrieval cluster, the retrieval method further comprises:
and registering at least one retrieval function configured by the retrieval node and the node information of the retrieval node to a preset registration server.
6. The retrieval method of claim 5, wherein for each retrieval node in the retrieval cluster, the retrieval method further comprises:
the retrieval node acquires a configured retrieval function file from a preset configuration server;
the retrieval node opens the retrieval function file to obtain at least one retrieval function;
and the retrieval node loads the at least one retrieval function to realize the configuration of the retrieval function of the retrieval node.
7. A retrieval apparatus, applied to a server, comprising:
the device comprises a filling unit, a searching unit and a searching unit, wherein the filling unit is used for filling contents to be searched carried by a searching request to a target searching function when the agent cluster of a server receives the searching request, and the agent cluster comprises at least one agent node;
the issuing unit is used for the agent cluster to issue the filled target retrieval function to a retrieval cluster of the server, wherein the retrieval cluster comprises at least one retrieval node;
and the retrieval unit is used for executing the filled target retrieval function by the retrieval cluster to obtain a retrieval result.
8. The retrieval device of claim 7, wherein the filler unit comprises:
the type judging subunit is used for judging the service type of the retrieval request when the agent cluster receives the retrieval request;
a function determining subunit, configured to determine, by the proxy cluster, a retrieval function associated with the service type as the target retrieval function;
and the function filling subunit is used for filling the content to be retrieved carried by the retrieval request to the target retrieval function by the proxy cluster.
9. A server comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the method according to any of claims 1 to 6 when executing the computer program.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the method according to any one of claims 1 to 6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010802421.1A CN111931033A (en) | 2020-08-11 | 2020-08-11 | Retrieval method, retrieval device and server |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010802421.1A CN111931033A (en) | 2020-08-11 | 2020-08-11 | Retrieval method, retrieval device and server |
Publications (1)
Publication Number | Publication Date |
---|---|
CN111931033A true CN111931033A (en) | 2020-11-13 |
Family
ID=73311144
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010802421.1A Pending CN111931033A (en) | 2020-08-11 | 2020-08-11 | Retrieval method, retrieval device and server |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111931033A (en) |
Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105677829A (en) * | 2016-01-04 | 2016-06-15 | 陈华锋 | Retrieving method and system |
CN205540723U (en) * | 2016-01-22 | 2016-08-31 | 宿州学院 | Information retrieval system based on cloud calculates |
CN106484872A (en) * | 2016-10-12 | 2017-03-08 | 南方电网科学研究院有限责任公司 | Patent retrieval method under server architecture, receiving server and server architecture |
CN107273540A (en) * | 2017-07-05 | 2017-10-20 | 北京三快在线科技有限公司 | Distributed search and index updating method, system, server and computer equipment |
CN108062384A (en) * | 2017-12-13 | 2018-05-22 | 阿里巴巴集团控股有限公司 | The method and apparatus of data retrieval |
US20180144026A1 (en) * | 2016-11-21 | 2018-05-24 | International Business Machines Corporation | Selectively retrieving data from remote share nothing computer clusters |
CN108664914A (en) * | 2018-05-04 | 2018-10-16 | 腾讯科技(深圳)有限公司 | Face retrieval method, apparatus and server |
CN110287360A (en) * | 2019-06-26 | 2019-09-27 | 银河水滴科技(北京)有限公司 | System, the method and device of multitask retrieval |
CN111143427A (en) * | 2019-11-25 | 2020-05-12 | 中国科学院计算技术研究所 | Distributed information retrieval method, system and device based on-line computing |
CN111260193A (en) * | 2020-01-09 | 2020-06-09 | 江苏满运软件科技有限公司 | Vehicle and goods matching search system, method, computer device and storage medium |
-
2020
- 2020-08-11 CN CN202010802421.1A patent/CN111931033A/en active Pending
Patent Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105677829A (en) * | 2016-01-04 | 2016-06-15 | 陈华锋 | Retrieving method and system |
CN205540723U (en) * | 2016-01-22 | 2016-08-31 | 宿州学院 | Information retrieval system based on cloud calculates |
CN106484872A (en) * | 2016-10-12 | 2017-03-08 | 南方电网科学研究院有限责任公司 | Patent retrieval method under server architecture, receiving server and server architecture |
US20180144026A1 (en) * | 2016-11-21 | 2018-05-24 | International Business Machines Corporation | Selectively retrieving data from remote share nothing computer clusters |
CN107273540A (en) * | 2017-07-05 | 2017-10-20 | 北京三快在线科技有限公司 | Distributed search and index updating method, system, server and computer equipment |
CN108062384A (en) * | 2017-12-13 | 2018-05-22 | 阿里巴巴集团控股有限公司 | The method and apparatus of data retrieval |
CN108664914A (en) * | 2018-05-04 | 2018-10-16 | 腾讯科技(深圳)有限公司 | Face retrieval method, apparatus and server |
CN110287360A (en) * | 2019-06-26 | 2019-09-27 | 银河水滴科技(北京)有限公司 | System, the method and device of multitask retrieval |
CN111143427A (en) * | 2019-11-25 | 2020-05-12 | 中国科学院计算技术研究所 | Distributed information retrieval method, system and device based on-line computing |
CN111260193A (en) * | 2020-01-09 | 2020-06-09 | 江苏满运软件科技有限公司 | Vehicle and goods matching search system, method, computer device and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11064053B2 (en) | Method, apparatus and system for processing data | |
US20200019552A1 (en) | Query optimization method and related apparatus | |
US20150310045A1 (en) | Managing an index of a table of a database | |
US9742860B2 (en) | Bi-temporal key value cache system | |
KR20180131634A (en) | Enriching database query responses using data from external data sources | |
US20160261687A1 (en) | Defragmenting clusters with reserved resources | |
CN111221840A (en) | Data processing method and device, data caching method, storage medium and system | |
US11762775B2 (en) | Systems and methods for implementing overlapping data caching for object application program interfaces | |
KR20220014325A (en) | Communication server device, method and communication system for recommending one or more points of interest for transportation related services to a user. | |
CN113271359A (en) | Method and device for refreshing cache data, electronic equipment and storage medium | |
CN108154024B (en) | Data retrieval method and device and electronic equipment | |
US12117999B2 (en) | Masking shard operations in distributed database systems | |
US11704327B2 (en) | Querying distributed databases | |
CN113037851B (en) | Method for cloud mobile phone system super-resolution based on storage implementation | |
CN111931033A (en) | Retrieval method, retrieval device and server | |
US10114864B1 (en) | List element query support and processing | |
CN109960695B (en) | Management method and device for database in cloud computing system | |
CN112699149A (en) | Target data acquisition method and device, storage medium and electronic device | |
CN112445817A (en) | Query instruction execution method and device, electronic equipment and computer readable medium | |
US12105705B2 (en) | Database query processing with database clients | |
CN118413572B (en) | CDN-based access request processing method and device | |
CN116305288B (en) | Method, device, equipment and storage medium for isolating database resources | |
CN115543411A (en) | Application configuration release system, method, device and equipment | |
CN114238483A (en) | Data processing method, apparatus, device, medium, and program product | |
CN116719872A (en) | Database deployment method and database management platform |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
WD01 | Invention patent application deemed withdrawn after publication | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20201113 |