CN110347533A - The processing method of data exception, calculates equipment and medium at device - Google Patents
The processing method of data exception, calculates equipment and medium at device Download PDFInfo
- Publication number
- CN110347533A CN110347533A CN201910625782.0A CN201910625782A CN110347533A CN 110347533 A CN110347533 A CN 110347533A CN 201910625782 A CN201910625782 A CN 201910625782A CN 110347533 A CN110347533 A CN 110347533A
- Authority
- CN
- China
- Prior art keywords
- atomic transaction
- exception
- module
- transaction
- withdraws
- 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
- 238000003672 processing method Methods 0.000 title claims abstract description 25
- 238000000034 method Methods 0.000 claims abstract description 63
- 230000008569 process Effects 0.000 claims abstract description 35
- 238000012545 processing Methods 0.000 claims abstract description 15
- 230000002159 abnormal effect Effects 0.000 claims description 20
- 238000001514 detection method Methods 0.000 claims description 8
- 230000006399 behavior Effects 0.000 claims description 6
- 238000010586 diagram Methods 0.000 description 18
- 230000006870 function Effects 0.000 description 18
- 238000007689 inspection Methods 0.000 description 13
- 238000004590 computer program Methods 0.000 description 11
- 238000005516 engineering process Methods 0.000 description 6
- 230000004044 response Effects 0.000 description 4
- 230000009471 action Effects 0.000 description 3
- 238000005538 encapsulation Methods 0.000 description 3
- 230000004048 modification Effects 0.000 description 3
- 238000012986 modification Methods 0.000 description 3
- 238000012544 monitoring process Methods 0.000 description 3
- 230000008859 change Effects 0.000 description 2
- 238000004891 communication Methods 0.000 description 2
- 239000000758 substrate Substances 0.000 description 2
- 230000002411 adverse Effects 0.000 description 1
- 230000008901 benefit Effects 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 235000013399 edible fruits Nutrition 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000005611 electricity Effects 0.000 description 1
- 239000000835 fiber Substances 0.000 description 1
- 238000005111 flow chemistry technique Methods 0.000 description 1
- PCHJSUWPFVWCPO-UHFFFAOYSA-N gold Chemical compound [Au] PCHJSUWPFVWCPO-UHFFFAOYSA-N 0.000 description 1
- 239000010931 gold Substances 0.000 description 1
- 229910052737 gold Inorganic materials 0.000 description 1
- 230000000977 initiatory effect Effects 0.000 description 1
- 210000003127 knee Anatomy 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
- G06F11/1402—Saving, restoring, recovering or retrying
- G06F11/1415—Saving, restoring, recovering or retrying at system level
- G06F11/1438—Restarting or rejuvenating
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
- G06F11/1402—Saving, restoring, recovering or retrying
- G06F11/1474—Saving, restoring, recovering or retrying in transactions
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
Present disclose provides a kind of processing methods of data exception.This method comprises: determining multiple atomic transactions, the atomic transaction includes the operation of required execution in the parallel process of data;The multiple atomic transaction is executed parallel;Before the multiple atomic transaction executes completion, if exception occurs in the operational process of any one of atomic transaction, execution withdraws operation;And obtain the operation result of the multiple atomic transaction.The disclosure additionally provides a kind of processing unit of data exception, calculates equipment and medium.
Description
Technical field
This disclosure relates to field of computer technology, more particularly, to a kind of processing method of data exception, device, meter
Calculate equipment and medium.
Background technique
Bank transaction often relates to multiple operating processes, for example a process of exchange includes the legitimacy inspection of input information
It looks into, relevant parameter inspection, Transaction Information inspection, product information inspection, each business processing.In these operating processes
In, these affairs are handled according to serial manner, that is, wait a transaction business process to finish the place for carrying out next affairs again
Reason, will substantially prolong the time of flow processing, influences customer experience, and the capacity of system is not high.To solve the above problems, phase
Pass technology is generally using concurrent processing method of trading.
During realizing disclosure design, at least there are the following problems in the prior art: related skill for inventor's discovery
For art during the concurrent processing of data, if exception occurs in some of them operation, the mechanism that withdraws of system can be to these exceptions
Operation is withdrawn, and other normal operatings in parallel can't be withdrawn simultaneously, this will lead to abnormal operation and normal behaviour
It is inconsistent to make obtained data.
Summary of the invention
In view of this, present disclose provides a kind of processing method of data exception, device, calculating equipment and medium.
An aspect of this disclosure provides a kind of processing method of data exception, comprising: determines multiple atomic transactions, institute
State the operation that atomic transaction includes required execution in the parallel process of data;The multiple atomic transaction is executed parallel;?
Before the multiple atomic transaction executes completion, if exception occurs in the operational process of any one of atomic transaction, execute
Withdraw operation;And obtain the operation result of the multiple atomic transaction.
In accordance with an embodiment of the present disclosure, wherein the multiple atomic transaction include memory write operation, database write operations with
And one of file write operation or a variety of.
In accordance with an embodiment of the present disclosure, the above method further include: determine whether the operation result exception occurs;And if
Any one operation result occurs abnormal in the operation result, then executes and withdraw operation.
In accordance with an embodiment of the present disclosure, it includes: to obtain in the multiple atomic transaction except operation that the execution, which withdraws operation,
There are other atomic transactions except abnormal atomic transaction in process;And it executes and is withdrawn corresponding to other described atomic transactions
Sub-operation.
In accordance with an embodiment of the present disclosure, the above method further include: it is whether abnormal that operation is withdrawn described in determining;And if described
Operation exception is withdrawn, then executes Exception handling operation.
In accordance with an embodiment of the present disclosure, the Exception handling operation includes that scene, the life that operation occurs are withdrawn described in record
At warning message and re-executes and described withdraw one of operation or a variety of.
Another aspect of the disclosure provides a kind of processing unit of data exception, including determining module, for determining
Multiple atomic transactions, the atomic transaction include the operation of required execution in the parallel process of data;Execution module is used for
The multiple atomic transaction is executed parallel;First withdraws module, is used for before the multiple atomic transaction executes completion, in office
In the case that exception occurs in the operational process of one atomic transaction of meaning, execution withdraws operation;And module is obtained, for obtaining
Obtain the operation result of the multiple atomic transaction.
In accordance with an embodiment of the present disclosure, above-mentioned apparatus further includes result detection module, for determining that the operation result is
No appearance is abnormal;Second withdraws module, in the case that there is exception in any one operation result in the operation result,
Execution withdraws operation.
Another aspect of the disclosure provides a kind of calculating equipment, comprising: one or more processors;Storage device,
For storing one or more programs, wherein when one or more of programs are executed by one or more of processors,
So that one or more of processors realize method as described above.
Another aspect of the present disclosure provides a kind of computer readable storage medium, is stored with computer executable instructions,
Described instruction is when executed for realizing method as described above.
Another aspect of the present disclosure provides a kind of computer program, and the computer program, which includes that computer is executable, to be referred to
It enables, described instruction is when executed for realizing method as described above.
In accordance with an embodiment of the present disclosure, by the way that in the case where exception occurs in atomic transaction operational process, execution withdraws behaviour
Make, thus by atomic transaction operate object be restored to atomic transaction execute before state, avoid normal atomic transaction with
There is the inconsistent situation of modification of the abnormal atomic transaction to data, guarantees the consistency of data.Meanwhile it is any one wherein
Executing in the case where exception, which occurs, in a atomic transaction withdraws operation, without waiting the execution of other atomic transactions to terminate, therefore
Reduce the response time, improves treatment effeciency.
Detailed description of the invention
By referring to the drawings to the description of the embodiment of the present disclosure, the above-mentioned and other purposes of the disclosure, feature and
Advantage will be apparent from, in the accompanying drawings:
Fig. 1 diagrammatically illustrates the exemplary system of the processing method that can apply data exception according to the embodiment of the present disclosure
System framework;
Fig. 2 diagrammatically illustrates the example flow diagram of the processing method of the data exception according to the embodiment of the present disclosure;
Fig. 3 diagrammatically illustrates the example flow diagram according to an embodiment of the present disclosure for executing and withdrawing operation;
Fig. 4 diagrammatically illustrates the example flow diagram of the processing method of the data exception according to another embodiment of the disclosure;
Fig. 5 diagrammatically illustrates the example flow diagram of the processing method of the data exception according to another embodiment of the disclosure;
Fig. 6 diagrammatically illustrates the example flow diagram of the fund purchase-transaction according to another embodiment of the disclosure;
Fig. 7 diagrammatically illustrates the example block diagram of the processing unit of the data exception according to the embodiment of the present disclosure;
Fig. 8 diagrammatically illustrates the example block diagram of the processing unit of the data exception according to another embodiment of the disclosure;With
And
Fig. 9 is diagrammatically illustrated according to the computer system for being adapted for carrying out method as described above of the embodiment of the present disclosure
Block diagram.
Specific embodiment
Hereinafter, will be described with reference to the accompanying drawings embodiment of the disclosure.However, it should be understood that these descriptions are only exemplary
, and it is not intended to limit the scope of the present disclosure.In the following detailed description, to elaborate many specific thin convenient for explaining
Section is to provide the comprehensive understanding to the embodiment of the present disclosure.It may be evident, however, that one or more embodiments are not having these specific thin
It can also be carried out in the case where section.In addition, in the following description, descriptions of well-known structures and technologies are omitted, to avoid
Unnecessarily obscure the concept of the disclosure.
Term as used herein is not intended to limit the disclosure just for the sake of description specific embodiment.It uses herein
The terms "include", "comprise" etc. show the presence of the feature, step, operation and/or component, but it is not excluded that in the presence of
Or add other one or more features, step, operation or component.
There are all terms (including technical and scientific term) as used herein those skilled in the art to be generally understood
Meaning, unless otherwise defined.It should be noted that term used herein should be interpreted that with consistent with the context of this specification
Meaning, without that should be explained with idealization or excessively mechanical mode.
It, in general should be according to this using statement as " at least one in A, B and C etc. " is similar to
Field technical staff is generally understood the meaning of the statement to make an explanation (for example, " system at least one in A, B and C "
Should include but is not limited to individually with A, individually with B, individually with C, with A and B, with A and C, have B and C, and/or
System etc. with A, B, C).Using statement as " at least one in A, B or C etc. " is similar to, generally come
Saying be generally understood the meaning of the statement according to those skilled in the art to make an explanation (for example, " having in A, B or C at least
One system " should include but is not limited to individually with A, individually with B, individually with C, with A and B, have A and C, have
B and C, and/or the system with A, B, C etc.).
Embodiment of the disclosure provides a kind of processing method of data exception and can apply the device of this method.It should
Method includes: firstly, determining the operation of required execution in parallel process as atomic transaction.Then, these are executed parallel
Atomic transaction.Before the operation of these atomic transactions is completed, if there is exception in the operational process of any one of atomic transaction,
It then executes and withdraws operation.Then, after the completion of these atomic transactions are run, the operation result of these atomic transactions is obtained.
Fig. 1 diagrammatically illustrates the exemplary system of the processing method that can apply data exception according to the embodiment of the present disclosure
System framework 100.It should be noted that being only the example that can apply the system architecture of the embodiment of the present disclosure shown in Fig. 1, to help
Those skilled in the art understand that the technology contents of the disclosure, but it is not meant to that the embodiment of the present disclosure may not be usable for other and set
Standby, system, environment or scene.
As shown in Figure 1, system architecture 100 may include terminal device 101,102,103, network according to this embodiment
104 and server 105.Network 104 between terminal device 101,102,103 and server 105 to provide communication link
Medium.Network 104 may include various connection types, such as wired, wireless communication link or fiber optic cables etc..
User can be used terminal device 101,102,103 and be interacted by network 104 with server 105, to receive transaction
Information or transmission trading instruction etc..Various telecommunication customer end applications, such as net can be installed on terminal device 101,102,103
It goes to bank, fund transaction software etc. (merely illustrative).
Terminal device 101,102,103 can be the various electronic equipments with display screen and supported web page browsing, packet
Include but be not limited to smart phone, tablet computer, pocket computer on knee and desktop computer etc..
Server 105 can be to provide the server of various services, such as utilize terminal device 101,102,103 to user
The website browsed provides the back-stage management server (merely illustrative) supported.Back-stage management server can be to the use received
The data such as family request analyze etc. processing, and by processing result (such as according to user's request or the webpage of generation, believe
Breath or data etc.) feed back to terminal device.
It should be noted that the processing method of data exception provided by the embodiment of the present disclosure generally can be by server
105 execute.Correspondingly, the processing unit of data exception provided by the embodiment of the present disclosure generally can be set in server 105
In.The processing method of data exception provided by the embodiment of the present disclosure can also be by being different from server 105 and can be with terminal
The server or server cluster that equipment 101,102,103 and/or server 105 communicate execute.Correspondingly, the embodiment of the present disclosure
The processing unit of provided data exception also can be set in be different from server 105 and can with terminal device 101,102,
103 and/or server 105 communicate server or server cluster in.
It should be understood that the number of terminal device, network and server in Fig. 1 is only schematical.According to realization need
It wants, can have any number of terminal device, network and server.
Fig. 2 diagrammatically illustrates the example flow diagram of the processing method 200 of data exception according to an embodiment of the present disclosure.
As shown in Fig. 2, this method may include following operation S210~S250.
In operation S210, multiple atomic transactions are determined.
In accordance with an embodiment of the present disclosure, operation S210 for example may include initiating transaction in response to terminal to server and asking
Ask (transaction request such as transaction data inspection, parameter transaction inspection, the update of product amount, processing of opening an account, transaction details registration
Deng), server starts corresponding transaction flow according to transaction request, wherein some processes can carry out parallel, parallel at these
The concrete operations executed in the process of progress are atomic transaction.For example, as shown in table 1 described below, operation
The pre action of WorkA, WorkB, WorkC are all WorkFirst, can concurrently be started after WorkFirst operation
WorkA, WorkB, WorkC, therefore, WorkA, WorkB, WorkC are atomic transaction.It will be understood by those skilled in the art that preceding
It sets operation and refers to that the operation that starting subsequent operation is relied on, subsequent operation refer to that needing to wait for its pre action is all finished
The operation that can start.
Table 1
Pre action | Subsequent operation |
TradeBegin | WorkFirst |
WorkFirst | WorkA |
WorkFirst | WorkB |
WorkFirst | WorkC |
WorkA | WorkEnd |
WorkB | WorkEnd |
WorkC | WorkEnd |
In accordance with an embodiment of the present disclosure, atomic transaction for example may include memory write operation, database write operations and text
One of part write operation is a variety of.
In accordance with an embodiment of the present disclosure, operating the original transaction determined in S210 can be stored in array, so as to subsequent
It searches.Optionally, original transaction also can store in other data structures such as list, and the disclosure is not done this specifically
Restriction.
In operation S220, multiple atomic transactions are executed parallel.
In accordance with an embodiment of the present disclosure, operation S220 for example may include concurrently starting the multiple atoms determined in S210
Affairs, while running these atomic transactions.
Next, determining whether the operational process of any one atomic transaction exception occurs in operation S230.If it is determined that
There is exception, then executes operation S250.Otherwise, operation S240 is executed.Next it will be described in operation 230.
In accordance with an embodiment of the present disclosure, operation S230 for example may include the operation process for monitoring all atomic transactions, when
It listens in the operational process of any one atomic transaction and reports an error, then execute S250, if not reporting an error in operational process, execute
S240。
In operation S240, the operation result of multiple atomic transactions is obtained.
In accordance with an embodiment of the present disclosure, the operation result of atomic transaction may include success or failure.For example, if atom thing
Business is write operation, then its operation result is whether to successfully complete write operation.It in accordance with an embodiment of the present disclosure, can be according to original
The return value of function is executed corresponding to subtransaction to determine the operation result of the atomic transaction.For example, if function return value is
SUCCESS, then it represents that operation result is that successfully, otherwise, expression operation result is failure.
In operation S250, execution withdraws operation.
In accordance with an embodiment of the present disclosure, operation S250 for example may include the change for being done above-mentioned all atomic transactions
It withdraws, to be restored to the state before atomic transaction executes.
According to the embodiment of the present disclosure, it can realize that the execution of operation S250 withdraws operation according to following scheme.Fig. 3 signal
Property show according to an embodiment of the present disclosure execute and withdraw the example flow diagram of operation.
As shown in figure 3, operation S250 may further include following operation S251~S252.
In operation S251, other originals in multiple atomic transactions in addition to abnormal atomic transaction occurs in operational process are obtained
Subtransaction.
In accordance with an embodiment of the present disclosure, operation S251 for example may include looking into the array for storing all atomic transactions
Find out other atomic transactions except existing abnormal atomic transaction.
Next, executing in operation S252 and withdrawing sub-operation corresponding to other atomic transactions.
In accordance with an embodiment of the present disclosure, the reverse operating that sub-operation is atomic transaction is withdrawn, being used for will be by the atomic transaction
The object of operation is restored to by the state before operating.Such as atomic transaction is that numerical value A is written in memory, then its corresponding time
Remove the numerical value A that write-in is deleted in sub-operation position.In another example atomic transaction is that the numerical value B in database is revised as C, then its is corresponding
Withdrawing sub-operation is that C is modified back B.In accordance with an embodiment of the present disclosure, letter can be withdrawn accordingly for each atomic transaction is default
Number withdraws function corresponding to atomic transaction by calling, object operated by atomic operation is restored to and executes the atom
State before operation.
It is further to note that, for there is abnormal atomic transaction, can be carried in the present embodiment with calling system
Exception handling is withdrawn.It will be understood by those skilled in the art that various technologies can be used to realize exception handler
System is withdrawn, and the embodiment of the present disclosure is limited not to this.
In accordance with an embodiment of the present disclosure, by the way that in the case where exception occurs in atomic transaction operational process, execution withdraws behaviour
Make, so that the object that atomic transaction operates is restored to the state before atomic transaction executes, to avoid normal atom thing
The business situation inconsistent with there is modification of the abnormal atomic transaction to data, guarantees the consistency of data.Meanwhile appointing wherein
Executing in the case where exception, which occurs, in atomic transaction of anticipating withdraws operation, without waiting the execution of other atomic transactions to terminate,
Therefore reduce the response time, improve treatment effeciency.
Fig. 4 diagrammatically illustrates the example flow of the processing method 400 of the data exception according to another embodiment of the disclosure
Figure.
As shown in figure 4, unlike the processing method 200 of data exception shown in Fig. 2, in addition to operating S210~S250
It in addition, can also include operation S460 according to the processing method 400 of the data exception of another embodiment of the disclosure.
After step S240 for example shown in Fig. 2 obtains the operation result of multiple atomic transactions, operation can also be performed
S460.In operation S460, determine whether operation result exception occurs, any one operation result occurs abnormal in operation result
In the case where, jump execution operation S250.
In accordance with an embodiment of the present disclosure, indicate that operation result appearance is different if the operation result of atomic transaction is failure
Often.
In accordance with an embodiment of the present disclosure, determine occur in operation result different by the operation result to atomic transaction
It is executed when often and withdraws operation, the object that atomic transaction operates is restored to the state before atomic transaction executes, to avoid just
Normal atomic transaction and the atomic transaction for exception occur modify inconsistent situation to data, guarantee the consistency of data.
Fig. 5 diagrammatically illustrates the example flow diagram of the processing method of the data exception according to another embodiment of the disclosure.
As shown in figure 5, unlike the processing method 200 of data exception shown in Fig. 4, in addition to operating S210~S250
It can also include following operation according to the processing method 500 of the data exception of another embodiment of the disclosure and other than S460
S570~S580.
In operation S570, determine to withdraw operate whether exception executes S580 in the case where withdrawing operation exception.According to
Embodiment of the disclosure, can by monitor withdraw operation called it is each withdraw whether function operation reports an error, and return
Judge whether successfully to return to original state the object that atomic transaction operates to determine and withdraw operation after removing function operation
It is whether abnormal.If withdrawing, function reports an error or object does not recover to original state, then it represents that withdraws operation exception.
In operation S580, Exception handling operation is executed.
In accordance with an embodiment of the present disclosure, the Exception handling operation includes the scene letter for withdrawing operation described in record and occurring
Breath, scene information is for example including the information such as the atomic transaction ID being abnormal and the contextual information of corresponding transaction.
In other embodiments of the disclosure, Exception handling operation can also include generating warning message or again
Operation etc. is withdrawn described in new execution.
In accordance with an embodiment of the present disclosure, it by the way that operation is withdrawn, whether exception is detected, and when withdrawing unsuccessfully, executes
Corresponding Exception handling operation, so as to reduce adverse effect caused by withdrawing failure.
It will be understood by those skilled in the art that in further embodiments, the processing method 500 of data exception can not also
Comprising S460, only comprising operation S210~S250 and operation S570~S580.
The technical solution of the embodiment of the present disclosure in order to facilitate understanding, below with reference to Fig. 6, the process with fund purchase-transaction is
Example, illustrates the processing method of the above-mentioned data exception of the disclosure.It will be understood by those skilled in the art that fund purchase shown in fig. 6
The process of transaction is merely illustrative, and the embodiment of the present disclosure is not limited to this.
As shown in fig. 6, in operation S601: determining that fund buys 3 atomic transactions for needing concurrently to execute: blacklist inspection
It looks into, fund transaction limit updates, fund point family updates.
In operation S602, concurrently start blacklist inspection, fund transaction limit updates, fund point family updates.
In operation S603, whether the operational process that monitoring blacklist inspection, the update of fund transaction limit, fund divide family to update
It is abnormal.If blacklist inspection, fund transaction limit update, fund divides family operation all normal, S604 is executed, otherwise, is executed
S607。
Next, obtaining the operation result of each atomic transaction in operation S604.
Then, in operation S605, operation result is determined, if blacklist inspection, fund transaction limit update, base
Gold point family more new capital is processed into function, then executes S606, otherwise execute S607.
In operation S606, the next step process traded.
In operation S607, starting affairs withdraw operation.
In operation S608, the update of fund transaction limit is concurrently executed with what fund point family updated and withdraws sub-operation.
It should be noted that due to blacklist inspection operation only related data is read, not to data into
Row change operation, therefore withdrawn in the present embodiment without being executed for blacklist inspection operation.
In operation S609, whether what the update of monitoring fund transaction limit and fund point family updated withdraws sub-operation abnormal.Such as
Fruit withdraws normally, then executes S611, otherwise, executes S609.
In operation S610, starting is abnormal to withdraw Exception handling operation, the transaction data of recording exceptional.
Then, in operation S611, the next step process traded.
Fig. 7 diagrammatically illustrates the block diagram of the processing unit of data exception according to an embodiment of the present disclosure.
As shown in fig. 7, device 700 withdraws module 730 including determining module 710, execution module 720, first and obtains mould
Block 740.
Determining module 710, for determining that multiple atomic transactions, the atomic transaction include in the parallel process of data
The operation of required execution.
Execution module 720, for executing multiple atomic transactions parallel.
First withdraws module 730, is used for before multiple atomic transactions execute completion, in the fortune of any one atomic transaction
In the case that exception occurs in row process, execution withdraws operation.
Module 740 is obtained, for obtaining the operation result of multiple atomic transactions.
In accordance with an embodiment of the present disclosure, by the way that in the case where exception occurs in atomic transaction operational process, execution withdraws behaviour
Make, so that the object that atomic transaction operates is restored to the state before atomic transaction executes, to avoid normal atom thing
The business situation inconsistent with there is modification of the abnormal atomic transaction to data, guarantees the consistency of data.Meanwhile appointing wherein
Executing in the case where exception, which occurs, in atomic transaction of anticipating withdraws operation, without waiting the execution of other atomic transactions to terminate,
Therefore reduce the response time, improve treatment effeciency.
Fig. 8 diagrammatically illustrates the block diagram of the processing unit of the data exception according to another embodiment of the disclosure.
As shown in figure 8, the determining module 710 shown in Fig. 7 of device 800, execution module 720, first withdrawing 730 and of module
It further include result detection module 840, for determining whether operation result exception occurs on the basis of obtaining module 740;And the
Two withdraw module 850, in the case that exception occurs in any one operation result in multiple operation results, execution to withdraw behaviour
Make.
In accordance with an embodiment of the present disclosure, determine occur in operation result different by the operation result to atomic transaction
It is executed when often and withdraws operation, the object that atomic transaction operates is restored to the state before atomic transaction executes, to avoid just
Normal atomic transaction and the atomic transaction for exception occur modify inconsistent situation to data, guarantee the consistency of data.
It is module according to an embodiment of the present disclosure, submodule, unit, any number of or in which any more in subelement
A at least partly function can be realized in a module.It is single according to the module of the embodiment of the present disclosure, submodule, unit, son
Any one or more in member can be split into multiple modules to realize.According to the module of the embodiment of the present disclosure, submodule,
Any one or more in unit, subelement can at least be implemented partly as hardware circuit, such as field programmable gate
Array (FPGA), programmable logic array (PLA), system on chip, the system on substrate, the system in encapsulation, dedicated integrated electricity
Road (ASIC), or can be by the hardware or firmware for any other rational method for integrate or encapsulate to circuit come real
Show, or with any one in three kinds of software, hardware and firmware implementations or with wherein any several appropriately combined next reality
It is existing.Alternatively, can be at least by part according to one or more of the module of the embodiment of the present disclosure, submodule, unit, subelement
Ground is embodied as computer program module, when the computer program module is run, can execute corresponding function.
For example, determining module 710, execution module 720, first withdraw module 730, obtain module 740, result detection module
840 and second withdraw module 850 any number of may be incorporated in a module realize or any one mould therein
Block can be split into multiple modules.Alternatively, at least partly function of one or more modules in these modules can be with it
He combines at least partly function of module, and realizes in a module.In accordance with an embodiment of the present disclosure, determining module 710,
Execution module 720, first withdraw module 730, obtain module 740, obtain submodule 810, withdraw the detection of submodule 820, first
Module 910, second withdraw at least one of module 920, the second detection module 1010 and Exception handling module 1020 can be with
At least it is implemented partly as hardware circuit, such as field programmable gate array (FPGA), programmable logic array (PLA), piece
The system in system, encapsulation, specific integrated circuit (ASIC) in upper system, substrate, or can be by being integrated to circuit
Or the hardware such as any other rational method or firmware of encapsulation are realized, or with three kinds of software, hardware and firmware realization sides
Any one in formula several appropriately combined is realized with wherein any.Alternatively, determining module 710, execution module 720,
One withdraw module 730, obtain module 740, result detection module 840 and second withdraw at least one of module 850 can be with
It is at least implemented partly as computer program module, when the computer program module is run, corresponding function can be executed
Energy.
Fig. 9 is diagrammatically illustrated according to the computer system for being adapted for carrying out method as described above of the embodiment of the present disclosure
Block diagram.Computer system shown in Fig. 9 is only an example, should not function and use scope band to the embodiment of the present disclosure
Carry out any restrictions.
As shown in figure 9, computer system 900 includes processor 910, computer readable storage medium 920, sender unit
930 and signal receiver 940.The computer system 900 can execute the method according to the embodiment of the present disclosure.
Specifically, processor 910 for example may include general purpose microprocessor, instruction set processor and/or related chip group
And/or special microprocessor (for example, specific integrated circuit (ASIC)), etc..Processor 910 can also include using for caching
The onboard storage device on way.Processor 910 can be the different movements for executing the method flow according to the embodiment of the present disclosure
Single treatment unit either multiple processing units.
Computer readable storage medium 920, such as can be non-volatile computer readable storage medium, specific example
Including but not limited to: magnetic memory apparatus, such as tape or hard disk (HDD);Light storage device, such as CD (CD-ROM);Memory, such as
Random access memory (RAM) or flash memory;Etc..
Computer readable storage medium 920 may include computer program 921, which may include generation
Code/computer executable instructions execute processor 910 according to the embodiment of the present disclosure
Method or its any deformation.
Computer program 921 can be configured to have the computer program code for example including computer program module.Example
Such as, in the exemplary embodiment, the code in computer program 921 may include one or more program modules, for example including
921A, module 921B ....It should be noted that the division mode and number of module are not fixation, those skilled in the art can
To be combined according to the actual situation using suitable program module or program module, when these program modules are combined by processor 910
When execution, processor 910 is executed according to the method for the embodiment of the present disclosure or its any deformation.
In accordance with an embodiment of the present disclosure, processor 910 can be handed over sender unit 930 and signal receiver 940
Mutually, it executes according to the method for the embodiment of the present disclosure or its any deformation.
According to an embodiment of the invention, determining module 710, execution module 720, first withdraw module 730, obtain module
740, result detection module 840 and second withdraw at least one of module 850 can be implemented as with reference to Fig. 9 description calculating
Corresponding operating described above may be implemented when being executed by processor 910 in machine program module.
The disclosure additionally provides a kind of computer readable storage medium, which can be above-mentioned reality
It applies included in equipment/device/system described in example;Be also possible to individualism, and without be incorporated the equipment/device/
In system.Above-mentioned computer readable storage medium carries one or more program, when said one or multiple program quilts
When execution, the method according to the embodiment of the present disclosure is realized.
In accordance with an embodiment of the present disclosure, computer readable storage medium can be non-volatile computer-readable storage medium
Matter, such as can include but is not limited to: portable computer diskette, hard disk, random access storage device (RAM), read-only memory
(ROM), erasable programmable read only memory (EPROM or flash memory), portable compact disc read-only memory (CD-ROM), light
Memory device, magnetic memory device or above-mentioned any appropriate combination.In the disclosure, computer readable storage medium can
With to be any include or the tangible medium of storage program, the program can be commanded execution system, device or device use or
Person is in connection.
Flow chart and block diagram in attached drawing are illustrated according to the system of the various embodiments of the disclosure, method and computer journey
The architecture, function and operation in the cards of sequence product.In this regard, each box in flowchart or block diagram can generation
A part of one module, program segment or code of table, a part of above-mentioned module, program segment or code include one or more
Executable instruction for implementing the specified logical function.It should also be noted that in some implementations as replacements, institute in box
The function of mark can also occur in a different order than that indicated in the drawings.For example, two boxes succeedingly indicated are practical
On can be basically executed in parallel, they can also be executed in the opposite order sometimes, and this depends on the function involved.Also it wants
It is noted that the combination of each box in block diagram or flow chart and the box in block diagram or flow chart, can use and execute rule
The dedicated hardware based systems of fixed functions or operations is realized, or can use the group of specialized hardware and computer instruction
It closes to realize.
It will be understood by those skilled in the art that the feature recorded in each embodiment and/or claim of the disclosure can
To carry out multiple combinations and/or combination, even if such combination or combination are not expressly recited in the disclosure.Art technology
Personnel it should be understood that in the case where the spirit and scope of the present disclosure limited without departing substantially from the following claims and their equivalents,
A variety of changes in form and details can be carried out to the disclosure.Therefore, the scope of the present disclosure should not necessarily be limited by above-described embodiment,
But should be not only determined by appended claims, also it is defined by the equivalent of appended claims.
Claims (10)
1. a kind of processing method of data exception, comprising:
Determine that multiple atomic transactions, the atomic transaction include the operation of required execution in the parallel process of data;
The multiple atomic transaction is executed parallel;
Before the multiple atomic transaction executes completion, if there is exception in the operational process of any one of atomic transaction,
It then executes and withdraws operation;And
Obtain the operation result of the multiple atomic transaction.
2. according to the method described in claim 1, wherein, the multiple atomic transaction includes memory write operation, database write behaviour
One of work and file write operation are a variety of.
3. according to the method described in claim 1, further include:
Determine whether the operation result exception occurs;And
If any one operation result occurs abnormal in the operation result, execution withdraws operation.
4. according to the method in any one of claims 1 to 3, the execution withdraws operation and includes:
Obtain other atomic transactions in the multiple atomic transaction in addition to abnormal atomic transaction occurs in operational process;And
It executes and withdraws sub-operation corresponding to other described atomic transactions.
5. according to the method in any one of claims 1 to 3, further includes:
It is whether abnormal that operation is withdrawn described in determination;And
If described withdraw operation exception, Exception handling operation is executed.
6. according to the method described in claim 5, wherein, the Exception handling operation includes withdrawing what operation occurred described in record
Scene generates warning message and re-executes and described withdraws one of operation or a variety of.
7. a kind of processing unit of data exception, comprising:
Determining module, for determining that multiple atomic transactions, the atomic transaction include required in the parallel process of data hold
Capable operation;
Execution module, for executing the multiple atomic transaction parallel;
First withdraws module, is used for before the multiple atomic transaction executes completion, in any one of atomic transaction
In the case that exception occurs in operational process, execution withdraws operation;And
Module is obtained, for obtaining the operation result of the multiple atomic transaction.
8. device according to claim 7, further includes:
As a result detection module, for determining whether the operation result exception occurs;And
Second withdraws module, for executing back in the case that exception occurs in any one operation result in the operation result
Remove operation.
9. a kind of calculating equipment, comprising:
One or more processors;
Storage device, for storing one or more programs,
Wherein, when one or more of programs are executed by one or more of processors, so that one or more of
The method that processor realizes any one of claims 1 to 6.
10. a kind of computer readable storage medium, is stored thereon with executable instruction, which makes to handle when being executed by processor
The method that device realizes any one of claims 1 to 6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910625782.0A CN110347533A (en) | 2019-07-11 | 2019-07-11 | The processing method of data exception, calculates equipment and medium at device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910625782.0A CN110347533A (en) | 2019-07-11 | 2019-07-11 | The processing method of data exception, calculates equipment and medium at device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN110347533A true CN110347533A (en) | 2019-10-18 |
Family
ID=68175034
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910625782.0A Pending CN110347533A (en) | 2019-07-11 | 2019-07-11 | The processing method of data exception, calculates equipment and medium at device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110347533A (en) |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101689138A (en) * | 2007-06-27 | 2010-03-31 | 微软公司 | Handling falsely doomed parents of nested transactions |
CN102156700A (en) * | 2010-02-12 | 2011-08-17 | 华为技术有限公司 | Database accessing method and device and system |
CN105512244A (en) * | 2015-11-30 | 2016-04-20 | 北京京东尚科信息技术有限公司 | Database transaction processing method and device based on message queue |
CN106775959A (en) * | 2016-12-06 | 2017-05-31 | 上海亿账通互联网科技有限公司 | Distributed transaction processing method and system |
CN106970846A (en) * | 2017-03-15 | 2017-07-21 | 北京驰波信息工程有限公司 | Payment system message is controlled and processing method, device |
CN107203560A (en) * | 2016-03-18 | 2017-09-26 | 中国移动通信集团宁夏有限公司 | Database, multiple database operation transaction consistency ensuring method and system |
CN108874587A (en) * | 2018-06-06 | 2018-11-23 | 亚信科技(中国)有限公司 | A kind of the final consistency support method and system of affairs |
CN109324925A (en) * | 2018-08-29 | 2019-02-12 | 北京仁科互动网络技术有限公司 | The transaction methods and device of Distributed Architecture |
-
2019
- 2019-07-11 CN CN201910625782.0A patent/CN110347533A/en active Pending
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101689138A (en) * | 2007-06-27 | 2010-03-31 | 微软公司 | Handling falsely doomed parents of nested transactions |
CN102156700A (en) * | 2010-02-12 | 2011-08-17 | 华为技术有限公司 | Database accessing method and device and system |
CN105512244A (en) * | 2015-11-30 | 2016-04-20 | 北京京东尚科信息技术有限公司 | Database transaction processing method and device based on message queue |
CN107203560A (en) * | 2016-03-18 | 2017-09-26 | 中国移动通信集团宁夏有限公司 | Database, multiple database operation transaction consistency ensuring method and system |
CN106775959A (en) * | 2016-12-06 | 2017-05-31 | 上海亿账通互联网科技有限公司 | Distributed transaction processing method and system |
CN106970846A (en) * | 2017-03-15 | 2017-07-21 | 北京驰波信息工程有限公司 | Payment system message is controlled and processing method, device |
CN108874587A (en) * | 2018-06-06 | 2018-11-23 | 亚信科技(中国)有限公司 | A kind of the final consistency support method and system of affairs |
CN109324925A (en) * | 2018-08-29 | 2019-02-12 | 北京仁科互动网络技术有限公司 | The transaction methods and device of Distributed Architecture |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9442832B2 (en) | User workflow replication for execution error analysis | |
CN111611145B (en) | Breakdown information collection method and device, storage medium and electronic equipment | |
CN110515795A (en) | A kind of monitoring method of big data component, device, electronic equipment | |
CN110471754A (en) | Method for exhibiting data, device, equipment and storage medium in job scheduling | |
CN110244951B (en) | Application publishing method and device | |
US9461884B2 (en) | Information management device and computer-readable medium recorded therein information management program | |
CN109408361A (en) | Monkey tests restored method, device, electronic equipment and computer readable storage medium | |
CN110019063B (en) | Method for computing node data disaster recovery playback, terminal device and storage medium | |
JP5773493B2 (en) | Information processing device | |
CN113312259B (en) | Interface testing method and device | |
CN112860412B (en) | Service data processing method and device, electronic equipment and storage medium | |
US9405786B2 (en) | System and method for database flow management | |
CN110908644B (en) | Configuration method and device of state node, computer equipment and storage medium | |
US11243742B2 (en) | Data merge processing based on differences between source and merged data | |
CN109582476B (en) | Data processing method, device and system | |
CN109324867A (en) | A kind of virtual machine temporary storage method, restoration methods and device | |
WO2018022303A1 (en) | Capturing commands in a multi-engine graphics processing unit | |
CN110347533A (en) | The processing method of data exception, calculates equipment and medium at device | |
US9286349B2 (en) | Dynamic search system | |
CN115237889A (en) | Database switching method and device, storage medium and computer equipment | |
CN111221817B (en) | Service information data storage method, device, computer equipment and storage medium | |
CN107705089B (en) | Service processing method, device and equipment | |
CN111639057A (en) | Log message processing method and device, computer equipment and storage medium | |
CN110264211B (en) | Wind control method, system, device and equipment | |
JP2010181924A (en) | Database management method, database management device, and its processing program |
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: 20191018 |
|
RJ01 | Rejection of invention patent application after publication |