CN106339183B - Data retrieval method and server - Google Patents

Data retrieval method and server Download PDF

Info

Publication number
CN106339183B
CN106339183B CN201610749786.6A CN201610749786A CN106339183B CN 106339183 B CN106339183 B CN 106339183B CN 201610749786 A CN201610749786 A CN 201610749786A CN 106339183 B CN106339183 B CN 106339183B
Authority
CN
China
Prior art keywords
heap memory
data objects
server
storage device
data
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.)
Active
Application number
CN201610749786.6A
Other languages
Chinese (zh)
Other versions
CN106339183A (en
Inventor
于明光
纪勇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Neusoft Corp
Original Assignee
Neusoft Corp
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Neusoft Corp filed Critical Neusoft Corp
Priority to CN201610749786.6A priority Critical patent/CN106339183B/en
Publication of CN106339183A publication Critical patent/CN106339183A/en
Application granted granted Critical
Publication of CN106339183B publication Critical patent/CN106339183B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/062Securing storage systems
    • G06F3/0623Securing storage systems in relation to content
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0662Virtualisation aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0674Disk device
    • G06F3/0676Magnetic disk device

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a data retrieval method and a server, which are used for solving the technical problem of memory overflow in a JVM server heap during data retrieval. The method comprises the following steps: acquiring a keyword for retrieval; and retrieving the data objects in the storage device in a paging mode according to the keywords, wherein the following operations are executed for each page of the data objects: sequentially storing the unique identification of the data object with the key words into an in-heap memory; and when the number of the unique identifiers stored in the in-heap memory reaches a threshold value, storing the unique identifiers stored in the in-heap memory into an out-of-heap memory, and deleting the unique identifiers stored in the in-heap memory. The embodiment of the invention is used for data retrieval.

Description

Data retrieval method and server
Technical Field
The invention relates to the field of data retrieval, in particular to a data retrieval method and a server.
Background
A JVM (Java Virtual Machine) is a specification for a computing device, which is an imaginary computer implemented by emulating and simulating various computer functions on an actual computer. In a large service platform, a large number of JVM servers may exist inside the service platform, and are used for monitoring applications of the platform, collecting data generated by various applications, analyzing various data, and giving an alarm in time when behavior of the applications is found to be unexpected or abnormal, so that maintenance personnel can handle problems and remove faults or potential problems.
In the prior art, when a JVM server searches data stored in a disk, all data meeting conditions in the disk are stored in an in-heap memory of the JVM server, and because the capacity of the in-heap memory of the JVM is small, the memory overflow is easily caused when large data is searched.
Disclosure of Invention
The invention aims to provide a data retrieval method and a server, which are used for solving the technical problem of memory overflow in a JVM server heap during data retrieval.
In order to achieve the above object, a first aspect of the present invention provides a data retrieval method, where the method is applied to a server running a Java virtual machine JVM, where the server includes an in-heap memory and an out-of-heap memory of the JVM, and the method includes:
the server acquires a keyword for retrieval;
and retrieving the data objects in the storage device in a paging mode according to the keywords, wherein the following operations are executed for each page of the data objects:
sequentially storing the unique identification of the data object with the key words into the in-heap memory; wherein the unique identifier is used for directly querying a corresponding data object in the storage device;
and when the number of the unique identifiers stored in the in-heap memory reaches a threshold value, storing the unique identifiers stored in the in-heap memory into the out-of-heap memory, and deleting the unique identifiers stored in the in-heap memory.
Optionally, each page in the storage device comprises N data objects;
when the number of the unique identifiers stored in the in-heap memory reaches a threshold value, the step of storing the unique identifiers stored in the in-heap memory into the out-of-heap memory includes:
and after N data objects with the keywords are searched in a paging mode, storing the unique identifications of the N data objects in the in-heap memory into the out-of-heap memory.
Optionally, the method further comprises:
reading N data objects in the storage device according to the N unique identifiers in the off-heap memory;
and loading and displaying the N data objects.
Optionally, before retrieving the data object in the storage device in a page according to the keyword, the method further comprises:
paging all data objects in the storage device.
Optionally, the method further comprises:
and dividing the storage space of the server to allocate the storage space of the off-heap memory.
In a second aspect, a server is provided, where the server runs a Java virtual machine JVM, and the server includes an in-heap memory and an out-of-heap memory of the JVM, and the server further includes:
an acquisition unit configured to acquire a keyword for retrieval;
the retrieval unit is used for retrieving the data objects in a storage device in a paging mode according to the keywords;
the storage unit is used for sequentially storing the unique identification of the data object with the keyword into the in-heap memory; wherein the unique identifier is used for directly querying a corresponding data object in the storage device;
a determining unit, configured to determine that the number of the unique identifiers stored in the in-heap memory reaches a threshold;
the storage unit is further configured to store the unique identifier stored in the in-heap memory into the out-heap memory;
and the deleting unit is used for deleting the unique identifier stored in the in-heap memory.
Optionally, each page in the storage device comprises N data objects;
the determining unit is configured to determine that the retrieving unit retrieves N data objects with the keyword in a paging manner;
the storage unit is configured to store the unique identifiers of the N data objects in the in-heap memory into the out-heap memory.
Optionally, the method further comprises:
a reading unit, configured to read N data objects in the storage device according to the N unique identifiers in the off-heap memory;
and the display unit is used for loading and displaying the N data objects.
Optionally, the method further comprises:
and the paging unit is used for paging all the data objects in the storage device before the retrieval unit retrieves the data objects in the storage device in a paging mode according to the keywords.
Optionally, the server further comprises:
and the allocation unit is used for allocating the storage space of the off-heap memory.
By adopting the technical scheme, the server searches data in the storage device in a paging mode, when the unique identifiers of the data objects stored in the memory in the JVM heap of the server reach a certain number, the unique identifiers of the data objects are stored in the memory in the heap, and the unique identifiers stored in the memory in the heap are deleted. Compared with the prior art that all data in the storage device is read into the in-heap memory during data retrieval, the invention only needs to read one page of data object to the in-heap memory every time during paging retrieval data, thereby avoiding memory overflow. Compared with the prior art, the storage position of the unique identifier of the data object is changed from the in-heap memory to the out-heap memory, and the overflow of the in-heap memory caused by the overlarge data size of the retrieval is also avoided.
In particular, other features and advantages of the present invention will be described in detail in the detailed description that follows.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this specification, illustrate embodiments of the invention and together with the description serve to explain the principles of the invention and not to limit the invention. In the drawings:
FIG. 1 is a schematic diagram of a conventional data retrieval system according to an embodiment of the present invention;
FIG. 2 is a flow diagram of a method of data retrieval provided based on the system architecture shown in FIG. 1;
FIG. 3 is a flow chart illustrating a method for data retrieval according to an embodiment of the present invention;
FIG. 4 is a system architecture diagram for data retrieval according to an embodiment of the present invention;
FIG. 5 is a flow chart diagram of a method of data retrieval provided based on the system architecture shown in FIG. 4;
fig. 6A is a schematic structural diagram of a server according to an embodiment of the present invention;
fig. 6B is a schematic structural diagram of another server according to an embodiment of the present invention.
Detailed Description
The following detailed description of embodiments of the invention refers to the accompanying drawings. It should be understood that the detailed description and specific examples, while indicating the present invention, are given by way of illustration and explanation only, not limitation.
In order to make it easier for those skilled in the art to understand the improvement of the embodiment of the present invention compared with the prior art, a brief description of the data retrieval method of the prior art is first provided below.
Fig. 1 shows a conventional system architecture, which includes a server 10, and the server 10 runs a Java virtual machine JVM 101 and an in-heap memory 102 of the JVM. The system architecture also includes a storage device 11 coupled to the server 10. The storage device 11 may be a magnetic disk, which stores data objects.
Based on the system architecture shown in fig. 1, a data retrieval process in the prior art is shown in fig. 2, and includes:
s201, the server acquires a keyword for searching.
It is worth noting that the data objects in the storage device include a plurality of attribute information. For example, in the case where the data object is a user, the data object may include a plurality of information such as the user's name, date of birth, identification number, and the like. The keyword in step S201 may be any attribute information of the data object, such as the birth date of the user.
S202, the server searches all data objects stored in the storage device according to the keyword.
S203, the server stores all the data objects with the key words in the in-heap memory.
According to the above process, in the prior art, the retrieval results are stored in the in-heap memory, so that the in-heap memory is easy to overflow when the retrieved data volume is large, and the in-heap memory has a low read-write rate, which affects the retrieval efficiency. The above problems are solved in the embodiments of the present invention, which are described in detail below.
An embodiment of the present invention provides a data retrieval method, where the method is applied to a server, where the server runs a JVM, and the server includes an in-heap memory and an out-of-heap memory, as shown in fig. 3, the method includes:
s301, the server acquires a keyword for search.
The keyword for search may be a keyword input by the user and acquired by the server. Still taking the user as an example as a data object, if the user enters the birth date from 1990 to 1995, the server will retrieve all users stored in the storage device whose birth dates were between 1990 and 1995.
The above is merely an example, and in a specific implementation, other types of object data may be stored in the storage device, and the keyword for search may also be another keyword, which is not limited in the present invention.
S302, the server searches the data object in the storage device in a page mode according to the keyword.
Paging retrieval refers to sequentially retrieving each page of data objects in a storage device. Wherein the number of data objects per page may be related to the display of the search result. For example, if the search result can only be displayed 20 pieces at a time in the web page, the number of data objects per page in the storage device may be 20.
Further, in the page search process, the following steps S303 to S304 are performed for each page data object.
S303, the server stores the unique identification of the data objects with the keywords in the in-heap memory in sequence.
Wherein the unique identifier is used for directly querying the corresponding data object in the storage device.
S304, when the number of the unique identifications stored in the in-heap memory reaches a threshold value, the server stores the unique identifications stored in the in-heap memory into the out-heap memory, and deletes the unique identifications stored in the in-heap memory.
By adopting the technical scheme, the server searches data in the storage device in a paging mode, when the unique identifiers of the data objects stored in the memory in the JVM heap of the server reach a certain number, the unique identifiers of the data objects are stored in the memory in the heap, and the unique identifiers stored in the memory in the heap are deleted. Compared with the prior art that all data in the storage device is read into the in-heap memory during data retrieval, the invention only needs to read one page of data object to the in-heap memory every time during paging retrieval data, thereby avoiding memory overflow. Compared with the prior art, the storage position of the unique identifier of the data object is changed from the in-heap memory to the out-heap memory, and the overflow of the in-heap memory caused by the overlarge data size of the retrieval is also avoided. Moreover, the speed of the off-heap memory is higher than that of the in-heap memory when data is read and written, that is, the data retrieval efficiency can be improved by the embodiment of the invention.
In order to make those skilled in the art understand the technical solutions provided by the embodiments of the present invention, the following detailed descriptions are provided for the above steps.
Specifically, the off-heap memory may be a storage space applied by the server in an initial state, that is, before the step S301, the method further includes: and dividing the storage space of the server to allocate the storage space of the off-heap memory.
The specific size of the storage space of the off-heap memory can be set according to actual requirements, wherein the off-heap memory is easier to expand than the in-heap memory, and therefore, the storage space of the off-heap memory can be expanded in subsequent operations.
Further, if the data object in the storage device is not paged, the embodiment of the present invention may also page all the data objects in the storage device before step S302.
Wherein, in the case that each page of the storage device includes N data objects, the step S304 specifically includes: and after N data objects with the keywords are searched in a paging mode, storing the unique identifications of the N data objects in the in-heap memory into the out-of-heap memory, and deleting the unique identification stored in the in-heap memory.
That is to say, every time the unique identifier of every full N data objects is stored in the in-heap memory, the server transfers the unique identifier stored in the in-heap memory to the out-heap memory for storage, and erases the storage space of the in-heap memory, and then further retrieves the unique identifier of the data object to be stored in the erased in-heap memory, and the process is repeated. Therefore, the storage space occupied by the heap memory does not exceed N at each time, and the memory overflow is avoided. And the number of the unique identifications of the qualified data objects stored in the off-heap memory is just one page, which is beneficial to displaying the retrieval result.
In addition, it should be noted that the unique identifier of the data object may be a hash value of the data object, and the data object is stored in the off-heap memory in a key-value form, so that the server can directly query the data object from the storage device according to the unique identifier key.
Further, the data retrieval method provided by the embodiment of the present invention further includes: and reading N data objects in the storage device according to the N unique identifiers in the off-heap memory, and loading and displaying the N data objects.
Illustratively, as shown in fig. 4, a system architecture provided by an embodiment of the present invention includes a server 40, where the server 40 runs a Java virtual machine JVM, and the server 40 further includes an in-heap memory 401 and an out-of-heap memory 402 of the JVM. The system architecture further includes a storage device 41 coupled to the server for storing data objects, wherein the data objects in the storage device are divided into a plurality of pages, such as the first page through the Mth page shown in FIG. 4, M being a positive integer greater than or equal to 2.
Based on the system architecture shown in fig. 4, a data retrieval method provided by the embodiment of the present invention is shown in fig. 5, and the method includes:
s501, the server 40 applies for a storage space of the off-heap memory 402 of a fixed size in advance during initialization.
S502, the server 40 acquires a keyword for search.
Specifically, reference is made to the above description of step S301, which is not repeated herein.
S503, the server 40 searches the first page of the storage device 41 according to the keyword.
S504, the server 40 stores the unique identifier of the data object having the key in the first page in the in-heap memory 401.
S505, the server 40 determines whether the number of the unique identifiers stored in the in-heap memory 401 reaches a threshold value.
Wherein the threshold value may be preset according to actual requirements. For example, the setting is made according to the space size of the in-heap memory.
Further, if the number of unique identifiers stored in the in-heap memory 401 reaches the threshold value, steps S506 and S507 are executed, and if the number of unique identifiers stored in the in-heap memory 401 does not reach the threshold value, step S508 is executed.
S506, the server 40 stores the unique identifier stored in the in-heap memory 401 in the out-heap memory 402.
S507, the server 40 deletes the unique identifier of the data object stored in the in-heap memory 401.
Further, step S508 is performed.
S508, the server 40 searches the second page of the storage device 41 according to the keyword until all data objects in the storage device 41 are searched.
That is, referring to the above steps S503 to S507, the server 40 performs the same operation for each page subsequent to the second page until all data objects in the storage device 41 are retrieved.
It should be noted that, after the last page in the storage device 41 is retrieved, if the unique identifier in the in-heap memory does not reach the threshold, the server 40 also transfers the unique identifier in the in-heap memory 401 to the out-heap memory 402 for storage.
S509, the server 40 reads the data object corresponding to the unique identifier in the storage device 41 according to the unique identifier in the off-heap memory 402.
And S510, the server 40 loads and displays the retrieval result.
By adopting the method, when the unique identification of a certain number of data objects is fully stored in the in-heap memory, the server transfers the unique identification stored in the in-heap memory to the out-heap memory for storage, simultaneously erases the storage space of the in-heap memory, then further retrieves the unique identification of the data objects to store in the erased in-heap memory, and the process is repeated. Therefore, under the condition of no search omission, the storage space occupied by the in-heap memory in each search is ensured not to exceed the threshold value, and the memory overflow is avoided. In addition, the read-write speed of the off-heap memory is higher than that of the in-heap memory, so that the embodiment of the invention can also improve the retrieval efficiency.
It should be noted that, for simplicity of description, the above method embodiments are described as a series of action combinations, but those skilled in the art should understand that the present invention is not limited by the described action sequences, and those skilled in the art should understand that the embodiments described in the description belong to the preferred embodiments, and the actions involved are not necessarily required by the present invention.
An embodiment of the present invention further provides a server 60, configured to implement the method for data retrieval provided in the foregoing method embodiment, where the server 60 includes an in-heap memory and an out-of-heap memory of a JVM, as shown in fig. 6A, the server 60 further includes:
an acquiring unit 61 is configured to acquire a keyword for search.
A retrieving unit 62, configured to retrieve the data object in a storage device in a page according to the keyword.
And the storage unit 63 is configured to sequentially store the unique identifiers of the data objects with the keywords in the in-heap memory.
Wherein the unique identifier is used for directly querying the corresponding data object in the storage device.
A determining unit 64, configured to determine that the number of the unique identifiers stored in the in-heap memory reaches a threshold value.
The storage unit 63 is further configured to store the unique identifier stored in the in-heap memory into the out-heap memory.
A deleting unit 65, configured to delete the unique identifier stored in the in-heap memory.
By adopting the server, the server searches data in a storage device in a paging mode, when the unique identifiers of the data objects stored in the memory in the JVM heap of the server reach a certain number, the unique identifiers of the data objects are stored in the memory in the heap, and the unique identifiers stored in the memory in the heap are deleted. Compared with the prior art that all data in the storage device is read into the in-heap memory during data retrieval, the invention only needs to read one page of data object to the in-heap memory every time during paging retrieval data, thereby avoiding memory overflow. Compared with the prior art, the storage position of the unique identifier of the data object is changed from the in-heap memory to the out-heap memory, and the overflow of the in-heap memory caused by the overlarge data size of the retrieval is also avoided. Moreover, the speed of the off-heap memory is higher than that of the in-heap memory when data is read and written, that is, the data retrieval efficiency can be improved by the embodiment of the invention.
Optionally, each page in the storage device comprises N data objects; the determining unit 64 is configured to determine that the retrieving unit pages to retrieve N data objects having the key; the storage unit 63 is configured to store the unique identifiers of the N data objects in the in-heap memory into the out-heap memory.
That is to say, every time the unique identifier of every full N data objects is stored in the in-heap memory, the server transfers the unique identifier stored in the in-heap memory to the out-heap memory for storage, and erases the storage space of the in-heap memory, and then further retrieves the unique identifier of the data object to be stored in the erased in-heap memory, and the process is repeated. Therefore, the storage space occupied by the heap memory does not exceed N at each time, and the memory overflow is avoided. And the number of the unique identifications of the qualified data objects stored in the off-heap memory is just one page, which is beneficial to displaying the retrieval result.
Optionally, as shown in fig. 6B, the server 60 further includes:
a reading unit 66, configured to read N data objects in the storage device according to the N unique identifiers in the off-heap memory; and the display unit 67 is used for loading and displaying the N data objects.
Optionally, as shown in fig. 6B, the server 60 further includes:
a paging unit 68, configured to page all data objects in the storage device before the retrieving unit retrieves the data objects in the storage device in a page according to the keyword.
Optionally, as shown in fig. 6B, the server 60 further includes:
an allocating unit 69, configured to allocate a storage space of the off-heap memory.
It should be noted that the above division of the unit of the server 60 is only one logical function division, and there may be another division manner in actual implementation. For example, the above-described storage unit 63 and determination unit 64 are divided into one processing unit. Moreover, various implementations of the physical implementation of the above functional units are also possible. For example, the processing unit may be a central processing unit CPU, or may also be an FPGA (Field Programmable Gate Array), which is not limited in the present invention.
In addition, it should be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of each unit of the server described above may refer to corresponding processes in the foregoing method embodiments, and are not described herein again.
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, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional unit.
The integrated unit implemented in the form of a software functional unit may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute some steps of the methods according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing data, such as a usb disk, a removable hard disk, a RAM (Random Access Memory), a magnetic disk, or an optical disk.
The above description is only for the specific embodiment of the present invention, but the scope of the present invention is not limited thereto, and any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present invention are included in the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (6)

1. A method for data retrieval, the method is applied to a server running a Java Virtual Machine (JVM), the server comprises an in-heap memory and an out-of-heap memory of the JVM, and the method comprises:
the server acquires a keyword for retrieval;
retrieving data objects in a storage device in a page according to the keywords, wherein each page in the storage device comprises N data objects, and performing the following operations for each page of data objects:
sequentially storing the unique identification of the data object with the key words into the in-heap memory; wherein the unique identifier is used for directly querying a corresponding data object in the storage device;
when the number of the unique identifiers stored in the in-heap memory reaches a threshold value, storing the unique identifiers stored in the in-heap memory into the out-of-heap memory, and deleting the unique identifiers stored in the in-heap memory; wherein, when the number of the unique identifiers stored in the in-heap memory reaches a threshold value, the storing of the unique identifiers stored in the in-heap memory into the out-heap memory includes:
after N data objects with the keywords are searched in a paging mode, storing the unique identifications of the N data objects in the in-heap memory into the out-of-heap memory;
the method further comprises the following steps: reading N data objects in the storage device according to the N unique identifiers in the off-heap memory; and loading and displaying the N data objects.
2. The method of claim 1, wherein prior to retrieving data objects in pages in a storage device according to the key, the method further comprises:
paging all data objects in the storage device.
3. The method of claim 1, further comprising:
and dividing the storage space of the server to allocate the storage space of the off-heap memory.
4. A server, wherein the server runs a Java virtual machine JVM, and wherein the server includes an in-heap memory and an out-of-heap memory of the JVM, and wherein the server further comprises:
an acquisition unit configured to acquire a keyword for retrieval;
the retrieval unit is used for retrieving the data objects in a storage device in a paging mode according to the keywords, wherein each page in the storage device comprises N data objects;
the storage unit is used for sequentially storing the unique identification of the data object with the keyword into the in-heap memory; wherein the unique identifier is used for directly querying a corresponding data object in the storage device;
a determining unit, configured to determine that the retrieving unit pages to retrieve N data objects having the key;
the storage unit is further configured to store the unique identifiers of the N data objects in the in-heap memory into the out-heap memory;
a deleting unit, configured to delete the unique identifier stored in the in-heap memory;
a reading unit, configured to read N data objects in the storage device according to the N unique identifiers in the off-heap memory;
and the display unit is used for loading and displaying the N data objects.
5. The server of claim 4, further comprising:
and the paging unit is used for paging all the data objects in the storage device before the retrieval unit retrieves the data objects in the storage device in a paging mode according to the keywords.
6. The server of claim 4, further comprising:
and the allocation unit is used for allocating the storage space of the off-heap memory.
CN201610749786.6A 2016-08-29 2016-08-29 Data retrieval method and server Active CN106339183B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610749786.6A CN106339183B (en) 2016-08-29 2016-08-29 Data retrieval method and server

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610749786.6A CN106339183B (en) 2016-08-29 2016-08-29 Data retrieval method and server

Publications (2)

Publication Number Publication Date
CN106339183A CN106339183A (en) 2017-01-18
CN106339183B true CN106339183B (en) 2020-02-11

Family

ID=57823927

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610749786.6A Active CN106339183B (en) 2016-08-29 2016-08-29 Data retrieval method and server

Country Status (1)

Country Link
CN (1) CN106339183B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108196937B (en) * 2017-12-26 2021-06-15 金蝶软件(中国)有限公司 Method and device for processing character string object, computer equipment and storage medium
CN110895475B (en) * 2018-09-10 2023-03-31 深圳云天励飞技术有限公司 Search server starting method and device and search server
CN109324904A (en) * 2018-09-29 2019-02-12 智器云南京信息科技有限公司 Dynamic memory management method and device

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101894049A (en) * 2010-07-14 2010-11-24 中兴通讯股份有限公司 System and method for recycling garbage object in self-adaptive way
CN103914399A (en) * 2012-12-31 2014-07-09 中国移动通信集团公司 Disk cache method and device in parallel computer system
CN104620219A (en) * 2012-08-31 2015-05-13 优米有限公司 Network service system and method with off-heap caching
CN104915435A (en) * 2015-06-24 2015-09-16 努比亚技术有限公司 Data query method and device
CN105224252A (en) * 2015-09-28 2016-01-06 北京奇虎科技有限公司 Date storage method and device
CN105893435A (en) * 2015-12-11 2016-08-24 乐视网信息技术(北京)股份有限公司 Data loading and storing equipment, method and system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101894049A (en) * 2010-07-14 2010-11-24 中兴通讯股份有限公司 System and method for recycling garbage object in self-adaptive way
CN104620219A (en) * 2012-08-31 2015-05-13 优米有限公司 Network service system and method with off-heap caching
CN103914399A (en) * 2012-12-31 2014-07-09 中国移动通信集团公司 Disk cache method and device in parallel computer system
CN104915435A (en) * 2015-06-24 2015-09-16 努比亚技术有限公司 Data query method and device
CN105224252A (en) * 2015-09-28 2016-01-06 北京奇虎科技有限公司 Date storage method and device
CN105893435A (en) * 2015-12-11 2016-08-24 乐视网信息技术(北京)股份有限公司 Data loading and storing equipment, method and system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Java 的缓存系统的设计;李海兵;《软件开发与设计》;20101218(第24期);第45-46页 *

Also Published As

Publication number Publication date
CN106339183A (en) 2017-01-18

Similar Documents

Publication Publication Date Title
US10606806B2 (en) Method and apparatus for storing time series data
EP3260993A1 (en) File operation method and device
US20160147806A1 (en) Versioned bloom filter
CN109496292B (en) Disk management method, disk management device and electronic equipment
EP3309685A1 (en) Method and apparatus for writing data to cache
CN106339183B (en) Data retrieval method and server
US20160216915A1 (en) Controller, flash memory apparatus, method for identifying data block stability, and method for storing data in flash memory apparatus
CN109086141B (en) Memory management method and device and computer readable storage medium
CN104794228A (en) Search result providing method and device
CN112148736B (en) Method, device and storage medium for caching data
CN105468644B (en) Method and equipment for querying in database
CN111831691B (en) Data reading and writing method and device, electronic equipment and storage medium
CN115840731A (en) File processing method, computing device and computer storage medium
CN109408416B (en) Address mapping table entry page management method and device
CN107590077B (en) Spark load memory access behavior tracking method and device
CN106156038B (en) Date storage method and device
US20170177476A1 (en) System and method for automated data organization in a storage system
JP2011165093A (en) Memory access examination device, memory access examination method and program
US10198209B2 (en) Memory storage recycling
CN108021562B (en) Disk storage method and device applied to distributed file system and distributed file system
CN112347060B (en) Data storage method, device and equipment of desktop cloud system and readable storage medium
JP2014071906A5 (en)
CN114265828A (en) Line migration elimination method and device, computer equipment and storage medium
CN113778911A (en) L2P data caching method and device, readable storage medium and electronic equipment
CN114297196A (en) Metadata storage method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant