CN104077111B - The concurrent access control method and device of business operation - Google Patents

The concurrent access control method and device of business operation Download PDF

Info

Publication number
CN104077111B
CN104077111B CN201410284930.4A CN201410284930A CN104077111B CN 104077111 B CN104077111 B CN 104077111B CN 201410284930 A CN201410284930 A CN 201410284930A CN 104077111 B CN104077111 B CN 104077111B
Authority
CN
China
Prior art keywords
lock
application
business
accesses
access
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.)
Active
Application number
CN201410284930.4A
Other languages
Chinese (zh)
Other versions
CN104077111A (en
Inventor
祁宏伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
You Pu Information Technology Co Ltd Of Ufsoft
Original Assignee
You Pu Information Technology Co Ltd Of Ufsoft
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by You Pu Information Technology Co Ltd Of Ufsoft filed Critical You Pu Information Technology Co Ltd Of Ufsoft
Priority to CN201410284930.4A priority Critical patent/CN104077111B/en
Publication of CN104077111A publication Critical patent/CN104077111A/en
Application granted granted Critical
Publication of CN104077111B publication Critical patent/CN104077111B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

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

Abstract

The invention provides a kind of concurrent access control method of business operation, including:The operation requests that service end is sent based on client, the control for accessing lock is placed on single business procession;Service end is based on presetting business operation corresponding with the operation requests in multiple business operations, and classification application accesses lock;Service end performs corresponding operating based on the application result for accessing lock.Present invention also offers a kind of Parallel access control device of business operation.Pass through technical scheme, can be on the basis of the Parallel access control mode of existing business operation, make full use of the access control of single business operation to complete the Parallel access control of multi-service operation, establish general, the unified access control thinking of the Parallel access control towards multi-service operation that single business operation participates in.

Description

The concurrent access control method and device of business operation
Technical field
The present invention relates to field of computer technology, in particular it relates to a kind of concurrent access control method of business operation and A kind of Parallel access control device of business operation.
Background technology
In the system that many management softwares are applied, the concurrently access operation of data is directed to.Concurrently accessing is Refer to same data or there are the more datas of correlation by multiple operations while access, at this time, it is necessary to pass through Parallel access control Technology solves, so as to prevent from producing between multiple operations influencing each other.
For example, when One function is ongoing, it may be necessary to load some data to calculate and influence and change Other data, at this time, if other feature operations are also required to change these related datas simultaneously, it is possible to cause number occur According to the situation of disorderly or dirty reading.The problem of concurrently accessing operation is there is between the two or multiple functions.
At present, it is common to use mode is using the lock mechanism of database itself or the increase application visit in business operation Ask that the mode of lock controls to carry out the service concurrence of coarseness.The Parallel access control generally used is by database itself Lock mechanism realizes that in the case where multi-user exists and concurrently accessed, database provides a set of lock mechanism, by accessed Data on lock, and allow other concurrent operations to wait in line, to prevent data while be changed.
The shortcomings that this mode is first way be:It can only be locked to accessing modification identical data, it is impossible to more Identical or related service influences and the batch of data of modification locks, and is not suitable for the slightly complicated service application of a bit.
The second way is to carry out application in server end by the function that the request to user performs to access lock, is visited The management of lock is asked, if applying successfully, continuing through access data progress business and performing the request.If application failure, Application server directly returns to the message that request can not be processed.
For example, in patent(Application)Number be 200810161293.6 patent(Application)In document, disclose a kind of concurrent Access control method and device, database burden exacerbation be present to solve current Database lock mechanism, easily produce deadlock Problem.The concurrent access control method includes:Received server-side access request;Confirm whether the request needs application to access Lock, if it is, application accesses lock;Locked successfully if application accesses, the request is performed by accessing database;When the request After being finished, discharge described access and lock.The concurrent access control method and device provide the lock of a set of application level rank Parallel access control at application server end, is asked just to be employed server end before database is reached by mechanism, the mechanism Filtered, filtered out concurrent request.Therefore, multi-user, exist concurrently access in the case of effectively control data Concurrently access with modification, the load of database can be mitigated, and can effectively reduce the abnormal feelings such as deadlock, the wait of database Condition.
But the shortcomings that this mode is the second way is:It is excessively thick to access the granularity of lock, if concurrent user's amount is more In the case of, it is very easy to occur constantly asking the mistake that can not be processed, influences the use of user.
Therefore, it is necessary to a kind of Parallel access control technology of new business operation, can existing business operation and On the basis of sending out access control scheme, the access control of single business operation is made full use of to complete the concurrently access control of multi-service operation System, establish general, the unified access control thinking of the Parallel access control towards multi-service operation that single business operation participates in.
The content of the invention
The present invention is based on above mentioned problem, it is proposed that a kind of Parallel access control technology of new business operation, can be with On the basis of the Parallel access control mode of existing business operation, the access control of single business operation is made full use of to complete more industry Be engaged in the Parallel access control of operation, establish the Parallel access control towards multi-service operation that single business operation participates in it is general, Unified access control thinking.
In view of this, the present invention proposes a kind of concurrent access control method of business operation, including:Step 102:Service The operation requests that end group is sent in client, the control for accessing lock is placed on single business procession;Step 104:Service In presetting business operation corresponding with the operation requests in multiple business operations, classification application accesses locks end group;Step 106:Service end performs corresponding operating based on the application result for accessing lock.In the technical scheme, pass through the refinement to accessing lock Control, can greatly reduce the concurrent access conflict of business, it is also possible to bring good usage experience to user.
In the above-mentioned technical solutions, it is preferable that the step 102 specifically includes:Step 202:Client sends operation please Ask, service end receives the operation requests that client is sent;Step 204:Service end performs the operation requests phase sent with client Corresponding current business, the current business correspondingly preset a business operation in multiple business operations.In the technical scheme, By the way that the control for accessing lock is placed on single business procession, it can become shorter the time of locking, and make user Between there is access conflict situation be minimized.
In the above-mentioned technical solutions, it is preferable that the step 104 specifically includes:Step 206:Service end is based on currently holding Business operation corresponding to industry business, application access lock;Further, the service end is based on business corresponding to current execution business Operation, application access the flow of lock, in addition to:When the operation that this application accesses lock is read lock operation, judge whether existing The access is locked:If in the presence of the operation for writing lock, this application accesses the operation failure of lock;If the operation of read lock be present or in the absence of this When accessing lock, then this application accesses the operation success of lock, increases the lock information corresponding with the operation that this application accesses lock;When this The operation that application accesses lock is when writing lock operation, judges whether existing access lock:If in the presence of the operation for writing lock or reading be present The operation failure of the operation of lock, then this application access lock;If in the absence of the access lock, this application access lock operation into Work(, increase the lock information corresponding with the operation that this application accesses lock.In the technical scheme, the classification refinement of lock is accessed, point For read lock and lock is write, when carrying out read lock operation, correlation does not conflict multiple business operations.
In the above-mentioned technical solutions, it is preferable that the step 106 specifically includes:Step 208:When access lock is applied successfully, The business operation, which performs, accesses database;Step 210:At the end of the business operation accesses database, release accesses lock.In the skill In art scheme, when business operation in due course in do not clash when, business is normally carried out.
In the above-mentioned technical solutions, it is preferable that the step 106 specifically also includes:Step 212:Access lock application failure When, after service end waits preset duration, retry automatically and apply accessing lock preset times, apply accessing the result locked according to retrying, Perform step 214 or perform step 2161;Step 214:Locked successfully if retrying application in preset times and accessing, business behaviour It is normally carried out;Step 216:If it is unsuccessful that application access lock is retried in preset times, current operation is returned to client The message that request conflicts with the operation of other users, just a moment,please performs;Step 218:The monitoring interface that client passes through application lock Display and the corresponding application situation for accessing lock of management, operate for corresponding service and perform the in the case of of failure, allow user oneself Lock is accessed corresponding to coming and is managed operation.In the technical scheme, by after error, carry out waiting very little when Between, and the mode that application again accesses lock is carried out, automatically to be retried, can not go out under conflict situations between reaching in due course Mistake, business are normally carried out;And in the case of long-time conflicts, after the predetermined number of times of configuration is retried, just return to request and its The operation conflict of its user, the message that just a moment,please performs;Meanwhile shown and managed by providing the monitoring interface for applying locking The application situation of lock is managed, the special circumstances to be broken down for system, to allow user oneself to be managed operation to lock.
According to a further aspect of the invention, it is also proposed that a kind of Parallel access control device of business operation, including:It is single Individual Service Processing Unit, the operation requests sent for service end based on client, the control for accessing lock is placed on single industry Business processing procedure;Lock classification application unit is accessed, being based on presetting for service end please with the operation in multiple business operations Corresponding business operation is sought, classification application accesses lock;Lock application result execution unit is accessed, is based on accessing for service end The application result of lock, perform corresponding operating.In the technical scheme, by controlling the refinement for accessing lock, it can greatly reduce The concurrent access conflict of business, it is also possible to bring good usage experience to user.
In the above-mentioned technical solutions, it is preferable that the single Service Processing Unit, specifically include:Operation requests receive and dispatch mould Block, operation requests are sent for client, service end receives the operation requests that client is sent;Current business execution module, use The current business corresponding with the operation requests that client is sent is performed in service end, the current business correspondingly presets multiple business A business operation in operation.In the technical scheme, by the way that the control for accessing lock is placed on into single business procession On, it can become shorter the time of locking, and the situation for making access conflict occur between user is minimized.
In the above-mentioned technical solutions, it is preferable that it is described to access lock classification application unit, specifically include:Access lock Shen Please module, be based on business operation corresponding to current execution business for service end, application accesses lock;Read lock module, should for working as When the operation that application accesses lock is read lock operation, judge whether existing access lock:If in the presence of the operation for writing lock, this application Access the operation failure of lock;If the operation of read lock be present or locked in the absence of the access, this application accesses the operation success of lock, Increase the lock information corresponding with the operation that this application accesses lock;Lock module is write, the operation for accessing lock when this application is to write During lock operation, judge whether existing access lock:If in the presence of writing the operation of lock or the operation of read lock being present, this application accesses The operation failure of lock;If during in the absence of access lock, this application accesses the operation success of lock, increase accesses lock with this application Operate corresponding lock information;Lock application result feedback module is accessed, for based on read lock module and the processing knot for writing lock module Fruit, fed back to lock application result execution unit is accessed.In the technical scheme, the classification refinement of lock is accessed, is divided into read lock With writing lock, when carrying out read lock operation, correlation does not conflict multiple business operations.
In the above-mentioned technical solutions, it is preferable that it is described to access lock application result execution unit, specifically include:Access lock Shen Processing module when please succeed, when applying successfully for accessing lock, the business operation, which performs, accesses database;And for this At the end of business operation accesses database, release accesses lock.In the technical scheme, do not sent out when business operation is interior in due course During raw conflict, business is normally carried out.
In the above-mentioned technical solutions, it is preferable that it is described to access lock application result execution unit, specifically also include:Access lock Processing module during application failure, when locking application failure for accessing, after service end waits preset duration, application is retried automatically and is visited Lock preset times are asked, according to the result for retrying application access lock, perform following operate:If retry application in preset times to access Lock successfully, then the business operation is normally carried out;If it is unsuccessful that application access lock is retried in preset times, returned to client The message that current operation request conflicts with the operation of other users, just a moment,please performs;The monitoring interface that client passes through application lock Display and the corresponding application situation for accessing lock of management, operate for corresponding service and perform the in the case of of failure, allow user oneself Lock is accessed corresponding to coming and is managed operation.In the technical scheme, by after error, carry out waiting very little when Between, and the mode that application again accesses lock is carried out, automatically to be retried, can not go out under conflict situations between reaching in due course Mistake, business are normally carried out;And in the case of long-time conflicts, after the predetermined number of times of configuration is retried, just return to request and its The operation conflict of its user, the message that just a moment,please performs;Meanwhile shown and managed by providing the monitoring interface for applying locking The application situation of lock is managed, the special circumstances to be broken down for system, to allow user oneself to be managed operation to lock.
, can be fully sharp on the basis of the Parallel access control mode of existing business operation by above technical scheme Complete the Parallel access control that multi-service operates with the access control of single business operation, establish that single business operation participates in towards more General, the unified access control thinking of the Parallel access control of business operation.
Brief description of the drawings
Fig. 1 shows the flow chart of the concurrent access control method of business operation according to an embodiment of the invention;
Fig. 2 shows the detail flowchart of the concurrent access control method of business operation according to an embodiment of the invention;
Fig. 3 shows the process chart according to an embodiment of the invention for accessing lock application failure;
Fig. 4 shows the classification refined flow chart according to an embodiment of the invention for accessing lock;
Fig. 5 shows the block diagram of the Parallel access control device of business operation according to an embodiment of the invention.
Embodiment
It is below in conjunction with the accompanying drawings and specific real in order to be more clearly understood that the above objects, features and advantages of the present invention Mode is applied the present invention is further described in detail.It should be noted that in the case where not conflicting, the implementation of the application Feature in example and embodiment can be mutually combined.
Many details are elaborated in the following description to facilitate a thorough understanding of the present invention, still, the present invention may be used also To be different from other modes described here using other to implement, therefore, protection scope of the present invention is not by described below Specific embodiment limitation.
Fig. 1 shows the flow chart of the concurrent access control method of business operation according to an embodiment of the invention.
As shown in figure 1, the concurrent access control method of business operation according to an embodiment of the invention, including:Step 102:The operation requests that service end is sent based on client, the control for accessing lock is placed on single business procession;Step 104:Service end is based on presetting business operation corresponding with the operation requests in multiple business operations, and classification application accesses Lock;Step 106:Service end performs corresponding operating based on the application result for accessing lock.In the technical scheme, by accessing The refinement control of lock, can greatly reduce the concurrent access conflict of business, it is also possible to bring good use body to user Test.
In the above-mentioned technical solutions, it is preferable that as shown in Figure 2 and Figure 4, step 102 specifically includes:Step 202:Client Operation requests are sent, service end receives the operation requests that client is sent;Step 204:Service end performs what is sent with client The corresponding current business of operation requests, the current business correspondingly preset a business operation in multiple business operations.At this In technical scheme, by the way that the control for accessing lock is placed on single business procession, the time of locking can be made become more It is short, and the situation for making access conflict occur between user is minimized.
In the above-mentioned technical solutions, it is preferable that as shown in Figure 2 and Figure 4, step 104 specifically includes:Step 206:Service end Based on business operation corresponding to current execution business, application accesses lock;Further, it is corresponding to be based on current execution business for service end Business operation, application access lock flow, in addition to:When the operation that this application accesses lock is read lock operation, judge whether Existing access lock:If in the presence of the operation for writing lock, this application accesses the operation failure of lock;If the operation or not of read lock be present When being locked in the presence of the access, then this application accesses the operation success of lock, increases the lock corresponding with the operation that this application accesses lock and believes Breath;When the operation that this application accesses lock is to write lock operation, judge whether existing access lock:If in the presence of the operation for writing lock or The operation of read lock be present, then this application accesses the operation failure of lock;If during in the absence of access lock, this application accesses the behaviour of lock Succeed, increase the lock information corresponding with the operation that this application accesses lock.In the technical scheme, the classification for accessing lock is thin Change, be divided into read lock and write lock, when carrying out read lock operation, correlation does not conflict multiple business operations.
In the above-mentioned technical solutions, it is preferable that as shown in Fig. 2 step 106 specifically includes:Step 208:Access lock application During success, the business operation, which performs, accesses database;Step 210:At the end of the business operation accesses database, release accesses Lock.In the technical scheme, when business operation in due course in do not clash when, business is normally carried out.
In the above-mentioned technical solutions, it is preferable that as shown in Fig. 2 step 106 specifically also includes:Step 212:Access lock Shen When please fail, after service end waits preset duration, application is retried automatically and accesses lock preset times, lock is accessed according to application is retried As a result, perform step 214 or perform step 2161;Step 214:Locked successfully if retrying application in preset times and accessing, should Business operation is normally carried out;Step 216:If it is unsuccessful that application access lock is retried in preset times, return and work as to client The message that preceding operation requests conflict with the operation of other users, just a moment,please performs;Step 218:The prison that client passes through application lock Interface display and the corresponding application situation for accessing lock of management are controlled, is operated for corresponding service and performs the in the case of of failure, allows use Family oneself carrys out the corresponding lock that accesses and is managed operation.In the technical scheme, by after error, carrying out waiting a very little Time, and carry out again application access lock mode, automatically to be retried, energy under conflict situations between reaching in due course Do not malfunction, business is normally carried out;And in the case of long-time conflicts, after the predetermined number of times of configuration is retried, just return to request Operation with other users conflicts, the message that just a moment,please performs;Meanwhile shown by providing the monitoring interface for applying locking With the application situation of management lock, the special circumstances to be broken down for system, to allow user oneself to be managed operation to lock.
Fig. 5 shows the block diagram of the Parallel access control device of business operation according to an embodiment of the invention.
As shown in figure 5, the block diagram of the Parallel access control device of business operation according to an embodiment of the invention, including: Single Service Processing Unit 302, the operation requests sent for service end based on client, the control for accessing lock is placed on single Business procession;Access lock classification application unit 304, is based on presetting in multiple business operations with being somebody's turn to do for service end Business operation corresponding to operation requests, classification application access lock;Lock application result execution unit 306 is accessed, for servicing End group performs corresponding operating in the application result for accessing lock., can by controlling the refinement for accessing lock in the technical scheme To greatly reduce the concurrent access conflict of business, it is also possible to bring good usage experience to user.
In the above-mentioned technical solutions, it is preferable that single Service Processing Unit 302, specifically include:Operation requests transceiver module 3021, operation requests are sent for client, service end receives the operation requests that client is sent;Current business execution module 3022, the current business corresponding with the operation requests that client is sent is performed for service end, the current business is corresponding default A business operation in multiple business operations.In the technical scheme, by the way that the control for accessing lock is placed on into single business It in processing procedure, can become shorter the time of locking, and the situation for making access conflict occur between user is minimized.
In the above-mentioned technical solutions, it is preferable that access lock classification application unit 304, specifically include:Access lock application Module 3041, business operation corresponding to current execution business is based on for service end, application accesses lock;Read lock module 3042, use In when the operation of this application access lock is read lock operation, judge whether existing access lock:If in the presence of the operation for writing lock, This application accesses the operation failure of lock;If the operation of read lock be present or locked in the absence of the access, this application accesses the behaviour of lock Succeed, increase the lock information corresponding with the operation that this application accesses lock;Lock module 3043 is write, for being locked when this application accesses Operation be when writing lock operation, to judge whether existing access lock:If in the presence of writing the operation of lock or the operation of read lock be present, This application accesses the operation failure of lock;If during in the absence of access lock, this application accesses the operation success of lock, increase and the Shen It please access the corresponding lock information of the operation of lock;Lock application result feedback module 3044 is accessed, for based on read lock module and writing The result of lock module, fed back to lock application result execution unit is accessed.In the technical scheme, the classification of lock is accessed Refinement, it is divided into read lock and writes lock, when carrying out read lock operation, correlation does not conflict multiple business operations.
In the above-mentioned technical solutions, it is preferable that access lock application result execution unit 306, specifically include:Access lock application Processing module 3061 during success, when applying successfully for accessing lock, the business operation, which performs, accesses database;And it is used for At the end of the business operation accesses database, release accesses lock.In the technical scheme, when business operation in due course in not When clashing, business is normally carried out.
In the above-mentioned technical solutions, it is preferable that access lock application result execution unit 306, specifically also include:Access lock Shen Processing module 3062 when please fail, when locking application failure for accessing, after service end waits preset duration, application is retried automatically Lock preset times are accessed, according to the result for retrying application access lock, perform following operate:If retry application in preset times to visit Ask and lock successfully, then the business operation is normally carried out;If it is unsuccessful that application access lock is retried in preset times, returned to client Return the message that current operation request conflicts with the operation of other users, just a moment,please performs;Monitoring circle that client passes through application lock Face shows and managed the application situation of corresponding access lock, is operated for corresponding service and performs the in the case of of failure, allows user certainly Oneself carrys out the corresponding lock that accesses and is managed operation.In the technical scheme, by after error, carry out waiting very little when Between, and the mode that application again accesses lock is carried out, automatically to be retried, can not go out under conflict situations between reaching in due course Mistake, business are normally carried out;And in the case of long-time conflicts, after the predetermined number of times of configuration is retried, just return to request and its The operation conflict of its user, the message that just a moment,please performs;Meanwhile shown and managed by providing the monitoring interface for applying locking The application situation of lock is managed, the special circumstances to be broken down for system, to allow user oneself to be managed operation to lock.
Technical scheme, database related management software is related generally to, be particularly one kind of its business operation simultaneously Send out the method and device of access control.
In order to solve the above problems, the present invention adds 3 improvement projects on the basis of the above-mentioned second way:
(1) the granularity of lock is accessed, is not necessarily to for adding access to be locked in user's operation, the operation of a user can wrap Containing multiple specific business processions, this multiple business procession have plenty of need carry out lock control, some then need not. By the way that the control for accessing lock is placed on single business procession, the time of locking is become shorter, is occurred between user The situation of access conflict is minimized.
(2) the processing of lock application failure is accessed, and when there is accessing lock application failure, another general business operation can be very The bad interactive experience of user is given in fast end, now, the message that directly returning to request can not be handled.And by malfunctioning Afterwards, carry out waiting the time of a very little, and carry out the mode that application again accesses lock, automatically to be retried, reach It can not be malfunctioned under appropriate time conflict situations, business is normally carried out.And in the case of long-time conflicts, retrying the finger of configuration After determining number, just return to request and conflict with the operation of other users, the message that just a moment,please performs, corresponding principle can be found in Fig. 3 Related statement.
(3) the classification refinement of lock is accessed, is divided into read lock and writes lock, for multiple business operations when carrying out read lock operation, correlation is not Conflict.If a business is when writing lock, other business can not be operated simultaneously.Specific logic is locking logic figure, can Stated referring to the correlation in Fig. 4.
Meanwhile the monitoring interface for applying for lock by providing goes out for system come the application situation for being shown and managing lock The special circumstances of existing failure, to allow user oneself to be managed operation to lock.
Empirical tests, technical scheme, in UFSOFT ERP products U9, after implementing the technical program, not only significantly The concurrent access conflict for reducing business, meanwhile, also make to bring good product usage experience to user, for product The raising of concurrent user number brings obvious effect.
Technical scheme is described in detail above in association with accompanying drawing, it is contemplated that there is no simplicity, system in correlation technique The solution of one Parallel access control for complicated business operation.Existing Parallel access control can not complete complexity The Parallel access control process that business operation participates in.Therefore, the present invention proposes a kind of Parallel access control side of business operation The Parallel access control device of method and a kind of business operation, can be on the Parallel access control mode basis of existing business operation On, make full use of the access control of single business operation to complete the Parallel access control of multi-service operation, establish single business operation ginseng With towards multi-service operation Parallel access control general, unified access control thinking.
The preferred embodiments of the present invention are the foregoing is only, are not intended to limit the invention, for the skill of this area For art personnel, the present invention can have various modifications and variations.Within the spirit and principles of the invention, that is made any repaiies Change, equivalent substitution, improvement etc., should be included in the scope of the protection.

Claims (2)

  1. A kind of 1. concurrent access control method of business operation, it is characterised in that including:
    Step 102:The operation requests that service end is sent based on client, the control for accessing lock is placed on single business processing mistake Journey, the step 102 specifically include:Step 202:Client sends operation requests, and service end receives the operation that client is sent Request;Step 204:Service end performs the current business corresponding with the operation requests that client is sent, and the current business is corresponding Preset a business operation in multiple business operations;
    Step 104:Service end is based on presetting business operation corresponding with the operation requests in multiple business operations, classification Shen Lock please be access, the step 104 specifically includes:Step 206:Service end is based on business operation, Shen corresponding to current execution business It please access lock;Further, the service end is based on business operation corresponding to current execution business, and application accesses the flow of lock, Also include:When the operation that this application accesses lock is read lock operation, judge whether existing access lock:If in the presence of the behaviour for writing lock Make, then this application accesses the operation failure of lock;If the operation of read lock be present or locked in the absence of the access, this application accesses lock Operation success, increase accesses the corresponding lock information of operation locked with this application;When the operation that this application accesses lock is to write lock During operation,
    Judge whether existing access lock:If in the presence of writing the operation of lock or the operation of read lock being present, this application accesses lock Operation failure;If during in the absence of access lock, this application accesses the operation success of lock, increase accesses the operation of lock with this application Corresponding lock information;
    Step 106:Service end performs corresponding operating, the step 106 specifically includes based on the application result for accessing lock:
    Step 208:When access lock is applied successfully, the business operation, which performs, accesses database;
    Step 210:At the end of the business operation accesses database, release accesses lock;
    Step 212:When accessing lock application failure, after service end waits preset duration, application is retried automatically and accesses lock preset times, According to the result for retrying application access lock, perform step 214 or perform step 216;
    Step 214:Locked successfully if retrying application in preset times and accessing, the business operation is normally carried out;
    Step 216:If it is unsuccessful that application access lock is retried in preset times, current operation request and its are returned to client The operation conflict of its user, the message that just a moment,please performs;
    Step 218:Client is by applying for that the monitoring interface of lock shows and managed the corresponding application situation for accessing lock, for corresponding Business operation performs situation about breaking down, and allows user oneself to carry out the corresponding lock that accesses and is managed operation.
  2. A kind of 2. Parallel access control device of business operation, it is characterised in that including:
    Single Service Processing Unit, the operation requests sent for service end based on client, the control for accessing lock is placed on list Individual business procession, the single Service Processing Unit, is specifically included:Operation requests transceiver module, sent out for client Go out operation requests, service end receives the operation requests that client is sent;Current business execution module, performed and visitor for service end Send out at family end
    The corresponding current business of the operation requests that go out, the current business correspondingly preset the business behaviour in multiple business operations Make;Lock classification application unit is accessed, is based on for service end corresponding with the operation requests in default multiple business operations Business operation, classification application accesses lock, described to access lock classification application unit, specifically includes:Access lock application mould Block, business operation corresponding to current execution business is based on for service end, application accesses lock;Read lock module, for working as this application When the operation for accessing lock is read lock operation, judge whether existing access lock:If in the presence of the operation for writing lock, this application accesses The operation failure of lock;If the operation of read lock be present or locked in the absence of the access, this application accesses the operation success of lock, increase The lock information corresponding with the operation that this application accesses lock;Lock module is write, the operation for accessing lock when this application is to write lock behaviour When making, judge whether existing access lock:If in the presence of writing the operation of lock or the operation of read lock being present, this application accesses lock Operation failure;If during in the absence of access lock, this application accesses the operation success of lock, increase accesses the operation of lock with this application Corresponding lock
    Information;Lock application result feedback module is accessed, for based on read lock module and the result for writing lock module, being locked to accessing Application result execution unit is fed back;Lock application result execution unit is accessed, for service end based on the application knot for accessing lock Fruit, perform corresponding operating;
    It is described to access lock application result execution unit, specifically include:The processing module locked and applied when successfully is accessed, is locked for accessing When applying successfully, the business operation, which performs, accesses database, and, at the end of accessing database for the business operation, release Access lock;Processing module during lock application failure is accessed, when locking application failure for accessing, after service end waits preset duration, Automatic retry is applied accessing lock preset times, applies accessing the result locked according to retrying, perform following operation:
    Locked successfully if retrying application in preset times and accessing, the business operation is normally carried out;
    If it is unsuccessful that application access lock is retried in preset times, current operation request and other users' are returned to client Operation conflict, the message that just a moment,please performs;
    Client is operated by applying for that the monitoring interface of lock shows and managed the corresponding application situation for accessing lock for corresponding service Situation about breaking down is performed, allows user oneself to carry out the corresponding lock that accesses and is managed operation.
CN201410284930.4A 2014-06-24 2014-06-24 The concurrent access control method and device of business operation Active CN104077111B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410284930.4A CN104077111B (en) 2014-06-24 2014-06-24 The concurrent access control method and device of business operation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410284930.4A CN104077111B (en) 2014-06-24 2014-06-24 The concurrent access control method and device of business operation

Publications (2)

Publication Number Publication Date
CN104077111A CN104077111A (en) 2014-10-01
CN104077111B true CN104077111B (en) 2018-03-02

Family

ID=51598386

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410284930.4A Active CN104077111B (en) 2014-06-24 2014-06-24 The concurrent access control method and device of business operation

Country Status (1)

Country Link
CN (1) CN104077111B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112491986B (en) * 2016-02-29 2022-07-29 华为技术有限公司 Method, device and system for distributing commands in distributed system
CN107360117B (en) * 2016-05-09 2020-03-13 阿里巴巴集团控股有限公司 Data processing method, device and system
CN106060060A (en) * 2016-06-22 2016-10-26 努比亚技术有限公司 Method and system for client to obtain lock
CN107105064A (en) * 2017-06-02 2017-08-29 上海艾融软件股份有限公司 The method for pushing and system of a kind of Transaction Information
CN108459913B (en) * 2017-12-26 2022-06-10 创新先进技术有限公司 Data parallel processing method and device and server
CN110851243B (en) * 2019-11-05 2022-04-12 东软集团股份有限公司 Flow access control method and device, storage medium and electronic equipment
CN112231131B (en) * 2020-09-28 2024-05-28 北京金山云网络技术有限公司 Method, device and equipment for realizing database lock and readable storage medium

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103458036A (en) * 2013-09-03 2013-12-18 杭州华三通信技术有限公司 Access device and method of cluster file system

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5742813A (en) * 1994-11-10 1998-04-21 Cadis, Inc. Method and apparatus for concurrency in an object oriented database using lock inheritance based on class objects
CN101364230B (en) * 2008-09-24 2011-04-20 金蝶软件(中国)有限公司 Concurrent access control method and device
CN103019651B (en) * 2012-08-02 2016-06-29 青岛海信传媒网络技术有限公司 The method for parallel processing of complex task and device

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103458036A (en) * 2013-09-03 2013-12-18 杭州华三通信技术有限公司 Access device and method of cluster file system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
多线程并发synchronized对象锁的控制与优化;sharpyuce;《http://blog.csdn.net/sharpyuce/article/details/10315123》;20130826;第6页至第9页 *

Also Published As

Publication number Publication date
CN104077111A (en) 2014-10-01

Similar Documents

Publication Publication Date Title
CN104077111B (en) The concurrent access control method and device of business operation
US10904339B2 (en) Techniques for storing and distributing metadata among nodes in a storage cluster system
US9444678B2 (en) Automatic cloud-based disaster recovery system including modifying a copy command based on a copy time threshold
CN106843749A (en) Write request processing method, device and equipment
US10282379B2 (en) Techniques for visualizing storage cluster system configurations and API therefore
US20140310434A1 (en) Enlightened Storage Target
US11556407B2 (en) Fast node death detection
US10031822B2 (en) Techniques for estimating ability of nodes to support high availability functionality in a storage cluster system
US20200089587A1 (en) Disaster recovery specific configurations, management, and application
CN104951855B (en) Apparatus and method for facilitating management of resources
US9680939B2 (en) Maintaining technical support continuity across system restarts and multiple operating systems
US11138198B2 (en) Handling of unresponsive read only instances in a reader farm system
US20160073315A1 (en) Information processing apparatus, storage control apparatus, and information processing method
US20060080399A1 (en) Remote configuration management for data processing units
US9612776B2 (en) Dynamically updated user data cache for persistent productivity
US9032484B2 (en) Access control in a hybrid environment
US9910893B2 (en) Failover and resume when using ordered sequences in a multi-instance database environment
US20120166387A1 (en) Member management system and member management apparatus
US11711261B2 (en) Automated host management service
US20050234325A1 (en) Method and apparatus for processing data, and medical appliance system for processing data
US11108700B2 (en) Method and system to implement messaging for cluster elections
RU2714373C1 (en) Method and system for scheduling execution of input/output operations
US7895259B2 (en) Method for preventing use of multiple application instances
CN104935450B (en) A kind of access session management method and its device
CN117075827A (en) Rights management method and device for printing system, electronic equipment and storage medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant