CN100498719C - Method and device for executing batch processing job - Google Patents

Method and device for executing batch processing job Download PDF

Info

Publication number
CN100498719C
CN100498719C CNB2006101732214A CN200610173221A CN100498719C CN 100498719 C CN100498719 C CN 100498719C CN B2006101732214 A CNB2006101732214 A CN B2006101732214A CN 200610173221 A CN200610173221 A CN 200610173221A CN 100498719 C CN100498719 C CN 100498719C
Authority
CN
China
Prior art keywords
data information
data
processing
handle
marks
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
CNB2006101732214A
Other languages
Chinese (zh)
Other versions
CN101000562A (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.)
China Construction Bank Corp
Original Assignee
China Construction Bank Corp
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 China Construction Bank Corp filed Critical China Construction Bank Corp
Priority to CNB2006101732214A priority Critical patent/CN100498719C/en
Publication of CN101000562A publication Critical patent/CN101000562A/en
Application granted granted Critical
Publication of CN100498719C publication Critical patent/CN100498719C/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

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

Abstract

A method for executing batch processing job includes fetching data information being used to finalize specific batch processing job, converting data information to be on-line affairs job according to preset on-line affairs conversion rule, sending said on-line affairs job to on-line affairs job processing environment for carrying out process there, receiving and storing processed result feedback from said processing environment, fetching next data information and repeating above said process till all data information is processed.

Description

A kind of method and device of carrying out batch processing job
Technical field
The present invention relates to data processing field, particularly relate to the data processing field of batch environment and on-line environment.
Background technology
In large-scale data handling system, generally adopt core system to handle various related datas, can provide two kinds of data processing circumstances in the core system: on-line environment and batch environment.They are data processing circumstances of two class different qualities, usually based on the different middleware platforms.
On-line environment is real-time affairs or transaction processing environment, can support a large amount of concurrent affairs processes, the affairs process can be triggered in real time by the user, and can start the issued transaction that (Start) affairs process is correlated with according to conditions needed, finishes (Commit) up to carrying out.Usually can finish the processing of affairs and renewal (Syncpoint) work synchronously of processing related database records in a short period of time, and result is returned to the user.Issued transaction has atomicity, and its implication is meant: for the affairs of specific operation sequence composition, or all finish, or also do not do with regard to one.If in the process of issued transaction, unpredictable mistake takes place, for guaranteeing the atomicity of affairs, when transaction abort, must carry out rolling back action, so that the operation that elimination has been carried out is to the influence of database according to daily record.The online transaction program that much is used for issued transaction is arranged in core system, be used for supporting and realizing various Transaction Processing functions.For example, under on-line environment, the user can trigger different online transaction in real time by terminal or various electronic channel, finish the processing of various financial affairs, as carry out storage/access money, account transfer, the inquiry into balance of bank, the buying in/sell, complete a business transaction of security, the declaration form of insurance company is accepted, premium is continuously paid, Claims Resolution etc.
Batch environment is the environment that batch data is handled, can support data processing process by the gross, normally handling the batch processing job of in automatic control flow chart, submitting, can be used for visit of process database or files in batches or operation such as renewal, the renewal of database need be provided with the condition of (Syncpoint) synchronously usually, can carry out synchronously after upgrading many data-base recordings.Under the perfect condition of automatic control flow chart, whole batch process can need not the batch job of finishing of manual intervention and handle.In core system, equally also there is the program that much is used for the batch data processing to support and realize various batch processing functions.For example, in core system, after day every day is whole, the data processing and the processing of many batches is arranged, as generate all kinds of accounting statements; Bank's interest-bearing, unloading automatically, automatic refund etc., the declaration form continuation of insurance of insurance company etc.
The business function of being realized for part batch processing job program, for example, in the bank some operation as keep accounts automatically, withhold, the batch data processing of refund etc., from the processing of single record (everyone/pen), its processing data information flow process is identical with the treatment scheme of online transaction accordingly.In current key issue in application system, online and batch processing job moves in environment separately respectively, provides the function support by online and business procedure batch processing respectively, and operation is separately finished function by the functional programs of calling separately.Because the running environment difference, the specification of the program code in two environment has bigger difference.In the method for existing execution batch processing job, there is following shortcoming:
1, in batch environment and the on-line environment program of finishing identical function is arranged respectively, the function program that batch processing job calls in the batch environment is finished data processing, wasted the program resource of identical function in the on-line environment, the program of identical function has taken the space of storer, has wasted hardware resource.
2, the system maintenance personnel need safeguard the program of finishing identical function in two environment simultaneously when safeguarding, the program maintenance workload is big.
3, when developing new data processing function, need develop the program of finishing said function simultaneously at batch environment and on-line processing environment, the development amount is big.
Summary of the invention
Technical matters to be solved by this invention provides a kind of method and device of carrying out batch processing job, wastes resource in the prior art to solve, maintenance workload is big and the big problem of development amount.
In order to solve the problems of the technologies described above, the invention discloses a kind of method of carrying out batch processing job, comprising:
Reading of data data, described data information are used to finish specific batch processing job task;
Online transaction transformation rule according to default is converted to the online transaction operation with data information;
Described online transaction operation is sent to the Transaction Processing environment to be handled;
Receive and preserve the result that described on-line job processing environment returns;
Marks for treatment writes in the described data information;
Read next bar data information and repeat above-mentioned processing, until handling all data informations.
Preferably, described method also comprises,
Judge whether described data information has marks for treatment, if having, this data information is not handled, read next bar data information and handle,, continue to handle if do not have;
If a last data information has marks for treatment, and this data information have no alternative but to marks for treatment, this data information is recovered to handle.
Preferably, described method also comprises, preserves current executing state sign.
Preferably, described method also comprises,
Receive steering order;
Judge whether steering order is correct; If correct, continue next step processing;
Read the executing state sign;
Judge according to described executing state sign whether described steering order can be carried out,, continue next step processing if can carry out.
Preferably, described method also comprises,
Judge to have or not to stop request,, stop to handle,, continue to handle if do not have if having;
Judge to have or not and suspend request, if having, suspends the specific time after, continue processing.
Preferably, described data information be the general service data information, towards positive professional data information or nonstandard categorical data data.
Preferably, described data information is kept in database or the file.
The present invention also provides a kind of device of carrying out batch processing job, comprising:
Reading unit is used for the reading of data data, and described data information is used to finish specific batch processing job task;
Converting unit is used for according to default online transaction transformation rule data information being converted to the online transaction operation;
Transmitting element is used for that described online transaction operation is sent to the Transaction Processing environment and handles;
Receiving element is used to receive and preserve the result that described Transaction Processing environment returns;
The mark writing unit is used for marks for treatment is write described data information;
First control module is used to control reading unit and reads next bar data information and repeat processing, until handling all data informations.
Preferably, described device also comprises,
Second control module is used to judge whether described data information has marks for treatment, if having, this data information is not handled, and reads next bar data information and handles, if do not have, continues to handle;
Recover processing unit, be used for the data data is recovered to handle;
The 3rd control module has marks for treatment if be used for a last data information, and this data information have no alternative but to marks for treatment, calls the recovery processing unit this data information is recovered to handle.
Preferably, described device also comprises,
Executing state is preserved the unit, is used to preserve current executing state sign.
Preferably, described device also comprises,
The steering order receiving element is used to receive steering order;
The steering order judging unit is used to judge whether steering order is correct; If correct, continue next step processing;
The executing state reading unit is used to read the executing state sign;
The steering order performance element is used for judging according to described executing state sign whether described steering order can be carried out, if can carry out, continues next step processing.
Preferably, described device also comprises,
Stop judging unit, be used for judging having or not stopping request,, stop to handle,, continue to handle if do not have if having;
Suspend judging unit, be used for judging having or not and suspend request, if having, suspends the specific time after, continue processing.
Compared with prior art, the present invention has the following advantages:
1, can call the program of handling identical function in the on-line environment at batch environment, save the function program resource, reduce taking of storage space, save hardware resource.
2, the system maintenance personnel only need safeguard the function program in the on-line environment, and maintenance workload is little.
3, in exploitation and the on-line processing environment during batch application of existing program identical function, the function program that can call in the on-line environment is finished data processing, when developing new function, only need develop new function program in on-line environment, and the development amount is few.
4, when carrying out batch processing job generation interruption, the invention provides automatic error recovery operation, guaranteed the correctness of data.
5, data information of the present invention can read from data file or database, is applicable to file system and Database Systems simultaneously.
6, data handling procedure has been utilized the atomicity of Transaction Processing, has improved reliability and consistance that batch processing job is carried out.Because Transaction Processing adopts or all submit to, perhaps whole rollback modes again in conjunction with log record, can be determined the position of makeing mistakes to have made things convenient for executory wrong recovery of batch processing job easily.
7, because employing sends to the method that on-line environment is handled with the online transaction operation, can not be subjected to the Platform Type of on-line environment and the restriction in geographic position, realize cross-platform and data data processing cross-region.
8, can receive steering order batch processing job is controlled, convenient for users to use.
9, support in batches towards orthofunction, conveniently handle a large amount of processing mistakes that reasons such as submitting mistake owing to batch processing job causes, can save misoperation or other mistake easily.
Description of drawings
Fig. 1 is method embodiment 1 process flow diagram of the present invention;
Fig. 2 is method embodiment 2 process flow diagrams of the present invention;
Fig. 3 is device embodiment 1 block diagram of the present invention.
Embodiment
For above-mentioned purpose of the present invention, feature and advantage can be become apparent more, the present invention is further detailed explanation below in conjunction with the drawings and specific embodiments.
Core concept of the present invention is: in the batch processing job of carrying out in batch environment, processing from the single data information, message processing flow is identical with the treatment scheme of the online transaction operation of corresponding on-line environment, a batch processing job like this can be equal to a virtual teller to the processing of business continuously to be triggered the online transaction operation and handles, even what trigger is same online transaction operation.If in batch processing job, can reuse already present online transaction program, not only economize on resources, the program maintenance amount is little, and for new business, needn't develop a cover program at batch environment in addition and do identical business processing; And, if the operation flow of online transaction operation is correct, just can guarantee that the operation flow of batch processing job is the same with online transaction correct.In addition, the atomicity of utilizing the online transaction operation to handle also helps mistake is carried out recovery operation, has fully guaranteed the correctness of business processing.
With reference to Fig. 1, be method embodiment 1 process flow diagram of the present invention, comprising:
Step 101, the reading of data data, described data information is used to finish specific batch processing job task.
The batching data data be under batch environment, be used to carry out specific function data acquisition, can include the data that many needs are handled.For example, when finishing the account transfer function, can comprise in every data data: information such as a plurality of users' action type, account information, target account information, transfer amount and current time, rely on these information, batch processing job can disposablely be finished a plurality of users' account transfer operation.
Step 102, the online transaction transformation rule according to default is converted to the online transaction operation with data information, and described online transaction transformation rule is used for data information is converted to the online transaction operation.
The issued transaction of on-line environment is only accepted the online transaction operation of specific format, before data information is sent to on-line environment, need be processed into the online transaction operation according to the form of the issued transaction of on-line environment, so that on-line environment is carried out.The rule of format conversion can set in advance, after reading every data information, and the automatic format conversion of carrying out, the form of the online transaction operation that the issued transaction of formation on-line environment can be accepted according to transformation rule.Transformation rule can be a formative input form, stipulated that those data in the batching data data should correspond to the ad-hoc location of online transaction operation, rely on transformation rule, the batching data data formatting can be generated the form of online transaction operation.
Step 103 sends to on-line environment with described online transaction operation and handles.
Batch environment and on-line environment are the data processing circumstances of two class different qualities, generally be on different system platforms, the different middleware, the online transaction operation is sent to on-line environment need call the cross-platform order that middleware system provides, described cross-platform order can be supported calling of Local or Remote, this cross-platform order is indirect provides independence between the calling platform, for example, can be the interface interchange order of a specific function, according to the regular transmission call instruction of calling of interface.Here also can use the cross-platform order that provides by operating system to send the online transaction operation.
On-line environment is handled the online transaction operation that receives, and the firm general online transaction message format of handling of result is returned to caller in the batch environment.
Step 104 receives and preserves the result that described on-line environment is returned.
Batch environment receive that on-line environment returns message as a result, extract the information such as result in the heading, preserve together through format conversion and the complete message that receives.Can be kept in data file or the database, as subsequent treatment master data, the supplementary that the data of preserving in this step can also be recovered as aborted.
Step 105 reads next bar data information and repeats above-mentioned processing, until handling all data informations.
Repeat to read the batching data data, up to handling all data informations.
Preferably, after receiving and preserve the result that described Transaction Processing environment returns, before reading next bar data information, comprise also that marks for treatment writes in the described data information.
When handling this data information, marks for treatment is written in former data file or the database.The marks for treatment that this step writes can be used to locate the last item successful execution data information be the position, also can be used for make mistakes or carries out be interrupted after, the data information that does not execute is carried out the recovery operation use.Having handled sign can be a zone bit, and for example, zone bit is 1 to be treatment state, and the no marks position is the state of being untreated.
Preferably, after the reading of data data, before data information is converted to the online transaction operation, also comprise,
Judge whether described data information has marks for treatment, if having, this record is not handled, read next bar data information and handle,, continue to handle if do not have;
If a last data information has marks for treatment, and this data information have no alternative but to marks for treatment, this data information is recovered to handle.
When execution last time is interrupted or stops, can rely on the data information that has disposed is skipped in the judgement of handling sign, up to first untreated data information position, owing to can not determine the disposition of first untreated data information, need carry out recovery operation to first untreated data information.
When carrying out recovery operation, relate to the problem of data sync, for different data sync modes, recovery operation also different.
Stride in the operation execution of on-line environment at batch environment, need to realize the data synchronization operation, needing data in synchronization can be two kinds: the state parameter of execution and data.Data sync has two kinds of implementations: confirmation of synchronization mode and asynchronous affirmation mode.The present invention can support two kinds of different data sync point affirmation modes simultaneously.
The confirmation of synchronization mode is that operation is in the renewal of batch environment to handled data information, after the end of transaction that on-line environment is striden in wait returns, carry out data sync in the lump and confirm " COMMIT SYNCPOINT ", in online transaction processing program, do not carry out data sync separately and confirm, make that like this it is synchronous that the renewal of same notes record is handled.The advantage of this mode be can not occur upgrading under the batch environment successfully, on-line environment upgrades failure, or on-line environment is upgraded successfully, batch environment upgrades the situation of failing, and makes unusual error handling processing become simply, need not the recovery processing that makes mistakes substantially.But the shortcoming of this mode is bigger to the consumption of system resource, and the Data Update flexibility ratio is little, is prone to unusual conditions such as locking or hang-up between two platforms.
Asynchronous affirmation mode, be that operation can be upgraded and confirmation of synchronization data at batch environment, and can upgrade repeatedly same record, as stride on-line environment and upgrade some data item before calling, upgrade some other data item behind the return results once more, in the issued transaction of on-line environment, record is upgraded and confirmation of synchronization.The advantage of this mode is independent mutually to the renewal of data between cross-platform, the Data Update flexibility ratio is improved, and the resource consumption to system is relatively little, but whether shortcoming is will differentiate the affirmation of handling that is recorded in two Data Update in the environment when makeing mistakes unusually to finish, and making makes mistakes recovers to become complicated.
Adopting in the following method of recovery operation " RECOVER " when Data Update is used asynchronous affirmation mode realizes: at first, in the attribute data of the affairs of Transaction Processing, be provided with and whether will carry out the data sync mistake and recover, if sign is set to "No", then these affairs do not need to carry out data sync mistake recovery processing, promptly do not support " RECOVER " function; If sign is set to "Yes", then support " RECOVER " function.If this online transaction is supported " RECOVER " function, then when handling, can write down the reports on the implementation of these affairs, the content of record includes the contents such as serial number of these affairs.When carrying out operation generation aborted, check the execution control data of operation, and take out the serial number of the data information that finishing touch runs succeeded that serial number is added 1, and promptly the next record serial number goes to read affairs reports on the implementation data.If the information of this flowing water not in the affairs reports on the implementation data represents that this data data does not begin to carry out as yet,, operation can be continued to carry out as any action; If there has been the information of this flowing water in the affairs reports on the implementation data shelves, the information of then taking out this flowing water writes troactively in the operation input and output data, and upgrades operation synchronously and carry out control data.Recovery finishes, and continues to carry out operation.
Preferably, described method also comprises, preserves current executing state sign.
Carry out the various treatment states of the current operation of record in the control data in operation, so that monitor and inquiry, state can have following several:
(1) INITIAL-initialization.Before operation was carried out for the first time, the state that this operation is carried out in the control data archives was " initialization " state, and this operation can be performed, and the state after processing operation is carried out normal termination " disposes ", and this operation also can be performed.
(2) during RUNNING-carries out.After operation was batch processing the online transaction analog controller and calls execution, controller was carried out the state that state in control data archives is being changed into " in the execution " with this operation.
(3) INTERRUPT-interrupts.Have no progeny in the order that the execution of operation is artificially interrupted for various reasons, job state becomes " interruption ", in have no progeny and restart (Restart), job state returns to " in the execution ".
(4) PAUSE WAIT-suspends.When needs are handled some system problems, system resource peak for example, operation need be suspended the peak of riving, a stand-by period is set artificially to be suspended this operation to handle, controller changes the state of this operation into " time-out ", after receiving the order of removing time-out, operation continues to carry out, and recovering state is to " in the execution ".
(5) EOF-disposes.Normally carry out end when operation, job state is " disposing ".
(6) the ERROR-mistake takes place.Carry out at the batch processing and the on-line transaction platform of striding this locality when operation, operation self is carried out and is made mistakes and aborted, and job state is " mistake generation ".
(7) REMOTE ERROR-remote error takes place.Striding the on-line transaction platform of changing places when the batch processing job execution, operation self is carried out and is made mistakes and aborted, and job state is " remote error generation ".
Preferably, before described method, also comprise,
Receive steering order;
Judge whether steering order is correct, the steering order of steering order that receives and permission use is compared,, continue next step processing if instruction is correct;
The executing state sign of reading operation;
Judge according to described executing state sign whether described steering order can be carried out,, continue next step processing if can carry out.
Stride calling of batch environment and on-line environment and can use control command to trigger, also can be by the triggering of independent batch processing.When using control command to trigger, can adopt following order to control the execution of operation:
(1) begin-normally begins " STRT ".
State in this operation is under " initialization " or " disposing " this two states, can accept " STRT " order and normally begin to carry out this operation.When carrying out row, operation begins to carry out in turn, up to executing the finishing touch data information from the first stroke data information.
(2) restart-from the beginning carry out " RERUN ".
Operation is interrupted carrying out and be need not and recovers, the state of originally carrying out is reinitialized also accent to begin to carry out, whether application system will be held this operation can restart " RERUN ", and carry out in the control data in operation that attribute is set to can " RERUN ", reset command just can come into force, otherwise return command is invalid.
(3) breakpoint restart-in have no progeny and restart " RSTART ".
Aborted is handled in the operation that causes for various reasons, or operation makes mistakes unusually, the online transaction system that comprises local and remote side, carry out the breakpoint reset command, the affairs analog controller can be skipped the record that normally is finished, automatically navigate to finishing touch and handle, after it is recovered to handle, down continue to carry out.
(4) the mistake recovery-operation recovery " RECOVER " that makes mistakes unusually.
This situation is the state of operation appearance " mistake generation " or " remote error generation " often, does not know the recovery processing that the finishing touch record need be done when whether disposing, and this order only recovers to handle to the finishing touch data information.This order can independently be carried out, and also can directly carry out one and order the recovery " RSTART " that makes mistakes, because it has comprised the function of this order.
Preferably, also comprise,
Judge to have or not to stop request,, stop to handle,, continue to handle if do not have if having;
Judge to have or not and suspend request, if having, suspends the specific time after, continue processing.
Before handling a current data data, reading next bar data information, judged whether to stop request, if having, stop current data processing.Can preestablish stroke count and a time out of a data information to be processed, before will handling the next record data information, if the request of time-out is arranged, then the time out that presets by the station suspends execution, after the time out, continues data processing.
In operation is carried out, the command request below can be corresponding:
(1) time-out-time-out is handled " PAUSE ".
When needs are handled some system problems, for example to rive period on system resource peak, operation is artificially suspended, the time of suspending wait sets in advance in carrying out control data, also can be by the order time update, a stand-by period is set suspends the processing of this operation, and the stand-by period one handles to continuing to carry out operation automatically.
(2) termination-Interrupt Process " STOP ".
When because other various reasons of non-operation self mistake need interruption operation, " STOP " ordered in following termination, the execution of interruption operation, and job state becomes " interruption ".In have no progeny with in have no progeny and restart the execution that (RESTART) continues operation.
In operation is carried out, can also receive following order simultaneously and carry out the inquiry of job state and the time interval of revising time-out.
(1) inquiry-query processing situation " DISPLAY ".
Carry out the executing state that this order can inquiry job, need find out when operation is restarted especially which kind of state this operation is in, the mode which kind of is restarted is taked in decision again.
(2) change-change suspends data " CHANGE ".
This order only for time-out, is used to revise the time interval that operation suspends.
Preferably, described data information be the general service data information, towards positive professional data information or nonstandard type service data information.
Data information can be the data information of general service, for example, and the professional data information of depositing or withhold.
Data information can also be towards positive professional data information.
Usually owing to reasons such as operating mistakes, for example the input data of operation are taken by mistake by the gross, though or program bug cause running succeeded, the execution result mistake needs operation by the gross to dash and just operates.After operation is finished, can will comprise the inputoutput data data of processing result information, generate through conversion and dash the positive professional data information of just handling that dashes; Perhaps in carrying out, operation finds this type of mistake, interruption operation immediately, for the sake of assurance, after execution error recovers " RECOVERY " again, with all data informations that have been finished, through format conversion, generation is towards positive professional data information, submit to by operating personnel, finish towards positive function the repair data mistake.
Dash by the gross just be finished after, in output result report, also may viciously report, for example, what pay out wages automatically and keep accounts just dashes, because certain account's the fund that keeps accounts is produced by account transfer, cause to dash and just fail, at this moment need be by manual intervention, this special situation of manual process.
Data information can also be nonstandard type service data information.
Generally speaking, data information to be processed can generate in advance according to set form, for example, can be gone to generate by service logic and condition by program, and the filename of generation need be defined in operation and carry out in the control data in order to call automatically.Another situation is that data information to be processed can't generate in advance, but continues dynamically to generate under the dynamic environment data, and extends across on-line environment in real time and handle, and obtains return results.In order to solve this type of problem, can write the export procedure of this operation correspondence by the user voluntarily, this program can be defined in operation and carry out in the control data.
Satisfy at specific transactions under the situation of certain condition, as the fluctuation of the exchange rate, or in particular time interval, trigger the export procedure of this operation, generate the input data of operation, be cross over on-line environment and transferred the Transaction Processing program, the object information after returning is write in the operation input and output data.
In nonstandard types of transactions, the process of batch processing job need be set the end that the condition of closing triggers process, and this class process also can be established as permanent process usually, supports 24 hours continual business processing.The handling procedure that makes full use of the online transaction of having set up is finished professional processing automatically.
General batch processing Transaction Processing is to be undertaken by the data information file of the input that has generated (as withholding input file in batches).And nonstandard types of transactions is the poll by application process, when its finds to have when satisfying condition the data that can handle, trigger the export procedure of this process, generate required data information, handle by the function code that calls after the format conversion in the on-line environment, processing is write object information in the input and output data of process after finishing.
For example, handle for the foreign exchange trading credit, because exchange rate fluctuation makes certain business of foreign exchange trading bring success together, after foreign exchange trading credit treatment progress captures this information that needs credit, promptly trigger corresponding export procedure, generate the input data information, finish credit and handle, and credit information is write in the relevant Service Database.
Preferably, it is characterized in that described data information is kept in database or the file.
The present invention can be applicable to simultaneously based on the batch processing platform of file system and Database Systems and online platform.
With reference to Fig. 2, be method embodiment 2 process flow diagrams of the present invention, present embodiment is that example is introduced to withhold in batches.Withhold in batches be that bank provides a kind of and withhold the money service, can realize once taking off a collection of client's expense, for example, can be used to withhold charges for water and electricity or telephone charge.Specifically comprise:
Step 201 receives steering order.
Step 202 checks whether instruction is correct, if correct, execution in step 203, if not, execution in step 216.
Step 203 is checked current treatment situation sign, judges whether to allow the execution of instructing.If allow to carry out, execution in step 204, if not, execution in step 216.
For example, current state is that processing procedure is interrupted, and then unavailable beginning (Start) instruction continues to carry out, and has no progeny in must utilizing to restart (Restart) instruction, reaches the purpose that recovery is handled.
Step 204 reads transaction record successively from file or database.
Step 205 judges whether to also have untreated transaction record, if, execution in step 206, if not, execution in step 216.If do not read transaction record, then handled whole transaction records.
Step 206 changes transaction record into the online transaction operation of the acceptable established form of on-line environment.
Step 207, the cross-platform order that utilizes middleware system or operating system to provide is arrived on-line environment with the online transaction job transfer.When on-line environment behind transaction file, call the processing that relevant on-line Application program is handled these affairs as required.
Step 208 after being handled by the handling procedure of on-line environment, is returned result with general online transaction message format, and batch environment receives the result of returning.
Step 209 is carried out format conversion with result, extracts the data that need.
Step 210 is preserved data after the conversion and the result that receives.Can write in a file or the database,, and can provide auxiliary restarting after the aborted as the master data of subsequent treatment.
Step 211 adds the mark of " handling " on original transaction record, then the lump-sum record is rewritten back in original or the database.
Step 212 after handling each transaction, judges to have or not to stop request that if having, then execution in step 216, if there is not execution in step 213.
Step 213 is judged to have or not and is suspended request, if having, execution in step 214 is not if there is execution in step 204
Step 214 judges whether the record of having handled reaches the time-out stroke count, if, execution in step 215, if not, execution in step 204.
Step 215 is suspended according to predefined time out, finishes execution in step 204 up to time out.
Step 216 stops to handle.
Batch in this example withholds processing need do the processing of button account to a large amount of accounts that withholds, and guarantees the consistance of business datums such as customer account remaining sum, customer account detail, collecting account remaining sum, collecting account detail simultaneously when the button account again; It is professional to allow the client feel that just as teller operation one faces cabinet.
Withhold in the processing carrying out batch, batch environment, what the transaction of on-line transaction that the on-line transaction analog controller calls and cabinet face single deduct was used is a program.When therefore withholding professional demand generation change, the maintainer only need safeguard that a program can be finished in batches and the change of single deduct transaction, and maintenance workload is little, and the modification of carrying out business function is convenient.
Introduce the positive processing procedure of dashing in withholding in batches below.
After withholding successful execution in batches, find afterwards that branch sends to withhold account data mistake (may check in branch and find when withholding as a result), can carry out batch this moment and withhold by the gross towards just handling.Operating personnel submit to by the gross towards positive pre-treatment job, are just changing the batch that will comprise processing result information and withhold every notes record that input file withholds output file in batches and all change and generate accordingly towards the incoming message form of just handling by dashing.Operating personnel submit to by the gross towards positive processing operation, send to dash to on-line environment and just conclude the business, and finish just dashing of account and handle, and generate towards positive result file.The business personnel of branch compares and in batches withholds destination file and towards positive destination file, to handling towards the accent account that positive account is correlated with.
With reference to Fig. 3, be device embodiment block diagram of the present invention, comprising:
Reading unit 301 is used for the reading of data data, and described data information is used to finish specific batch processing job task.
Converting unit 302 is used for according to default online transaction transformation rule data information being converted to the online transaction operation, and described online transaction transformation rule is used for data information is converted to the online transaction operation.
Transmitting element 303 is used for that described online transaction operation is sent to the Transaction Processing environment and handles.
Receiving element 304 is used to receive and preserve the result that described Transaction Processing environment returns.
First control module 305 is used to control reading unit 301 and reads next bar data information and repeat processing, until handling all data informations.
Read the batching data data by reading unit 301, converting unit 302 is converted into the batching data data that reads the form of online transaction operation, the online transaction operation that generates uses cross-platform order to send to on-line environment by transmitting element 303, online transaction environment calls function corresponding code is carried out the online transaction operation, and the result that will carry out returns to the caller of batch environment, receiving element 304 receives the result that on-line environment is returned, and preserve, first control module 305 is used to control reading unit 301 and reads next bar data information, repeat above-mentioned processing, up to handling all data informations.
Preferably, also comprise,
Mark writing unit 306 is used for marks for treatment is write described data information.
When handling this data information, marks for treatment is written in former data file or the database.
Preferably, also comprise,
Second control module 307 is used to judge whether described data information has marks for treatment, if having, this data information is not handled, and reads next bar data information and handles, if do not have, handles.
Recover processing unit 308, be used for the data data is recovered to handle.
The 3rd control module 309 has marks for treatment if be used for a last data information, and this data information have no alternative but to marks for treatment, calls the recovery processing unit this data information is recovered to handle.
When execution last time is interrupted or stops, can rely on the data information that has disposed is skipped in the judgement of handling sign, up to first untreated data information position, owing to can not determine the disposition of first untreated data information, need carry out recovery operation to first untreated data information.
When carrying out recovery operation, relate to the problem of data sync, for different data sync modes, can take different recovery operations.For the confirmation of synchronization mode, need not substantially to make mistakes and recover to handle.For asynchronous affirmation mode, adopting in the following method of recovery operation " RECOVER " when Data Update is used asynchronous affirmation mode realizes: at first, in the attribute data of the affairs of Transaction Processing, be provided with and whether will carry out the data sync mistake and recover, if sign is set to "No", then these affairs do not need to carry out data sync mistake recovery processing, promptly do not support " RECOVER " function; If sign is set to "Yes", then support " RECOVER " function.If this online transaction is supported " RECOVER " function, then when handling, can write down the reports on the implementation of these affairs, the content of record includes the contents such as serial number of these affairs.When carrying out operation generation aborted, check the execution control data of operation, and take out the serial number of the data information that finishing touch runs succeeded that serial number is added 1, and promptly the next record serial number goes to read affairs reports on the implementation data.If the information of this flowing water not in the affairs reports on the implementation data represents that this data data does not begin to carry out as yet,, operation can be continued to carry out as any action; If there has been the information of this flowing water in the affairs reports on the implementation data shelves, the information of then taking out this flowing water writes troactively in the operation input and output data, and upgrades operation synchronously and carry out control data.Recovery finishes, and continues to carry out operation.
Preferably, also comprise,
Executing state is preserved unit 310, is used to preserve current executing state sign.
Carry out the various treatment states of the current operation of record in the control data in operation, so that monitoring and inquiry, state can have following several: initialization, carry out in, interrupt, suspend, dispose, mistake takes place and remote error generation etc.
Preferably, also comprise,
Steering order receiving element 312 is used to receive steering order;
Steering order judging unit 313 is used to judge whether steering order is correct; If correct, proceed to handle
Executing state reading unit 314 is used to read the executing state sign;
Steering order performance element 315 is used for judging according to described executing state sign whether described steering order can be carried out.,, proceed to handle if can carry out.
Stride calling of batch environment and on-line environment and can use control command to trigger, also can be by the triggering of independent batch processing.When using control command to trigger, can adopt following order to control the execution of operation: to begin, restart, breakpoint is restarted and wrong the recovery.
Preferably, also comprise,
Stop judging unit 316, be used for judging having or not stopping request,, stop to handle,, continue to handle if do not have if having;
Suspend judging unit 317, be used for judging having or not and suspend request, if having, suspends the specific time after, continue processing.
When stopping request because other a variety of causes of non-operation self mistake when needing interruption operation, send, the execution of interruption operation, job state becomes " interruption ".In have no progeny can with in have no progeny and restart the execution that (RESTART) order continues operation.
When needs are handled some system problems, for example will avoid the period on system resource peak, operation can be suspended, the time of suspending wait sets in advance in carrying out control data, also can be by the order time update, the stand-by period finishes to continue to carry out operation automatically and handles.
The present invention can realize remote access after having set up the connecting of local batch environment and strange land online transaction platform, call the transaction processing program of remote connection system, can realize calling of cross-region.
More than to a kind of method and apparatus of carrying out batch processing job provided by the present invention, be described in detail, used specific case herein principle of the present invention and embodiment are set forth, the explanation of above embodiment just is used for helping to understand method of the present invention and core concept thereof; Simultaneously, for one of ordinary skill in the art, according to thought of the present invention, the part that all can change in specific embodiments and applications, in sum, this description should not be construed as limitation of the present invention.

Claims (12)

1, a kind of method of carrying out batch processing job is characterized in that, comprising:
Reading of data data, described data information are used to finish specific batch processing job task;
Online transaction transformation rule according to default is converted to the online transaction operation with data information;
Described online transaction operation is sent to the Transaction Processing environment to be handled;
Receive and preserve the result that described on-line job processing environment returns;
Marks for treatment writes in the described data information;
Read next bar data information and repeat above-mentioned processing, until handling all data informations.
2, method according to claim 1 is characterized in that, after the reading of data data, before data information is converted to the online transaction operation, also comprise,
Judge whether described data information has marks for treatment, if having, this data information is not handled, read next bar data information and handle,, continue to handle if do not have;
If a last data information has marks for treatment, and this data information have no alternative but to marks for treatment, this data information is recovered to handle.
3, method according to claim 1 is characterized in that, also comprises, preserves current executing state sign.
4, method according to claim 3 is characterized in that, before described method, also comprise,
Receive steering order;
Judge whether steering order is correct; If correct, continue next step processing;
Read the executing state sign;
Judge according to described executing state sign whether described steering order can be carried out,, continue next step processing if can carry out.
5, method according to claim 1 is characterized in that, after receiving and preserve the result that described Transaction Processing environment returns, reads before next bar data information, also comprise,
Judge to have or not to stop request,, stop to handle,, continue to handle if do not have if having;
Judge to have or not and suspend request, if having, suspends the specific time after, continue processing.
According to claim 1,2,3,4,5 any described methods, it is characterized in that 6, described data information is the general service data information, towards positive professional data information or nonstandard categorical data data.
7, according to claim 1,2,3,4,5 any described methods, it is characterized in that described data information is kept in database or the file.
8, a kind of device of carrying out batch processing job is characterized in that, comprising:
Reading unit is used for the reading of data data, and described data information is used to finish specific batch processing job task;
Converting unit is used for according to default online transaction transformation rule data information being converted to the online transaction operation;
Transmitting element is used for that described online transaction operation is sent to the Transaction Processing environment and handles;
Receiving element is used to receive and preserve the result that described Transaction Processing environment returns;
The mark writing unit is used for marks for treatment is write described data information;
First control module is used to control reading unit and reads next bar data information and repeat processing, until handling all data informations.
9, device according to claim 8 is characterized in that, also comprise,
Second control module is used to judge whether described data information has marks for treatment, if having, this data information is not handled, and reads next bar data information and handles, if do not have, continues to handle;
Recover processing unit, be used for the data data is recovered to handle;
The 3rd control module has marks for treatment if be used for a last data information, and this data information have no alternative but to marks for treatment, calls the recovery processing unit this data information is recovered to handle.
10, device according to claim 8 is characterized in that, also comprise,
Executing state is preserved the unit, is used to preserve current executing state sign.
11, device according to claim 10 is characterized in that, also comprise,
The steering order receiving element is used to receive steering order;
The steering order judging unit is used to judge whether steering order is correct; If correct, continue next step processing;
The executing state reading unit is used to read the executing state sign;
The steering order performance element is used for judging according to described executing state sign whether described steering order can be carried out, if can carry out, continues next step processing.
12, device according to claim 8 is characterized in that, also comprise,
Stop judging unit, be used for judging having or not stopping request,, stop to handle,, continue to handle if do not have if having;
Suspend judging unit, be used for judging having or not and suspend request, if having, suspends the specific time after, continue processing.
CNB2006101732214A 2006-12-30 2006-12-30 Method and device for executing batch processing job Active CN100498719C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB2006101732214A CN100498719C (en) 2006-12-30 2006-12-30 Method and device for executing batch processing job

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB2006101732214A CN100498719C (en) 2006-12-30 2006-12-30 Method and device for executing batch processing job

Publications (2)

Publication Number Publication Date
CN101000562A CN101000562A (en) 2007-07-18
CN100498719C true CN100498719C (en) 2009-06-10

Family

ID=38692546

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2006101732214A Active CN100498719C (en) 2006-12-30 2006-12-30 Method and device for executing batch processing job

Country Status (1)

Country Link
CN (1) CN100498719C (en)

Families Citing this family (24)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101430687B (en) * 2007-11-09 2015-11-25 阿里巴巴集团控股有限公司 Based on statistical form application process and the system of OLTP environment
CN101556678A (en) * 2009-05-21 2009-10-14 中国建设银行股份有限公司 Processing method of batch processing services, system and service processing control equipment
CN102222297A (en) * 2010-04-15 2011-10-19 中国银联股份有限公司 Data processing method and system thereof
CN102221995A (en) * 2011-05-19 2011-10-19 中国石油集团川庆钻探工程有限公司 Breakpoint recovery method for seismic data processing operation
CN103501326A (en) * 2013-09-26 2014-01-08 中国银行股份有限公司 Data processing method and system based on middleware
CN104077362A (en) * 2014-06-09 2014-10-01 中国建设银行股份有限公司 Online mass data processing system and method
CN104007984B (en) * 2014-06-20 2017-06-16 中国银行股份有限公司 A kind of method and device of change data
CN104407847B (en) * 2014-10-29 2019-05-07 中国建设银行股份有限公司 A kind of method and device of batch processing
CN105912541A (en) * 2015-12-12 2016-08-31 乐视移动智能信息技术(北京)有限公司 Method and device for batch processing of database operation
CN107609793A (en) * 2017-10-09 2018-01-19 税友软件集团股份有限公司 A kind of method and device of process for producing transaction system abnormality
CN108376171B (en) * 2018-02-27 2020-04-03 平安科技(深圳)有限公司 Method and device for quickly importing big data, terminal equipment and storage medium
CN108961039B (en) * 2018-07-02 2023-03-31 创新先进技术有限公司 Transaction processing method, device and system
CN110825560B (en) * 2018-08-10 2022-11-01 北京嘀嘀无限科技发展有限公司 Method, device and equipment for processing execution errors and computer readable storage medium
CN109492034A (en) * 2018-09-17 2019-03-19 中国建设银行股份有限公司 Batch processing system, method, apparatus and storage medium
CN109658264A (en) * 2018-12-13 2019-04-19 泰康保险集团股份有限公司 Receipt and payment method, device and equipment
CN110070440A (en) * 2019-04-30 2019-07-30 苏州工业园区服务外包职业学院 A kind of business data processing method, device, equipment and storage medium
CN110232571B (en) * 2019-06-04 2021-07-23 中国工商银行股份有限公司 Cross-row receipt data processing method, device and system
CN110381150B (en) * 2019-07-24 2021-12-17 中国工商银行股份有限公司 Data processing method and device on block chain, electronic equipment and storage medium
CN110597668B (en) * 2019-09-20 2022-04-29 中国银行股份有限公司 Resident job processing method and system
CN110825771B (en) * 2019-10-12 2024-06-28 中国平安财产保险股份有限公司 Batch data processing method, electronic device, computer equipment and storage medium
CN111210340B (en) * 2020-01-03 2023-08-18 中国建设银行股份有限公司 Automatic task processing method, device, server and storage medium
CN111679896A (en) * 2020-06-03 2020-09-18 中国银行股份有限公司 TWS-based work flow cycle analysis method and device
CN112785209A (en) * 2021-03-23 2021-05-11 中国工商银行股份有限公司 Processing method, device and system for online operation
CN113971007B (en) * 2021-10-29 2024-05-10 中国建设银行股份有限公司 Information processing method, device, electronic equipment and medium

Also Published As

Publication number Publication date
CN101000562A (en) 2007-07-18

Similar Documents

Publication Publication Date Title
CN100498719C (en) Method and device for executing batch processing job
US6138143A (en) Method and apparatus for asynchronous transaction processing
US6990466B1 (en) Method and system for integrating core banking business processes
US5151987A (en) Recovery objects in an object oriented computing environment
CN102934114B (en) For the checkpoint of file system
CN100452030C (en) System and method for a snapshot query during database recovery
EP0351969A2 (en) Exactly-once semantics in a TP queuing system
US6389431B1 (en) Message-efficient client transparency system and method therefor
JPH06301581A (en) Mistake permission transaction directivity data processing
JPH10124371A (en) Method and system for transaction processing
CN101212336A (en) Automatic software update method for client, auxiliary method and related device
CN104077362A (en) Online mass data processing system and method
CN114925084A (en) Distributed transaction processing method, system, device and readable storage medium
US5706500A (en) Selective transaction oriented recovery and restart for message-driven business applications
CN100456255C (en) Device and method for fetching snapshot data
CN115633025B (en) Intelligent integrated equipment based on USBServer and application method
US20060085473A1 (en) Method and system for business process super-transaction
US6330686B1 (en) Handling protected conversation messages across IMS restart in shared queues environment
US8830831B1 (en) Architecture for balancing workload
JP5187958B2 (en) Automatic transaction equipment control system
US6256641B1 (en) Client transparency system and method therefor
CN1296220A (en) Method and system for installing and/or updating software of self-aid financial business terminal
CN101021791A (en) Method and apparatus for realizing distributed object persistence and compiling unit
JPH11306263A (en) Electronic money system, linking method of bank account for electronic money and recording medium
CN1680920B (en) Method and apparatus of basic inputting and outputting system in far-end updating data processing system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant