CN109471879A - A kind of householder method and device of data seniority among brothers and sisters - Google Patents

A kind of householder method and device of data seniority among brothers and sisters Download PDF

Info

Publication number
CN109471879A
CN109471879A CN201811248981.6A CN201811248981A CN109471879A CN 109471879 A CN109471879 A CN 109471879A CN 201811248981 A CN201811248981 A CN 201811248981A CN 109471879 A CN109471879 A CN 109471879A
Authority
CN
China
Prior art keywords
sisters
brothers
seniority
memory type
scene
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
Application number
CN201811248981.6A
Other languages
Chinese (zh)
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.)
Zhuhai Tianyan Technology Co Ltd
Original Assignee
Zhuhai Tianyan Technology Co Ltd
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 Zhuhai Tianyan Technology Co Ltd filed Critical Zhuhai Tianyan Technology Co Ltd
Priority to CN201811248981.6A priority Critical patent/CN109471879A/en
Publication of CN109471879A publication Critical patent/CN109471879A/en
Pending legal-status Critical Current

Links

Abstract

The invention relates to the householder methods and device of a kind of data seniority among brothers and sisters.Method includes: to obtain memory type data when triggering preset condition for seniority among brothers and sisters scene and need synchronous data;According to ordered set data structure, needs synchronous data to be synchronized in the memory type database for seniority among brothers and sisters scene the memory type database, it is corresponding data cached to obtain the seniority among brothers and sisters scene;After obtaining for the seniority among brothers and sisters inquiry request of the seniority among brothers and sisters scene, the sequentialize commands of ordered set data structure are constructed;The data cached execution sequentialize commands corresponding to the seniority among brothers and sisters scene, obtain the corresponding ranking data of the seniority among brothers and sisters scene.The application provides real-time ranking data under the premise of meeting the seniority among brothers and sisters query requirement of high concurrent, independent of service database.

Description

A kind of householder method and device of data seniority among brothers and sisters
Technical field
The householder method and dress ranked the invention relates to technical field of data processing more particularly to a kind of data It sets.
Background technique
Traditional operation system is to determine ranking data from the service database of relationship type.This mode heavy dependence In the performance of service database.In the case where the seniority among brothers and sisters of high concurrent inquires scene, will cause service database does not have resource to provide connection, Inquiry is caused to fail.
For this problem, existing settling mode is the row that will be determined from service database based on asynchronous thread Row data are buffered in memory type database, are responsible for providing ranking data by memory type database.But asynchronous thread is using regular Execution mechanism not can guarantee the timeliness of ranking data;In addition, in the offline or abnormal scene of service database, such as it is right When service database carries out behavior extension, memory type database will be unable to be updated, and cause the ranking data of caching seriously stagnant Afterwards, the experience of user is significantly impacted.
In view of this, providing real-time ranking data how under the premise of meeting the seniority among brothers and sisters query requirement of high concurrent, being Technical problems to be solved in this application.
Summary of the invention
The embodiment of the present application purpose is to provide the householder method and device of a kind of data seniority among brothers and sisters, can meet high concurrent Under the premise of ranking query requirement, real-time ranking data is provided.
To achieve the goals above, the embodiment of the present application is achieved in that
In a first aspect, providing a kind of householder method of data seniority among brothers and sisters, comprising:
When triggering preset condition, memory type data are obtained for seniority among brothers and sisters scene and need synchronous data;
According to ordered set data structure, need synchronous data synchronous for seniority among brothers and sisters scene the memory type database To in the memory type database, it is corresponding data cached to obtain the seniority among brothers and sisters scene;
After obtaining for the seniority among brothers and sisters inquiry request of the seniority among brothers and sisters scene, the sequence life of building ordered set data structure It enables;
The data cached execution sequentialize commands corresponding to the seniority among brothers and sisters scene, obtain the corresponding row of the seniority among brothers and sisters scene Row data.
Second aspect provides a kind of auxiliary device of data seniority among brothers and sisters, comprising:
Module is obtained, needs synchronous number for seniority among brothers and sisters scene for when triggering preset condition, obtaining memory type data According to;
Synchronization module, for according to ordered set data structure, the memory type database to be needed for seniority among brothers and sisters scene Synchronous data are synchronized in the memory type database, and it is corresponding data cached to obtain the seniority among brothers and sisters scene;
Module is constructed, for constructing ordered set data after obtaining for the seniority among brothers and sisters inquiry request of the seniority among brothers and sisters scene The sequentialize commands of structure;
Execution module obtains the row for the data cached execution sequentialize commands corresponding to the seniority among brothers and sisters scene The corresponding ranking data of row scene.
In the embodiment of the present application, when the relevant business datum of seniority among brothers and sisters scene changes, according to ordered set data knot Structure will need to be synchronized to memory type database for the synchronous data of seniority among brothers and sisters scene, to utilize ordered set data structure Sequentialize commands are ranked up in memory type database for seniority among brothers and sisters the data cached of scene, obtain the corresponding row of seniority among brothers and sisters scene Row data.On the one hand, it needs not rely on asynchronous thread and obtains ranking data from service database, therefore is with higher real-time Property, and it is offline in service database or when being abnormal, it will not be affected;On the other hand, type database is strong based on memory The sorting query efficiency of big handling capacity and ordered set data structure superelevation, additionally it is possible to which the seniority among brothers and sisters inquiry for meeting high concurrent is wanted It asks.
Detailed description of the invention
In order to illustrate the technical solutions in the embodiments of the present application or in the prior art more clearly, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this The some embodiments recorded in application embodiment, for those of ordinary skill in the art, in not making the creative labor property Under the premise of, it is also possible to obtain other drawings based on these drawings.
Fig. 1 is the flow diagram of the householder method of data provided by the embodiments of the present application seniority among brothers and sisters;
Fig. 2 is the first process signal of the householder method of data provided by the embodiments of the present application seniority among brothers and sisters in practical applications Figure;
Fig. 3 is the second process signal of the householder method of data provided by the embodiments of the present application seniority among brothers and sisters in practical applications Figure;
Fig. 4 is the third process signal of the householder method of data provided by the embodiments of the present application seniority among brothers and sisters in practical applications Figure;
Fig. 5 is the structural schematic diagram of the auxiliary device of data provided by the embodiments of the present application seniority among brothers and sisters.
Specific embodiment
In order to make those skilled in the art better understand the technical solutions in the application, below in conjunction with the application reality The attached drawing in example is applied, the technical scheme in the embodiment of the application is clearly and completely described, it is clear that described implementation Example is merely a part but not all of the embodiments of the present application.Based on the embodiment in the application, this field is common The application protection all should belong in technical staff's every other embodiment obtained without creative efforts Range.
As previously mentioned, the prior art is the seniority among brothers and sisters that the asynchronous thread by being periodically executed will be determined from service database Data buffer storage is responsible for providing ranking data by memory type database into memory line database.This mode timeliness without Method meets in the requirement of user, such as some practical business scenes, and real-time ranking data can stimulate the sense of participation of user, right An important factor for being affect experience for user.In addition, the update of memory type data relies on service database, work as business datum Library it is offline or in it is abnormal when, will lead to the data cached there are serious lag and user institute nothing of memory type data What method received.
In view of this, the embodiment of the present application provides a kind of technical solution that can be solved the above problems.
On the one hand, the embodiment of the present application provides a kind of householder method of data seniority among brothers and sisters, as shown in Figure 1, comprising:
Step 102, when triggering preset condition, memory type data is obtained for seniority among brothers and sisters scene and need synchronous data;
For step 102:
It can obtain memory type data when operation system changes for the corresponding business datum of seniority among brothers and sisters scene and be directed to It ranks scene and needs synchronous data.
For example, above-mentioned operation system is financial system, corresponding seniority among brothers and sisters scene can be the size to user according to remaining sum It is ranked.When user generates the amount of money of increase or reduction, memory type database can be obtained for seniority among brothers and sisters scene institute Need synchronous data.
Step 104, according to ordered set data structure, memory type database is needed into synchronous data for seniority among brothers and sisters scene It is synchronized in memory type database, it is corresponding data cached to obtain seniority among brothers and sisters scene;
For step 104:
Data sorting is ordered into the basic function of Collection data structures, and the embodiment of the present application will rank the data cached of scene It stores according to ordered set data structure to memory database, i.e., using the ranking function of ordered set data structure, to slow Deposit data is ranked up, and obtains ranking data.
Step 106, after obtaining for the seniority among brothers and sisters inquiry request of seniority among brothers and sisters scene, the sequence of ordered set data structure is constructed Order;
For step 106:
This step can realize the sequence of various ways, for example realize based on the sequentialize commands of ordered set data structure Page sorting, range sequence etc..
The embodiment of the present application is not defined specific sortord.
Step 108, to the corresponding data cached execution sequentialize commands of seniority among brothers and sisters scene, the corresponding seniority among brothers and sisters number of seniority among brothers and sisters scene is obtained According to.
For step 108:
It should be understood that ranking data is obtained to after the data cached execution sequentialize commands in memory type database, not It is as in the prior art, being obtained from service database.Therefore memory type database can not depend on service database and mention For ranking data.
In the embodiment of the present application, when the relevant business datum of seniority among brothers and sisters scene changes, according to ordered set data knot Structure will need to be synchronized to memory type database for the synchronous data of seniority among brothers and sisters scene, to utilize ordered set data structure Sequentialize commands are ranked up in memory type database for seniority among brothers and sisters the data cached of scene, obtain the corresponding row of seniority among brothers and sisters scene Row data.On the one hand, it needs not rely on asynchronous thread and obtains ranking data from service database, therefore is with higher real-time Property, and it is offline in service database or when being abnormal, it will not be affected;On the other hand, type database is strong based on memory The sorting query efficiency of big handling capacity and ordered set data structure superelevation, additionally it is possible to which the seniority among brothers and sisters inquiry for meeting high concurrent is wanted It asks.
It describes in detail below to the householder method of the data seniority among brothers and sisters of the embodiment of the present application.
The embodiment of the present application according to ZSet data structure (a kind of ordered set data structure), will specifically be needed for seniority among brothers and sisters The synchronous data of scene are synchronized in memory type database.
ZSet data structure belongs to key-value one of which manifestation mode.It includes: key, member and score tri- Kind of element, under each key, member is corresponding with a score.The characteristics of ZSet data structure, can be based on score value Size sorts to member.
The characteristics of based on ZSet data structure, the embodiment of the present application define seniority among brothers and sisters period, seniority among brothers and sisters object to seniority among brothers and sisters scene With seniority among brothers and sisters three attribute of attribute value, respectively as the key key, member member and score score of ZSet data structure.
The subsequent sequentialize commands to the data cached execution ZSet data structure after synchronizing, can be to rank the period as constraint Condition is ranked up seniority among brothers and sisters object according to the size of seniority among brothers and sisters attribute value, obtains the corresponding ranking data of seniority among brothers and sisters scene.
Wherein, memory type database includes: target row for the required data synchronous to service database of seniority among brothers and sisters scene The corresponding variate-value of seniority among brothers and sisters attribute value of row object (target seniority among brothers and sisters object belongs to the seniority among brothers and sisters object in seniority among brothers and sisters scene);
When executing above-mentioned steps 104, specifically includes the following steps:
Step 1041, if the key of memory type database has the field value in current seniority among brothers and sisters period, it is based on variate-value, it is right Target ranks field value of the object in the score that currently the seniority among brothers and sisters period corresponds to memory type database and modifies;
Step 1042, if the key of memory type database will currently be ranked week there is no the field value in current seniority among brothers and sisters period The field configuration of phase is based on variate-value into the key of memory type database, to target seniority among brothers and sisters object within a upper seniority among brothers and sisters period The field value deposited in the score of type database is calculated, and calculated result is written to target seniority among brothers and sisters object and is ranked currently Period corresponds in the score of memory type database.
It should be understood that the memory type database in the embodiment of the present application can save the ranking data in multiple seniority among brothers and sisters periods, i.e., Field value containing multiple seniority among brothers and sisters periods in the Key of memory type database.
Alternatively, the memory type database in the embodiment of the present application can also refer to the seniority among brothers and sisters number for retaining a nearest seniority among brothers and sisters period According to.That is, after having executed above-mentioned steps 1042, also further delete target seniority among brothers and sisters object a upper seniority among brothers and sisters period correspond to key, Field value in member, score.
Certainly, if the member of memory type database does not have the field value of target seniority among brothers and sisters object, the embodiment of the present application Further the field value of target seniority among brothers and sisters object can also be configured into the member of memory type database.
It should be noted that the ordering instruction of ZSet data structure is first according to the field value size of score to member It is ranked up, when score field value size is identical, according further to member field value with permanent order from big to small Member is ranked up.
Therefore, the embodiment of the present application can pass through setting in the member configuration seniority among brothers and sisters object for memory type database The size of the field value of object is ranked, to realize more specifically sequence effect.
For example, the seniority among brothers and sisters object that the application ranks in scene is divided into high priority seniority among brothers and sisters object and low priority seniority among brothers and sisters pair As.
When seniority among brothers and sisters attribute value is identical, the ranking that high priority ranks object should be located at the ranking of low priority seniority among brothers and sisters object Before.
Accordingly, the number that numerical value expression can be used in the embodiment of the present application represents seniority among brothers and sisters object, the seniority among brothers and sisters of high priority The number numerical value of object is greater than the number numerical value of the seniority among brothers and sisters object of low priority.
In the member configuration seniority among brothers and sisters object for memory type database, the number of object can will be ranked as seniority among brothers and sisters pair The field value of elephant is written into member.
Priority body using the user in operation system as seniority among brothers and sisters object as example, in actual scene, between user Present operation system side, operation system can generally give number of its user configuration as user identifier, different preferential to distinguish Grade.
It therefore, is reduction procedure, the embodiment of the present application can be using multiplexing service system as the number of user configuration, as user Field value in the member of memory type database.
Certainly, if operation system to the user identifier of its user configuration is not the number indicated with numerical value, the application is real It applies example and is further based on preset compiler algorithm, the number indicated with numerical value will be compiled into the user identifier that family configures.
It should be understood that the priority of user is higher, then the numerical value of the number of compiler algorithm compiling is bigger;The priority of user is got over Low, then the numerical value of the number of compiler algorithm compiling is smaller.
What needs to be explained here is that the ordering instruction of ZSet data structure can only be with the field value of member from big to small Permanent order is ranked up.
The corresponding number size of user depends on operation system, the number for the high-priority users that may determine in practice The number of low first grade user can be less than, will lead in this way when the ordering instruction based on ZSet data structure is ranked up, it is low excellent The ranking of first grade user is located at before the ranking of high priority.To avoid this problem from occurring, it is set larger to can be used one Value subtracts field value of the corresponding number of user as user in member.
For example it is 1 that operation system, which is the number value that high-priority users configure, the number value of low priority user configuration is 2, then predetermined value can take 10, and field value of the high-priority users in member is 10-1=9, and low priority user exists Field value in member is 10-2=8.Exist since field value of the high priority in member is greater than low priority user Field value (9 > 8) in member, therefore in the identical situation of the two seniority among brothers and sisters attribute value, high-priority users can come low Before priority users.
In specific implementation, the embodiment of the present application can construct the configuration process of the field value of seniority among brothers and sisters object, the configuration Journey is used to subtract the corresponding number of seniority among brothers and sisters object using predetermined value, and configures calculated result as the field value of seniority among brothers and sisters object Into the member of memory type database;Wherein, it is to rank the number of the number of object configuration that predetermined value, which should be greater than operation system, It is worth the upper limit, to avoid there is the case where negative value.
After obtaining configuration process, it can be based on above-mentioned configuration process, the field value of arbitrary target seniority among brothers and sisters object is configured Into the member of memory type database.
Accordingly, target is read from memory type database and rank object, then need to rank target object in member Middle field value reverts back corresponding number, to correctly identify that target ranks object based on number.That is, the embodiment of the present application Householder method further include:
The reading process of the field value of building seniority among brothers and sisters object, the reading process are used to subtract seniority among brothers and sisters pair using upper predetermined value As the field value in the member of memory type database, the corresponding number of seniority among brothers and sisters object is obtained;Wherein, seniority among brothers and sisters object is corresponding Number the reading result of the field value as seniority among brothers and sisters object.
For example, target seniority among brothers and sisters object is encoded to 10, set value 100 is based on above-mentioned configuration process, and target ranks object Field value in the member of memory type database is 100-10=90.
It, can through above-mentioned reading process when reading the field value marked and rank object in the member of memory type database To use set value 100 to subtract field value 90 of the target seniority among brothers and sisters object in member, accurate reproduction returns target seniority among brothers and sisters object Coding.
It should be understood that the scheme of the embodiment of the present application can be according to operation system to the configuration feature of user identifier, decision is No building seniority among brothers and sisters object is directed to the configuration process and reading process of member.
According to ZSet data structure, synchronous data are needed to be synchronized to memory for seniority among brothers and sisters scene memory type database After in type database, it can be ranked up by the sequentialize commands of ZSet data structure to data cached, to obtain ranking data.
Specifically, after obtaining seniority among brothers and sisters inquiry request, the field value in current seniority among brothers and sisters period is first determined, and by currently ranking The field value in period corresponds to the data cached of current seniority among brothers and sisters period to judge that memory database whether there is.
If the key of memory type database has the field value in current seniority among brothers and sisters period, construct currently to rank the word in period Segment value is constraint condition, the sequentialize commands being ranked up to member according to the size of score;
If there is no the field values in current seniority among brothers and sisters period by the key of memory type database, the above seniority among brothers and sisters period is constructed Field value is constraint condition, the sequentialize commands being ranked up to member according to the size of score.
In practical applications, the embodiment of the present application can construct ZRank order or ZRevarange order, to data cached Realize sequence.
By taking ZRank order as an example, the application can instruct the field value according to seniority among brothers and sisters object based on ZRank, and inquiry corresponds to Ranking.Skiplist skip list inside ZSet is (average O (logN) the worst O (N)) skip list with time complexity Node carries out span data, and inquiry obtains ranking data.
By taking ZRevarange order as an example, range query, such as 1-100 directly can be realized using ZrevRange order Name is ranked up seniority among brothers and sisters object according to the sequence of seniority among brothers and sisters attribute value from big to small, obtains first 100 seniority among brothers and sisters to seniority among brothers and sisters object Data.
It should be understood that the embodiment of the present application can be using key as constraint condition, according to score pairs based on ZSet data structure The characteristics of member is ranked up, will rank scene in the seniority among brothers and sisters period, seniority among brothers and sisters object and seniority among brothers and sisters attribute value as key, Member and score, to realize within a certain seniority among brothers and sisters period, the function being ranked up according to seniority among brothers and sisters attribute value to seniority among brothers and sisters object Energy.Mapping relations are simple between key, member and score, i.e., also can be realized when box lunch data volume grade is huge efficiently quickly Sequence, it is that the data structure of other key-value can not reach that performance is brilliant.
Below with reference to practical application, the process of the householder method of application embodiment is introduced.
Illustratively, the operation system in this practical application is metal system, is configured with Mysql database and Redis number According to library.Wherein, Mysql database is as service database;Redis database is as memory type database, for seniority among brothers and sisters scene, Using ZSet data structure.
Assuming that seniority among brothers and sisters scene is ranked for the remaining sum of user, the seniority among brothers and sisters period is week, as ZSet data structure key;Seniority among brothers and sisters object is user, the member as ZSet data structure;Seniority among brothers and sisters attribute value is remaining sum value, as ZSet data knot The score of structure.
This practical application can be updated Redis database using two ways.
A kind of mode is obtained from Mysql database and is needed for seniority among brothers and sisters scene using the asynchronous thread being periodically executed Synchronous data, which is as shown in Fig. 2, main flow includes:
When meeting the trigger condition being periodically executed, the pipelined data of full dose is obtained from Mysql database.
Determine the key value (field value) in current seniority among brothers and sisters period, i.e. this week corresponding Key value.
Based on the key value in preceding seniority among brothers and sisters period, it is synchronous that data are carried out to Redis database by the pipelined data of full dose.
Empty in Redis database it is upper one seniority among brothers and sisters the period it is data cached.
Since in the method, the synchrodata of Redis database derives from service database, therefore can be from business datum The pipelined data that library obtains full dose carries out balance updates to users all in Redis database can also be right after the completion of update A upper seniority among brothers and sisters the data cached of period is deleted.
Another way is, as soon as there is the remaining sum of user to change in operation system, carries out to Redis database same Step, which is as shown in figure 3, main flow includes:
When the remaining sum of target user in operation system changes, target user's remaining sum is obtained from operation system Variate-value.
Determine the key value (i.e. this week corresponding key value) in current seniority among brothers and sisters period.
Judge whether redis database deposits target with the presence or absence of the key value and redis database in current seniority among brothers and sisters period The member value of user.
If there is no the key values in current seniority among brothers and sisters period for redis database, call Zadd instruction in redis database The key value in current seniority among brothers and sisters period is configured in key.
If the member value of target user is not present in redis database, the Zadd of ZSet data structure is called to instruct The member value of target user, and the variate-value of the remaining sum based on target user are configured in the member of redis database, are matched Set field value of the target user in the score of current period.
If redis database has the key value in current seniority among brothers and sisters period and the member value of target user, call The incrementScorem order of ZSet data structure, according to the variate-value of the user balance, to the user in current period pair The score value answered is adjusted.
After being updated by Fig. 2 and method shown in Fig. 3 to Redis database, it can be obtained based on sequentialize commands The ranking data of Redis database, corresponding process are as shown in Figure 4, comprising:
Obtain the seniority among brothers and sisters inquiry request ranked with remaining sum size to user.
Determine the key value (i.e. this week corresponding key value) in current seniority among brothers and sisters period.
Judge redis database with the presence or absence of the key value in current seniority among brothers and sisters period.
It is right based on the key value in current seniority among brothers and sisters period if redis database has the key value in current seniority among brothers and sisters period The Page sorting of the data cached execution ZSet data structure of redis database instructs, and obtains the ranking data of Pagination Display;And The ranking data of Pagination Display is subjected to unserializing processing, and parsing, assembling, to show in operation system.
If redis database be there is no the key value in current seniority among brothers and sisters period (until current time, the ranking data of this week Do not change with upper week list data), it is determined that the kye value in a upper seniority among brothers and sisters period, and judge whether redis database is deposited In the key value in a upper seniority among brothers and sisters period;
If there are the key values in a upper seniority among brothers and sisters period for redis database, right based on the key value in a upper seniority among brothers and sisters period The Page sorting of the data cached execution ZSet data structure of redis database instructs, to the ranking data of Pagination Display;And it will The ranking data of Pagination Display carries out unserializing processing, and parsing, assembling, to show in operation system.If redis number According to library, there is no the key values in a upper seniority among brothers and sisters period, then execute abnormality processing (such as alarm, recording exceptional log).
Based on above-mentioned design, data page sort method provided by the embodiments of the present application is right by step shown in Fig. 2 Redis database carries out regularly full dose and updates, and is based on step shown in Fig. 3, carries out real-time increment to Redis database It updates, so that the ranking data for guaranteeing that Redis database provides is consistent with practical scene, is mentioned outward with the smallest performance consumption For ranking query service.Only need the key for increasing Redis database that more multi-functional extension can be realized simultaneously, such as simultaneously Realize the functions such as week list, day seniority among brothers and sisters, month list.
It is the introduction to the householder method of the data seniority among brothers and sisters of the embodiment of the present application above.It should be understood that the embodiment of the present application needle Seniority among brothers and sisters scene is not limited to only synchronize memory type database progress data according to ZSet data structure, can also be at this On basis, the data cached of scene is ranked further according to String data structure and Hash data structure records, to realize More expanding functions.In addition, the memory type database in the embodiment of the present application is also not necessarily limited to be only to record a kind of seniority among brothers and sisters scene It is corresponding data cached, it can be recorded respectively for different seniority among brothers and sisters scenes corresponding data cached.
Correspondingly, the embodiment of the present application also provides a kind of auxiliary device of data seniority among brothers and sisters, as shown in Figure 5, comprising:
Module 51 is obtained, is used for when triggering preset condition, memory type data is obtained for seniority among brothers and sisters scene and needs synchronization Data;
Specifically, obtain module 51 can when operation system changes for the corresponding business datum of seniority among brothers and sisters scene, It obtains memory type data and needs synchronous data for seniority among brothers and sisters scene.
For example, above-mentioned operation system is financial system, corresponding seniority among brothers and sisters scene can be the size to user according to remaining sum It is ranked.Module 51 is obtained when user generates the amount of money of increase or reduction, memory type database can be obtained for row Synchronous data required for row scene.
Synchronization module 52, for according to ordered set data structure, the memory type database to be needed for seniority among brothers and sisters scene The data to be synchronized are synchronized in the memory type database, and it is corresponding data cached to obtain the seniority among brothers and sisters scene;
Wherein, data sorting is ordered into the basic function of Collection data structures, will rank the data cached according to having of scene Ordered sets data structure is stored to memory database, i.e., using the ranking function of ordered set data structure, to data cached It is ranked up, obtains ranking data.
Module 53 is constructed, for constructing ordered set number after obtaining for the seniority among brothers and sisters inquiry request of the seniority among brothers and sisters scene According to the sequentialize commands of structure;
Wherein, building module 53 can realize the sequence of various ways based on the sequentialize commands of ordered set data structure, For example realize Page sorting, range sequence etc..The embodiment of the present application is not defined specific sortord.
Execution module 54 obtains described for the data cached execution sequentialize commands corresponding to the seniority among brothers and sisters scene Rank the corresponding ranking data of scene.
Wherein, ranking data is obtained to after the data cached execution sequentialize commands in memory type database, is not As in the prior art, being obtained from service database.Therefore memory type database can not depend on service database offer Ranking data.
In the embodiment of the present application, when the relevant business datum of seniority among brothers and sisters scene changes, according to ordered set data knot Structure will need to be synchronized to memory type database for the synchronous data of seniority among brothers and sisters scene, to utilize ordered set data structure Sequentialize commands are ranked up in memory type database for seniority among brothers and sisters the data cached of scene, obtain the corresponding row of seniority among brothers and sisters scene Row data.On the one hand, it needs not rely on asynchronous thread and obtains ranking data from service database, therefore is with higher real-time Property, and it is offline in service database or when being abnormal, it will not be affected;On the other hand, type database is strong based on memory The sorting query efficiency of big handling capacity and ordered set data structure superelevation, additionally it is possible to which the seniority among brothers and sisters inquiry for meeting high concurrent is wanted It asks.
It describes in detail below to the auxiliary device of the data seniority among brothers and sisters of the embodiment of the present application.
The embodiment of the present application according to ZSet data structure (a kind of ordered set data structure), will specifically be needed for seniority among brothers and sisters The synchronous data of scene are synchronized in memory type database.
ZSet data structure belongs to key-value one of which manifestation mode.It includes: key, member and score tri- Kind of element, under each key, member is corresponding with a score.The characteristics of ZSet data structure, can be based on score value Size sorts to member.
The characteristics of based on ZSet data structure, the embodiment of the present application define seniority among brothers and sisters period, seniority among brothers and sisters object to seniority among brothers and sisters scene With seniority among brothers and sisters three attribute of attribute value, respectively as the key key, member member and score score of ZSet data structure.
The subsequent sequentialize commands to the data cached execution ZSet data structure after synchronizing, can be to rank the period as constraint Condition is ranked up seniority among brothers and sisters object according to the size of seniority among brothers and sisters attribute value, obtains the corresponding ranking data of seniority among brothers and sisters scene.
Wherein, memory type database includes: target row for the required data synchronous to service database of seniority among brothers and sisters scene The corresponding variate-value of seniority among brothers and sisters attribute value of row object (target seniority among brothers and sisters object belongs to the seniority among brothers and sisters object in seniority among brothers and sisters scene);Synchronization module 52 are specifically used for:
If the key of the memory type database has the field value in current seniority among brothers and sisters period, it is based on the variate-value, to institute Field value of the target seniority among brothers and sisters object in the score that currently the seniority among brothers and sisters period corresponds to the memory type database is stated to modify;
If there is no the field values in current seniority among brothers and sisters period by the key of the memory type database, by the current seniority among brothers and sisters period Field configuration is based on the variate-value into the key of the memory type database, to target seniority among brothers and sisters object in a upper row The field value that the row period corresponds in the score of the memory type database is calculated, and calculated result is written to the mesh Mark seniority among brothers and sisters object is in the score that currently the seniority among brothers and sisters period corresponds to the memory type database.
It should be understood that the memory type database in the embodiment of the present application can save the ranking data in multiple seniority among brothers and sisters periods, i.e., Field value containing multiple seniority among brothers and sisters periods in the Key of memory type database.
Alternatively, the memory type database in the embodiment of the present application can also refer to the seniority among brothers and sisters number for retaining a nearest seniority among brothers and sisters period According to.That is, synchronization module 52 ranks object after currently ranking in the score that the period corresponds to memory type database in write-in target, It also further deletes target seniority among brothers and sisters object and corresponded to field value in key, member, score in a upper seniority among brothers and sisters period.
Certainly, if the member of memory type database does not have the field value of target seniority among brothers and sisters object, the embodiment of the present application Synchronization module 52 can also further configure the field value of target seniority among brothers and sisters object into the member of memory type database.
It should be noted that the ordering instruction of ZSet data structure is first according to the field value size of score to member It is ranked up, when score field value size is identical, according further to member field value with permanent order from big to small Member is ranked up.
Therefore, the synchronization module 52 of the embodiment of the present application for memory type database member configuration seniority among brothers and sisters object when, It can be by the size of the field value of setting seniority among brothers and sisters object, to realize more specifically sequence effect.
For example, the seniority among brothers and sisters object that the application ranks in scene is divided into high priority seniority among brothers and sisters object and low priority seniority among brothers and sisters pair As.
When seniority among brothers and sisters attribute value is identical, the ranking that high priority ranks object should be located at the ranking of low priority seniority among brothers and sisters object Before.
Accordingly, the number that numerical value expression can be used in the embodiment of the present application represents seniority among brothers and sisters object, the seniority among brothers and sisters of high priority The number numerical value of object is greater than the number numerical value of the seniority among brothers and sisters object of low priority.
Synchronization module 52 can will rank the number of object in the member configuration seniority among brothers and sisters object for memory type database Field value as seniority among brothers and sisters object is written into member.
Priority body using the user in operation system as seniority among brothers and sisters object as example, in actual scene, between user Present operation system side, operation system can generally give number of its user configuration as user identifier, different preferential to distinguish Grade.
Synchronization module 52 can be using multiplexing service system as the number of user configuration, as user in memory type database Field value in member.
Certainly, if operation system to the user identifier of its user configuration is not the number indicated with numerical value, synchronization module 52 can also be based further on preset compiler algorithm, and the number indicated with numerical value will be compiled into the user identifier that family configures.
What needs to be explained here is that the ordering instruction of ZSet data structure can only be with the field value of member from big to small Permanent order is ranked up.
The corresponding number size of user depends on operation system, it is thus possible to the high priority determined from business system side The number of user can be less than the number of low first grade user, will lead to arranged in the ordering instruction based on ZSet data structure in this way When sequence, the ranking of low priority user is located at before the ranking of high priority.To avoid this problem from occurring, synchronization module 52 can To use a set the larger value to subtract field value of the corresponding number of user as user in member.
For example it is 1 that operation system, which is the number value that high-priority users configure, the number value of low priority user configuration is 2, then predetermined value can take 10, and field value of the high-priority users in member is 10-1=9, and low priority user exists Field value in member is 10-2=8.Exist since field value of the high priority in member is greater than low priority user Field value (9 > 8) in member, therefore in the identical situation of the two seniority among brothers and sisters attribute value, high-priority users can come low Before priority users.
In specific implementation, synchronization module 52 can construct the configuration process of the field value of seniority among brothers and sisters object, the configuration process It is configured for using a predetermined value to subtract the corresponding number of seniority among brothers and sisters object, and using calculated result as the field value of seniority among brothers and sisters object Into the member of memory type database;Wherein, it is to rank the numerical value of the number of object configuration that predetermined value, which is greater than operation system, The upper limit.
After obtaining configuration process, synchronization module 52 is based on the configuration process, and arbitrary target can be ranked to the word of object Segment value is configured into the member of memory type database.
Accordingly, target seniority among brothers and sisters object is read from memory type database then needs to rank target object in member Field value reverts back corresponding number, to correctly identify that target ranks object.That is the synchronization module 52 of the embodiment of the present application Also particularly useful for:
The reading process of the field value of building seniority among brothers and sisters object, the reading process are used to subtract row using the predetermined value Field value of the row object in the member of the memory type database obtains the corresponding number of seniority among brothers and sisters object;Wherein seniority among brothers and sisters pair Reading result as corresponding number as the field value of seniority among brothers and sisters object.
For example, target seniority among brothers and sisters object is encoded to 10, set value 100 is based on above-mentioned configuration process, and target ranks object Field value in the member of memory type database is 100-10=90.Mark seniority among brothers and sisters object is being read by above-mentioned reading process When field value in the member of memory type database, set value 100 can be used and subtract target seniority among brothers and sisters object in member In field value 90, accurate reproduction return target seniority among brothers and sisters object coding.
In practical applications, whether synchronization module 52 can be determined according to operation system to the configuration feature of user identifier Building seniority among brothers and sisters object is directed to the configuration process and reading process of member.
According to ZSet data structure, synchronous data are needed to be synchronized to memory for seniority among brothers and sisters scene memory type database After in type database, building module 34 can construct the sequentialize commands of ZSet data structure.
As exemplary introduction, constructs module 34 and is specifically used for:
After obtaining seniority among brothers and sisters inquiry request, the field value in current seniority among brothers and sisters period is first determined, and pass through the currently seniority among brothers and sisters period Field value judges the memory database with the presence or absence of corresponding data cached.
If the key of memory type database has the field value in current seniority among brothers and sisters period, construct currently to rank the word in period Segment value is constraint condition, the sequentialize commands being ranked up to member according to the size of score;
If there is no the field values in current seniority among brothers and sisters period by the key of memory type database, the above seniority among brothers and sisters period is constructed Field value is constraint condition, the sequentialize commands being ranked up to member according to the size of score.
In practical applications, the embodiment of the present application can be by ZRank order and ZRevarange order to data cached Realize Page sorting.
By taking ZRank order as an example, execution module 54 can instruct the field value according to seniority among brothers and sisters object, inquiry based on ZRank Corresponding ranking.Skiplist skip list inside ZSet carries out span data by skip list node of time complexity, Inquiry obtains ranking data.
By taking ZRevarange order as an example, execution module 54 directly can realize range query using ZrevRange order, Such as 1-100 be ranked up seniority among brothers and sisters object according to seniority among brothers and sisters attribute value sequence from big to small, obtains preceding 100 to ranking pair The ranking data of elephant.
In addition, in practical applications, the acquisition module 51 of the application can obtain memory type database using two ways Synchronous data are needed for seniority among brothers and sisters scene.
A kind of mode is the asynchronous thread for obtaining module 51 and being periodically executed, and is obtained from service database for seniority among brothers and sisters scene Need synchronous data, in which, obtaining module 51 to need the preset condition triggered includes: holding for the asynchronous thread pre-seted The row period;
Another way obtains module 51 to Redis database as soon as there is the remaining sum of user to change in operation system It synchronizes.Obtaining module 51 to need the preset condition triggered includes: operation system for the corresponding business of the seniority among brothers and sisters scene Data change.It is corresponding for the seniority among brothers and sisters scene based on the operation system got from operation system to obtain module 51 The data that business datum changes determine that memory type database needs synchronous data for seniority among brothers and sisters scene.
Obviously, the auxiliary device of data seniority among brothers and sisters provided by the embodiments of the present application is the embodiment of the present application data provided above The executing subject of the householder method of seniority among brothers and sisters, therefore technical effect achieved by the householder method, it is provided by the embodiments of the present application Auxiliary device equally can be realized, than the step of described in as shown in Figure 1, Figure 2, Fig. 3 and Fig. 4 and function.
The computer program product of householder method and device based on data seniority among brothers and sisters provided by the embodiment of the present application, including The computer readable storage medium of program code is stored, the instruction that said program code includes can be used for executing previous methods reality The step of applying described in example, specific implementation can be found in embodiment of the method, and details are not described herein.
In addition, the embodiment of the present application also provides a kind of operation system, which includes:
The auxiliary device of memory type database and above-mentioned data seniority among brothers and sisters shown in fig. 5.
The corresponding data of scene will be ranked according to ZSet number based on the operation system with the auxiliary device, the embodiment of the present application It caches according to structure into memory type database.When receive for seniority among brothers and sisters scene ranking inquiry refer to request when, to memory type number According to the data cached execution sequentialize commands in library, thus efficiently, be quickly obtained corresponding precedence data, and respond.Due to disobeying Rely service database, therefore when service database occurs offline or abnormal, can also guarantee to provide real-time precedence data. In some special application scenarios, the operation system of the embodiment of the present application can meet user and urgently know current ranking data Demand, to transfer the enthusiasm and sense of participation of user.
In embodiment provided by the present invention, it should be understood that disclosed device and method, it can also be by other Mode realize.Device and method embodiment described above is only schematical, for example, flow chart and frame in attached drawing Figure shows the system frame in the cards of the system of multiple embodiments according to the present invention, method and computer program product Structure, function and operation.In this regard, each box in flowchart or block diagram can represent a module, section or code A part, a part of the module, section or code includes one or more for implementing the specified logical function Executable instruction.It should also be noted that function marked in the box can also be with not in some implementations as replacement It is same as the sequence marked in attached drawing generation.For example, two continuous boxes can actually be basically executed in parallel, they have When can also execute in the opposite order, this depends on the function involved.It is also noted that in block diagram and or flow chart Each box and the box in block diagram and or flow chart combination, can function or movement as defined in executing it is dedicated Hardware based system realize, or can realize using a combination of dedicated hardware and computer instructions.In addition, in this hair Each functional module in bright each embodiment can integrate one independent part of formation together, be also possible to modules list Solely exist, an independent part can also be integrated to form with two or more modules.
It should be noted that, in this document, term " including ", " including " or its any other variant are intended to non-row Its property includes, so that the process, method, article or equipment for including a series of elements not only includes those elements, and And further include the other elements being not explicitly listed, or further include for this process, method, article or equipment institute it is intrinsic Element.In the absence of more restrictions, the element limited by sentence " including one ... ", it is not excluded that including institute State in the process, method, article or equipment of element that there is also other identical elements.
The above description is only an example of the present application, is not intended to limit this application.For those skilled in the art For, various changes and changes are possible in this application.All any modifications made within the spirit and principles of the present application are equal Replacement, improvement etc., should be included within the scope of the claims of this application.

Claims (15)

1. a kind of householder method of data seniority among brothers and sisters characterized by comprising
When triggering preset condition, memory type data are obtained for seniority among brothers and sisters scene and need synchronous data;
According to ordered set data structure, synchronous data are needed to be synchronized to institute for seniority among brothers and sisters scene the memory type database It states in memory type database, it is corresponding data cached to obtain the seniority among brothers and sisters scene;
After obtaining for the seniority among brothers and sisters inquiry request of the seniority among brothers and sisters scene, the sequentialize commands of ordered set data structure are constructed;
The data cached execution sequentialize commands corresponding to the seniority among brothers and sisters scene, obtain the corresponding seniority among brothers and sisters number of the seniority among brothers and sisters scene According to.
2. the method as described in claim 1, which is characterized in that
The ordered set data structure is ZSet data structure, and the seniority among brothers and sisters period in the seniority among brothers and sisters scene is as the ZSet number According to the key key of structure, member member of the seniority among brothers and sisters object ranked in scene as the ZSet data structure, the row Score score of the seniority among brothers and sisters attribute value as the ZSet data structure in row scene;
Wherein, the sequentialize commands are used to be ranked up member according to the size of score using key as constraint condition.
3. method according to claim 2, which is characterized in that
The memory type database includes target seniority among brothers and sisters object for the required data synchronous to service database of seniority among brothers and sisters scene The corresponding variate-value of seniority among brothers and sisters attribute value, target seniority among brothers and sisters object belongs to the seniority among brothers and sisters object in the seniority among brothers and sisters scene;
According to ordered set data structure, synchronous data are needed to be synchronized to institute for seniority among brothers and sisters scene the memory type database It states in memory type database, comprising:
If the key of the memory type database has the field value in current seniority among brothers and sisters period, it is based on the variate-value, to the mesh Field value of the mark seniority among brothers and sisters object in the score that currently the seniority among brothers and sisters period corresponds to the memory type database is modified;
If there is no the field values in current seniority among brothers and sisters period by the key of the memory type database, by the field in current seniority among brothers and sisters period Configuration is based on the variate-value into the key of the memory type database, to target seniority among brothers and sisters object in upper seniority among brothers and sisters week The field value that phase corresponds in the score of the memory type database is calculated, and calculated result is written to the target and is arranged Row object is in the score that currently the seniority among brothers and sisters period corresponds to the memory type database.
4. method as claimed in claim 3, which is characterized in that
According to ordered set data structure, synchronous data are needed to be synchronized to institute for seniority among brothers and sisters scene the memory type database It states in memory type database, further includes:
If the member of the memory type database does not have the field value of the target seniority among brothers and sisters object, the target is ranked The field value of object is configured into the member of the memory type database.
5. method as claimed in claim 4, which is characterized in that
Seniority among brothers and sisters object in the seniority among brothers and sisters scene is corresponding with the number that the numerical value of operation system configuration indicates;
The field value of target seniority among brothers and sisters object is configured into the member of the memory type database, comprising:
The configuration process of the field value of building seniority among brothers and sisters object, the configuration process are used to subtract seniority among brothers and sisters object using a predetermined value Corresponding number, and configure calculated result as the field value of seniority among brothers and sisters object into the member of the memory type database; Wherein, it is to rank the numerical upper limits of the number of object configuration that the predetermined value, which is greater than the operation system,;
Based on the configuration process, the field value of target seniority among brothers and sisters object is configured to the member of the memory type database In.
6. method as claimed in claim 5, which is characterized in that further include:
The reading process of the field value of building seniority among brothers and sisters object, the reading process are used to subtract seniority among brothers and sisters pair using the predetermined value As the field value in the member of the memory type database, the corresponding number of seniority among brothers and sisters object is obtained;Wherein rank object pair Reading result of the number answered as the field value of seniority among brothers and sisters object.
7. method according to claim 2, which is characterized in that
Construct the sequentialize commands of ordered set data structure, comprising:
If the key of the memory type database has the field value in current seniority among brothers and sisters period, construct currently to rank the word in period Segment value is constraint condition, the sequentialize commands being ranked up to member according to the size of score;
If there is no the field values in current seniority among brothers and sisters period by the key of the memory type database, the above seniority among brothers and sisters period is constructed Field value is constraint condition, the sequentialize commands being ranked up to member according to the size of score.
8. such as method of any of claims 1-7, which is characterized in that
The preset condition includes: that operation system changes for the corresponding business datum of the seniority among brothers and sisters scene;
It obtains memory type database and needs synchronous data for seniority among brothers and sisters scene, comprising:
It is changed based on the operation system got from operation system for the corresponding business datum of the seniority among brothers and sisters scene Data determine that memory type database needs synchronous data for seniority among brothers and sisters scene.
9. such as method of any of claims 1-7, which is characterized in that
The preset condition includes: the execution period pre-seted;
It obtains memory type database and needs synchronous data for seniority among brothers and sisters scene, comprising:
Based on asynchronous thread, the memory type database is obtained from service database for seniority among brothers and sisters scene and needs synchronous number According to.
10. a kind of auxiliary device of data seniority among brothers and sisters characterized by comprising
Module is obtained, needs synchronous data for seniority among brothers and sisters scene for when triggering preset condition, obtaining memory type data;
Synchronization module, for according to ordered set data structure, the memory type database being needed to synchronize for seniority among brothers and sisters scene Data be synchronized in the memory type database, it is corresponding data cached to obtain the seniority among brothers and sisters scene;
Module is constructed, for constructing ordered set data structure after obtaining for the seniority among brothers and sisters inquiry request of the seniority among brothers and sisters scene Sequentialize commands;
Execution module obtains the seniority among brothers and sisters field for the data cached execution sequentialize commands corresponding to the seniority among brothers and sisters scene The corresponding ranking data of scape.
11. device as claimed in claim 10, which is characterized in that
The ordered set data structure is ZSet data structure, and the seniority among brothers and sisters period in the seniority among brothers and sisters scene is as the ZSet number According to the key key of structure, member member of the seniority among brothers and sisters object ranked in scene as the ZSet data structure, the row Score score of the seniority among brothers and sisters attribute value as the ZSet data structure in row scene;
Wherein, the sequentialize commands are used to be ranked up member according to the size of score using key as constraint condition.
12. device as claimed in claim 11, which is characterized in that
The memory type database includes target seniority among brothers and sisters object for the required data synchronous to service database of seniority among brothers and sisters scene The corresponding variate-value of seniority among brothers and sisters attribute value, target seniority among brothers and sisters object belongs to the seniority among brothers and sisters object in the seniority among brothers and sisters scene;
The synchronization module is specifically used for:
If the key of the memory type database has the field value in current seniority among brothers and sisters period, it is based on the variate-value, to the mesh Field value of the mark seniority among brothers and sisters object in the score that currently the seniority among brothers and sisters period corresponds to the memory type database is modified;
If there is no the field values in current seniority among brothers and sisters period by the key of the memory type database, by the field in current seniority among brothers and sisters period Configuration is based on the variate-value into the key of the memory type database, to target seniority among brothers and sisters object in upper seniority among brothers and sisters week The field value that phase corresponds in the score of the memory type database is calculated, and calculated result is written to the target and is arranged Row object is in the score that currently the seniority among brothers and sisters period corresponds to the memory type database.
13. device as claimed in claim 12, which is characterized in that
The synchronization module also particularly useful for:
If the member of the memory type database does not have the field value of the target seniority among brothers and sisters object, the target is ranked The field value of object is configured into the member of the memory type database.
14. device as claimed in claim 13, which is characterized in that
Seniority among brothers and sisters object in the seniority among brothers and sisters scene is corresponding with the number that the numerical value of operation system configuration indicates;
The synchronization module is specifically used for:
The configuration process of the field value of building seniority among brothers and sisters object, the configuration process are used to subtract seniority among brothers and sisters object using a predetermined value Corresponding number, and configure calculated result as the field value of seniority among brothers and sisters object into the member of the memory type database; Wherein, it is to rank the numerical upper limits of the number of object configuration that the predetermined value, which is greater than the operation system,;
Based on the configuration process, the field value of target seniority among brothers and sisters object is configured to the member of the memory type database In.
15. device as claimed in claim 12, which is characterized in that
The building module is specifically used for:
If the key of the memory type database has the field value in current seniority among brothers and sisters period, construct currently to rank the word in period Segment value is constraint condition, the sequentialize commands being ranked up to member according to the size of score;
If there is no the field values in current seniority among brothers and sisters period by the key of the memory type database, the above seniority among brothers and sisters period is constructed Field value is constraint condition, the sequentialize commands being ranked up to member according to the size of score.
CN201811248981.6A 2018-10-25 2018-10-25 A kind of householder method and device of data seniority among brothers and sisters Pending CN109471879A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811248981.6A CN109471879A (en) 2018-10-25 2018-10-25 A kind of householder method and device of data seniority among brothers and sisters

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811248981.6A CN109471879A (en) 2018-10-25 2018-10-25 A kind of householder method and device of data seniority among brothers and sisters

Publications (1)

Publication Number Publication Date
CN109471879A true CN109471879A (en) 2019-03-15

Family

ID=65665863

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811248981.6A Pending CN109471879A (en) 2018-10-25 2018-10-25 A kind of householder method and device of data seniority among brothers and sisters

Country Status (1)

Country Link
CN (1) CN109471879A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110061933A (en) * 2019-04-03 2019-07-26 网宿科技股份有限公司 A kind of data processing method and device, equipment, storage medium
CN110209720A (en) * 2019-05-23 2019-09-06 上海易点时空网络有限公司 The management method and device of list data
CN110232065A (en) * 2019-05-23 2019-09-13 上海易点时空网络有限公司 List ranking value generation method and apparatus

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105677819A (en) * 2015-12-31 2016-06-15 广州华多网络科技有限公司 Ranking list refreshing method and device
CN106250392A (en) * 2016-07-15 2016-12-21 北京奇虎科技有限公司 The method and device of data seniority among brothers and sisters
CN106599104A (en) * 2016-11-29 2017-04-26 北京锐安科技有限公司 Mass data association method based on redis cluster
US20180032636A1 (en) * 2016-07-29 2018-02-01 Newswhip Media Limited System and method for identifying and ranking trending named entities in digital content objects
CN108182152A (en) * 2017-11-28 2018-06-19 深圳市丰巢科技有限公司 A kind of local cache based on Redis refreshes implementation method and device
CN108495195A (en) * 2018-03-13 2018-09-04 武汉斗鱼网络科技有限公司 A kind of network direct broadcasting ranking list generation method, device, equipment and storage medium
CN108509529A (en) * 2018-03-14 2018-09-07 武汉斗鱼网络科技有限公司 Data page sort method, device and readable storage medium storing program for executing

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105677819A (en) * 2015-12-31 2016-06-15 广州华多网络科技有限公司 Ranking list refreshing method and device
CN106250392A (en) * 2016-07-15 2016-12-21 北京奇虎科技有限公司 The method and device of data seniority among brothers and sisters
US20180032636A1 (en) * 2016-07-29 2018-02-01 Newswhip Media Limited System and method for identifying and ranking trending named entities in digital content objects
CN106599104A (en) * 2016-11-29 2017-04-26 北京锐安科技有限公司 Mass data association method based on redis cluster
CN108182152A (en) * 2017-11-28 2018-06-19 深圳市丰巢科技有限公司 A kind of local cache based on Redis refreshes implementation method and device
CN108495195A (en) * 2018-03-13 2018-09-04 武汉斗鱼网络科技有限公司 A kind of network direct broadcasting ranking list generation method, device, equipment and storage medium
CN108509529A (en) * 2018-03-14 2018-09-07 武汉斗鱼网络科技有限公司 Data page sort method, device and readable storage medium storing program for executing

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
JAYSUN: "使用Redis Zset来处理活动常用排行榜", 《SEGMENTFAULT》 *
黄二的NPE: "redis zset做排行榜", 《简书》 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110061933A (en) * 2019-04-03 2019-07-26 网宿科技股份有限公司 A kind of data processing method and device, equipment, storage medium
CN110209720A (en) * 2019-05-23 2019-09-06 上海易点时空网络有限公司 The management method and device of list data
CN110232065A (en) * 2019-05-23 2019-09-13 上海易点时空网络有限公司 List ranking value generation method and apparatus
CN110232065B (en) * 2019-05-23 2021-07-20 上海易点时空网络有限公司 List ranking value generation method and apparatus

Similar Documents

Publication Publication Date Title
CN105468473B (en) Data migration method and data migration device
CN110162528A (en) Magnanimity big data search method and system
CN103810237B (en) Data managing method and system
CN102063490B (en) Database partition method and device
CN106201355B (en) Data processing method and device and storage system
CN110493325A (en) Block chain state method of data synchronization and device, electronic equipment
CN109471879A (en) A kind of householder method and device of data seniority among brothers and sisters
CN110347684A (en) Based on the classification storage method and device of block chain, electronic equipment
KR101372964B1 (en) Managing memory pages
CN109871367A (en) A kind of distributed cold and heat data separation method based on Redis and HBase
CN105069134A (en) Method for automatically collecting Oracle statistical information
CN109740038A (en) Network data distributed parallel computing environment and method
CN105389367B (en) The multilevel distributed storage method of grid graph multi-time Scales based on Mongo databases
CN106557272B (en) A kind of efficient sensor historic data archiving method
CN103246616A (en) Global shared cache replacement method for realizing long-short cycle access frequency
CN110347660A (en) Based on the classification storage method and device of block chain, electronic equipment
JP2015518223A (en) Memory search, real-time search system and method, and computer storage medium
CN109002484A (en) A kind of method and system for sequence consumption data
CN109284305A (en) A kind of update method of data, apparatus and system
CN109194711A (en) A kind of synchronous method of organizational structure, client, server-side and medium
CN106055622A (en) Data searching method and system
EP3970094A1 (en) Real time collaboration in calendar
CN109933632A (en) A kind of data migration method of database, device and equipment
CN109271449A (en) A kind of distributed storage inquiry system file-based and querying method
CN107704573A (en) A kind of intelligent buffer method coupled with business

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20190315