Specific embodiment
In a computer, journal file is the record file or file set for records application program action event, can
Activity, the tracking for diagnosing problem, processing historical data etc. for understanding application program.Application program issue it is online before,
Close beta can generally be passed through can just issue online after through close beta.For being in the terminal in close beta stage
On application program, almost all the time all generate log information, when application program close beta run break down when, phase
That answers can also generate log information, for recording when secondary failure.Therefore for operation and maintenance personnel, when answering in terminal
It is run with program close beta when breaking down, generally requires by journal file and analyze and orientation problem, and primary asked
Topic is that operation maintenance personnel needs to check log information in journal file, to analyze and orientation problem.Particularly, for difference
Operation and maintenance personnel for, it is sometimes desirable to check log information caused by application program in more terminals.
The method for the log information checked in journal file at present is: log displaying terminal is sent to terminal obtains log text
The instruction of part, terminal is after receiving the instruction for obtaining journal file, and by corresponding journal file, (application program is generated
Log information encryption write-in journal file) it is uploaded to log displaying terminal, the journal file is decrypted in log displaying terminal,
After the journal file is decrypted, operation and maintenance personnel searches pair from the journal file that log displaying terminal is stored
The journal file answered, and check the log information in the journal file, need to consume accordingly operation and maintenance personnel it is certain when
Between and energy go to search corresponding journal file, and the day in journal file is checked after finding corresponding journal file
Will information.
In view of the above-mentioned problems, this specification provides a kind of technical solution, log generates terminal and intercepts local application institute
The log information of generation stores to data buffer storage space, for the day in data buffer storage space the log information intercepted
Will information can send it to log displaying terminal, so that log displaying terminal shows the log information.Operation is tieed up
For shield personnel, the real time inspection log information on log displaying terminal can be directly selected, saves and searches journal file
Time and efforts effectively increases the efficiency for solving failure.
Specifically, the technical solution that this specification provides is as follows:
One or more log generates terminal and is attached with one or more log displaying terminal;To locally applied journey
Before the encryption of log information caused by sequence, log generates terminal and intercepts log information caused by local application;For
The log information intercepted is stored to data buffer storage space;It will be in the data buffer storage space according to preset push rule
Log information pushes to log displaying terminal;Log displaying terminal receives log and generates the log information that terminal is pushed, and opens up
Show the log information.
In the present specification, log, which generates terminal, can be mobile phone, the equipment such as plate, and log displaying terminal can be notes
The equipment such as sheet, computer, display.One or more log generates terminal and is connected with one or more described log displaying terminal
It connects, it is meant that: generating terminal for every log can connect one or more log displaying terminals, and every log is shown
Terminal can connect the log information that one or more log generates terminal push, and a kind of log generates terminal and log is shown eventually
The schematic diagram being attached is held, as shown in Figure 1, log generates terminal and log displaying terminal can be real by various forms of networks
It now communicates to connect, this specification is not construed as limiting this.
In order to make those skilled in the art more fully understand the technical solution in this specification embodiment, below in conjunction with this
Attached drawing in specification embodiment is described in detail the technical solution in this specification embodiment, it is clear that described
Embodiment is only a part of the embodiment of this specification, instead of all the embodiments.The embodiment of base in this manual,
Those of ordinary skill in the art's every other embodiment obtained, all should belong to the range of protection.
As shown in Fig. 2, a kind of interaction schematic diagram of the log information methods of exhibiting provided for this specification, this method are specific
It may comprise steps of:
S201, before to the encryption of log information caused by local application, log generates terminal and intercepts local answer
The log information caused by program;
In general, log generate the application program installed in terminal run caused by log information by interface class (such as
LoggerImpi interface class can be regarded as an example, realize specific function, all journal functions, such as by log
Information is recorded in journal file, is realized by such) it encrypts in write-in journal file, the skill provided by this specification
In art scheme, be pre-configured with journaling agent class (such as LoggerProxy, it is similar with interface class, also can be regarded as realizing specific
The example of function), before interface class encrypts log information caused by local application, log generates terminal and blocks
Cut log information caused by local application, it can the locally applied journey in interface class is intercepted by the journaling agent class
Log information caused by sequence, it is meant that log generates log information caused by the application program operation installed in terminal and arrives
While up to interface class (unencryption at this time), journaling agent class can intercept log caused by local application from interface class
Information, that is, what is intercepted is log cleartext information.
It is worth noting that, every log, which generates terminal, can intercept local answer when generating terminal comprising more logs
All log informations caused by program.
S202 stores to data buffer storage space the log information intercepted;
For the log information intercepted, on the one hand, store the log information intercepted into data buffer storage space, separately
On the one hand, the log information intercepted is encrypted in write-in journal file according to preset Encryption Algorithm.
In addition, the log information intercepted can also be stored to data in addition to above-mentioned described data buffer storage space
In cache file or data buffer storage database, this specification is not construed as limiting this.
The log information intercepted is encrypted in write-in journal file according to preset Encryption Algorithm, which can be with
It is des encryption algorithm, RSA cryptographic algorithms etc., this specification is not construed as limiting specific Encryption Algorithm, with close in journal file
The form of text stores log information.
Log information in the data buffer storage space is pushed to log according to preset push rule and shown eventually by S203
End;
For the log information in data buffer storage space, it is regular by the data according to preset push that log generates terminal
Log information in spatial cache pushes to log displaying terminal, and wherein log generates terminal by the day in data buffer storage space
Will information presets the push rule of log information before pushing to log displaying terminal:
Terminal is generated for every log, the log information in data buffer storage space is pushed into all logs and is shown eventually
End, such as log generate terminal A and the log information in data buffer storage space are pushed to log displaying terminal B, log displaying eventually
Hold C.
Terminal is generated for every log, the log information in data buffer storage space is pushed into corresponding log and is shown eventually
End, such as log generate terminal A and the log information in data buffer storage space are pushed to log displaying terminal A1, and log generates eventually
Hold B that the log information in data buffer storage space is pushed to log displaying terminal B1.
Terminal is generated for all logs, the log information in data buffer storage space is pushed into every log and is shown eventually
End, such as log generate terminal A and the log information in data buffer storage space are pushed to log displaying terminal a, and log generates eventually
Hold B that the log information in data buffer storage space is pushed to log displaying terminal a.
Specific push rule is varied, and this is no longer going to repeat them for this specification.
In addition terminal is generated with every log and the log information in data buffer storage space is pushed into 5 log displaying terminals
For, the log information in data buffer storage space can be sent to by this 5 log displaying terminals according to preset transmission rule,
For the transmission medium that log generates between terminal and log displaying terminal, there are the theoretic transmission rate upper limit,
Within the scope of this, log information can be sent to by log displaying terminal according to certain transmission rate, it is ensured that log information
It can be successfully transmitted to log displaying terminal.For example, the transmission medium is USB data line, the transmission rate upper limit is 12Mbps, to
It can be 5Mbps that this 5 log displaying terminals, which send the rate of log information, it is ensured that log information can be successfully transmitted to log
Displaying terminal.Or log information periodically is sent to this 5 log displaying terminals, such as can be with 2 seconds for the period, every time
5000 log informations are sent to log displaying terminal.
Furthermore it is also possible to log information wherein included is chosen according to preset selection rule from data buffer storage space,
Selection rule can be according to log information generation time choose default number of branches log information, such as choose generation time it is more early
Preceding 5000 log informations, or choose generation time preceding 3000 log informations earlier, it is regular according to preset push
Selected log information in data buffer storage space is pushed into log displaying terminal.
Secondly, log generate terminal can by passively push or active push in the form of push to log displaying terminal,
It, will be described according to preset push rule i.e. in the case where receiving the journal file acquisition instruction of log displaying terminal transmission
Log information in data buffer storage space pushes to log displaying terminal, or is monitoring the application program operation appearance event
In the case where barrier, the log information in the data buffer storage space is pushed into log according to preset push rule and is shown eventually
End is specifically not construed as limiting using that mode this specification.
S204, log displaying terminal receives log and generates the log information that terminal is pushed, and shows the log information.
After the log information in the data buffer storage space is pushed to log displaying terminal through the above way, day
Will displaying terminal receives log information, and shows the log information.For every log displaying terminal can receive one or
More logs generate the log information of terminal push, for example, for log displaying terminal A1 can receive log generate terminal A and
Log generates the log information that terminal B is pushed or log displaying terminal A1 and can receive log and generate what terminal A was pushed
Log information, log displaying terminal B1 can receive log and generate log information or log displaying terminal that terminal B is pushed
A1, log displaying terminal B1 can receive log and generate the log information that terminal A is pushed, and specific log displaying terminal connects
The multimodal multiplicity of form that log generates the log information that terminal is pushed is received, this is no longer going to repeat them for this specification.
For received every log generate the log information of terminal push, can classify displaying, and mark every class day
The source of will information, wherein can be marked with IP address, title, the MAC Address etc. that log generates terminal.For example, for
Log displaying terminal A receives log generation terminal A1, log generates terminal A2, log generates terminal A3, log generates terminal A4,
Log generates the log information of terminal A5 push, and classifies, and every class log information can be carried out with A1, A2, A3, A4, A5
Label is distinguished.
Furthermore it is possible to show log information according to certain displaying rule.Such as it can be according to certain displaying period
It successively shows log information, and shows that the time of every log information can preset, such as with two seconds for the period, successively
Show that log information, log information show that the time is two seconds.It can also be the log information for showing fixed strip number every time, such as can
Once to show 5 or 10 log informations.
Log generates terminal and can not only store the log information intercepted to data buffer storage space in the present specification
In, the log information intercepted can also be encrypted in write-in journal file according to preset Encryption Algorithm, it is meant that intercept
It after log information, is on the one hand stored into data buffer storage space, is on the other hand also calculated it according to preset encryption
In method encryption write-in journal file, log information deposits in data buffer storage space with plaintext version, while also being deposited with ciphertext form
It is put in journal file, can first be stored into data buffer storage space, then encrypt it according to preset Encryption Algorithm
It is written in journal file, alternatively, writing it according to the encryption of preset Encryption Algorithm while storage to data buffer storage space
Enter in journal file, execution sequence this specification of above-mentioned two step is not construed as limiting.
By the description of the above-mentioned technical solution provided this specification, log generates terminal and intercepts local application institute
The log information of generation stores to data buffer storage space, for the day in data buffer storage space the log information intercepted
Will information can send it to log displaying terminal, so that log displaying terminal shows the log information.Operation is tieed up
For shield personnel, the real time inspection log information on log displaying terminal can be directly selected, saves and searches journal file
Time and efforts effectively increases the efficiency for solving failure.
In order to better illustrate the scheme of this specification embodiment, separately below from unilateral angle, to the method for execution
It is illustrated:
Terminal is generated for log, needing to be implemented for task is mainly as follows:
S1, before to the encryption of log information caused by local application, it is locally applied that log generates terminal interception
Log information caused by program;
S2 stores to data buffer storage space the log information intercepted;
Log information in the data buffer storage space is pushed to log according to preset push rule and shown eventually by S3
End;
For log displaying terminal, needing to be implemented for task is mainly as follows:
B1, log displaying terminal receives log and generates the log information that terminal is pushed, and shows the log information.
Relative to above method embodiment, this specification also provides a kind of log information displaying device, is applied to terminal, such as
Shown in Fig. 3, which includes: information intercepting module 310, information storage module 320, info push module 330.
Information intercepting module 310, for intercepting local before to the encryption of log information caused by local application
Log information caused by application program;
Message processing module 320 is stored for the log information for being intercepted to data buffer storage space;
Info push module 330, for regular by the log information in the data buffer storage space according to preset push
Log displaying terminal is pushed to, so that log displaying terminal receives log and generates the log information that terminal is pushed, and shows institute
State log information.
This specification also provides a kind of log information display systems, which includes: that log generates terminal, log is shown eventually
End is attached wherein the log generates terminal with log displaying terminal;
Before to the encryption of log information caused by local application, log generates terminal and intercepts local application
Generated log information;
For the log information intercepted, store to data buffer storage space;
The log information in the data buffer storage space is pushed into log displaying terminal according to preset push rule;
Log displaying terminal receives log and generates the log information that terminal is pushed, and shows the log information.
By the description of the above-mentioned technical solution provided this specification, log generates terminal and intercepts local application institute
The log information of generation stores to data buffer storage space, for the day in data buffer storage space the log information intercepted
Will information can send it to log displaying terminal, so that log displaying terminal shows the log information.Operation is tieed up
For shield personnel, the real time inspection log information on log displaying terminal can be directly selected, saves and searches journal file
Time and efforts effectively increases the efficiency for solving failure.
This specification embodiment also provides a kind of computer equipment, as shown in figure 4, the equipment may include: processor
410, memory 420, input/output interface 430, communication interface 440 and bus 450.Wherein processor 410, memory 420,
Input/output interface 430 and communication interface 440 pass through the communication connection between the realization of bus 450 inside equipment.
Processor 410 can use general CPU (Central Processing Unit, central processing unit), micro process
Device, application specific integrated circuit (Application Specific Integrated Circuit, ASIC) or one or
The modes such as multiple integrated circuits are realized, for executing relative program, to realize technical solution provided by this specification embodiment.
Memory 420 can use ROM (Read Only Memory, read-only memory), RAM (Random Access
Memory, random access memory), static storage device, the forms such as dynamic memory realize.Memory 420 can store
Operating system and other applications are realizing technical solution provided by this specification embodiment by software or firmware
When, relevant program code is stored in memory 420, and execution is called by processor 410.
Input/output interface 430 is for connecting input/output module, to realize information input and output.Input and output/
Module can be used as component Configuration (not shown) in a device, can also be external in equipment to provide corresponding function.Wherein
Input equipment may include keyboard, mouse, touch screen, microphone, various kinds of sensors etc., output equipment may include display,
Loudspeaker, vibrator, indicator light etc..
Communication interface 440 is used for connection communication module (not shown), to realize the communication of this equipment and other equipment
Interaction.Wherein communication module can be realized by wired mode (such as USB, cable etc.) and be communicated, can also be wirelessly
(such as mobile network, WIFI, bluetooth etc.) realizes communication.
Bus 450 includes an access, in various components (such as the processor 410, memory 420, input/output of equipment
Interface 430 and communication interface 440) between transmit information.
It should be noted that although above equipment illustrates only processor 410, memory 420, input/output interface
430, communication interface 440 and bus 450, but in the specific implementation process, which can also include realizing to operate normally
Necessary other assemblies.In addition, it will be appreciated by those skilled in the art that, it can also be only comprising realizing in above equipment
Component necessary to this specification example scheme, without including all components shown in figure.
This specification embodiment also provides a kind of computer readable storage medium, is stored thereon with computer program, the journey
Log information methods of exhibiting above-mentioned is realized when sequence is executed by processor.This method includes at least:
A kind of log information methods of exhibiting is applied to log and generates terminal, this method comprises:
Before to the encryption of log information caused by local application, log caused by local application is intercepted
Information;
For the log information intercepted, store to data buffer storage space;
The log information in the data buffer storage space is pushed into log displaying terminal according to preset push rule, with
So that log displaying terminal is received log and generate the log information that terminal is pushed, and shows the log information.
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 (transitorymedia), such as the data-signal and carrier wave of modulation.
As seen through the above description of the embodiments, those skilled in the art can be understood that this specification
Embodiment can be realized by means of software and necessary general hardware platform.Based on this understanding, this specification is implemented
Substantially the part that contributes to existing technology can be embodied in the form of software products the technical solution of example in other words,
The computer software product can store in storage medium, such as ROM/RAM, magnetic disk, CD, including some instructions are to make
It is each to obtain computer equipment (can be personal computer, server or the network equipment etc.) execution this specification embodiment
Method described in certain parts of a embodiment or embodiment.
System, device, module or the unit that above-described embodiment illustrates can specifically realize by computer chip or entity,
Or it is realized by the product with certain function.A kind of typically to realize that equipment is computer, the concrete form of computer can
To be personal computer, laptop computer, cellular phone, camera phone, smart phone, personal digital assistant, media play
In device, navigation equipment, E-mail receiver/send equipment, game console, tablet computer, wearable device or these equipment
The combination of any several equipment.
All the embodiments in this specification are described in a progressive manner, same and similar portion between each embodiment
Dividing may refer to each other, and each embodiment focuses on the differences from other embodiments.Especially for device reality
For applying example, since it is substantially similar to the method embodiment, so describing fairly simple, related place is referring to embodiment of the method
Part explanation.The apparatus embodiments described above are merely exemplary, wherein described be used as separate part description
Module may or may not be physically separated, can be each module when implementing this specification example scheme
Function realize in the same or multiple software and or hardware.Can also select according to the actual needs part therein or
Person's whole module achieves the purpose of the solution of this embodiment.Those of ordinary skill in the art are not the case where making the creative labor
Under, it can it understands and implements.
The above is only the specific embodiment of this specification embodiment, it is noted that for the general of the art
For logical technical staff, under the premise of not departing from this specification embodiment principle, several improvements and modifications can also be made, this
A little improvements and modifications also should be regarded as the protection scope of this specification embodiment.