[go: up one dir, main page]

CN110413633A - Inactive users screening technique and readable medium and equipment based on Redis database - Google Patents

Inactive users screening technique and readable medium and equipment based on Redis database Download PDF

Info

Publication number
CN110413633A
CN110413633A CN201810412126.8A CN201810412126A CN110413633A CN 110413633 A CN110413633 A CN 110413633A CN 201810412126 A CN201810412126 A CN 201810412126A CN 110413633 A CN110413633 A CN 110413633A
Authority
CN
China
Prior art keywords
user
state information
information parameters
inactive users
redis database
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
CN201810412126.8A
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.)
Wuhan Douyu Network Technology Co Ltd
Original Assignee
Wuhan Douyu Network 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 Wuhan Douyu Network Technology Co Ltd filed Critical Wuhan Douyu Network Technology Co Ltd
Priority to CN201810412126.8A priority Critical patent/CN110413633A/en
Publication of CN110413633A publication Critical patent/CN110413633A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0201Market modelling; Market analysis; Collecting market data
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0201Market modelling; Market analysis; Collecting market data
    • G06Q30/0203Market surveys; Market polls

Landscapes

  • Business, Economics & Management (AREA)
  • Strategic Management (AREA)
  • Engineering & Computer Science (AREA)
  • Accounting & Taxation (AREA)
  • Development Economics (AREA)
  • Finance (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Game Theory and Decision Science (AREA)
  • Data Mining & Analysis (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

A kind of inactive users screening technique based on Redis database, which comprises the following steps: S1, distribute identity information parameter for each user in customer information system, and be the corresponding state information parameters of each user setting;S2, a record being stored as using the identity information parameter of same user and state information parameters as a data group in Redis database;S3, when user performs new operation, the state information parameters of the user are updated;And S4, according to the current state of the state information parameters of the user judge whether the user is inactive users.Method flow provided by the invention is efficiently succinct, eliminates the defect that the inefficient and high system resource of relevant database occupies, and low cost solves the problems, such as inactive users screening, improves the overall performance of system.The invention further relates to relevant computer readable storage medium and electronic equipments.

Description

Inactive users screening technique and readable medium and equipment based on Redis database
Technical field
The present invention relates to the technical fields of data processing, more particularly, to a kind of based on the inactive of Redis database User's screening technique.
Background technique
As the appearance of more and more systems and application attracts more users to make to efficiently catch a large number of users With system and application, a kind of way is discovery inactive users, then carries out message push for these users or stimulation uses. Here, above system can be the related system such as on-line shopping system, similarly, above-mentioned application be can be such as use In the related application of the application software of mobile phone terminal.For example, a certain user is registered and has been used to certain application preceding, but It is that for some reason, client is not logged in a long time or using the application, at this time can be defined as this user non-live Jump user, and is applied by waking up the user to user's PUSH message using corresponding, or can also push away to the user The interest that relevant advertisements are sent to excite user to use.
Here, finding these inactive users firstly the need of by certain mode.Traditional inactive users screens inspection The method of survey is that log-on message, shopping information, the various information of payment information are inquired in relevant database such as Mysql, is come Check user have how long not active behavior.Such method can satisfy the demand of screening system inactive users.But It is that this needs repeatedly to go the database data of scanning magnanimity once a day or daily, it is living that user is screened from data-base recording Jump information, and this mode of operation efficiency is lower and occupying system resources are larger, therefore cost is higher.
A kind of method of inactive users screening that efficient and low system resource occupies is needed in the prior art.
Summary of the invention
At least one of regarding to the issue above, as one aspect of the present invention, propose a kind of based on Redis data The inactive users screening technique in library, method includes the following steps:
S1, identity information parameter is distributed for each user in customer information system, and corresponding for each user setting State information parameters;
S2, Redis number is stored as using the identity information parameter of same user and state information parameters as a data group According to a record in library;
S3, when user performs new operation, the state information parameters of the user are updated;And
S4, judge whether the user is inactive users according to the current state of the state information parameters of the user.
In some embodiments, in step sl, the state information parameters are the time that user is operated recently.
In some embodiments, in step s3, the state information parameters of the user are updated including according to institute The operation that user executes recently is stated to be updated the time for executing operation.
In some embodiments, in step s3, the new operation includes register, purchase operation or hair message behaviour Make.
In some embodiments, step S4 is specifically included, and inquires the current state and nearest one of the state information parameters Time span between secondary update, and using the time span as the free time length of corresponding user, according to the free time Time span judges whether the user is inactive users.
In some embodiments, judged according to the free time length user whether be inactive users step It suddenly include: setting idle time threshold, it, will be described if the free time length of the user is greater than the idle time threshold User is determined as inactive users.
In some embodiments, described to inquire using the object free time order in Redis database in step S4 Time span between the current state and last update of state information parameters.
In some embodiments, the time between the current state and last update of the state information parameters is inquired Length include: inquired using the scan command in Redis database the current states of the state information parameters of all users with Time span between last update.
Another aspect provides a kind of computer readable storage mediums, are stored thereon with executable instruction, institute It states executable instruction when executed by the processor, realizes as previously described based on the inactive users screening side of Redis database The step of method.
Another aspect of the present invention provides electronic equipment, comprising:
Memory, for storing executable instruction;And
Processor, for executing the executable instruction stored in the memory, to realize that basis is based on as previously described The step of inactive users screening technique of Redis database.
Based on the above-mentioned technical proposal it is found that the present invention at least achieves one in following beneficial effect:
Inactive users screening technique proposed by the present invention based on Redis database, the time that user is operated recently Information is stored in Redis database and stores, when not enlivening in conjunction with the high-performance treatments ability of Redis and its keyword provided Between query function, can be realized efficiently scanning and screening system inactive users, for subsequent user stimulation and strategy Change marketing and efficient data support is provided.Method flow provided by the invention is efficiently succinct, departing from the low of relevant database The defect that effect and high system resource occupy, low cost solve the problems, such as inactive users screening, improve the globality of system Energy.
Detailed description of the invention
Fig. 1 is the stream according to the inactive users screening technique based on Redis database of one embodiment of the present of invention Cheng Tu;
Fig. 2 is the inactive users screening technique based on Redis database according to a preferred embodiment of the present invention Flow chart;
Fig. 3 is the schematic diagram according to the computer readable storage medium of the embodiment of the present invention;
Fig. 4 is the schematic diagram according to the electronic equipment of the embodiment of the present invention.
Specific embodiment
To make the object, technical solutions and advantages of the present invention clearer, technical solution of the present invention will be carried out below Clearly and completely describe.Obviously, described embodiment is a part of the embodiments of the present invention, instead of all the embodiments. Based on described the embodiment of the present invention, those of ordinary skill in the art are obtained under the premise of being not necessarily to creative work Every other embodiment, shall fall within the protection scope of the present invention.
Unless otherwise defined, the technical term or scientific term that the present invention uses should be tool in fields of the present invention The ordinary meaning for thering is the personage of general technical ability to be understood.
Referring to Fig.1, the inactive users screening according to an embodiment of the invention based on Redis database is shown Method flow diagram, the inactive users screening technique the following steps are included:
S1, identity information parameter is distributed for each user in customer information system, and corresponding for each user setting State information parameters;
S2, Redis number is stored as using the identity information parameter of same user and state information parameters as a data group According to a record in library;
S3, when user performs new operation, the state information parameters of the user are updated;And
S4, judge whether the user is inactive users according to the current state of the state information parameters of the user.
Redis database is a kind of memory database, and Redis database stores data in memory, directly in memory Middle reading data carry out corresponding operation processing, since the reading and writing data speed of memory will be higher by the several orders of magnitude of disk, Redis database can greatly improve the treatment effeciency of data by storing data in memory.Redis database simultaneously In each keyword (key) have recorded the nearest active time of keyword key, and provide application programming interface (API) how long the keyword key to inquire in Redis database has had in an inactive state, i.e., there is no reading Write operation.
Based on the features above of Redis database, for example, can be by the id information of each user with keyword in the present embodiment The mode of key is stored in Redis database, as the identity information parameter, and using value corresponding to keyword key as institute State information parameters are stated, to constitute identity information parameter and the one-to-one key-value pair of state information parameters;In conjunction with Redis number According to the query function of the high-performance treatments ability in library and its non-active time of keyword provided, it can be realized and efficiently scan simultaneously The inactive users of screening system.
According to some embodiments, in step sl, state information parameters are the time that user is operated recently.For example, Value corresponding to keyword key is the timestamp for the time that user carries out active operation recently.In step s 2, by same user Identity information parameter and state information parameters be stored in Redis database as a data group, to constitute same use The identity information parameter at family and the one-to-one key-value pair of state information parameters, it is possible thereby to by means of Redis database Capability of fast response is quickly read or is written to the identity information parameter and/or state information parameters of same user.
According to some embodiments, in step s3, the operation executed recently according to the user is to the time for executing operation It is updated.For example, value corresponding to keyword key is updated to the timestamp that user carries out the time of new active operation. That is, state information parameters corresponding to identity information parameter by user be updated to the newest operation of user it is occurred when Temporal information.
Wherein, the operation of user may include register, purchase operation and/or hair Message Opcode etc..That is, working as User executes any one or more of register, purchase operation and hair Message Opcode etc. operation behaviour in system or application Make the update of Shi Junke state of activation information parameter.It should be understood that the operation of above-mentioned user not only includes register, purchase Operation and/or hair Message Opcode, also may include that other can indicate that user is in the operation of active state.
According to some embodiments, step S4 include inquire state information parameters current state and last update it Between time span judged according to free time length and using the time span as the free time length of corresponding user Whether user is inactive users.
According to some embodiments, step S4 further includes idle time threshold being arranged, if the free time length of user is greater than The user is then determined as inactive users by the threshold value.That is, free time threshold can be arranged in advance according to actual needs Value, and the free time length and the threshold value of user are compared, in the case where reaching the threshold value, it is non-to judge that user belongs to Any active ues, and the user information can be utilized by further mode.
According to some embodiments, in step S4, using the object free time (OBJECT in Redis database IDLETIME) order is to inquire the time span between the current state of state information parameters and last update.OBJECT The effect of IDLETIM order is to have returned to free time of the value since storage corresponding to given keyword key in seconds Length is not read the time span being also not written to.It is ordered using the OBJECT IDLETIM that Redis database provides It enables, is capable of the free time of key word of the inquiry key, with the inactive users of efficiently screening system.
According to some embodiments, step S4 further includes being inquired using scanning (SCAN) order in Redis database Time span in Redis database between the current state and last update of the state information parameters of all users, with Inactive users is filtered out in all users.When screening inactive users, system traverses Redis number by SCAN order According to keyword key all in library, Redis database is continually scanned for, until scanning through all keyword key.It utilizes The SCAN order that Redis database provides traverses the free time of all keyword key in Redis database, efficiently to sweep Retouch all users of system.
After filtering out inactive users, message push is carried out to all inactive users or it is stimulated to use related system Or application.In conjunction with the above method, it can be realized and efficiently scan and filter out inactive users, for subsequent user stimulation and plan Slightly change marketing and efficient data support is provided.
Below with reference to Fig. 2, a preferred embodiment of the present invention is introduced, Fig. 2 is one according to the present invention preferred implementation The flow chart of the inactive users screening technique based on Redis database of example, method includes the following steps:
S01: the id information of each user is stored in Redis database in a manner of keyword key, wherein each key Value corresponding to word key is the timestamp for the time that user executes operation recently, to constitute identity information parameter and state letter Cease the one-to-one key-value pair of parameter;
S02: when user carries out new operation, the value of keyword is updated to by value corresponding to trasaction key key User carries out the timestamp of the time of new operation;
S03: value corresponding to the keyword key in Redis database is continually scanned for by SCAN order;
S04: one threshold value of setting passes through the free time of value corresponding to OBJECT IDLETIM order key word of the inquiry key Time span, judges whether free time length is greater than threshold value, if being then transferred to S05a, is otherwise transferred to S05b;
S05a: the corresponding user of the keyword is inactive users, records the id information of user;
S05b: without any processing;
S06: whether the primary traversal of judgement is completed, i.e., whether has scanned through the corresponding keyword key of all users, if All inactive users are then found, process terminates;Otherwise return step S03.
The entire algorithm flow provided in the embodiment of the present invention is efficiently succinct, departing from conventional method use relationship type The defect that the inefficient and high system resource of database Mysql occupies, low cost solve the problems, such as inactive users screening, improve The overall performance of system.
Based on the same inventive concept, refering to what is shown in Fig. 3, the embodiment of the present invention also provides a kind of computer-readable storage medium Matter 201, is stored thereon with executable instruction 202, executable instruction 202 when executed by one or more processors, Ke Yishi Now the step of any inactive users screening technique based on Redis database of embodiment as above.
Based on the same inventive concept, refering to what is shown in Fig. 4, the embodiment of the present invention also provides a kind of electronic equipment 301, packet It includes: memory 302, for storing executable instruction;And processor 303, for execute stored in memory 302 it is executable Instruction, the step of to execute according to any inactive users screening technique based on Redis database of embodiment as above.
Particular embodiments described above has carried out further in detail the purpose of the present invention, technical scheme and beneficial effects Describe in detail bright, it should be understood that the above is only a specific embodiment of the present invention, is not intended to restrict the invention, it is all Within the spirit and principles in the present invention, any modification, equivalent substitution, improvement and etc. done should be included in protection of the invention Within the scope of.

Claims (10)

1. a kind of inactive users screening technique based on Redis database, which comprises the following steps:
S1, identity information parameter is distributed for each user in customer information system, and be the corresponding state of each user setting Information parameter;
S2, Redis database is stored as using the identity information parameter of same user and state information parameters as a data group In one record;
S3, when user performs new operation, the state information parameters of the user are updated;And
S4, judge whether the user is inactive users according to the current state of the state information parameters of the user.
2. according to the method described in claim 1, wherein, in step sl, the state information parameters are that user carries out recently The time of operation.
3. according to the method described in claim 2, wherein, in step s3, being carried out more to the state information parameters of the user It newly include that the operation executed recently according to the user is updated the time for executing operation.
4. according to the method described in claim 1, wherein, in step s3, the new operation includes register, purchase behaviour Make or send out Message Opcode.
5. according to the method described in claim 1, wherein, the step S4 includes: the current of the inquiry state information parameters Time span between state and last update, and using the time span as the free time length of corresponding user, Judge whether the user is inactive users according to the free time length.
6. according to the method described in claim 5, wherein, judging whether the user is non-according to the free time length The step of any active ues includes: setting idle time threshold, if the free time length of the user is greater than the free time The user is then determined as inactive users by threshold value.
7. idle using the object in Redis database in the step S4 according to the method described in claim 5, wherein Time span between current state and last update of the time order to inquire the state information parameters.
8. the method according to any one of claim 4-7, wherein inquire the current state of the state information parameters Time span between last update includes: that all users are inquired using the scan command in Redis database Time span between the current state and last update of state information parameters.
9. a kind of computer readable storage medium, is stored thereon with executable instruction, the executable instruction is held by processor When row, inactive users screening technique described in any one of -8 based on Redis database according to claim 1 is realized Step.
10. a kind of electronic equipment, comprising:
Memory, for storing executable instruction;And
Processor, for executing the executable instruction stored in the memory, with any in realization according to claim 1-8 The step of inactive users screening technique based on Redis database described in item.
CN201810412126.8A 2018-04-28 2018-04-28 Inactive users screening technique and readable medium and equipment based on Redis database Pending CN110413633A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810412126.8A CN110413633A (en) 2018-04-28 2018-04-28 Inactive users screening technique and readable medium and equipment based on Redis database

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810412126.8A CN110413633A (en) 2018-04-28 2018-04-28 Inactive users screening technique and readable medium and equipment based on Redis database

Publications (1)

Publication Number Publication Date
CN110413633A true CN110413633A (en) 2019-11-05

Family

ID=68357976

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810412126.8A Pending CN110413633A (en) 2018-04-28 2018-04-28 Inactive users screening technique and readable medium and equipment based on Redis database

Country Status (1)

Country Link
CN (1) CN110413633A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111913977A (en) * 2020-08-19 2020-11-10 上海莉莉丝网络科技有限公司 Data processing method, device and medium
CN113590591A (en) * 2021-07-30 2021-11-02 中国平安财产保险股份有限公司 Method, device, equipment and storage medium for automatically updating event state

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104104717A (en) * 2014-06-30 2014-10-15 广州唯品会网络技术有限公司 Inputting channel data statistical method and device
CN105872012A (en) * 2016-03-11 2016-08-17 乐视网信息技术(北京)股份有限公司 Method and system for sending information based on member user terminal
CN107147660A (en) * 2017-06-01 2017-09-08 上海斐讯数据通信技术有限公司 A kind of efficient login authentication method of mass users and system
CN107508917A (en) * 2017-09-29 2017-12-22 济南浚达信息技术有限公司 A kind of web site user activity statistical method and system based on bitmap

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104104717A (en) * 2014-06-30 2014-10-15 广州唯品会网络技术有限公司 Inputting channel data statistical method and device
CN105872012A (en) * 2016-03-11 2016-08-17 乐视网信息技术(北京)股份有限公司 Method and system for sending information based on member user terminal
CN107147660A (en) * 2017-06-01 2017-09-08 上海斐讯数据通信技术有限公司 A kind of efficient login authentication method of mass users and system
CN107508917A (en) * 2017-09-29 2017-12-22 济南浚达信息技术有限公司 A kind of web site user activity statistical method and system based on bitmap

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111913977A (en) * 2020-08-19 2020-11-10 上海莉莉丝网络科技有限公司 Data processing method, device and medium
CN111913977B (en) * 2020-08-19 2023-10-20 上海莉莉丝网络科技有限公司 Data processing method, device and medium
CN113590591A (en) * 2021-07-30 2021-11-02 中国平安财产保险股份有限公司 Method, device, equipment and storage medium for automatically updating event state
CN113590591B (en) * 2021-07-30 2023-08-22 中国平安财产保险股份有限公司 Automatic event state updating method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN101317153B (en) System and method used for object model on workflow and administrative behavior purpose
US9189270B2 (en) Realizing jumps in an executing process instance
US8352411B2 (en) Activity schemes for support of knowledge-intensive tasks
US20160098293A1 (en) System, method, and software for controlled interruption of batch job processing
US20110246994A1 (en) Scheduling heterogeneous partitioned resources with sharing constraints
US20120110047A1 (en) Reducing the Response Time of Flexible Highly Data Parallel Tasks
JP5947266B2 (en) Systems and methods for data privacy and data destruction in a multi-system landscape
CN103854214B (en) Method and system for processing auction data
US20160267509A1 (en) Automated rules-based pricing
CN111951052B (en) Method and device for acquiring potential clients based on knowledge graph
CN102722381A (en) Techniques to optimize upgrade tasks
US20160232548A1 (en) Adaptive pricing analytics
US9875137B2 (en) Intelligent application back stack management
WO2016155008A1 (en) Method and system for scheduling transactions in a data system
CN109426550A (en) The dispatching method and equipment of resource
CN112287339A (en) APT intrusion detection method and device and computer equipment
CN110413633A (en) Inactive users screening technique and readable medium and equipment based on Redis database
CN105678323A (en) Image-based-on method and system for analysis of users
CN109885642B (en) Hierarchical storage method and device for full-text retrieval
CN103377292A (en) Database result set caching method and device
US20180247273A1 (en) Dynamic schedule creation based on knowledge
CN107688586B (en) Client data shielding processing method and device
CN116226202A (en) Multidimensional database query method, multidimensional database query device, computer equipment and storage medium
US20160266942A1 (en) System to Schedule and Perform Automated Software Tasks During Unattended System Time Using Predicted Knowledge of Individual User Behavior
CN113342863A (en) Business document processing method and device, computer equipment and storage medium

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

Application publication date: 20191105

RJ01 Rejection of invention patent application after publication