Method and device for traversing timer

A timer and traversal technology, applied in the Internet field, can solve problems such as low efficiency of timer traversal, achieve the effects of reducing traversal times, improving traversal efficiency, and saving processing resources

Inactive Publication Date: 2016-06-08
BEIJING QIHOO TECH CO LTD +1
View PDF5 Cites 5 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The invention provides a method and device for traversing timers, which can solve the problem of low efficiency of timer traversal

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and device for traversing timer
  • Method and device for traversing timer
  • Method and device for traversing timer

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0027] Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that the present invention can be more thoroughly understood and the scope of the present disclosure can be fully conveyed to those skilled in the art.

[0028] The embodiment of the present invention provides a method for traversing timers, which is applied to the server side and is mainly used for traversing the timers used by the server memory. Such as figure 1 As shown, the method includes:

[0029] 101. Build a timer binary tree.

[0030] The server starts a timer for each piece of cached data. The start time of the timer is the moment when the data is stored in t...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a method and a device for traversing a timer, relates to the technical field of the Internet and is invited for solving the low traversing efficiency of the timer. The method comprises the following steps: constructing a timer binary tree, wherein the node numerical value of the timer binary tree is the arrival time moment value of the timer, the subnode of which the node numerical value is greater than a father node numerical value is the right subnode of the father node, and the subnode of which the node numerical value is smaller than the father node numerical value is the left subnode of the father node; traversing from a root node, and searching a target node of which the node numerical value is smaller than or equal to a current moment value; and closing the timer corresponding to the target node. The method is mainly used for traversing the timer used by a server memory.

Description

technical field [0001] The invention relates to the technical field of the Internet, in particular to a method and device for traversing a timer. Background technique [0002] When the terminal requests data from the server, the server will access the database, obtain the data content requested by the terminal from the database and return it to the terminal. Since each request will access the database, when the number of concurrent requests is large, it will cause a relatively large access pressure on the database. In order to reduce the access pressure of the database, engineers improved the existing technology and cached the data obtained from the database in the server memory. When the terminal initiates a data request, the server searches the memory for the data requested by the terminal, and returns it directly to the terminal if the data is found, thereby reducing the number of visits to the database. [0003] Usually, server-side memory resources are very precious, ...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F9/50G06F17/30
CPCG06F16/24539G06F9/5022G06F16/2246G06F16/24552
Inventor 艾菲
Owner BEIJING QIHOO TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products