CN107193721A - A kind of method and apparatus for generating daily record - Google Patents

A kind of method and apparatus for generating daily record Download PDF

Info

Publication number
CN107193721A
CN107193721A CN201710204037.XA CN201710204037A CN107193721A CN 107193721 A CN107193721 A CN 107193721A CN 201710204037 A CN201710204037 A CN 201710204037A CN 107193721 A CN107193721 A CN 107193721A
Authority
CN
China
Prior art keywords
daily record
memory space
function
current business
standard logs
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.)
Granted
Application number
CN201710204037.XA
Other languages
Chinese (zh)
Other versions
CN107193721B (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.)
Wuhan Douyu Network Technology Co Ltd
Original Assignee
Wuhan Douyu Network Technology Co 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 Wuhan Douyu Network Technology Co Ltd filed Critical Wuhan Douyu Network Technology Co Ltd
Priority to CN201710204037.XA priority Critical patent/CN107193721B/en
Publication of CN107193721A publication Critical patent/CN107193721A/en
Application granted granted Critical
Publication of CN107193721B publication Critical patent/CN107193721B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3466Performance evaluation by tracing or monitoring
    • G06F11/3476Data logging
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/172Caching, prefetching or hoarding of files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/1734Details of monitoring file system events, e.g. by the use of hooks, filter drivers, logs

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Debugging And Monitoring (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiments of the invention provide a kind of method and apparatus for generating daily record, the daily record unified for realizing different business generation standard.Methods described includes:During current business is run, the log parameters of the daily record for generating current business are gathered;Standard logs function is called, the standard logs function is system function;By the incoming standard logs function of the log parameters, and the standard logs function is run, to generate the daily record of the current business.

Description

A kind of method and apparatus for generating daily record
Technical field
The present invention relates to field of computer technology, more particularly to a kind of method and apparatus for generating daily record.
Background technology
When electronic equipment performs different business, in order to record business implementation status, one or more daily record can be generated, And then when business malfunctions administrative staff can be caused to seek solution by analyzing daily record.Generally, it is preset with this in business The log function of business, then when electronic equipment performs the business, calls the log function of the business to generate the daily record of the business.
However, diversified daily record causes to search for and to read daily record less efficient.
The content of the invention
The embodiments of the invention provide a kind of method and apparatus for generating daily record, for realizing different business generation standard system One daily record.
In a first aspect, the invention provides a kind of method for generating daily record, including:
During current business is run, the log parameters of the daily record for generating current business are gathered;
Standard logs function is called, the standard logs function is system function;
By the incoming standard logs function of the log parameters, and the standard logs function is run, it is described to generate The daily record of current business.
Optionally, after the daily record of the current business is generated, methods described also includes:
The daily record of the current business is stored into the first memory space, first memory space is used to cache day Will;
Judge whether the daily record stored in first memory space meets preparatory condition;
When the daily record stored in first memory space meets the preparatory condition, by first memory space The daily record of storage is stored into the second memory space, and second memory space is used to preserve daily record.
Optionally, the standard logs function includes predetermined keyword extracting rule, runs the standard logs function, bag Include:
The keyword of the daily record of the current business is extracted according to the predetermined keyword.
Optionally, the standard logs function also includes predetermined level division rule, runs the standard logs function, also Including:
Grade classification is carried out to the daily record of the current business according to the predetermined level division rule.
Optionally, by the memory space of daily record second stored in first memory space, including:
The daily record stored in first memory space storage is arrived described second according to the keyword and/or grade of daily record In memory space.
Second aspect, the invention provides a kind of device for generating daily record, including:
Acquisition module, for during current business is run, gathering the daily record of the daily record for generating current business Parameter;
Calling module, for calling standard logs function, the standard logs function is system function;
Generation module, for by the incoming standard logs function of the log parameters, and runs the standard logs letter Number, to generate the daily record of the current business.
Optionally, described device also includes:
First memory module, for after the daily record of the current business is generated, the daily record of the current business to be deposited Store up into the first memory space, first memory space is used for log cache;
Whether judge module, the daily record for judging to store in first memory space meets preparatory condition;
Second memory module, for when the daily record stored in first memory space meets the preparatory condition, inciting somebody to action The daily record stored in first memory space is stored into the second memory space, and second memory space is used to preserve day Will.
Optionally, the standard logs function includes predetermined keyword extracting rule, and the generation module is used for according to institute State the keyword that predetermined keyword extracts the daily record of the current business.
Optionally, the standard logs function also includes predetermined level division rule, and the generation module is used for according to institute State daily record of the predetermined level division rule to the current business and carry out grade classification.
Optionally, second memory module is used for according to the keyword and/or grade of daily record that the described first storage is empty Between in storage daily record store into second memory space.
Said one or multiple technical schemes in the embodiment of the present application, are at least imitated with following one or more technologies Really:
In the technical scheme of the embodiment of the present invention, during current business is run, gather for generating current industry The log parameters of the daily record of business, then call standard logs function, and the standard logs function is system function, then will be described The incoming standard logs function of log parameters, and the standard logs function is run, to generate the daily record of the current business. It can be seen that, the daily record is generated by the unified standard logs function, then, even if the different business of operation, also can The unified daily record of acquisition standard, so the embodiment of the present invention realizes the technique effect of daily record standardization.So, compared to various Change daily record, search and reading daily record efficiency are improved.
Brief description of the drawings
Fig. 1 is the method flow diagram of generation daily record in the embodiment of the present invention;
Fig. 2 is the apparatus structure schematic diagram of generation daily record in the embodiment of the present invention.
Embodiment
The embodiments of the invention provide a kind of method and apparatus for generating daily record, for realizing different business generation standard system One daily record.
In order to solve the above-mentioned technical problem, the technical scheme general thought that the present invention is provided is as follows:
In the technical scheme of the embodiment of the present invention, during current business is run, gather for generating current industry The log parameters of the daily record of business, then call standard logs function, and the standard logs function is system function, then will be described The incoming standard logs function of log parameters, and the standard logs function is run, to generate the daily record of the current business. It can be seen that, the daily record is generated by the unified standard logs function, then, even if the different business of operation, also can The unified daily record of acquisition standard, so the embodiment of the present invention realizes the technique effect of daily record standardization.So, compared to various Change daily record, search and reading daily record efficiency are improved.
Technical solution of the present invention is described in detail below by accompanying drawing and specific embodiment, it should be understood that the application Specific features in embodiment and embodiment are the detailed description to technical scheme, rather than to present techniques The restriction of scheme, in the case where not conflicting, the technical characteristic in the embodiment of the present application and embodiment can be mutually combined.
The terms "and/or", only a kind of incidence relation for describing affiliated partner, represents there may be three kinds of passes System, for example, A and/or B, can be represented:Individualism A, while there is A and B, these three situations of individualism B.In addition, herein Middle character "/", it is a kind of relation of "or" to typically represent forward-backward correlation object.
First aspect present invention provides a kind of method for generating daily record, refer to Fig. 1, to generate the method flow of daily record Figure.This method includes:
S101:During current business is run, the log parameters of the daily record for generating current business are gathered;
S102:Standard logs function is called, the standard logs function is system function;
S103:By the incoming standard logs function of the log parameters, and the standard logs function is run, to generate The daily record of the current business.
Specifically, the method for generation of embodiment of the present invention daily record can apply to network side equipment or user equipment etc. In electronic equipment, or can also be applied to simultaneously in multiple electronic equipments such as network side equipment and user equipment, for example by with Family equipment operation business simultaneously gathers log parameters, then utilizes the log parameters received from user equipment to generate by network side equipment Daily record, the present invention is not particularly limited.Certainly, said one or multiple electronic equipments store and can load operating system, grasp Make that there are multiple system functions in system.Operating system includes but is not limited to apple intelligent operating system IOS systems, Android system With Windows systems etc., standard logs function that system function includes but is not limited in the embodiment of the present invention, generation window GetScreenMode functions of Oncreat functions and acquisition screen present display mode etc., the present invention is not particularly limited.
Business in the embodiment of the present invention can be any business run in the electronic device, such as network direct broadcasting industry Business, searching service, shopping service and payment transaction etc., the present invention is not particularly limited.In S101, the process of current business is run In, gather the log parameters of the daily record for generating current business.In embodiments of the present invention, log parameters include but is not limited to The state of current business, the address for accessing memory space, execute instruction coding and time etc., common skill of the art Art personnel can be according to being actually configured, and the present invention is not particularly limited.
Optionally, in one embodiment, the logic of business in itself includes the default log function of the business, then may be used With the log parameters required for being gathered according to the log function of the business.Wherein, for one business of log function is exclusive, no May be different with log parameters needed for the log function of business, and the daily record standard ultimately generated may also be different.Another Plant in embodiment, the logic of business in itself does not include log function, then can be according to the standard in electronic apparatus system function Log parameters required for log function collection.
When needing generation log function, in S102, standard logs function is called.Specifically, the embodiment of the present invention In standard logs function be system function, in other words, the standard logs function is a function in system function, rather than A function in multiple functions of business.Standard logs function is used to generate daily record, and the input of standard logs function is daily record Parameter, output is then the daily record generated according to log parameters.
Further, for calling time of standard logs function, in wherein a kind of embodiment, adjusted every predetermined period With a standard logs function, that is, during current business is run, a daily record is just generated every predetermined period. In another embodiment, call standard logs function, that is, current when the logic for generating daily record is gone in current business Business needs just to generate a daily record during generation daily record.In another embodiment, current business performs the finger of predetermined number A standard logs function is called after order, predetermined number is, for example, 10 or 20 etc..That is, current business often performs predetermined number A daily record is generated after instruction.During implementing, the time of standard logs function is called to be not limited to above-mentioned embodiment, Those skilled in the art can be selected according to actual, and the present invention is not particularly limited.
Call after standard logs function, in S103, the log parameters collected are inputted in standard logs function and run Standard logs function, and then obtain the daily record of the current business of standard logs function output.
It can be seen from foregoing description in embodiments of the present invention, due to standard logs function generate daily record mode and Standard will not change because of different business, therefore different calling service standard unified standard logs function generates daily record, Allow for different business and generate the consistent daily record of standard.And then, when searching for and reading daily record, due to the daily record of each business Standard is unified, so search and the efficiency read more facilitate, and it is more efficient.
During implementing, if current because including the log function of oneself, in order to avoid current business is run The personalized daily record of log function generation, and then disturb the generation of mark daily record, can the business log function entrance Place sets hook HOOK functions to intercept instruction, log parameters etc., so that log function can not be run and generate daily record.
Further, with reference in above-described embodiment, as a kind of optional embodiment, also include after S103:
The daily record of the current business is stored into the first memory space, first memory space is used to cache day Will;
Judge whether the daily record stored in first memory space meets preparatory condition;
When the daily record stored in first memory space meets the preparatory condition, by first memory space The daily record of storage is stored into the second memory space, and second memory space is used to preserve daily record.
Specifically, the daily record generated for standard logs function, the storage of daily record finally can't be stored at once empty Between, i.e. the second memory space, but first by daily record storage to the first memory space.In embodiments of the present invention, the first storage is empty Between be used for caching standard log function generate daily record.Wherein, the first memory space can be specially the memory space in internal memory, Or can also be not particularly limited for the space in hard disk, the present invention.Second memory space is then the sky of longer-term storage daily record Between, such as the space in hard disk.
The daily record of current business may be only stored in first memory space, it is also possible to while the daily record of history service is stored, The present invention is not particularly limited.The daily record stored in first memory space is monitored, judges to store in the first memory space Whether daily record meets preparatory condition.Also, when the daily record in the first memory space meets preparatory condition, by the first memory space In daily record store into the second memory space.
In one embodiment, it is specially judgement to judge whether the daily record in the first memory space meets preparatory condition Whether the data volume of the daily record in one memory space reaches preset data amount, and preset data amount is, for example, 10M, 3M or 500K etc., The present invention is not particularly limited.When the data volume of the daily record in the first memory space reaches preset data amount, represent that first deposits Daily record in storage space meets preparatory condition, conversely, when the data volume of the daily record in the first memory space is not up to preset data During amount, represent that the daily record in the first memory space is unsatisfactory for preparatory condition.In another embodiment, judge that the first storage is empty Between in daily record whether meet preparatory condition be specially judge whether to reach from first daily record of storage time interval so far it is pre- If time interval, prefixed time interval is, for example, 3S or 10S etc..When time interval reaches prefixed time interval, first is represented Daily record in memory space meets preparatory condition, conversely, when time interval is not up to prefixed time interval, representing that first stores Daily record in space is unsatisfactory for preparatory condition.In another embodiment, judge whether the daily record in the first memory space is full Sufficient preparatory condition can also be specially judge the corresponding business of daily record in the first memory space whether end of run.Deposit when first After the corresponding service operation of daily record in storage space terminates, represent that the daily record in the first memory space meets preparatory condition, conversely, At the end of the corresponding business off-duty of daily record in the first memory space, represent that the daily record in the first memory space is unsatisfactory for pre- If condition.
During implementing, those skilled in the art can be according to the above-mentioned implementation of actual selection Any of mode or other embodiment, the present invention are not particularly limited.
Seen from the above description, first the daily record of current business is stored into the first memory space, in the first memory space The daily record of storage again stores the daily record of the first memory space into the second memory space when meeting preparatory condition, thus reduces The consumption of device resource caused by write operation is performed to the second memory space.
Further, with reference to above-described embodiment, as a kind of optional embodiment, standard logs function includes predetermined keyword Operation standard log function in extracting rule, S103, including:
The keyword of the daily record of the current business is extracted according to the predetermined keyword.
Specifically, during implementing, those skilled in the art can work out predetermined keyword extracting rule Into standard logs function, predetermined keyword extracting rule is set to turn into a part of logic of standard logs function.So, in S103 During operation standard log function, not only daily record can be generated based on log parameters, can also extract and advise according to predetermined keyword Then carry out keyword extraction.
Specifically, the keyword in the embodiment of the present invention includes but is not limited to Business Name, Exception Type, error code With the function name of misoperation etc..And then, predetermined keyword extracting rule also includes a variety of.In one embodiment, day Will parameter at least includes Business Name or code, and predetermined keyword extracting rule is specially to extract the business that log parameters include Title.In another embodiment, log parameters at least include access path, and predetermined keyword extracting rule is specially to extract Access path in log parameters.In another embodiment, standard logs function judges that current business is according to log parameters It is no exception or mistake occur, if there is exception and mistake, abnormal and mistake code recorded in daily record.Implement in this kind In mode, predetermined keyword extracting rule is specially the exception or error code extracted and included in daily record.In another embodiment party In formula, standard logs function judges whether current business has illegal operation according to log parameters, for example, go fishing or access privacy Space etc., if with illegal operation, the description information of illegal operation recorded in daily record.In this kind of embodiment, Predetermined keyword extracting rule is specially to extract to include illegal operation description information in daily record.
During implementing, those skilled in the art can be according to the above-mentioned implementation of actual selection Any of mode or other embodiment, the present invention are not particularly limited.
Further, during implementing, the keyword extracted can be recorded in log content, can also conduct Journal file name either journal file name part or can also create in the list for recording each bar daily record keyword Deng the present invention is not particularly limited.
Daily record keyword is extracted according to preset rules, then it can be seen from foregoing description when searching for daily record by closing Keyword can more rapidly search for correlation log, then day can more be understood quickly according to keyword when reading daily record Will content, so, further increase search and read the efficiency of daily record.
Further, with reference to above-described embodiment, as a kind of optional embodiment, standard logs function also includes predetermined level Operation standard log function in division rule, S103, including:
Grade classification is carried out to the daily record of the current business according to the predetermined level division rule.
Specifically, during implementing, predetermined level division rule can be organized into by those skilled in the art In standard logs function, predetermined level division rule is set to turn into a part of logic of standard logs function.So, run in S103 During standard logs function, not only daily record can be generated based on log parameters, be closed according to predetermined keyword extracting rule Keyword is extracted, and can also mark off logging level according to predetermined level.
Specifically, the grade in the embodiment of the present invention includes but is not limited to normal level and exception level, represents different The grade of error level and the grade for representing service priority, the present invention are not particularly limited.
In order to illustrate how to carry out grade classification to the daily record of current business according to predetermined level division rule, below with etc. Level is specially normal level and exception level, exemplified by the grade for representing different error levels and the grade for representing service priority To illustrate.
(1) predetermined level is specially normal level and exception level.Normal level represents business normal termination, exception level Represent that service exception terminates.In one embodiment, divided according to predetermined level division rule, specially judge daily record In end type whether be normal type.If end type is normal type, the daily record is divided into normal level, instead It, if end type is not normal type, Exception Type is divided into by the daily record.In another embodiment, daily record Keyword include end type, then daily record need not be analyzed, directly judge that the end type in keyword is No is normal type.
(2) predetermined level is the grade for representing different error levels.For convenience of explanation, it is assumed that system mistake for it is urgent, Warning, mistake, message and Debug, corresponding error level are once 1,2,3,4 and 5.In one embodiment, daily record is joined Number includes type of error, is divided according to predetermined level division rule, is specially the wrong class included according to log parameters Type, using the corresponding grade of the type of error as the daily record grade.As an example it is assumed that the wrong class that log parameters include Type is urgent, because urgent corresponding grade is 1, so the errorlevel for determining the daily record generated by the log parameters is 1. In another embodiment, manual or automatic comprehensive analysis can also be carried out to the content of daily record, thus divide errorlevel 4.
(3) predetermined level is the priority of different business.For convenience of explanation, it is assumed that the priority of business from high to low according to It is secondary including buying the business of virtual present, recharging service, the business for buying free gift, concern business and viewing network direct broadcasting Business, corresponding predetermined level is then followed successively by 1,2,3,4 and 5.In one embodiment, log parameters include the class of business Type, is divided according to predetermined level division rule, is specially the type of service included according to log parameters, by the type of service Corresponding grade as the daily record grade.As an example it is assumed that the type of service that log parameters include is supplements with money, due to filling The corresponding grade of value business is 2, so the grade for determining the daily record generated by the log parameters is 2.In another embodiment In, the keyword of daily record includes type of service, then directly according to the type of service in keyword to the daily record etc. it is grading Row is divided.As an example it is assumed that the keyword of a daily record includes " concern ", because the corresponding grade of concern business is 4, So the grade for determining this daily record is 4.
During implementing, also include other embodiment party according to the grade of predetermined level division rule division log Formula, is not just repeated one by one here, and those skilled in the art can be of the invention according to being actually configured It is not particularly limited.
Seen from the above description, according to predetermined level division rule division log grade, make administrative staff can be with specific aim Search for and read daily record in ground.For example predetermined level is normal level and exception level, in order to improve service reliability, then specific aim Read the daily record that grade is exception level in ground.So, further increase search and read the efficiency of daily record.
Further, with reference to above-described embodiment, as a kind of optional embodiment, the daily record that will be stored in the first memory space Second memory space, including:
The daily record stored in first memory space storage is arrived described second according to the keyword and/or grade of daily record In memory space.
Specifically, can be according to random suitable when the daily record in the first memory space is stored to the second memory space Sequence is stored, or the time sequencing storage according to generation daily record etc..In wherein a kind of embodiment, according to the key of daily record Word, the same or analogous daily record of keyword is stored in logical address in the second memory space is continuous or physical address is continuously deposited Store up space.Or, in another embodiment party, logging level identical daily record is stored in logical address in the second memory space The continuous or continuous memory space of physical address.Or, it is in another embodiment, daily record keyword is same or similar, And grade identical daily record is stored in that logical address in the second memory space is continuous or the continuous memory space of physical address.
Seen from the above description, daily record is stored according to the keyword and/or grade of daily record, not only can further improves and search Rope and the efficiency for reading daily record, are also convenient for managing daily record, such as when deleting the daily record of a certain grade, it is not necessary to which searching one by one should The daily record of business, is deleted according to continuation address.
Based on the same inventive concept of the method with generating daily record in previous embodiment, second aspect of the present invention also provides one The device of generation daily record is planted, as shown in Fig. 2 including:
Acquisition module 101, for during current business is run, gathering the day of the daily record for generating current business Will parameter;
Calling module 102, for calling standard logs function, the standard logs function is system function;
Generation module 103, for by the incoming standard logs function of the log parameters, and runs the standard logs Function, to generate the daily record of the current business.
Further, described device also includes:
First memory module, for after the daily record of the current business is generated, the daily record of the current business to be deposited Store up into the first memory space, first memory space is used for log cache;
Whether judge module, the daily record for judging to store in first memory space meets preparatory condition;
Second memory module, for when the daily record stored in first memory space meets the preparatory condition, inciting somebody to action The daily record stored in first memory space is stored into the second memory space, and second memory space is used to preserve day Will.
Further, the standard logs function include predetermined keyword extracting rule, the generation module be used for according to The predetermined keyword extracts the keyword of the daily record of the current business.
Further, the standard logs function also include predetermined level division rule, the generation module be used for according to Daily record of the predetermined level division rule to the current business carries out grade classification.
Further, second memory module is used to store described first according to the keyword and/or grade of daily record The daily record stored in space is stored into second memory space.
The various change mode and instantiation of the method for generation daily record in the embodiment of earlier figures 1 are equally applicable to this reality The device of the generation daily record of example is applied, by the foregoing detailed description to generating the method for daily record, those skilled in the art can be clear The implementation for knowing the device that daily record is generated in the present embodiment of Chu, thus it is succinct for specification, it will not be described in detail herein.
Said one or multiple technical schemes in the embodiment of the present application, are at least imitated with following one or more technologies Really:
In the technical scheme of the embodiment of the present invention, during current business is run, gather for generating current industry The log parameters of the daily record of business, then call standard logs function, and the standard logs function is system function, then will be described The incoming standard logs function of log parameters, and the standard logs function is run, to generate the daily record of the current business. It can be seen that, the daily record is generated by the unified standard logs function, then, even if the different business of operation, also can The unified daily record of acquisition standard, so the embodiment of the present invention realizes the technique effect of daily record standardization.So, compared to various Change daily record, search and reading daily record efficiency are improved.
It should be understood by those skilled in the art that, embodiments of the invention can be provided as method, system or computer program Product.Therefore, the present invention can be using the reality in terms of complete hardware embodiment, complete software embodiment or combination software and hardware Apply the form of example.Moreover, the present invention can be used in one or more computers for wherein including computer usable program code The computer program production that usable storage medium is implemented on (including but is not limited to magnetic disk storage, CD-ROM, optical memory etc.) The form of product.
The present invention is the flow with reference to method according to embodiments of the present invention, equipment (system) and computer program product Figure and/or block diagram are described.It should be understood that can be by every first-class in computer program instructions implementation process figure and/or block diagram Journey and/or the flow in square frame and flow chart and/or block diagram and/or the combination of square frame.These computer programs can be provided The processor of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing devices is instructed to produce A raw machine so that produced by the instruction of computer or the computing device of other programmable data processing devices for real The device for the function of being specified in present one flow of flow chart or one square frame of multiple flows and/or block diagram or multiple square frames.
These computer program instructions, which may be alternatively stored in, can guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works so that the instruction being stored in the computer-readable memory, which is produced, to be included referring to Make the manufacture of device, the command device realize in one flow of flow chart or multiple flows and/or one square frame of block diagram or The function of being specified in multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that in meter Series of operation steps is performed on calculation machine or other programmable devices to produce computer implemented processing, thus in computer or The instruction performed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one The step of function of being specified in individual square frame or multiple square frames.
Obviously, those skilled in the art can carry out the essence of various changes and modification without departing from the present invention to the present invention God and scope.So, if these modifications and variations of the present invention belong to the scope of the claims in the present invention and its equivalent technologies Within, then the present invention is also intended to comprising including these changes and modification.

Claims (10)

1. a kind of method for generating daily record, it is characterised in that including:
During current business is run, the log parameters of the daily record for generating current business are gathered;
Standard logs function is called, the standard logs function is system function;
By the incoming standard logs function of the log parameters, and the standard logs function is run, it is described current to generate The daily record of business.
2. the method as described in claim 1, it is characterised in that after the daily record of the current business is generated, methods described Also include:
The daily record of the current business is stored into the first memory space, first memory space is used for log cache;
Judge whether the daily record stored in first memory space meets preparatory condition;
When the daily record stored in first memory space meets the preparatory condition, it will be stored in first memory space Daily record store into the second memory space, second memory space be used for preserve daily record.
3. method as claimed in claim 2, it is characterised in that the standard logs function includes predetermined keyword and extracts rule Then, the standard logs function is run, including:
The keyword of the daily record of the current business is extracted according to the predetermined keyword.
4. method as claimed in claim 3, it is characterised in that the standard logs function also includes predetermined level and divides rule Then, the standard logs function is run, in addition to:
Grade classification is carried out to the daily record of the current business according to the predetermined level division rule.
5. method as claimed in claim 4, it is characterised in that store the daily record second stored in first memory space Space, including:
The daily record stored in first memory space storage is stored to described second according to the keyword and/or grade of daily record In space.
6. a kind of device for generating daily record, it is characterised in that including:
Acquisition module, for during current business is run, gathering the log parameters of the daily record for generating current business;
Calling module, for calling standard logs function, the standard logs function is system function;
Generation module, for by the incoming standard logs function of the log parameters, and runs the standard logs function, with Generate the daily record of the current business.
7. device as claimed in claim 6, it is characterised in that described device also includes:
First memory module, for after the daily record of the current business is generated, the daily record storage of the current business to be arrived In first memory space, first memory space is used for log cache;
Whether judge module, the daily record for judging to store in first memory space meets preparatory condition;
Second memory module, for when the daily record stored in first memory space meets the preparatory condition, by described in The daily record stored in first memory space is stored into the second memory space, and second memory space is used to preserve daily record.
8. device as claimed in claim 7, it is characterised in that the standard logs function includes predetermined keyword and extracts rule Then, the generation module is used for the keyword that the daily record of the current business is extracted according to the predetermined keyword.
9. device as claimed in claim 8, it is characterised in that the standard logs function also includes predetermined level and divides rule Then, the generation module is used to carry out grade classification to the daily record of the current business according to the predetermined level division rule.
10. device as claimed in claim 9, it is characterised in that second memory module is used for the keyword according to daily record And/or grade stores the daily record stored in first memory space into second memory space.
CN201710204037.XA 2017-03-30 2017-03-30 Method and device for generating log Active CN107193721B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710204037.XA CN107193721B (en) 2017-03-30 2017-03-30 Method and device for generating log

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710204037.XA CN107193721B (en) 2017-03-30 2017-03-30 Method and device for generating log

Publications (2)

Publication Number Publication Date
CN107193721A true CN107193721A (en) 2017-09-22
CN107193721B CN107193721B (en) 2020-10-16

Family

ID=59871720

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710204037.XA Active CN107193721B (en) 2017-03-30 2017-03-30 Method and device for generating log

Country Status (1)

Country Link
CN (1) CN107193721B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110515814A (en) * 2019-08-16 2019-11-29 海南车智易通信息技术有限公司 Full dose log collecting method, device and the mobile terminal of iOS client
CN111897789A (en) * 2020-07-15 2020-11-06 中国民航信息网络股份有限公司 Log generation method and device

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060167955A1 (en) * 2005-01-21 2006-07-27 Vertes Marc P Non-intrusive method for logging of internal events within an application process, and system implementing this method
US20090222492A1 (en) * 2008-02-28 2009-09-03 Mtsubishi Electric Corporation Logging Device and Recording Medium
CN102609484A (en) * 2012-01-19 2012-07-25 北京神州数码思特奇信息技术股份有限公司 General method for managing log of system
CN102891873A (en) * 2011-07-21 2013-01-23 腾讯科技(深圳)有限公司 Method for storing log data and log data storage system
CN102981943A (en) * 2012-10-29 2013-03-20 新浪技术(中国)有限公司 Method and system for monitoring application logs
CN105022774A (en) * 2014-04-15 2015-11-04 Ls产电株式会社 Apparatus, system and method for application log data processing
CN105187241A (en) * 2015-08-19 2015-12-23 浪潮(北京)电子信息产业有限公司 Log recording method and system based on linux kernel
CN105843852A (en) * 2016-03-16 2016-08-10 汉柏科技有限公司 Log storage management method and system

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060167955A1 (en) * 2005-01-21 2006-07-27 Vertes Marc P Non-intrusive method for logging of internal events within an application process, and system implementing this method
US20090222492A1 (en) * 2008-02-28 2009-09-03 Mtsubishi Electric Corporation Logging Device and Recording Medium
CN102891873A (en) * 2011-07-21 2013-01-23 腾讯科技(深圳)有限公司 Method for storing log data and log data storage system
CN102609484A (en) * 2012-01-19 2012-07-25 北京神州数码思特奇信息技术股份有限公司 General method for managing log of system
CN102981943A (en) * 2012-10-29 2013-03-20 新浪技术(中国)有限公司 Method and system for monitoring application logs
CN105022774A (en) * 2014-04-15 2015-11-04 Ls产电株式会社 Apparatus, system and method for application log data processing
CN105187241A (en) * 2015-08-19 2015-12-23 浪潮(北京)电子信息产业有限公司 Log recording method and system based on linux kernel
CN105843852A (en) * 2016-03-16 2016-08-10 汉柏科技有限公司 Log storage management method and system

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110515814A (en) * 2019-08-16 2019-11-29 海南车智易通信息技术有限公司 Full dose log collecting method, device and the mobile terminal of iOS client
CN110515814B (en) * 2019-08-16 2023-09-19 海南车智易通信息技术有限公司 Method and device for collecting full log of iOS client and mobile terminal
CN111897789A (en) * 2020-07-15 2020-11-06 中国民航信息网络股份有限公司 Log generation method and device
CN111897789B (en) * 2020-07-15 2024-04-02 中国民航信息网络股份有限公司 Log generation method and device

Also Published As

Publication number Publication date
CN107193721B (en) 2020-10-16

Similar Documents

Publication Publication Date Title
CN104156201B (en) Apparatus and method for generating user interface
CN110442712B (en) Risk determination method, risk determination device, server and text examination system
CN107767021A (en) A kind of risk control method and equipment
CN107424069A (en) A kind of generation method of air control feature, risk monitoring and control method and apparatus
CN103336737B (en) Information handling systems and the method for enforcement thereof
CN112199430A (en) Business data processing system and method based on data middling station
US20080195404A1 (en) Compliant-based service level objectives
US20150052129A1 (en) Weighting sentiment information
US20090319951A1 (en) Aggregating Service Components
CN108984658A (en) A kind of intelligent answer data processing method and device
CN107678938A (en) The adjustment method and equipment of a kind of application program
CN104216911B (en) One kind browses tracking and device
US11016730B2 (en) Transforming a transactional data set to generate forecasting and prediction insights
CN109871963A (en) Operation troubles restoring method, device, electronic equipment and storage medium
CN113157947A (en) Knowledge graph construction method, tool, device and server
CN109992569A (en) Cluster log feature extracting method, device and storage medium
CN109543891A (en) Method for building up, equipment and the computer readable storage medium of capacity prediction model
CN103886250B (en) The data processing method of service-oriented support system, device, controller and system
CN109767269A (en) A kind for the treatment of method and apparatus of game data
CN105405221A (en) Method and device for automated test
CN108228709A (en) Date storage method and system, electronic equipment, program and medium
CN107070897A (en) Network log storage method based on many attribute Hash duplicate removals in intruding detection system
CN107193721A (en) A kind of method and apparatus for generating daily record
CN106899436A (en) A kind of cloud platform failure predication diagnostic system
CN109614380A (en) Log processing method, system, computer equipment and readable medium

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
GR01 Patent grant
GR01 Patent grant