CN102012909A - Event reminding business processing method - Google Patents

Event reminding business processing method Download PDF

Info

Publication number
CN102012909A
CN102012909A CN 201010548272 CN201010548272A CN102012909A CN 102012909 A CN102012909 A CN 102012909A CN 201010548272 CN201010548272 CN 201010548272 CN 201010548272 A CN201010548272 A CN 201010548272A CN 102012909 A CN102012909 A CN 102012909A
Authority
CN
China
Prior art keywords
data
event
node
incident
time
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
CN 201010548272
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.)
SHENZHEN DUOYING SOFTWARE TECHNOLOGY Co Ltd
Original Assignee
SHENZHEN DUOYING SOFTWARE 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 SHENZHEN DUOYING SOFTWARE TECHNOLOGY Co Ltd filed Critical SHENZHEN DUOYING SOFTWARE TECHNOLOGY Co Ltd
Priority to CN 201010548272 priority Critical patent/CN102012909A/en
Publication of CN102012909A publication Critical patent/CN102012909A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses an event reminding business processing method which comprises the following steps: (A1) storing the event data set by a user into a data table of a database, wherein the event data comprise an event transmission time stamp; (A2) caching the event data of which the event transmission time stamp is greater than the current system time into the data structure of a memory; (A3) scanning the data structure at regular time, and comparing the current system time with the event transmission time stamp; and (A4) if the current system time is greater than or equal to the event transmission time stamp, transmitting the event data to the user. By using the event reminding business processing method disclosed in the invention, the query efficiency of the event data can be greatly improved, the real-time requirement of event reminding can be met, and the performance of the database of a system can not be influenced.

Description

A kind of event notification method for processing business
Technical field
The present invention relates to the technology of event setup time monitoring and prompting, be specifically related to a kind of event notification method for processing business.
Background technology
Need in some multi-users' the service system event notification that certain user sets put at the appointed time and send to this user, as the calendar prompting business.As shown in Figure 1, the basic procedure of this class service business is, the user generates incident, system scan event set data then, and the alert notification with this incident when reaching the time point of a certain Event triggered sends to designated user, deletes this incident at last.Most of service systems are saved in lane database with event data, and timing utilizes the sql statement to search and according to time sequence, obtains up-to-date incident then, find the user of needs notice then according to incident, at last the event notification notice are sent.The problem that present event notification method for processing business exists is the conflict of user experience demand and system performance, improve user experience, will be at the time point of appointment, the event notification notice is sent to the user of appointment, so just need a second level data library lookup frequency, just all want the scan database tables of data p.s., see the time point that the incident that whether reaches requires.The database lookup operations of second level can cause database performance sharply to descend because the database of General System is not single business, the data mixing that the multiple business logic often arranged together, such as the data of preserving user login information are arranged.Under the huge situation of customer volume and volume of event data, because the randomness of database manipulation, this moment not only during the inquiring user log-on message because database is not carried out or carries out very slowly, cause user's login authentication slack-off, nor the operation that the incident that can guarantee is searched can finish in the time that requires, and that is to say that the mode of database lookup incident can't satisfy the real-time requirement of event notification.
Summary of the invention
The technical problem to be solved in the present invention provides a kind of event notification method for processing business, overcomes the mode that prior art event notification method for processing business adopts the database lookup incident, can't satisfy the defective that the event notification real-time requires.
The present invention solves the problems of the technologies described above the technical scheme that is adopted to be:
A kind of event notification method for processing business comprises step:
A1, event data storage that the user is provided with are in the data of database table, and described event data comprises that the incident transmitting time stabs;
A2, the described event data that described incident transmitting time is stabbed greater than current system time are cached in the data structure of internal memory;
A3, the described data structure of timing scan, more current system time and described incident transmitting time are stabbed;
If the current system time of A4 is greater than or equal to described incident transmitting time and stabs, then described event data is sent to described user.
Described event notification method for processing business wherein also comprises steps A 5: described event data is carried out subsequent treatment.
Described event notification method for processing business, wherein said tables of data and described data structure have uniform data format, and described data layout comprises incident sequence number field, incident creator field, incident transmitting time stamp field, event content field, the person's of being alerted field and transmit status field.
Described event notification method for processing business, wherein said incident transmitting time stab and are made as the integer data.
Described event notification method for processing business wherein is provided with the main chain table in internal memory, described main chain table on time between span node is set, and derive from corresponding child list by each node, store described data structure by the node of described child list.
Described event notification method for processing business, the time sequencing that wherein said child list stabs by described incident transmitting time generates the child list node.
Described event notification method for processing business, wherein the subsequent treatment that described event data is carried out comprises and revises described tables of data, with described transmit status field identification for sending.
Described event notification method for processing business, wherein the subsequent treatment that described event data is carried out comprises deletion child list node, if the child list of this child list node correspondence is deleted the main chain table node of then deletion correspondence.
Beneficial effect of the present invention: event notification method for processing business of the present invention can improve the search efficiency of event data significantly, satisfies the real-time requirement of event notification, and does not influence the performance of system database.
Description of drawings
The present invention includes following accompanying drawing:
Fig. 1 is a prior art event notification business processing general flow synoptic diagram;
Fig. 2 is an event notification method for processing business process flow diagram of the present invention;
Fig. 3 is event notification method for processing business main chain table of the present invention and child list structural representation;
Fig. 4 is an ergodic chain table process flow diagram of the present invention;
Fig. 5 inquires about and follow-up processing flow figure event data for the present invention.
Embodiment
With embodiment the present invention is described in further detail with reference to the accompanying drawings below:
The determinant attribute of event data
The incident that the user is provided with comprises following several determinant attribute:
The incident transmitting time: the general standard form is " YYYY-MM-DD HH24:MM:SS ", as " 2010-09-0108:00:00 ".
Event content: as calendar prompting meeting, content such as message is public.
The object of reception incident: can be that the sole user also can be that the user collects.
The incident person of setting.
According to the attribute characteristics of event data, for improving search efficiency, newly-increased attribute: the incident transmitting time is stabbed, and the time that is about to standard format converts the integer data to, and stabbing as " 2010-09-0108:00:00 " time corresponding is exactly 1283299200.
Thus, the establishment SQL script of design database tables of data is as follows:
CREATE?TABLE`t_event_info`(
‘ID`int(11)NOT?NULL,
`CreateUser`varchar(32)DEFAULT?NULL
`SendTime`datetime?DEFAULT?NULL,
`Content`varchar(254)DEFAULT?NULL,
`ReceiverUser`varchar(254)DEFAULT?NULL,
‘SendTmeStamp`int(11)NOT?NULL,
‘Status`int(2)NOT?NULL,
PRIMARY?KEY(`SendTmeStamp`))
Be described in detail as follows:
Id field only as the sequence number of incident, increases progressively with event data.
The CreateUser field, incident founder.
The SendTime field, the incident transmitting time.
The Content field will send the content of incident.
The ReceiveUser field, the user of reception incident.
The SendTimeStamp field, the incident transmitting time of incident transmitting time conversion is stabbed the integer data.
Status field, transmit status, value are 0 or 1,0 to be to send, and 1 for sending.
This tables of data is created in the system database with other business datum tables of system.
List structure according to this tables of data illustrates, and need notify Xiao Wang to have a meeting to meeting room in 9 o'clock sharps of the morning on September 1st, 2010 as Xiao Ming, and this notice will send to Xiao Wang in 8 o'clock sharps of the morning on September 1st, 2010.The form that is saved among the database table t_event_info of this incident is as shown in table 1 like this:
Table 1
Figure BSA00000350303700051
According to this form, any newly-increased data can be inserted tables of data with reference to this data layout.
Overall process flow
The process flow diagram of processing events reminding business as shown in Figure 2,
Detailed process is described as follows:
1) operating system of user is provided with incident, and in the tables of data that is saved in system database of event data, data layout as previously mentioned.
2) starting a subsystem is cached to the event data of incident transmitting time stamp greater than current system time in the data structure of internal memory.
3) scan-data structure checks whether current system time reaches the triggered time of incident, and frequency is that per second starts single pass.
4) system time stabs more than or equal to the incident transmitting time, and incident is triggered.
5) send this event data to designated user.
6) data structure of this event data correspondence in the deletion buffer memory is revised in the database corresponding simultaneously
The state of transmit status field is for sending.
Be cached to the treatment scheme of the data structure of internal memory
As shown in Figure 3, the data structure generation strategy of the present invention's design is to add N bar child list composition with a main chain table, and the N here is any positive integer.The structural design of these two chained lists is as follows:
● main chain list structure (being described) with the C language
typedef?struct?m_node
{
Int?timestamp;
Int?timedifference;
struct?s_node*s_link;
struct?m_node*link;
}m_link;
Be described in detail as follows:
1) timestamp: the timestamp of start time some day is exactly that correspondent time is 1282492800 as " 2010-08-2300:00:00 ".
2) timedifference: the span of corresponding Event triggered time, promptly interval time difference fate, value is the integer greater than 0.For example value is 1 o'clock, and the Event triggered time on the then corresponding child list all took place in one day after main chain table zero-time timestamp; Value is 2 o'clock, and the Event triggered time on the then corresponding child list all took place in two days after main chain table zero-time timestamp.
3) s_link: corresponding child list pointer.
4) link: the pointer of next node.
5) timedifference of each node preservation is identical.
6) difference between the timestamp preserved of each node can both divide exactly one day total second number (24*3600), and the value that obtains after dividing exactly all is the integral multiple of attribute timedifference holding time span fate.
● child list structure (being described) with the C language
typedef?struct?s_node
{
Int?sendtimestamp;
Char?content[256];
Char?receiveuser[256];
Int?ID;
struct?s_node*link;
}s_link;
Be described in detail as follows:
1) sendtimestamp: the incident transmitting time is stabbed.
2) content: event content to be sent.
3) receiveuser: the user who receives incident.
4) ID: this event data record sequence number that Field ID is preserved among the corresponding data table t_event_info.
5) link: the pointer of next node.
In conjunction with above-mentioned list structure, data structure buffer memory product process figure of the present invention is described in detail as follows by number of steps among Fig. 4 as shown in Figure 4:
1) be condition with current system time after the system start-up, read event data to be sent from lane database, the incident transmitting time is stabbed and is greater than current system time.The incident transmitting time is stabbed the outdated data that belongs to before current system time.
2) traversal event data, stab each node that removes to travel through the main chain table according to the current event transmitting time, it should be noted that here if article one data, at this moment Dui Ying main chain table should have only a first node, and the timestamp that first node is preserved is the start time on the same day of current time correspondence.Such as, system time is at " 2010-08-2312:00:00 ", and then the incident transmitting time of main chain table subsequent node correspondence stamp all should be greater than " 2010-08-2300:00:00 ".
3) calculate the incident transmitting time and stab the difference of stabbing with each Node Events transmitting time of main chain table, with this difference divided by one day total second number (by 24 *60 *60 obtain), the smallest positive integral that the value that obtains is at last got greater than this value again just can obtain concrete interval fate.
4) fate of fate and main chain table nodal community Timedifference preservation carries out size relatively at interval
5) when fate that the interval fate is preserved less than main chain table nodal community Timedifference, this explanation incident transmitting time sends in this main chain table node time corresponding span, at this moment will further search the child list of this node correspondence.
6) each node in the traversal child list, the incident transmitting time that the contrast node is preserved is stabbed the size of stabbing with the current event transmitting time.
7) press the time from front to back, the incident transmitting time is stabbed ascending principle, in child list, generate a new node, the value that guarantees the incident transmitting time stamp of node is stabbed more than or equal to the incident transmitting time of previous node, and the incident transmitting time that is less than or equal to a back node is stabbed (if a back node is arranged).
8) node generates and finishes, and stops to travel through other nodes of chained list.
9) when fate that the interval fate is preserved greater than main chain table nodal community Timedifference, this explanation incident transmitting time does not send in this main chain table node time corresponding span, at this moment will further compare the incident transmitting time and stab the size of stabbing with the next node holding time.Exception if present node is exactly last node of main chain table, then will generate a node at the main chain table by the generation principle of node at last.
10) stab greater than the next node holding time when the incident transmitting time and stab, then repeat 3), 4) step.
11) when the incident transmitting time is stabbed the incident transmitting time stamp of preserving less than next node, need between these two nodes, generate principle and generate new node by node data.
12) newly-generated main chain table node also generates the child list of a correspondence simultaneously, event data is saved as the first node data of this child list.
13) node data generates and finishes, and stops to travel through other nodes of chained list.
14) generated data cached structure at last.
Inquiry and processing events data flow
After finishing the flow process that event data is cached to internal memory, all start p.s. once the scanning of this buffer memory event data, judge whether current system time reaches the trigger condition of incident, and treatment scheme is described in detail as follows as shown in Figure 5:
1) scanning main chain table data.
2) find corresponding child list address by main chain heading node.
3) obtain the value that incident transmitting time that subchain heading node preserves is stabbed.
4) size of contrast Node Events transmitting time stamp and current system time.
5) if being greater than or equal to described incident transmitting time, stabs current system time, promptly reach the trigger condition of the event data of node preservation, this event data is sent to designated user, and the value of transmit status field of revising correspondence database tables of data record simultaneously is for sending.
6) if the event data of this child list node storage all has been sent out away, just delete this node, if last node of this child list, the corresponding node of deletion main chain table when deleting this node.
7) if the Node Events transmitting time is stabbed greater than current system time, then stop ergodic data immediately, current system time does not satisfy the trigger condition of anything part.
Those skilled in the art do not break away from essence of the present invention and spirit, can there be the various deformation scheme to realize the present invention, the above only is the preferable feasible embodiment of the present invention, be not so limit to interest field of the present invention, the equivalent structure that all utilizations instructions of the present invention and accompanying drawing content are done changes, and all is contained within the interest field of the present invention.

Claims (8)

1. an event notification method for processing business is characterized in that, comprises step:
A1, event data storage that the user is provided with are in the data of database table, and described event data comprises that the incident transmitting time stabs;
A2, the described event data that described incident transmitting time is stabbed greater than current system time are cached in the data structure of internal memory;
A3, the described data structure of timing scan, more current system time and described incident transmitting time are stabbed;
If the current system time of A4 is greater than or equal to described incident transmitting time and stabs, then described event data is sent to described user.
2. event notification method for processing business according to claim 1 is characterized in that, also comprises steps A 5: described event data is carried out subsequent treatment.
3. event notification method for processing business according to claim 2, it is characterized in that: described tables of data and described data structure have uniform data format, and described data layout comprises incident sequence number field, incident creator field, incident transmitting time stamp field, event content field, the person's of being alerted field and transmit status field.
4. event notification method for processing business according to claim 3 is characterized in that: described incident transmitting time is stabbed and is made as the integer data.
5. event notification method for processing business according to claim 4, it is characterized in that: the main chain table is set in internal memory, described main chain table on time between span node is set, and derive from corresponding child list by each node, store described data structure by the node of described child list.
6. event notification method for processing business according to claim 5 is characterized in that: the time sequencing that described child list stabs by described incident transmitting time generates the child list node.
7. event notification method for processing business according to claim 2 is characterized in that: the subsequent treatment that described event data is carried out comprises revises described tables of data, with described transmit status field identification for sending.
8. event notification method for processing business according to claim 7, it is characterized in that: the subsequent treatment that described event data is carried out comprises deletion child list node, if the child list of this child list node correspondence is deleted, the main chain table node of then deletion correspondence.
CN 201010548272 2010-11-17 2010-11-17 Event reminding business processing method Pending CN102012909A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201010548272 CN102012909A (en) 2010-11-17 2010-11-17 Event reminding business processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201010548272 CN102012909A (en) 2010-11-17 2010-11-17 Event reminding business processing method

Publications (1)

Publication Number Publication Date
CN102012909A true CN102012909A (en) 2011-04-13

Family

ID=43843082

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201010548272 Pending CN102012909A (en) 2010-11-17 2010-11-17 Event reminding business processing method

Country Status (1)

Country Link
CN (1) CN102012909A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102945236A (en) * 2011-11-29 2013-02-27 Ut斯达康通讯有限公司 Method for synchronizing different databases by triggering events
CN104823431A (en) * 2012-11-29 2015-08-05 阿尔卡特朗讯 Status tracking system
CN108183948A (en) * 2017-12-28 2018-06-19 上海传英信息技术有限公司 A kind of item based reminding method and item system for prompting

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6044275A (en) * 1998-03-23 2000-03-28 Ericsson Inc. System and method for time defined delivery of short message service messages
CN1617610A (en) * 2003-10-31 2005-05-18 朗迅科技公司 Method and apparatus for network initiated event reminder alerting
CN1882014A (en) * 2005-06-17 2006-12-20 中兴通讯股份有限公司 Subscriber calendar prompting method based on intelligent network
CN101175114A (en) * 2007-11-20 2008-05-07 北大方正集团有限公司 Automatic reminding method, method for returning remind information, corresponding equipment and system
CN101626380A (en) * 2009-07-24 2010-01-13 深圳市新飞扬数码技术有限公司 Data processing system, data processing server and processing method thereof for online games

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6044275A (en) * 1998-03-23 2000-03-28 Ericsson Inc. System and method for time defined delivery of short message service messages
CN1617610A (en) * 2003-10-31 2005-05-18 朗迅科技公司 Method and apparatus for network initiated event reminder alerting
CN1882014A (en) * 2005-06-17 2006-12-20 中兴通讯股份有限公司 Subscriber calendar prompting method based on intelligent network
CN101175114A (en) * 2007-11-20 2008-05-07 北大方正集团有限公司 Automatic reminding method, method for returning remind information, corresponding equipment and system
CN101626380A (en) * 2009-07-24 2010-01-13 深圳市新飞扬数码技术有限公司 Data processing system, data processing server and processing method thereof for online games

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102945236A (en) * 2011-11-29 2013-02-27 Ut斯达康通讯有限公司 Method for synchronizing different databases by triggering events
CN104823431A (en) * 2012-11-29 2015-08-05 阿尔卡特朗讯 Status tracking system
CN104823431B (en) * 2012-11-29 2018-02-06 阿尔卡特朗讯 Status tracking system
CN108183948A (en) * 2017-12-28 2018-06-19 上海传英信息技术有限公司 A kind of item based reminding method and item system for prompting

Similar Documents

Publication Publication Date Title
CN107729366B (en) Universal multi-source heterogeneous large-scale data synchronization system
CN107038162B (en) Real-time data query method and system based on database log
US7650394B2 (en) Synchronizing email recipient lists using block partition information
US8140495B2 (en) Asynchronous database index maintenance
CN100579130C (en) A friend recommendation system and method in SNS network
JP7098007B2 (en) Remote data synchronization methods and equipment for databases
US20140181030A1 (en) Identifying data items
JP5314504B2 (en) SEARCH DEVICE, SEARCH PROGRAM, AND SEARCH METHOD
CN104794190B (en) The method and apparatus that a kind of big data effectively stores
CN105373541B (en) The processing method and system of the data operation request of database
KR20080068110A (en) A method for processing data synchronization and client terminal, server and data synchronization system thereof
CN101083631A (en) Method for establishing contact list and managing contact information in instant communication
CN109919691B (en) Data processing system, method and device
US20210279205A1 (en) Log-structured merge-tree with blockchain properties
US20080201475A1 (en) Device Management Method Using Nodes Having Additional Attribute and Device Management Client Thereof
EP3111407A1 (en) Utilizing interactivity signals to generate relationships and promote content
CN111651525A (en) Block chain data storage method and device
US20190278757A1 (en) Distributed Database Management System with Dynamically Split B-Tree Indexes
CN101895568B (en) Method and system for cleaning synchronous data
WO2015154625A1 (en) Timing event processing method, storage method, execution method and corresponding device
WO2016082616A1 (en) Method and device for providing website authentication data for search engine
CN102012909A (en) Event reminding business processing method
CN109145155A (en) High-concurrency warehousing processing method for mass remote sensing image metadata
CN101256572A (en) Method for operating XML document as well as XDMS
CN106603610A (en) Data acquisition method and apparatus

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C53 Correction of patent for invention or patent application
CB02 Change of applicant information

Address after: 518049 Guangdong city of Shenzhen province Futian District Meihua Road, building 105, 5 layers of technology from room 0504

Applicant after: Shenzhen win win E-Commerce Technology Co., Ltd.

Address before: 518049 Guangdong city of Shenzhen province Futian District Meihua Road, building 105, 5 layers of technology from room 0504

Applicant before: Shenzhen Duoying Software Technology Co., Ltd.

COR Change of bibliographic data

Free format text: CORRECT: APPLICANT; FROM: SHENZHEN DUOYING SOFTWARE TECHNOLOGY CO., LTD. TO: SHENZHEN DUOYING ELECTRONIC COMMERCE TECHNOLOGY CO., LTD.

C02 Deemed withdrawal of patent application after publication (patent law 2001)
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20110413

DD01 Delivery of document by public notice

Addressee: Shenzhen win win E-Commerce Technology Co., Ltd.

Document name: Notification of Approving Refund