CN108446143A - Event-handling method and device - Google Patents
Event-handling method and device Download PDFInfo
- Publication number
- CN108446143A CN108446143A CN201810168746.1A CN201810168746A CN108446143A CN 108446143 A CN108446143 A CN 108446143A CN 201810168746 A CN201810168746 A CN 201810168746A CN 108446143 A CN108446143 A CN 108446143A
- Authority
- CN
- China
- Prior art keywords
- event
- rule
- active
- request
- server
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/445—Program loading or initiating
- G06F9/44505—Configuring for program initiating, e.g. using registry, configuration files
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/445—Program loading or initiating
- G06F9/44521—Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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/00—Commerce
- G06Q30/02—Marketing; Price estimation or determination; Fundraising
- G06Q30/0207—Discounts or incentives, e.g. coupons or rebates
- G06Q30/0239—Online discounts or incentives
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Business, Economics & Management (AREA)
- Physics & Mathematics (AREA)
- Accounting & Taxation (AREA)
- Development Economics (AREA)
- Finance (AREA)
- General Engineering & Computer Science (AREA)
- Strategic Management (AREA)
- Entrepreneurship & Innovation (AREA)
- General Business, Economics & Management (AREA)
- Marketing (AREA)
- Economics (AREA)
- Game Theory and Decision Science (AREA)
- Computer And Data Communications (AREA)
Abstract
A kind of event-handling method of offer of the embodiment of the present invention and device.The event-handling method includes:The event request that client terminal is sent is received, the event request carries the event attribute of the event request;It is matched with the one or more active rules to prestore according to the event attribute, searches goal activities rule corresponding with the event request;Goal activities rule customer incident corresponding with the event request is loaded onto target context object to parse, parsing obtains action result corresponding with the customer incident.
Description
Technical field
The present invention relates to field of computer technology, in particular to a kind of event-handling method and device.
Background technology
With the development of computer networking technology, Above-the-line can use less human resources, can but realize
The prizegiving of sequence ground, therefore, various activities all use the pattern carried out on line, for example, prize drawing, having ready conditions and sending prize activity.It is existing
Be that program on special line is set generally directed to each activity, for user's operation, but due to current dog-eat-dog and fast
The internet industry of rhythm especially internet financial industry, activity renewal speed is than very fast, and programming personnel is in each activity
It is required for that program on corresponding line is arranged, causes workload larger, activity generation rate is relatively low.
Invention content
In view of this, the embodiment of the present invention is designed to provide a kind of event-handling method and device.
A kind of event-handling method provided in an embodiment of the present invention is applied to server, the server and client terminal
Communication connection, including:
The event request that client terminal is sent is received, the event request carries the event attribute of the event request;
It is matched, is searched and the event request pair with the one or more active rules to prestore according to the event attribute
The goal activities rule answered;
By goal activities rule customer incident corresponding with the event request be loaded onto target context object into
Row parsing, parsing obtain action result corresponding with the customer incident.
The embodiment of the present invention also provides a kind of event processing apparatus, is applied to server, the server and client terminal
Communication connection, the event processing apparatus include:
Receiving module, the event request for receiving client terminal transmission, the event request carry the event request
Event attribute;
Matching module is searched for being matched with the one or more active rules to prestore according to the event attribute
Goal activities rule corresponding with the event request;
Parsing module, for goal activities rule customer incident corresponding with the event request to be loaded onto target
Context object is parsed, and parsing obtains action result corresponding with the customer incident.
Compared with prior art, the event-handling method and device of the embodiment of the present invention, by using specific active rule
When, then the active rule is loaded onto target context object, to parse the active rule, obtain action result;So that
Handling item has reusability.It further, even if need not be every if programming personnel in the case that activity renewal speed is fast
As soon as an activity is required for that program on corresponding line is arranged, it is loaded directly into the active rule to prestore and is able to carry out activity description, drops
Activity generation rate improves in the case of the workload of low staff.
To enable the above objects, features and advantages of the present invention to be clearer and more comprehensible, preferred embodiment cited below particularly, and coordinate
Appended attached drawing, is described in detail below.
Description of the drawings
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below will be to needed in the embodiment attached
Figure is briefly described, it should be understood that the following drawings illustrates only certain embodiments of the present invention, therefore is not construed as pair
The restriction of range for those of ordinary skill in the art without creative efforts, can also be according to this
A little attached drawings obtain other relevant attached drawings.
Fig. 1 is the schematic diagram that the server that present pre-ferred embodiments provide is interacted with client terminal.
Fig. 2 is the block diagram for the server that present pre-ferred embodiments provide.
Fig. 3 is the flow chart for the event-handling method that present pre-ferred embodiments provide.
Fig. 4 is the detail flowchart of the step S203 for the event-handling method that present pre-ferred embodiments provide.
Fig. 5 is the high-level schematic functional block diagram for the event processing apparatus that present pre-ferred embodiments provide.
Specific implementation mode
Below in conjunction with attached drawing in the embodiment of the present invention, technical solution in the embodiment of the present invention carries out clear, complete
Ground describes, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.Usually exist
The component of the embodiment of the present invention described and illustrated in attached drawing can be arranged and be designed with a variety of different configurations herein.Cause
This, the detailed description of the embodiment of the present invention to providing in the accompanying drawings is not intended to limit claimed invention below
Range, but it is merely representative of the selected embodiment of the present invention.Based on the embodiment of the present invention, those skilled in the art are not doing
The every other embodiment obtained under the premise of going out creative work, shall fall within the protection scope of the present invention.
It should be noted that:Similar label and letter indicate similar terms in following attached drawing, therefore, once a certain Xiang Yi
It is defined, then it further need not be defined and explained in subsequent attached drawing in a attached drawing.Meanwhile the present invention's
In description, term " first ", " second " etc. are only used for distinguishing description, are not understood to indicate or imply relative importance.
As shown in Figure 1, being that the server 100 that present pre-ferred embodiments provide shows with what client terminal 200 interacted
It is intended to.The server 100 is communicatively coupled by network and one or more client terminals 200, with into row data communication
Or interaction.The server 100 can be network server, database server etc., and certain server 100 can also be
PC (personal computer, PC), tablet computer, smart mobile phone, personal digital assistant (personal
Digital assistant, PDA) etc..The client terminal 200 can be PC (personal computer, PC),
Tablet computer, smart mobile phone, personal digital assistant (personal digital assistant, PDA) etc..
The specified applications such as browser can be installed in the client terminal 200.The client terminal 200 can be by clear
Look at device or other specified applications sends event request to the server 100.Further, the event request can be
Account registration request, acquisition request of receiving the award, place an order the operation requests such as request and system of real name request.
Fig. 2 is the structure diagram of one embodiment of above-mentioned server 100.As shown in Fig. 2, server 100 includes:It deposits
Reservoir 102, processor 104 and network module 106.It is appreciated that structure shown in Fig. 2 is only to illustrate, not to service
The structure of device 100 causes to limit.For example, server 100 may also include than shown in Fig. 2 more either less components or
With the configuration different from shown in Fig. 2.
Memory 102 can be used for storing software program and module, such as the page versions test side in the embodiment of the present invention
Corresponding program instruction/the module of method, apparatus and system, processor 104 are stored in the software program in memory 102 by operation
And module realizes above-mentioned page versions test method to perform various functions application and data processing.Memory
102 may include high speed random access memory, may also include nonvolatile memory, and such as one or more magnetic storage device dodges
It deposits or other non-volatile solid state memories.In some instances, memory 102 can further comprise relative to processor
104 remotely located memories, these remote memories can pass through network connection to server 100.The example of above-mentioned network
Including but not limited to internet, intranet, LAN, mobile radio communication and combinations thereof.
Network module 106 is for receiving and transmitting network signal.Above-mentioned network signal may include wireless signal or have
Line signal.In an example, above-mentioned network signal is cable network signal.At this point, network module 106 may include processor,
The elements such as random access memory, converter, crystal oscillator.
Above-mentioned software program and module include:Operating system 108 and event processing apparatus 110.Wherein operation system
System 108 may be, for example, LINUX, UNIX, WINDOWS, may include various (such as memory management, depositing for managing system task
Store up equipment control, power management etc.) component software and/or driving, and can mutually be communicated with various hardware or component software, from
And provide the running environment of other software component.Event processing apparatus 110 operates on the basis of operating system 108, and passes through
The request for carrying out automatic network is monitored in the network service of operating system 108, completes corresponding data processing according to request, and return to processing
As a result client terminal 200 is given.That is, event processing apparatus 110 is used to provide service to client terminal 200.
Operation system of marketing is the important daily operation tool of Internet company, and existing marketing operation way is substantially all
Be each activity all it is that specific exploitation and the final publication of test is needed to reach the standard grade, finally shows in front of the user.This mode pair
It is very unfavorable, master in the fast development of current dog-eat-dog and allegro internet industry especially internet financial industry
It to be caused due to the shortcomings that following several respects:1) is linked up of high cost:Activity scheme formulates the work compound for needing multiple departments,
Such as:Operation department provides activity scheme, produce sector's deisgn product prototype, developing department's evaluation feasibility and exploitation and sets
Meter, O&M department are also needed to for the server resource allotment during activity.Thus, which a large amount of time is all expended in department
Between communication on, increase intangible cost;2) activities publication is of high cost:Activity is required for different degrees of exploitation to survey each time
Examination and publication are the waste of various aspects resource during this;3) rate of code reuse is low:Due to activity diversity, every time activity
With before active rule and interface have place that is many or even cannot being all multiplexed;4) maintenance costs are high:Due to code
Reusability is low, and whole system can become more and more too fat to move with movable be continuously increased, and many codes useless are always in system
In, it is prodigious challenge for the colleague that the maintenance in later stage is especially newly taken over, the upgrading of internal system interface needs compatibility each
A version;5) consumption of server resources is more:Expired activity may still be run and (especially service class) on the server, meeting
Cause the unnecessary waste of server resource;6) once exploitation is completed, active rule and scheme determine substantially, are unfavorable for for activities
Modification activity scheme and active rule in operation;7) systems are irregular, and the information of different platform is difficult to centralized management;
8) coupling between systems is larger, forms cobweb model for each system of data transfer in activity, and any one connects
The exception of mouth may all lead to the snowslide of system.
The present invention can efficiently solve drawbacks described above by following embodiment, be described in detail below.The marketing
Each step in shown in the executable Fig. 3 of operation.
Referring to Fig. 3, being the event handling applied to server 100 shown in Fig. 2 that present pre-ferred embodiments provide
The flow chart of method.Detailed process shown in Fig. 3 will be described in detail below.
Step S201 receives the event request that client terminal is sent.
In the present embodiment, the event request carries the event attribute of the event request.The event attribute may include using
The information such as IP address, registration source occur for family identifier, Time To Event, event registration account, event.
In the present embodiment, after the event request that step receives that client terminal is sent, the method further includes:To described
Client terminal sends confirmation message.
In general message subscribing, a piece of news (can be sent and be confirmed by ACK after recipient receives and has smoothly executed
Message), in the case where size of message is bigger, message packing phenomenon may be caused.To avoid postponing, in above-mentioned steps S201
Place, after the server receives event request, the server will dish out an asynchronous thread handle the event request (
It is exactly step S202 and step S203 below), the server can give the client terminal for sending event request to send true at this time
Recognize message, the client terminal can continue to send other message, the timely processing of message is ensure that with this, is also taken full advantage of
The resource of the server.
In the present embodiment, key operation of the user in the provided operation interface of client terminal is directed in the server in advance
(fix tentatively for event, stated below with event) defines its event attribute;For user in the provided operation interface of client terminal
Event addition message queue triggering bury a little, and the event is broadcasted in the form of message queue;It is configured by custom script
Active rule, rule in using event attribute verification user behavior whether meet Operations Requirements, each activity is under the jurisdiction of a thing
Part;It creates message queue and monitors channel.
Step S202 is matched according to the event attribute with the one or more active rules to prestore, is searched and is somebody's turn to do
The corresponding goal activities rule of event request.
In the present embodiment, the customer incident can be matched to one or more active rules.In an example, described
Event attribute may include the time that event occurs, the event that can be occurred by the event and the one or more work to prestore
Active period is matched as defined in each active rule in dynamic rule, if the time that the event occurs is any
In activity time, then it represents that the active rule is goal activities rule.If for example, the time that the event occurs is multiple
In the period of active rule defined, then multiple active rules can be matched to.
In another example, the event attribute includes investment amount, then can by the investment amount with prestore
One or more active rules in each active rule as defined in investment amount range matched, if the event is asked
The investment amount asked then advises the active rule for the goal activities within the scope of the investment amount as defined in any active rule
Then.
In the present embodiment, one or more active rules store in the database, for example, the database can be
MongoDB.The MongoDB is a database stored based on distributed document.
In the present embodiment, one or more active rules are prestored in the server.The active rule can be in work
It is sent by the management terminal being connect with server communication before dynamic execution, with the active rule stored;Can also be by straight
Connect the one or more active rules being arranged in the server.
In one embodiment, the server is connect with management terminal communications, and the method further includes:Receive management
One or more active rules that terminal is sent;Then, the one or more active rules received are registered, to create
Event queue monitors channel.
The queue of this example events monitors channel using the pattern used afterwards is first registered, and selection is needed to register after establishment activity
Start, active rule can just come into force, and this avoid the unnecessary mistakes caused by active edit state taking effect rules.In addition by
It is relatively large in the amount of message queue.
Event-handling method in the embodiment of the present invention uses the Deployment System For Clusters of more exemplary applications, multiple customer incidents
Or shared queue between the corresponding activity of multiple active rules, the Double Spending of message is prevented, handling up for queue consumption is improved
It measures (TPS).
In another embodiment, before activity executes, the server can receive user's input, or the work uploaded
Dynamic rule related data, and preserve the related data to form one or more active rules.Then, to receiving
One or more active rules are registered, and channel is monitored to create event queue.
Further, the server before receiving the event request first according to the active rule establishment activity,
And the active rule is configured, its event type is specified, and be registered in queue and monitor;So that the server can listen to institute
State the event request of client terminal transmission.
It can only need operation personnel that active rule is set before activity by above-mentioned setting activity scheme, be not necessarily to it
His departmental staff participates in, and largely reduces unnecessary communication cost.In addition, movable publication only need to be pre-configured with movable rule
Then, it is not necessarily to develop and issue flow, activity can be with Quick thread.Further, activity is configured by active rule
It generates, can make adjustment as needed at any time, keep movable flexibility more preferable.
Goal activities rule customer incident corresponding with the event request is loaded onto target or more by step S203
Literary object is parsed, and parsing obtains action result corresponding with the customer incident.
In the present embodiment, goal activities rule and the customer incident are loaded into target context object.This
Can be that parameter is loaded into the target context object by the corresponding event attribute of the customer incident in embodiment.
In one example, the event-handling method in the present embodiment is used to handle carries out prize allocation activities to meet the user of condition.
In the present embodiment, extra data can also be loaded before parsing, such as:Historical statistical data and event information it
Outer user related data.
In the present embodiment, analytics engine is stored in the server;In one embodiment, the analytics engine can
To be JS analytics engines.As shown in figure 4, the step S203 includes:Step S2031 to step S2033.
The active rule is loaded onto the target context object by step S2031, is drawn with initializing the parsing
It holds up.
In the present embodiment, template method is prefabricated in the analytics engine, the template method is used to advise the activity
Then carry out operation;
Step S2032 parses the customer incident with active rule using the analytics engine, obtains executing knot
Fruit.
Step S2033 is matched according to the implementing result with the winnings information to prestore to obtain target winnings information.
Further, after step S2033, the method further includes:The target winnings information is sent to prize
In queue.
The target winnings information may include bonus items, reward object, reward the identifier of object (for example, mobile phone
Number) etc..
It parses the first application program that the process of the customer incident uses to be handled, winnings information is answered using other
It is handled with program.Winnings information is handled using another second application program.In detail, described in the parsing of the first application program
Customer incident obtains target winnings information after obtaining the implementing result, and first application program will using RabbitMQ communications
The target winnings information is sent to prize queue and is preserved.Second application program can then read the prize queue
In winnings information.RabbitMQ communication is a kind of communication means of application program to application program.
The step S2033 can first match corresponding target winnings information according to the implementing result, then by institute
It states target winnings information and is sent in a queue and preserved, so that related personnel can obtain prize from the prize queue
Information, with for user's awarding of winning a prize.
In one embodiment, the event-handling method is to be based on RabbitMQ message queues, is advised using JS scripts
The parsing for the customer incident that then analytics engine is realized.Itself mainly solving the technical problems that:Activity repeat, redundancy is avoided to open
The waste of the human resources of hair and each department;Satisfaction becomes increasingly abundant and changeable operation activity need;The redundancy of reduction system
Degree improves the reusability of code, reduces Service Source expense;Degree of coupling between reduction system avoids between system
It directly affects;The centralized management of separate traffic function reduces the O&M cost of system.
It is mainly to improve to realize by the following to solve above-mentioned technical problem:The JS parsings used in the present embodiment are drawn
It holds up and does not support the flexible configuration of most of active rule effectively in metadata level Depth Expansion for specific activities, improve
Rate of code reuse, also drastically reduces movable development cost;Using MongoDB as datum number storage according to library, effectively
Meet the storage of the active rule and mass users behavioral data changeable to format.For the number for needing to count in active rule
According to, it is accumulative after event triggering to be stored in Redis, it is obtained from Redis when being used in rule, when avoiding rule verification
It counts again, improves throughput of system (TPS) and performance.System is communicated using RabbitMQ, the coupling between reduction system
Conjunction degree, while decreasing the degree of dependence between system.System is complete in active rule parsing and winnings information transmission level
Full decoupling, winnings information is sent after rule parsing success by MQ queues, and prize services independent process award data.
In the present embodiment, after the step S2032, the method further includes:Judge the implementing result with it is preset
Whether expected results match;If the implementing result is mismatched with preset expected results, step S2033 is not executed and directly will
The customer incident is preserved.If the implementing result is matched with preset expected results, then follow the steps institute after S2033
Customer incident is stated to be preserved.In one embodiment, the customer incident can store in the database, the database
Can be MongoDB.Terminate in each customer incident or be saved because executing the suspended data of mistake, is conducive to use
Data during the management activity of family.
It is described to be matched with one or more active rules according to the event attribute in the present embodiment, it searches
The step of goal activities rule corresponding with the event request includes:Start an asynchronous thread according to the event attribute with it is described
One or more active rules are matched, and goal activities rule corresponding with the event request is searched.Institute in the present embodiment
Customer incident is all by message asynchronous process, and coupling reduces between each system, and task and reward etc. are as independent
Various centralized managements are serviced, system maintenance and stabilization are convenient for
The event-handling method of the embodiment of the present invention when by using specific active rule, then the active rule is added
It is loaded onto target context object, to parse the active rule, obtains action result;It is reused so that processing item has
Property.Further, even if not needing each activity in the case that activity renewal speed is fast if programming personnel is required for setting pair
Program on the line answered is loaded directly into the active rule to prestore and is just able to carry out activity description, reduces the workload of staff
In the case of activity generation rate improve.
The flow of the event-handling method is described with an example below.
For registering and send experience gold, active rule is this example:In 2017/12/1 to 2017/12/12 period from fast
Thunder, which is promoted, to be entered and send 10000 yuan of experience gold in the user of application program (App) registration.Assuming that the thing that registered events may include
Part attribute is following (including but not limited to):CustomerId (user id);Phone (cell-phone number);Platform (register platforms);
RegistDate (registion time), UtmSource (registration source).Certainly, the event attribute can also include in other
Hold.
First, the active configuration stage:
Configuration activities information:Activity time, activity name etc..In one embodiment, there can be management terminal reception
The action message of operation personnel's input, then server is sent to by the management terminal and is preserved.Configuration activities Rule Information:
Evt.Platform==" App ” &&Evt.RegistDate>(' 201,7/1,2/1 00=new Date:00:00')&&
Evt.RegistDate<new Date('2017/12/13 00:00:00') &&Evt.UtmSource=" Xunlei ".Configuration
Winnings information (prize and activity association):10000 yuan of experience gold.Registration activity event:That is modification activity service release, is noted again
In each activity to queue of volume.
Secondly, customer incident resolution phase:
The registration request for receiving client terminal transmission, the event attribute matching entrained by the registration request are corresponding
Active rule.Matching herein is all corresponding active rules of the life event to succeed in registration.It in an example, can be first
Currently valid active rule is first filtered out, carrying out following rule to effective each active rule verifies;
Loading activity rule and event information are to context:Event information can be loaded into the form of Evt objects at this time
Context object, it is assumed that current event information is:{“Platform”:”App”,”RegistDate”:" 2017/12/2,12:
00:00”,”CustomerId”:12345,”Phone”:”13800138000”,”UtmSource”:" Xunlei ", then will
Active rule and event information give JS analytics engines (using rule as expression formula, event information is that parameter is verified), institute simultaneously
Last implementing result can be exported by stating JS analytics engines.If being executed if:Parse winnings information:Above rule verifies
Pass through, the winnings information of activity association is sent to prize queue in the form of MQ herein.
Finally preserve all footprint information of customer incident.The footprint information may include being successfully generated winnings information
Customer incident, and fail the customer incident of successfully resolved.
The monitoring of this example events needs selection registration to start using the pattern consumed afterwards is first registered after establishment activity, living
Dynamic rule can just come into force, and this avoid the unnecessary mistakes caused by active edit state taking effect rules, additionally, due to message
The amount of queue is relatively large, and this system uses the Deployment System For Clusters of more exemplary applications, and shared queue between multiple examples prevents
The Double Spending of message.
Referring to Fig. 5, being the function module for the event processing apparatus shown in Fig. 2 110 that present pre-ferred embodiments provide
Schematic diagram.Modules in the event processing apparatus 110 and unit in the present embodiment are for executing above method implementation
Each step in example.The event processing apparatus 110 includes:Receiving module 1101, matching module 1102 and parsing module
1103。
The receiving module 1101, the event request for receiving client terminal transmission, the event request carry the thing
The event attribute of part request.
The matching module 1102, for according to the event attribute and the one or more active rules to prestore progress
Match, searches goal activities rule corresponding with the event request.
The parsing module 1103, for adding goal activities rule customer incident corresponding with the event request
It is loaded onto target context object to be parsed, parsing obtains action result corresponding with the customer incident.
In the present embodiment, analytics engine is stored in the server;The analytics engine can be JS analytics engines.Institute
Stating parsing module 1103 includes:Initialization unit, the first resolution unit and the second resolution unit.
The initialization unit, for the active rule to be loaded onto the target context object, to initialize
Analytics engine is stated, plate device is prefabricated in the analytics engine, the plate device is for transporting the active rule
It calculates.
First resolution unit, for being solved to the customer incident with active rule using the analytics engine
Analysis, obtains implementing result.
Second resolution unit obtains target for being matched with the winnings information to prestore according to the implementing result
Winnings information.
In the present embodiment, the parsing module parses to obtain the target winnings information, and the target winnings information is sent out
It send into prize queue.
In the present embodiment, the matching module 1102 is for starting an asynchronous thread according to the event attribute and described one
Kind or various activities rule are matched, and goal activities rule corresponding with the event request is searched.
In the present embodiment, the event processing apparatus 110 further includes:Confirmation module 1104 is used for the client terminal
Send confirmation message.
In the present embodiment, the event processing apparatus 110 further includes:Registration module 1105, for receiving management terminal hair
The one or more active rules sent, and the one or more active rules received are registered, to create event queue
Monitor channel.
The other details closed in this present embodiment can be further with reference to the description in above method embodiment, herein not
It repeats again.
The event processing apparatus of the embodiment of the present invention when by using specific active rule, then the active rule is added
It is loaded onto target context object, to parse the active rule, obtains action result;It is reused so that processing item has
Property.Further, even if not needing each activity in the case that activity renewal speed is fast if programming personnel is required for setting pair
Program on the line answered is loaded directly into the active rule to prestore and is just able to carry out activity description, reduces the workload of staff
In the case of activity generation rate improve.
In several embodiments provided herein, it should be understood that disclosed device and method can also pass through
Other modes are realized.The apparatus embodiments described above are merely exemplary, for example, the flow chart in attached drawing and block diagram
Show the device of multiple embodiments according to the present invention, the architectural framework in the cards of method and computer program product,
Function and operation.In this regard, each box in flowchart or block diagram can represent the one of a module, section or code
Part, a part for the module, section or code, which includes that one or more is for implementing the specified logical function, to be held
Row instruction.It should also be noted that at some as in the realization method replaced, the function of being marked in box can also be to be different from
The sequence marked in attached drawing occurs.For example, two continuous boxes can essentially be basically executed in parallel, they are sometimes
It can execute in the opposite order, this is depended on the functions involved.It is also noted that every in block diagram and or flow chart
The combination of box in a box and block diagram and or flow chart can use function or the dedicated base of action as defined in executing
It realizes, or can be realized using a combination of dedicated hardware and computer instructions in the system of hardware.
In addition, each function module in each embodiment of the present invention can integrate to form an independent portion
Point, can also be modules individualism, can also two or more modules be integrated to form an independent part.
It, can be with if the function is realized and when sold or used as an independent product in the form of software function module
It is stored in a computer read/write memory medium.Based on this understanding, technical scheme of the present invention is substantially in other words
The part of the part that contributes to existing technology or the technical solution can be expressed in the form of software products, the meter
Calculation machine software product is stored in a storage medium, including some instructions are used so that a computer equipment (can be
People's computer, server or network equipment etc.) it performs all or part of the steps of the method described in the various embodiments of the present invention.
And storage medium above-mentioned includes:USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), arbitrary access are deposited
The various media that can store program code such as reservoir (RAM, Random Access Memory), magnetic disc or CD.It needs
Illustrate, herein, relational terms such as first and second and the like be used merely to by an entity or operation with
Another entity or operation distinguish, and without necessarily requiring or implying between these entities or operation, there are any this realities
The relationship or sequence on border.Moreover, the terms "include", "comprise" or its any other variant are intended to the packet of nonexcludability
Contain, so that the process, method, article or equipment including a series of elements includes not only those elements, but also includes
Other elements that are not explicitly listed, or further include for elements inherent to such a process, method, article, or device.
In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including the element
Process, method, article or equipment in there is also other identical elements.
The foregoing is only a preferred embodiment of the present invention, is not intended to restrict the invention, for the skill of this field
For art personnel, the invention may be variously modified and varied.All within the spirits and principles of the present invention, any made by repair
Change, equivalent replacement, improvement etc., should all be included in the protection scope of the present invention.It should be noted that:Similar label and letter exist
Similar terms are indicated in following attached drawing, therefore, once being defined in a certain Xiang Yi attached drawing, are then not required in subsequent attached drawing
It is further defined and is explained.
The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any
Those familiar with the art in the technical scope disclosed by the present invention, can easily think of the change or the replacement, and should all contain
Lid is within protection scope of the present invention.Therefore, protection scope of the present invention should be subject to the protection scope in claims.
Claims (10)
1. a kind of event-handling method, which is characterized in that it is applied to server, the server is communicated to connect with client terminal,
The event-handling method includes:
The event request that client terminal is sent is received, the event request carries the event attribute of the event request;
It is matched, is searched corresponding with the event request with the one or more active rules to prestore according to the event attribute
Goal activities rule;
Goal activities rule customer incident corresponding with the event request is loaded onto target context object to solve
Analysis, parsing obtain action result corresponding with the customer incident.
2. event-handling method as described in claim 1, which is characterized in that be stored with analytics engine in the server;Institute
The step of being parsed goal activities rule customer incident corresponding with the event request to target context is stated to wrap
It includes:
The active rule is loaded onto the target context object, to initialize the analytics engine, the analytics engine
In be prefabricated with template method, the template method is used to carry out operation to the active rule;
The customer incident is parsed with active rule using the analytics engine, obtains implementing result;
It is matched with the winnings information to prestore to obtain target winnings information according to the implementing result.
3. event-handling method as claimed in claim 2, which is characterized in that described to use the analytics engine with active rule
After the step of parsing to the customer incident, obtain implementing result, the method further includes:
Judge whether the implementing result matches with preset expected results;
If the implementing result is mismatched with preset expected results, the customer incident is preserved.
4. event-handling method as claimed in claim 1 or 2, which is characterized in that it is described according to the event attribute with it is described
One or more active rules are matched, and the step for searching goal activities rule corresponding with the event request includes:
Start an asynchronous thread to be matched with one or more active rules according to the event attribute, search and the thing
Part asks corresponding goal activities rule.
5. event-handling method as claimed in claim 1 or 2, which is characterized in that receive the thing that client terminal is sent in step
After part request, the method further includes:
Confirmation message is sent to the client terminal.
6. event-handling method as described in claim 1, which is characterized in that the server is connect with management terminal communications,
The method further includes:
Receive one or more active rules that management terminal is sent;
The one or more active rules received are registered, channel is monitored to create event queue.
7. a kind of event processing apparatus, which is characterized in that it is applied to server, the server is communicated to connect with client terminal,
The event processing apparatus includes:
Receiving module, the event request for receiving client terminal transmission, the event request carry the event of the event request
Attribute;
Matching module is searched and is somebody's turn to do for being matched with the one or more active rules to prestore according to the event attribute
The corresponding goal activities rule of event request;
Parsing module, for goal activities rule customer incident corresponding with the event request to be loaded onto target or more
Literary object is parsed, and parsing obtains action result corresponding with the customer incident.
8. event processing apparatus as claimed in claim 7, which is characterized in that be stored with analytics engine in the server;Institute
Stating parsing module includes:
Initialization unit is drawn for the active rule to be loaded onto the target context object with initializing the parsing
It holds up, plate device is prefabricated in the analytics engine, the plate device is used to carry out operation to the active rule;
First resolution unit is held for being parsed to the customer incident with active rule using the analytics engine
Row result;
Second resolution unit obtains target prize letter for being matched with the winnings information to prestore according to the implementing result
Breath.
9. event processing apparatus as claimed in claim 7 or 8, which is characterized in that the matching module is asynchronous for starting one
Thread is matched according to the event attribute with one or more active rules, and mesh corresponding with the event request is searched
Mark active rule.
10. event processing apparatus as claimed in claim 7 or 8, which is characterized in that described device further includes:
Registration module, one or more active rules for receiving management terminal transmission, and it is one or more to what is received
Active rule is registered, and channel is monitored to create event queue.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810168746.1A CN108446143A (en) | 2018-02-28 | 2018-02-28 | Event-handling method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810168746.1A CN108446143A (en) | 2018-02-28 | 2018-02-28 | Event-handling method and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108446143A true CN108446143A (en) | 2018-08-24 |
Family
ID=63193116
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810168746.1A Pending CN108446143A (en) | 2018-02-28 | 2018-02-28 | Event-handling method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108446143A (en) |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110738384A (en) * | 2019-04-17 | 2020-01-31 | 北京航天飞行控制中心 | Event sequence checking method and system |
CN111260336A (en) * | 2020-02-13 | 2020-06-09 | 支付宝(杭州)信息技术有限公司 | Business checking method, device and equipment based on rule engine |
CN111290862A (en) * | 2020-01-21 | 2020-06-16 | 深圳前海环融联易信息科技服务有限公司 | Message processing method and device, computer equipment and storage medium |
CN111324469A (en) * | 2020-01-20 | 2020-06-23 | 天津美腾科技股份有限公司 | Method and system for distributed event center with biased application structure optimization |
CN113138871A (en) * | 2021-05-18 | 2021-07-20 | 拉扎斯网络科技(上海)有限公司 | Processing method and device of activity data and electronic equipment |
CN113496191A (en) * | 2020-04-01 | 2021-10-12 | 杭州海康威视数字技术股份有限公司 | Rule configuration method and system, server and terminal |
CN113743879A (en) * | 2020-05-28 | 2021-12-03 | 华为技术有限公司 | Automatic rule processing method, system and related equipment |
CN114860349A (en) * | 2022-07-06 | 2022-08-05 | 深圳华锐分布式技术股份有限公司 | Data loading method, device, equipment and medium |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1900906A (en) * | 2006-07-14 | 2007-01-24 | 中国科学院软件研究所 | Software process main body automatic consulting system and method based on rulls |
CN103986599A (en) * | 2014-05-14 | 2014-08-13 | 上海上讯信息技术股份有限公司 | Operation and maintenance alarm system and method for network equipment |
CN104966239A (en) * | 2015-06-30 | 2015-10-07 | 天津爱蔻科技有限公司 | Intelligent underwriting platform based on rule engine |
CN105786451A (en) * | 2014-12-15 | 2016-07-20 | 华为技术有限公司 | Method, device and system for processing complicated event |
CN106911784A (en) * | 2017-03-02 | 2017-06-30 | 北京奇鱼时代科技有限公司 | A kind of method and apparatus for performing asynchronous event |
CN107180338A (en) * | 2017-05-22 | 2017-09-19 | 深圳市小牛在线互联网信息咨询有限公司 | Business performs method, device, storage medium and computer equipment |
CN107274141A (en) * | 2016-04-07 | 2017-10-20 | 中国移动通信有限公司研究院 | A kind of event-handling method and the network equipment |
-
2018
- 2018-02-28 CN CN201810168746.1A patent/CN108446143A/en active Pending
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1900906A (en) * | 2006-07-14 | 2007-01-24 | 中国科学院软件研究所 | Software process main body automatic consulting system and method based on rulls |
CN103986599A (en) * | 2014-05-14 | 2014-08-13 | 上海上讯信息技术股份有限公司 | Operation and maintenance alarm system and method for network equipment |
CN105786451A (en) * | 2014-12-15 | 2016-07-20 | 华为技术有限公司 | Method, device and system for processing complicated event |
CN104966239A (en) * | 2015-06-30 | 2015-10-07 | 天津爱蔻科技有限公司 | Intelligent underwriting platform based on rule engine |
CN107274141A (en) * | 2016-04-07 | 2017-10-20 | 中国移动通信有限公司研究院 | A kind of event-handling method and the network equipment |
CN106911784A (en) * | 2017-03-02 | 2017-06-30 | 北京奇鱼时代科技有限公司 | A kind of method and apparatus for performing asynchronous event |
CN107180338A (en) * | 2017-05-22 | 2017-09-19 | 深圳市小牛在线互联网信息咨询有限公司 | Business performs method, device, storage medium and computer equipment |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110738384A (en) * | 2019-04-17 | 2020-01-31 | 北京航天飞行控制中心 | Event sequence checking method and system |
CN111324469A (en) * | 2020-01-20 | 2020-06-23 | 天津美腾科技股份有限公司 | Method and system for distributed event center with biased application structure optimization |
CN111290862A (en) * | 2020-01-21 | 2020-06-16 | 深圳前海环融联易信息科技服务有限公司 | Message processing method and device, computer equipment and storage medium |
CN111260336A (en) * | 2020-02-13 | 2020-06-09 | 支付宝(杭州)信息技术有限公司 | Business checking method, device and equipment based on rule engine |
CN113496191A (en) * | 2020-04-01 | 2021-10-12 | 杭州海康威视数字技术股份有限公司 | Rule configuration method and system, server and terminal |
CN113743879A (en) * | 2020-05-28 | 2021-12-03 | 华为技术有限公司 | Automatic rule processing method, system and related equipment |
CN113138871A (en) * | 2021-05-18 | 2021-07-20 | 拉扎斯网络科技(上海)有限公司 | Processing method and device of activity data and electronic equipment |
CN114860349A (en) * | 2022-07-06 | 2022-08-05 | 深圳华锐分布式技术股份有限公司 | Data loading method, device, equipment and medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108446143A (en) | Event-handling method and device | |
US12218795B2 (en) | Internet of things | |
US8694579B2 (en) | Enterprise network system for programmable electronic displays | |
US8180888B2 (en) | Network mass operation infrastructure | |
CN101636738B (en) | Method for obstruction and capacity information unification monitoring in unification management system environment and system for thereof | |
US20050261933A1 (en) | Service level agreement design and enforcement for outsourced call center | |
US20110196957A1 (en) | Real-Time Policy Visualization by Configuration Item to Demonstrate Real-Time and Historical Interaction of Policies | |
US20070282659A1 (en) | System and Methods for Managing Complex Service Delivery Through Coordination and Integration of Structured and Unstructured Activities | |
CN109564527A (en) | The security configuration of cloud computing node | |
MX2008013115A (en) | Business process meta-model. | |
US12213042B2 (en) | System of actions for IOT devices | |
CN108595316A (en) | Life cycle management method, manager, equipment and the medium of Distributed Application | |
US10410152B2 (en) | System and method for automatically and efficiently monitoring software development life cycles | |
CN104838354A (en) | Running agents to execute automation tasks in cloud systems | |
CN112882765B (en) | Digital twin model scheduling method and device | |
CN109816446A (en) | A kind of cross-platform advertisement data processing method and device | |
CN102385617A (en) | Dynamic domain query and query translation | |
CN116596596A (en) | Advertisement putting effect data processing method, device, equipment and storage medium | |
Radovici et al. | A model for the remote deployment, update, and safe recovery for commercial sensor-based iot systems | |
CN107609086A (en) | A kind of APP method for pushing and its automotive engine system | |
CN104951855A (en) | Apparatus and method for improving resource management | |
CN110188258B (en) | Method and device for acquiring external data by using crawler | |
Nam et al. | Business-aware framework for supporting RFID-enabled applications in EPC Network | |
Wolf | Succeedings of the second international software architecture workshop (isaw-2) | |
TW200905560A (en) | Meta-container for model-based distributed applications |
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: 20180824 |
|
RJ01 | Rejection of invention patent application after publication |