CN109447800A - A kind of log recording method, device and electronic equipment - Google Patents

A kind of log recording method, device and electronic equipment Download PDF

Info

Publication number
CN109447800A
CN109447800A CN201811219838.4A CN201811219838A CN109447800A CN 109447800 A CN109447800 A CN 109447800A CN 201811219838 A CN201811219838 A CN 201811219838A CN 109447800 A CN109447800 A CN 109447800A
Authority
CN
China
Prior art keywords
transaction
log
data
transaction data
generation
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201811219838.4A
Other languages
Chinese (zh)
Inventor
陆雯怡
肖飞军
金晓磊
王华阳
董洁
丁立
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Bank of China Ltd
Original Assignee
Bank of China Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Bank of China Ltd filed Critical Bank of China Ltd
Priority to CN201811219838.4A priority Critical patent/CN109447800A/en
Publication of CN109447800A publication Critical patent/CN109447800A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/546Message passing systems or structures, e.g. queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q20/00Payment architectures, schemes or protocols
    • G06Q20/38Payment protocols; Details thereof
    • G06Q20/389Keeping log of transactions for guaranteeing non-repudiation of a transaction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/548Queue

Abstract

The present invention provides a kind of log recording method, device and electronic equipments, by presetting public function, during multiple transaction processes execute respective transaction, obtain the first transaction data of each transaction process, obtain the second transaction data of each transaction process output, according to the first transaction data and the second transaction data of each transaction process, the transaction log of respective transaction is generated, is recorded using multiple transaction logs of the serial manner to generation.Transaction log is recorded by serial mode in the present invention, transaction log journal, after a transaction log record, another transaction log just be will record, and will not record multiple transaction logs simultaneously, and then be not in resource contention, the serial problem of log recording.

Description

A kind of log recording method, device and electronic equipment
Technical field
The present invention relates to data processing fields, set more specifically, being related to a kind of log recording method, device and electronics It is standby.
Background technique
Bank reception pay average trading volume be it is up to a million, trade peak when daily trading volume up to up to ten million, in order to transaction It is monitored analysis, all transaction are required to be recorded in the form of log.Specifically, transaction process will generate log, And by log recording into same journal file.
But when trading volume is larger, multiple transaction processes can have money simultaneously by log recording into same journal file Source competes, the serial problem of log in journal file.
Summary of the invention
In view of this, the present invention provides a kind of log recording method, device and electronic equipment, to solve multiple transaction processes Can be there is into resource contention, the serial problem of the log in journal file into same journal file in log recording simultaneously.
In order to solve the above technical problems, present invention employs following technical solutions:
A kind of log recording method, comprising:
By presetting public function, during multiple transaction processes execute respective transaction, each transaction process is obtained The first transaction data;
Obtain the second transaction data of each transaction process output;
According to the first transaction data and the second transaction data of each transaction process, the day of trade of respective transaction is generated Will;
It is recorded using multiple transaction logs of the serial manner to generation.
Preferably, according to the first transaction data and the second transaction data of each transaction process, respective transaction is generated Transaction log, comprising:
Data summarization is carried out to the first transaction data and the second transaction data, the data after being summarized;
Processing is formatted to the data after described summarize, obtains transaction log.
Preferably, it is recorded using multiple transaction logs of the serial manner to generation, comprising:
According to the generation time of transaction log, multiple transaction log sequences are added in message queue;
Disappear if the quantity of the transaction log in the message queue reaches described in default value or prefixed time interval The transaction log not increased newly in breath queue, the transaction log in the message queue is successively recorded in journal file.
Preferably, by presetting public function, during multiple transaction processes execute respective transaction, each friendship is obtained Before first transaction data of easy process, further includes:
Extract the shared transaction data in the transaction data of multiple default transaction process outputs;
According to the shared transaction data, the default public function is generated.
A kind of log recording apparatus, comprising:
First obtains module, is used for by presetting public function, during multiple transaction processes execute respective transaction, Obtain the first transaction data of each transaction process;
Second obtains module, for obtaining the second transaction data of each transaction process output;
Log generation module, it is raw for the first transaction data and the second transaction data according to each transaction process At the transaction log of respective transaction;
Logging modle, for being recorded using serial manner to multiple transaction logs of generation.
Preferably, the log generation module includes:
Collects submodule, for carrying out data summarization to the first transaction data and the second transaction data, after being summarized Data;
Data processing submodule obtains transaction log for being formatted processing to the data after described summarize.
Preferably, the logging modle includes:
Data add submodule, for the generation time according to transaction log, multiple transaction log sequences are added to and are disappeared It ceases in queue;
Record sub module, if the quantity for the transaction log in the message queue reaches default value or presets The transaction log not increased newly in the message queue in time interval successively records the transaction log in the message queue Into journal file.
Preferably, further includes:
Extraction module, the shared transaction data in transaction data for extracting multiple default transaction process outputs;
Function generation module, for generating the default public function according to the shared transaction data.
A kind of electronic equipment, comprising: memory and processor;
Wherein, the memory is for storing program;
Processor caller is simultaneously used for:
By presetting public function, during multiple transaction processes execute respective transaction, each transaction process is obtained The first transaction data;
Obtain the second transaction data of each transaction process output;
According to the first transaction data and the second transaction data of each transaction process, the day of trade of respective transaction is generated Will;
It is recorded using multiple transaction logs of the serial manner to generation.
Compared to the prior art, the invention has the following advantages:
The present invention provides a kind of log recording method, device and electronic equipment, recorded in the present invention by serial mode Transaction log, transaction log journal, after a transaction log record, another transaction log just be will record, will not be simultaneously Multiple transaction logs are recorded, and then are not in resource contention, the serial problem of log recording.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this The embodiment of invention for those of ordinary skill in the art without creative efforts, can also basis The attached drawing of offer obtains other attached drawings.
Fig. 1 is a kind of method flow diagram of log recording method provided in an embodiment of the present invention;
Fig. 2 is the method flow diagram of another log recording method provided in an embodiment of the present invention;
Fig. 3 is a kind of structural schematic diagram of log recording apparatus provided in an embodiment of the present invention;
Fig. 4 is the structural schematic diagram of another log recording apparatus provided in an embodiment of the present invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall within the protection scope of the present invention.
The embodiment of the invention provides a kind of log recording methods, referring to Fig.1, may include:
S11, each transaction is obtained during multiple transaction processes execute respective transaction by default public function First transaction data of process;
Specifically, default public function be it is pre-generated, the default public function of generation is to extract all transaction The transaction data for all being included, such as exchange hour, transaction journal number.The shared number of deals extracted using default public function According to there is no need to the processes of trading to provide, and transaction process provides distinctive transaction data in transaction.
The data format of first transaction data meets preset data format requirement.If the first column is trade date, the Two columns are transaction journal number etc..
In addition, multiple transaction processes execute the time of transaction without limitation, it can be and be performed simultaneously transaction, be also possible to not The same time executes transaction.As long as transaction process starts after executing transaction, so that it may obtain the first transaction data.
Optionally, on the basis of the present embodiment, before step S11, can also include:
1) the shared transaction data in the transaction data of multiple default transaction process outputs is extracted;
Specifically, process of such as transferring accounts is executing money transfer transactions during default transaction carries out execution transaction, withhold into Journey is withholdd transaction in execution, presets transaction process after having executed transaction, can generate and export transaction data, and transaction data can be with Including data such as exchange hour, transaction journal number, trading account, beneficiary, paying parties.
By analyzing multiple transaction data, the shared extracting section in multiple transaction data is come out, and as shared friendship Easy data, such as shared transaction data may include exchange hour, transaction journal number.
2) according to the shared transaction data, the default public function is generated.
After shared transaction data determines, a public function is generated, and there is the public function in transaction process During executing transaction, the function of shared transaction data is obtained.
S12, the second transaction data for obtaining each transaction process output;
Specifically, after transaction process has executed transaction the second transaction data can be exported, wherein the number of the second transaction data Meet preset data format requirement according to format, such as the first column is beneficiary, the second column is paying party.
S13, according to the first transaction data and the second transaction data of each transaction process, generate the friendship of respective transaction Easy log;
Optionally, on the basis of the present embodiment, step S13 may include:
1) data summarization is carried out to the first transaction data and the second transaction data, the data after being summarized;
2) processing is formatted to the data after described summarize, obtains transaction log.
Specifically, being formatted processing after the first transaction data and the second transaction data carry out data summarization, so that it may Obtain transaction log, formatting processing can be the format on date and be opened using preset Year/Month/Day format, transaction journal number Head is set as fixed number etc..
S14, it is recorded using multiple transaction logs of the serial manner to generation.
In the present embodiment, transaction log, transaction log journal, a transaction log record are recorded by serial mode Afterwards, another transaction log just will record, and will not record multiple transaction logs simultaneously, and then be not in resource contention, log Record serial problem.
Optionally, based on any of the above embodiments, may include: referring to Fig. 2, step S14
Multiple transaction log sequences are added in message queue by S21, the generation time according to transaction log;
Specifically, a generation time is just had after transaction log generates, when at this time by multiple transaction logs according to generating Between be sequentially put into message queue MQ queue.
If the quantity of S22, transaction log in the message queue reaches institute in default value or prefixed time interval The transaction log not increased newly in message queue is stated, by the transaction log record in the message queue into journal file.
Specifically, asynchronous circulation monitors MQ queue, and determine the quantity of the transaction log in MQ queue, is set when quantity reaches It is more than certain time in the dominant record number set, i.e. default value or MQ queue without new record, at this time just message queue In transaction log be sequentially recorded in journal file.
In the present embodiment, MQ queue is written into transaction log, realizes that the output of transaction log records by read-write MQ queue, It avoids each process while writing the serial problem of resource contention and log recording caused by journal file, while reducing to data file Operation improves log recording efficiency.
In addition, once reading the dominant record number (n item) of MQ queue by parameter configuration backstage finger daemon and reading The time-out time (t seconds) of MQ queue, according to backstage finger daemon obtain record number whether reach n item or whether more than t seconds MQ Queue still decides whether to write log, realizes that file operation records a plurality of log recording, reduce to file without new record Operation improves log recording efficiency;
Third, the embodiment of the present invention meet multi-process high concurrent system All Activity and record same log request, log note Record does not influence system performance.
Optionally, on the basis of the embodiment of above-mentioned log recording method, another embodiment of the present invention provides one Kind log recording apparatus, reference Fig. 3 may include:
First obtains module 101, for executing the process of respective transaction in multiple transaction processes by presetting public function In, obtain the first transaction data of each transaction process;
Second obtains module 102, for obtaining the second transaction data of each transaction process output;
Log generation module 103, for the first transaction data and the second transaction data according to each transaction process, Generate the transaction log of respective transaction;
Logging modle 104, for being recorded using serial manner to multiple transaction logs of generation.
Further, the log generation module 103 may include:
Collects submodule, for carrying out data summarization to the first transaction data and the second transaction data, after being summarized Data;
Data processing submodule obtains transaction log for being formatted processing to the data after described summarize.
Further, can also include:
Extraction module, the shared transaction data in transaction data for extracting multiple default transaction process outputs;
Function generation module, for generating the default public function according to the shared transaction data.
In the present embodiment, transaction log, transaction log journal, a transaction log record are recorded by serial mode Afterwards, another transaction log just will record, and will not record multiple transaction logs simultaneously, and then be not in resource contention, log Record serial problem.
It should be noted that the course of work of modules and submodule in the present embodiment, please refers to above-described embodiment In respective description, details are not described herein.
Optionally, on the basis of the embodiment of any of the above-described log recording apparatus, referring to Fig. 4, the logging modle 104 May include:
Data add submodule 1041, and for the generation time according to transaction log, multiple transaction log sequences are added Into message queue;
Record sub module 1042, if the quantity for the transaction log in the message queue reach default value or The transaction log not increased newly in the message queue in prefixed time interval, successively by the transaction log in the message queue It is recorded in journal file.
In the present embodiment, MQ queue is written into transaction log, realizes that the output of transaction log records by read-write MQ queue, It avoids each process while writing the serial problem of resource contention and log recording caused by journal file, while reducing to data file Operation improves log recording efficiency.
In addition, once reading the dominant record number (n item) of MQ queue by parameter configuration backstage finger daemon and reading The time-out time (t seconds) of MQ queue, according to backstage finger daemon obtain record number whether reach n item or whether more than t seconds MQ Queue still decides whether to write log, realizes that file operation records a plurality of log recording, reduce to file without new record Operation improves log recording efficiency;
Third, the embodiment of the present invention meet multi-process high concurrent system All Activity and record same log request, log note Record does not influence system performance.
It should be noted that the course of work of modules and submodule in the present embodiment, please refers to above-described embodiment In respective description, details are not described herein.
Optionally, on the basis of the embodiment of above-mentioned log recording method and device, another embodiment of the present invention is mentioned A kind of electronic equipment has been supplied, may include: memory and processor;
Wherein, the memory is for storing program;
Processor caller is simultaneously used for:
By presetting public function, during multiple transaction processes execute respective transaction, each transaction process is obtained The first transaction data;
Obtain the second transaction data of each transaction process output;
According to the first transaction data and the second transaction data of each transaction process, the day of trade of respective transaction is generated Will;
It is recorded using multiple transaction logs of the serial manner to generation.
Further, processor is used for the first transaction data and the second transaction data according to each transaction process, raw At respective transaction transaction log when, be specifically used for:
Data summarization is carried out to the first transaction data and the second transaction data, the data after being summarized;
Processing is formatted to the data after described summarize, obtains transaction log.
Further, it is specific to use when processor is used to record multiple transaction logs of generation using serial manner In:
According to the generation time of transaction log, multiple transaction log sequences are added in message queue;
Disappear if the quantity of the transaction log in the message queue reaches described in default value or prefixed time interval The transaction log not increased newly in breath queue, the transaction log in the message queue is successively recorded in journal file.
Further, processor is used for by presetting public function, during multiple transaction processes execute respective transaction, Before the first transaction data for obtaining each transaction process, it is also used to:
Extract the shared transaction data in the transaction data of multiple default transaction process outputs;
According to the shared transaction data, the default public function is generated.
In the present embodiment, transaction log, transaction log journal, a transaction log record are recorded by serial mode Afterwards, another transaction log just will record, and will not record multiple transaction logs simultaneously, and then be not in resource contention, log Record serial problem.
Optionally, the embodiments of the present invention also provide a kind of log recording apparatus, the log recording apparatus includes place Device and memory are managed, above-mentioned first, which obtains module, the second acquisition module, log generation module and logging modle etc., is used as program Unit stores in memory, executes above procedure unit stored in memory by processor to realize corresponding function.
Include kernel in processor, is gone in memory to transfer corresponding program unit by kernel.Kernel can be set one Or more, resource contention, the serial problem of log recording are avoided the occurrence of by adjusting kernel parameter.
Memory may include the non-volatile memory in computer-readable medium, random access memory (RAM) and/ Or the forms such as Nonvolatile memory, if read-only memory (ROM) or flash memory (flash RAM), memory include that at least one is deposited Store up chip.
The embodiment of the invention provides a kind of storage mediums, are stored thereon with program, real when which is executed by processor The existing log recording method.
The embodiment of the invention provides a kind of processor, the processor is for running program, wherein described program operation Log recording method described in Shi Zhihang.
The embodiment of the invention provides a kind of equipment, equipment include processor, memory and storage on a memory and can The program run on a processor, processor perform the steps of when executing program
A kind of log recording method, comprising:
By presetting public function, during multiple transaction processes execute respective transaction, each transaction process is obtained The first transaction data;
Obtain the second transaction data of each transaction process output;
According to the first transaction data and the second transaction data of each transaction process, the day of trade of respective transaction is generated Will;
It is recorded using multiple transaction logs of the serial manner to generation.
Further, according to the first transaction data and the second transaction data of each transaction process, respective transaction is generated Transaction log, comprising:
Data summarization is carried out to the first transaction data and the second transaction data, the data after being summarized;
Processing is formatted to the data after described summarize, obtains transaction log.
Further, it is recorded using multiple transaction logs of the serial manner to generation, comprising:
According to the generation time of transaction log, multiple transaction log sequences are added in message queue;
Disappear if the quantity of the transaction log in the message queue reaches described in default value or prefixed time interval The transaction log not increased newly in breath queue, the transaction log in the message queue is successively recorded in journal file.
Further, by presetting public function, during multiple transaction processes execute respective transaction, each friendship is obtained Before first transaction data of easy process, further includes:
Extract the shared transaction data in the transaction data of multiple default transaction process outputs;
According to the shared transaction data, the default public function is generated.
Equipment herein can be server, PC, PAD, mobile phone etc..
Present invention also provides a kind of computer program products, when executing on data processing equipment, are adapted for carrying out just The program of beginningization there are as below methods step:
A kind of log recording method, comprising:
By presetting public function, during multiple transaction processes execute respective transaction, each transaction process is obtained The first transaction data;
Obtain the second transaction data of each transaction process output;
According to the first transaction data and the second transaction data of each transaction process, the day of trade of respective transaction is generated Will;
It is recorded using multiple transaction logs of the serial manner to generation.
Further, according to the first transaction data and the second transaction data of each transaction process, respective transaction is generated Transaction log, comprising:
Data summarization is carried out to the first transaction data and the second transaction data, the data after being summarized;
Processing is formatted to the data after described summarize, obtains transaction log.
Further, it is recorded using multiple transaction logs of the serial manner to generation, comprising:
According to the generation time of transaction log, multiple transaction log sequences are added in message queue;
Disappear if the quantity of the transaction log in the message queue reaches described in default value or prefixed time interval The transaction log not increased newly in breath queue, the transaction log in the message queue is successively recorded in journal file.
Further, by presetting public function, during multiple transaction processes execute respective transaction, each friendship is obtained Before first transaction data of easy process, further includes:
Extract the shared transaction data in the transaction data of multiple default transaction process outputs;
According to the shared transaction data, the default public function is generated.
It should be understood by those skilled in the art that, embodiments herein can provide as method, system or computer program Product.Therefore, complete hardware embodiment, complete software embodiment or reality combining software and hardware aspects can be used in the application Apply the form of example.Moreover, it wherein includes the computer of computer usable program code that the application, which can be used in one or more, The computer program implemented in usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) produces The form of product.
The application is referring to method, the process of equipment (system) and computer program product according to the embodiment of the present application Figure and/or block diagram describe.It should be understood that every one stream in flowchart and/or the block diagram can be realized by computer program instructions The combination of process and/or box in journey and/or box and flowchart and/or the block diagram.It can provide these computer programs Instruct the processor of general purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices to produce A raw machine, so that being generated by the instruction that computer or the processor of other programmable data processing devices execute for real The device for the function of being specified in present one or more flows of the flowchart and/or one or more blocks of the block diagram.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works, so that it includes referring to that instruction stored in the computer readable memory, which generates, Enable the manufacture of device, the command device realize in one box of one or more flows of the flowchart and/or block diagram or The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device, so that counting Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, thus in computer or The instruction executed on other programmable devices is provided for realizing in one or more flows of the flowchart and/or block diagram one The step of function of being specified in a box or multiple boxes.
In a typical configuration, calculating equipment includes one or more processors (CPU), input/output interface, net Network interface and memory.
Memory may include the non-volatile memory in computer-readable medium, random access memory (RAM) and/ Or the forms such as Nonvolatile memory, such as read-only memory (ROM) or flash memory (flash RAM).Memory is computer-readable Jie The example of matter.
Computer-readable medium includes permanent and non-permanent, removable and non-removable media can be by any method Or technology come realize information store.Information can be computer readable instructions, data structure, the module of program or other data. The example of the storage medium of computer includes, but are not limited to phase change memory (PRAM), static random access memory (SRAM), moves State random access memory (DRAM), other kinds of random access memory (RAM), read-only memory (ROM), electric erasable Programmable read only memory (EEPROM), flash memory or other memory techniques, read-only disc read only memory (CD-ROM) (CD-ROM), Digital versatile disc (DVD) or other optical storage, magnetic cassettes, tape magnetic disk storage or other magnetic storage devices Or any other non-transmission medium, can be used for storage can be accessed by a computing device information.As defined in this article, it calculates Machine readable medium does not include temporary computer readable media (transitory media), such as the data-signal and carrier wave of modulation.
It should also be noted that, the terms "include", "comprise" or its any other variant are intended to nonexcludability It include so that the process, method, commodity or the equipment that include a series of elements not only include those elements, but also to wrap Include other elements that are not explicitly listed, or further include for this process, method, commodity or equipment intrinsic want Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including element There is also other identical elements in process, method, commodity or equipment.
It will be understood by those skilled in the art that embodiments herein can provide as method, system or computer program product. Therefore, complete hardware embodiment, complete software embodiment or embodiment combining software and hardware aspects can be used in the application Form.It is deposited moreover, the application can be used to can be used in the computer that one or more wherein includes computer usable program code The shape for the computer program product implemented on storage media (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) Formula.
The foregoing description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, as defined herein General Principle can be realized in other embodiments without departing from the spirit or scope of the present invention.Therefore, of the invention It is not intended to be limited to the embodiments shown herein, and is to fit to and the principles and novel features disclosed herein phase one The widest scope of cause.

Claims (9)

1. a kind of log recording method characterized by comprising
By presetting public function, during multiple transaction processes execute respective transaction, the of each transaction process is obtained One transaction data;
Obtain the second transaction data of each transaction process output;
According to the first transaction data and the second transaction data of each transaction process, the transaction log of respective transaction is generated;
It is recorded using multiple transaction logs of the serial manner to generation.
2. log recording method according to claim 1, which is characterized in that handed over according to the first of each transaction process Easy data and the second transaction data, generate the transaction log of respective transaction, comprising:
Data summarization is carried out to the first transaction data and the second transaction data, the data after being summarized;
Processing is formatted to the data after described summarize, obtains transaction log.
3. log recording method according to claim 1, which is characterized in that multiple friendships using serial manner to generation Easy log is recorded, comprising:
According to the generation time of transaction log, multiple transaction log sequences are added in message queue;
If the quantity of the transaction log in the message queue reaches the message team in default value or prefixed time interval Transaction log in the message queue is successively recorded in journal file the transaction log not increased newly in column.
4. log recording method according to claim 1, which is characterized in that by presetting public function, in multiple transaction During process executes respective transaction, before the first transaction data for obtaining each transaction process, further includes:
Extract the shared transaction data in the transaction data of multiple default transaction process outputs;
According to the shared transaction data, the default public function is generated.
5. a kind of log recording apparatus characterized by comprising
First obtains module, for during multiple transaction processes execute respective transaction, obtaining by presetting public function First transaction data of each transaction process;
Second obtains module, for obtaining the second transaction data of each transaction process output;
Log generation module generates phase for the first transaction data and the second transaction data according to each transaction process The transaction log that should be traded;
Logging modle, for being recorded using serial manner to multiple transaction logs of generation.
6. log recording apparatus according to claim 5, which is characterized in that the log generation module includes:
Collects submodule, for carrying out data summarization to the first transaction data and the second transaction data, the data after being summarized;
Data processing submodule obtains transaction log for being formatted processing to the data after described summarize.
7. log recording apparatus according to claim 5, which is characterized in that the logging modle includes:
Data add submodule, and for the generation time according to transaction log, multiple transaction log sequences are added to message team In column;
Record sub module, if the quantity for the transaction log in the message queue reaches default value or preset time The transaction log not increased newly in the message queue in being spaced, is successively recorded day for the transaction log in the message queue In will file.
8. log recording apparatus according to claim 5, which is characterized in that further include:
Extraction module, the shared transaction data in transaction data for extracting multiple default transaction process outputs;
Function generation module, for generating the default public function according to the shared transaction data.
9. a kind of electronic equipment characterized by comprising memory and processor;
Wherein, the memory is for storing program;
Processor caller is simultaneously used for:
By presetting public function, during multiple transaction processes execute respective transaction, the of each transaction process is obtained One transaction data;
Obtain the second transaction data of each transaction process output;
According to the first transaction data and the second transaction data of each transaction process, the transaction log of respective transaction is generated;
It is recorded using multiple transaction logs of the serial manner to generation.
CN201811219838.4A 2018-10-19 2018-10-19 A kind of log recording method, device and electronic equipment Pending CN109447800A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811219838.4A CN109447800A (en) 2018-10-19 2018-10-19 A kind of log recording method, device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811219838.4A CN109447800A (en) 2018-10-19 2018-10-19 A kind of log recording method, device and electronic equipment

Publications (1)

Publication Number Publication Date
CN109447800A true CN109447800A (en) 2019-03-08

Family

ID=65546721

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811219838.4A Pending CN109447800A (en) 2018-10-19 2018-10-19 A kind of log recording method, device and electronic equipment

Country Status (1)

Country Link
CN (1) CN109447800A (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101425034A (en) * 2008-08-11 2009-05-06 深圳市金蝶中间件有限公司 Log recording method and log system
CN101601197A (en) * 2006-12-07 2009-12-09 索尼爱立信移动通讯股份有限公司 Generate the transaction log of exchanges data between portable mobile communication apparatus and other wireless device
US20100211554A1 (en) * 2009-02-13 2010-08-19 Microsoft Corporation Transactional record manager
CN103198007A (en) * 2012-01-06 2013-07-10 腾讯科技(深圳)有限公司 Multi-process log output method and system
CN103729442A (en) * 2013-12-30 2014-04-16 华为技术有限公司 Method for recording event logs and database engine
CN106503264A (en) * 2016-11-29 2017-03-15 中国银行股份有限公司 On-line transaction log recording method and equipment based on oracle database
CN107153695A (en) * 2017-05-05 2017-09-12 恒生电子股份有限公司 Log recording method and device, electronic equipment, storage medium
US20170344478A1 (en) * 2014-12-18 2017-11-30 Hua Zhong University Of Science Technology Storing log records in a non-volatile memory

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101601197A (en) * 2006-12-07 2009-12-09 索尼爱立信移动通讯股份有限公司 Generate the transaction log of exchanges data between portable mobile communication apparatus and other wireless device
CN101425034A (en) * 2008-08-11 2009-05-06 深圳市金蝶中间件有限公司 Log recording method and log system
US20100211554A1 (en) * 2009-02-13 2010-08-19 Microsoft Corporation Transactional record manager
CN103198007A (en) * 2012-01-06 2013-07-10 腾讯科技(深圳)有限公司 Multi-process log output method and system
CN103729442A (en) * 2013-12-30 2014-04-16 华为技术有限公司 Method for recording event logs and database engine
US20170344478A1 (en) * 2014-12-18 2017-11-30 Hua Zhong University Of Science Technology Storing log records in a non-volatile memory
CN106503264A (en) * 2016-11-29 2017-03-15 中国银行股份有限公司 On-line transaction log recording method and equipment based on oracle database
CN107153695A (en) * 2017-05-05 2017-09-12 恒生电子股份有限公司 Log recording method and device, electronic equipment, storage medium

Similar Documents

Publication Publication Date Title
CN107368259B (en) Method and device for writing service data into block chain system
CN110162662B (en) Verification method, device and equipment for data records in block chain type account book
CN108829350A (en) Data migration method and device based on block chain
CN107688899A (en) Business process monitoring method and device
CN105446990B (en) A kind of business data processing method and equipment
CN105791178B (en) Message assemble method and device
CN109284301A (en) Verification of data method and device
CN108173706A (en) Service marker method, apparatus and equipment under a kind of multiservice system
CN106686104B (en) Method and equipment for operation and maintenance of target server
CN107391532B (en) Data filtering method and device
CN110264332A (en) The method, apparatus and electronic equipment that account is entered an item of expenditure in the accounts
CN109460439A (en) A kind of data processing method, device, medium and electronic equipment
CN110392100A (en) Processing method and processing device, storage medium, the computer equipment of high concurrent event
CN107330572A (en) Air control method, apparatus and system
CN110442481A (en) Method for processing business, Service Component container and electronic equipment
CN108694664A (en) Checking method and device, the electronic equipment of operation system
CN105335142B (en) The method and apparatus of the performance bottleneck of Identifying transactions in transacter
CN107273378B (en) File storage method and device
EP3149589B1 (en) System and method for dynamic collection of system management data in a mainframe computing environment
CN106570005A (en) Database cleaning method and device
CN107018158B (en) Method and device for screening internet resources
CN109447800A (en) A kind of log recording method, device and electronic equipment
CN110689418A (en) Bill generation method and device
CN111274255B (en) Service data monitoring method and system, monitoring architecture, equipment and storage medium
CN109614548A (en) Information displaying method, device and storage medium based on service-user number change rate

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20190308

RJ01 Rejection of invention patent application after publication