CN108959041A - Method, server and the computer readable storage medium that information is sent - Google Patents
Method, server and the computer readable storage medium that information is sent Download PDFInfo
- Publication number
- CN108959041A CN108959041A CN201710353011.1A CN201710353011A CN108959041A CN 108959041 A CN108959041 A CN 108959041A CN 201710353011 A CN201710353011 A CN 201710353011A CN 108959041 A CN108959041 A CN 108959041A
- Authority
- CN
- China
- Prior art keywords
- information
- analyzed
- log information
- calling service
- server
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/30—Monitoring
- G06F11/34—Recording 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/3466—Performance evaluation by tracing or monitoring
- G06F11/3476—Data logging
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3692—Test management for test results analysis
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/46—Multiprogramming arrangements
- G06F9/54—Interprogram communication
- G06F9/547—Remote procedure calls [RPC]; Web services
Abstract
The embodiment of the invention discloses a kind of methods that information is sent, comprising: obtains log information to be analyzed;The log information to be analyzed is tested using default test case, to obtain test result;If the test result meets default alarm conditions, calling service relation information is generated according to the test result, wherein the calling service relation information is used to indicate the call relation between operation layer;The calling service relation information is sent to client.The present invention also provides a kind of server and computer readable storage mediums.The embodiment of the present invention can generate according to test result and show calling service relation information, and calling service relation information can directly indicate the call relation between each operation layer, without the call relation for spending more time and efforts to obtain between operation layer, to promote the efficiency of positioning abnormal problem.
Description
Technical field
The present invention relates to field of Internet communication, especially method, server and the computer-readable storage medium of information transmission
Matter.
Background technique
With the continuous development of Internet service, so that the framework of operation system also becomes increasingly complex.Business is in execution
May there is a problem of in the process various, developer needs to ask by obtaining log information to analyze and solve these
Topic.
Currently, providing a kind of method of log information analysis, log information is collected first and analysis system acquisition is to be measured
Then the log information of examination is tested it using test case, can be according to business system if reported an error in test process
Level call relation in system positions abnormal problem.
However, since operation system calls level that can usually reach five or six grades or even deeper level, if test process
It is middle to report an error, then it needs to spend more time and efforts to be positioned according to the call relation between each level and ask extremely
Topic, to reduce the efficiency of positioning abnormal problem.
Summary of the invention
The embodiment of the invention provides method, server and computer readable storage mediums that a kind of information is sent, can be with
It is generated according to test result and shows calling service relation information, and calling service relation information can directly indicate each business
Call relation between layer, without the call relation for spending more time and efforts to obtain between operation layer, to be promoted
Position the efficiency of abnormal problem.
In view of this, first aspect present invention provides a kind of method that information is sent, comprising:
Obtain log information to be analyzed;
The log information to be analyzed is tested using default test case, to obtain test result;
If the test result meets default alarm conditions, calling service relationship letter is generated according to the test result
Breath, wherein the calling service relation information is used to indicate the call relation between operation layer;
The calling service relation information is sent to client.
Second aspect of the present invention provides a kind of server, comprising:
First obtains module, for obtaining log information to be analyzed;
Test module is believed for obtaining the log to be analyzed that module obtains to described first using default test case
Breath is tested, to obtain test result;
Generation module, if meeting default alarm conditions, basis for the test result that the test module obtains
The test result generates calling service relation information, wherein the calling service relation information is for indicating between operation layer
Call relation;
Sending module, for sending the calling service relation information that the generation module generates to client.
Third aspect present invention provides a kind of server, comprising: memory, processor and bus system;
Wherein, the memory is for storing program;
The processor is used to execute the program in the memory, includes the following steps:
Obtain log information to be analyzed;
The log information to be analyzed is tested using default test case, to obtain test result;
If the test result meets default alarm conditions, calling service relationship letter is generated according to the test result
Breath, wherein the calling service relation information is used to indicate the call relation between operation layer;
The calling service relation information is sent to client;
The bus system is for connecting the memory and the processor, so that the memory and the place
Reason device is communicated.
The fourth aspect of the present invention provides a kind of computer readable storage medium, in the computer readable storage medium
It is stored with instruction, when run on a computer, so that computer executes method described in above-mentioned various aspects.
As can be seen from the above technical solutions, the embodiment of the present invention has the advantage that
In the embodiment of the present invention, a kind of method that information is sent is provided, log to be analyzed is obtained by server first and is believed
Then breath is tested log information to be analyzed using default test case, to obtain test result, if test result meets
Default alarm conditions, then server generates calling service relation information further according to test result, wherein calling service relation information
For indicating the call relation between operation layer, calling service relation information is sent to client.By the above-mentioned means, servicing
After device detects the test result for meeting default alarm conditions, it can be generated according to test result and show calling service relationship
Information, and calling service relation information can directly indicate the call relation between each operation layer, when more without spending
Between and energy obtain the call relation between operation layer, to promote the efficiency of positioning abnormal problem.
Detailed description of the invention
Fig. 1 is the architecture diagram of information transmitting system in the embodiment of the present invention;
Fig. 2 is method one embodiment schematic diagram that information is sent in the embodiment of the present invention;
Fig. 3 is one embodiment schematic diagram of call relation between operation layer in the embodiment of the present invention;
Fig. 4 is a schematic illustration of result collection system flume in the embodiment of the present invention;
Fig. 5 is a schematic illustration of distributed information system kafka in the embodiment of the present invention;
Fig. 6 is a configuration diagram of log information analysis platform in the embodiment of the present invention;
Fig. 7 is the interface schematic diagram that log information analyzes backstage in application scenarios of the present invention;
Fig. 8 is server one embodiment schematic diagram in the embodiment of the present invention;
Fig. 9 is another embodiment schematic diagram of server in the embodiment of the present invention;
Figure 10 is another embodiment schematic diagram of server in the embodiment of the present invention;
Figure 11 is another embodiment schematic diagram of server in the embodiment of the present invention;
Figure 12 is another embodiment schematic diagram of server in the embodiment of the present invention;
Figure 13 is another embodiment schematic diagram of server in the embodiment of the present invention;
Figure 14 is one structural schematic diagram of server in the embodiment of the present invention.
Specific embodiment
The embodiment of the invention provides method, server and computer readable storage mediums that a kind of information is sent, can be with
It is generated according to test result and shows calling service relation information, and calling service relation information can directly indicate each business
Call relation between layer, without the call relation for spending more time and efforts to obtain between operation layer, to be promoted
Position the efficiency of abnormal problem.
Description and claims of this specification and term " first ", " second ", " third ", " in above-mentioned attached drawing
The (if present)s such as four " are to be used to distinguish similar objects, without being used to describe a particular order or precedence order.It should manage
The data that solution uses in this way are interchangeable under appropriate circumstances, so that the embodiment of the present invention described herein for example can be to remove
Sequence other than those of illustrating or describe herein is implemented.In addition, term " includes " and " having " and theirs is any
Deformation, it is intended that cover it is non-exclusive include, for example, containing the process, method of a series of steps or units, system, production
Product or equipment those of are not necessarily limited to be clearly listed step or unit, but may include be not clearly listed or for this
A little process, methods, the other step or units of product or equipment inherently.
It should be understood that present invention is mainly applied to analyze the scene of log information, referring to Fig. 1, Fig. 1 is the embodiment of the present invention
The architecture diagram of middle information transmitting system, as shown, being believed in log collection layer by result collection system flume collector journal
Breath, log information is transmitted in distributed information system kafka.Log filter layer acquires required log letter from kafka
Breath, specific log information collection process is, first by CGI(Common gateway interface) (common gateway interface,
CGI) log information needed for request filtering, i.e., extract original log information, next according to the specific progress of log from kafka
The log information of CGI application program (application, APP) is merged processing by the extraction of each section, and will backstage
The log information of service (middle) merges processing.
CGI APP log information and middle log information are by data cleansing layer, into distributed cache memory
System (memcache) and the database (mongo database, mongoDB) of distributed document storage.Wherein, exist
Memcache is mainly used for carrying out data buffer storage to CGI APP log information and middle log information, in addition, memcache is also
For caching the test resource in automated test tool (automation testing tools, ATT).
After tester runs automatic test cases, log analysis platform is by collecting the CGI APP in memcache
Log information, middle log information and required test case resource, can analyze log information, and surveyed
Test result, will analysis result be stored in mongoDB be used for inquire and showing interface, exhibition method include it is not limited to
The mode of mail notification.It is understood that request needed for log analysis platform mainly provides test case for ATT provides
Source.
Below by from the angle of server, the method sent to information in the present invention is introduced, referring to Fig. 2, this hair
Method one embodiment of information transmission includes: in bright embodiment
101, log information to be analyzed is obtained;
In the present embodiment, server obtains log information to be analyzed first.Specifically, server can be first in background access
And original log information is obtained, corresponding log information to be analyzed is then obtained, log information to be analyzed can be CGI APP days
Will information and middle log information, middle log information are the log information of background service.
102, log information to be analyzed is tested using default test case, to obtain test result;
In the present embodiment, server tests the log information to be analyzed got using default test case, and
Obtain test result.
Wherein, test case is one group of test input, execution condition and the expected knot worked out for some special objective
Fruit, to test some Program path or to verify whether meet some particular demands.
If 103, test result meets default alarm conditions, calling service relation information is generated according to test result,
In, calling service relation information is used to indicate the call relation between operation layer;
In the present embodiment, if obtained test result meets default alarm conditions, need according to the test result
Generate corresponding calling service relation information, wherein calling service relation information is used to indicate the call relation between operation layer.
Specifically, it is assumed that can default test case add log classification for verifying, and cannot add log when detecting
When classification, it is believed that meet default alarm conditions, the reason of this problem will occur as a result, finding according to this this when,
And calling service relation information is embodied by intuitive ways such as diagram or lists.Referring to Fig. 3, Fig. 3 is the present invention
In embodiment between operation layer call relation one embodiment schematic diagram, as shown, solid arrow indicates same step in figure
With, for example, service entitled " jjj_jjjjjjjj_jjjjj_jjjjjj " business can another service be entitled with synchronization call
The business of " i_iiii_iiiiii_iiiiii ".Dotted arrow indicates asynchronous call in figure, such as services entitled " jjj_
The business of jjjjjjjj_jjjjj_jjjjjj " can another service be entitled " aaa_aaaaa_aaaa_aaaaa " with asynchronous call
Business.The case where hollow arrow expression alerts in figure, such as service the business of entitled " dd_dddd_dddd_ddddd "
It alerts, call relation is the calling service " dd_dddd_ for servicing entitled " jjj_jjjjjjjj_jjjjj_jjjjjj "
The business of dddd_ddddd ".
To sum up, operation maintenance personnel can be made very clear to the call relation between operation layer by content shown in Fig. 3.
104, calling service relation information is sent to client.
In the present embodiment, calling service relation information is sent from server to client, client can be by rendering
Calling service relation information is shown on display interface.
In the embodiment of the present invention, a kind of method that information is sent is provided, log to be analyzed is obtained by server first and is believed
Then breath is tested log information to be analyzed using default test case, to obtain test result, if test result meets
Default alarm conditions, then server generates calling service relation information further according to test result, wherein calling service relation information
For indicating the call relation between operation layer, calling service relation information is sent to client.By the above-mentioned means, servicing
After device detects the test result for meeting default alarm conditions, it can be generated according to test result and show calling service relationship
Information, and calling service relation information can directly indicate the call relation between each operation layer, when more without spending
Between and energy obtain the call relation between operation layer, to promote the efficiency of positioning abnormal problem.
Optionally, on the basis of above-mentioned Fig. 2 corresponding embodiment, the method for information transmission provided in an embodiment of the present invention
In first alternative embodiment, log information to be analyzed is obtained, may include:
Log information to be analyzed is obtained by distributed information system kafka, wherein log information to be analyzed is log receipts
Collecting system flume is collected.
In the present embodiment, the process of log information to be analyzed acquired in server can be result collection system " water
Slot " (flume) is stored with a large amount of log information, in order to mitigate the pressure of log information analysis platform, distributed information system
(kafka) the transfer service for uploading log information is provided, the log to be analyzed letter needed for then server can be obtained from kafka
Breath.
Specifically, flume is the open source distributed information log of a high-performance and High Availabitity that Cloudera company provides
Collection system, flume supports to customize Various types of data sender in log system, for collecting data.Referring to Fig. 4, Fig. 4 is
A schematic illustration of result collection system flume in the embodiment of the present invention, as shown, the core of flume is data
Come from data source (source) collection, the data being collected into are being sent to designated destination (sink).In order to guarantee to convey
Process centainly succeed, before being sent to destination (sink), can first data cached (channel), pending data really reaches
After sink, flume deletes the data of oneself caching again.
Source component is used to complete the collection to daily record data, and channel component mainly provides the function of a queue,
It is simply cached for the data in providing source component, sink component is used to take out the number in channel component
According to, and send the data to distributed file system (the hadoop distributed that corresponding extra large dupp is realized
File system, HDFS).
Kafka is that a kind of distributed post of high-throughput subscribes to message system, it can handle the net of consumer's scale
Movement flow data in standing.This movement (such as web page browsing, search and action of other users) is on modern network
Many social functions a key factor, and these data be often as handling capacity requirement and by processing log come
It solves.Referring to Fig. 5, Fig. 5 is a schematic illustration of distributed information system kafka in the embodiment of the present invention, as schemed institute
Show, the object of distribution subscription is the catalogue i.e. theme (topic) of message deposit in kafka.We can be every class data creation
The client to give out information to topic is referred to as " producer " (producer), the visitor of message is subscribed to from topic by one topic
Family end is referred to as " consumer " (consumer).Producers and consumers can read and write data from multiple topic simultaneously.One
A kafka cluster is made of one or more servers, it is responsible for persistence and backs up specific kafka message.Database
(database, DB) is connected by " connector " (connector) with kafka cluster, and provides a large amount of data.Using journey
Sequence is connected by " stream handle " (stream processor) with kafka cluster, and for carrying out data processing.
Secondly, server obtains log information to be analyzed by kafka in the embodiment of the present invention, wherein log to be analyzed
Information is that flume is collected.By the above-mentioned means, obtaining log information to be analyzed with following using kafka and flume
Advantage, first flume have better real-time, can monitor journal file in real time compared with traditional result collection system
Change, second level logs information is transferred to log information analysis platform, secondly, flume, without installation, starting script can make
With the later period does not need to safeguard substantially, and is that the primary log information based on regular expression comes, and configuration is simple, to save
O&M cost is saved, further, flume can be extended with customized third party Java packet, and customization is additionally taken when uploading log information
The information of band, such as Service name etc., thus the flexibility of lifting scheme.Log information analysis platform can reduce using kafka
Pressure, with this promoted server work stability.
Optionally, provided in an embodiment of the present invention on the basis of above-mentioned Fig. 2 and Fig. 2 corresponding one embodiment
In second alternative embodiment of method that information is sent, log information to be analyzed is carried out using default test case to test it
Before, can also include:
Obtain test case set;
By the typing of test case set into automated test tool ATT resources bank, wherein ATT resources bank is for storing
Default test case;
Default test case is extracted from ATT resources bank.
In the present embodiment, server may be used also before being tested using default test case log information to be analyzed
It include CGI and/or middle resource in test case set to obtain test case set automatically.Then by test use cases
Conjunction is input in automated test tool (automation testing tools, ATT) resources bank, and server is from ATT resource
Default test case is extracted in library.
Wherein, ATT is Black-box Testing tool, can be used to complete functional test and regression test, improve testing efficiency,
And reduce test labor cost.Automatic test is the direction of current test development, being capable of the saving of helper applications development teams
Testing time.Automatic test realizes test automation by executing test script, and the execution speed of single script than is manually held
Fast 10 times of row or more, can save a large amount of testing time for us.ATT resources bank contains at least one test case.
In order to make it easy to understand, please referring to table 1, table 1 is the content of test case set in ATT resources bank, specifically:
Table 1
It should be noted that the test case in table 1 is only a signal, in practical applications, ATT resources bank be can wrap
Containing other test cases, herein without limitation.
Secondly, server can extract directly from ATT resources bank presets test case, and ATT in the embodiment of the present invention
Test case set in resources bank is also that server obtains automatically, adds test case set manually without user, passes through
Aforesaid way can satisfy the iteratively faster of desire demand, the efficiency that automatic test cases are write be promoted, to increase scheme
Practicability.
Optionally, corresponding first or on the basis of second embodiment in above-mentioned Fig. 2, Fig. 2, the embodiment of the present invention is mentioned
In the method third alternative embodiment that the information of confession is sent, calling service relation information is generated according to test result, can wrap
It includes:
It is generated in calling service sequence, service server title and address of service server at least according to test result
One.
May include in the present embodiment, in calling service relation information calling service sequence, service server title and
At least one of in address of service server.
In order to make it easy to understand, referring to Fig. 3, Fig. 3 is a reality of call relation between operation layer in the embodiment of the present invention
It applies illustration to be intended to, wherein calling service sequence is the sequence of arrow instruction, and arrow is directed toward the server for indicating called.Industry
Business server name is the name of business, such as " dd_dddd_dddd_ddddd " or " hhh_hhhhh_ in Fig. 3
Hhhhhh_hhhhhh " etc..Address of service server is the IP address of server, such as " 9.999.9.999 " in Fig. 3.
It should be noted that being herein only a signal, in practical applications, calling service relation information can also include
Other information, herein without limitation.
Again, in the embodiment of the present invention, server generates calling service sequence, service server title according to test result
At least one of and in address of service server.By the above-mentioned means, further describing in calling service relation information
Which business module is content, the call relation between graphical representation operation system module, can intuitively navigate on and occur
Problem, thus the practicability and application efficiency of lifting scheme.
Optionally, above-mentioned Fig. 2 and Fig. 2 it is corresponding first to any one of third embodiment on the basis of, this
In the 4th alternative embodiment of method that the information that inventive embodiments provide is sent, after obtaining log information to be analyzed, may be used also
To include:
It is analysed to log information and is stored in distributed cache system memcache and based on distributed document storage
In database mongoDB, wherein memcache has obtained log information to be analyzed corresponding to test result for storing,
MongoDB is for storing the log information to be analyzed that default test case to be employed is tested.
In the present embodiment, after server obtains log information to be analyzed, it can also further be analysed to log letter
Breath is stored in distributed cache systems (memcache), meanwhile, it also needs to be analysed to log information to be stored in and is based on
In the database (mongoDB) of distributed document storage.
Specifically, referring to Fig. 6, Fig. 6 is a configuration diagram of log information analysis platform in the embodiment of the present invention,
As shown, log analysis platform generates the line of three datas analysis according to CGI APP log information and middle log information
Journey, respectively CGI hypertext transfer protocol (hyper text transfer protocol, http) thread, middle APP
Thread and CGI APP thread.Log analysis platform is interacted with data queue, and data queue is for providing log information
Transfer service can mitigate the pressure of log analysis platform.
CGI APP log information and middle log information are sent to memcache and mongoDB by data queue, different
, mongoDB be used to store it is after testing case as a result, namely calling service relation information mainly from
It is called in mongoDB.And memcache is mainly used for carry out use-case test and providing corresponding log information.
The workflow of memcache is as follows, the request data of client is first checked whether in memcache, if deposited
Then any operation no longer can carried out to database directly return request data, whereas if the data of request do not exist
In memcache, then needs further just to go to look into database, the data obtained from database are then returned to client, together
When data buffer storage portion into memcache (memcache is not responsible for by client, and program is needed clearly to realize).Every time more
The data in memcache are updated while new database, guarantee consistency.When the memory headroom for distributing to memcache is finished
Later, it will use in the recent period at least using algorithm (Least Recently Used, LRU) strategy plus the expiration policy that expires, failure
Data are replaced first, then replace nearest not used data again.
Memcache is a high performance distributed memory object caching system, by safeguarding a system in memory
One huge hash table, it can be used to store the data of various formats, including image, video, file and database inspection
The result etc. of rope.It is briefly exactly then to be read from memory by data call into memory, to greatly improve reading speed
Degree.
MongoDB is the database based on distributed document storage, is write by C Plus Plus, it is intended to be web application
Expansible high-performance data storage solution is provided.
MongoDB is a product between relational database and non-relational database.The data structure that it is supported
It is very loose, be similar JavaScript object markup language (javaScript object notation, json) two into
The storage format (binary serialized document format) of form processed, therefore can store more complicated number
According to type.The feature of mongoDB maximum is that the query language that he supports is very powerful, and grammer is somewhat similarly to object-oriented
Most functions of similarity relation database list table inquiry almost may be implemented in query language, but also support to build data
Lithol draws.
Secondly, after server obtains log information to be analyzed, server is analysed to log letter in the embodiment of the present invention
Breath is stored in memcache and mongoDB, wherein memcache has been obtained corresponding to test result for storing wait divide
Log information is analysed, mongoDB is for storing the log information to be analyzed that default test case to be employed is tested.By above-mentioned
Mode, using memcache as middleware, it is possible to reduce disk is output and input, the speed of service for lifting scheme.
Good query performance can be provided using mongoDB, and without installation, that is, there is high-performance, easily deployment and easily used
Characteristic, storing data is very convenient.
Optionally, above-mentioned Fig. 2 and Fig. 2 it is corresponding first to any one of the 4th embodiment on the basis of, this
In the 5th alternative embodiment of method that the information that inventive embodiments provide is sent, calling service relationship letter is sent to client
It ceases, may include:
Calling service relation information is sent to client in preset time, so that client shows calling service relationship letter
Breath.
In the present embodiment, server can also send calling service relation information, client to client in preset time
End side shows user after being rendered calling service relation information.
Specifically, timing customer service call relation information, business can be notified in a manner of mail daily than server
Call relation information includes interface alteration etc., so that user gets relevant information in time, and carries out corresponding operation.
It is understood that preset time is usually a set time, it is also possible to a fixed time period, such as often
4 points of 8 points of its morning or every afternoon etc. are also possible to periodically notify, such as are carried out every 12 hours notice servers
Notice, herein without limitation.
It should be noted that the client for receiving calling service relation information specifically can be Mail Clients, or
Person's instant messaging class client, such as " wechat " can also perhaps " QQ " etc. be notified by short message or phone etc., herein
Without limitation.
Secondly, server can send calling service relationship letter to client in preset time in the embodiment of the present invention
Breath, so that client shows calling service relation information.By the above-mentioned means, server can notify customer service to call automatically
Relation information understands interface more real-timely convenient for user and more becomes situation, and also can be faster by calling service relation information
Orient which module goes wrong, more accurately with the application convenience of this lifting scheme.
It for ease of understanding, below can be with a concrete application scene to the process being configured in automatic test platform
It is described, referring to Fig. 7, Fig. 7 is the interface schematic diagram that log information analyzes backstage in application scenarios of the present invention, specifically
Are as follows:
After user imports the resource saved on platform, request Packet type, the i.e. format of file can be correspondingly selected.So
After fill in CGI title, and CGI is selected to classify.
After the completion, need further to select to fill in CGI test owner, CGI exploitation responsible person, CGI O&M responsible person
And CGI product owner.Project belonging to being selected in home type, for example " wealth pair has been selected in the present embodiment
It is logical ".CGI description is filled in by user, for understanding the content of CGI.Request packet is then the one section of code intercepted and captured automatically, is used for
Carry out use-case test and analysis.
The server in the present invention is described in detail below, referring to Fig. 8, Fig. 8 is to service in the embodiment of the present invention
Device one embodiment schematic diagram, server 20 include:
First obtains module 201, for obtaining log information to be analyzed;
Test module 202, for obtaining the described to be analyzed of the acquisition of module 201 to described first using default test case
Log information is tested, to obtain test result;
Generation module 203, if meeting default alarm conditions for the test result that the test module 202 obtains,
Calling service relation information is then generated according to the test result, wherein the calling service relation information is for indicating business
Call relation between layer;
Sending module 204, for sending the calling service relationship letter that the generation module 203 generates to client
Breath.
In the present embodiment, the first acquisition module 201 obtains log information to be analyzed, and test module 202 is using default test
The log information to be analyzed that use-case obtains the first acquisition module 201 is tested, to obtain test result, if institute
It states the test result that test module 202 obtains and meets default alarm conditions, then generation module 203 is according to the test result
Generate calling service relation information, wherein the calling service relation information is used to indicate the call relation between operation layer, hair
Module 204 is sent to send the calling service relation information that the generation module 203 generates to client.
In the embodiment of the present invention, a kind of server is provided, log information to be analyzed is obtained by the server first, then
Server tests log information to be analyzed using default test case, to obtain test result, if test result meets
Default alarm conditions, then server generates calling service relation information further according to test result, wherein calling service relation information
For indicating the call relation between operation layer, calling service relation information is sent to client.By the above-mentioned means, servicing
After device detects the test result for meeting default alarm conditions, it can be generated according to test result and show calling service relationship
Information, and calling service relation information can directly indicate the call relation between each operation layer, when more without spending
Between and energy obtain the call relation between operation layer, to promote the efficiency of positioning abnormal problem.
Optionally, on the basis of the embodiment corresponding to above-mentioned Fig. 8, referring to Fig. 9, clothes provided in an embodiment of the present invention
It is engaged in another embodiment of device 20,
Described first, which obtains module 201, includes:
Acquiring unit 2011, for obtaining the log information to be analyzed by distributed information system kafka, wherein
The log information to be analyzed is that result collection system flume is collected.
Secondly, server obtains log information to be analyzed by kafka in the embodiment of the present invention, wherein log to be analyzed
Information is that flume is collected.By the above-mentioned means, obtaining log information to be analyzed with following using kafka and flume
Advantage, first flume have better real-time, can monitor journal file in real time compared with traditional result collection system
Change, second level logs information is transferred to log information analysis platform, secondly, flume, without installation, starting script can make
With the later period does not need to safeguard substantially, and is that the primary log information based on regular expression comes, and configuration is simple, to save
O&M cost is saved, further, flume can be extended with customized third party Java packet, and customization is additionally taken when uploading log information
The information of band, such as Service name etc., thus the flexibility of lifting scheme.Log information analysis platform can reduce using kafka
Pressure, with this promoted server work stability.
Optionally, on the basis of the embodiment corresponding to above-mentioned Fig. 8, referring to Fig. 10, provided in an embodiment of the present invention
In another embodiment of server 20, the server 20 further include:
Second obtains module 205, for using default test case to the log to be analyzed in the test module 202
Before information is tested, test case set is obtained;
Recording module 206, for by the second test case set typing that obtains of acquisition module 205 to automatic
Change in testing tool ATT resources bank, wherein the ATT resources bank is for storing the default test case;
Extraction module 207, for extracting the default survey from the ATT resources bank of 206 typing of recording module
Example on probation.
Secondly, server can extract directly from ATT resources bank presets test case, and ATT in the embodiment of the present invention
Test case set in resources bank is also that server obtains automatically, adds test case set manually without user, passes through
Aforesaid way can satisfy the iteratively faster of desire demand, the efficiency that automatic test cases are write be promoted, to increase scheme
Practicability.
Optionally, on the basis of the embodiment corresponding to above-mentioned Fig. 8, Fig. 9 or Figure 10, Figure 11 is please referred to, the present invention is real
In another embodiment that the server 20 of example offer is provided, the server 20 further include:
The generation module 203 includes:
Generation unit 2031, for according to the test result generate calling service sequence, service server title and
At least one of in address of service server.
Again, in the embodiment of the present invention, server generates calling service sequence, service server title according to test result
At least one of and in address of service server.By the above-mentioned means, further describing in calling service relation information
Which business module is content, the call relation between graphical representation operation system module, can intuitively navigate on and occur
Problem, thus the practicability and application efficiency of lifting scheme.
Optionally, on the basis of the embodiment corresponding to above-mentioned Fig. 8, Figure 12 is please referred to, it is provided in an embodiment of the present invention
In another embodiment of server 20,
The server 20 further include:
Memory module 208 will be described wait divide after obtaining log information to be analyzed for the first acquisition module 201
Analysis log information is stored in the distributed cache system memcache and database mongoDB based on distributed document storage
In, wherein the memcache has obtained the log information to be analyzed corresponding to the test result for storing, described
MongoDB is for storing the log information to be analyzed that the default test case to be employed is tested.
Secondly, after server obtains log information to be analyzed, server is analysed to log letter in the embodiment of the present invention
Breath is stored in memcache and mongoDB, wherein memcache has been obtained corresponding to test result for storing wait divide
Log information is analysed, mongoDB is for storing the log information to be analyzed that default test case to be employed is tested.By above-mentioned
Mode, using memcache as middleware, it is possible to reduce disk is output and input, the speed of service for lifting scheme.
Good query performance can be provided using mongoDB, and without installation, that is, there is high-performance, easily deployment and easily used
Characteristic, storing data is very convenient.
Optionally, on the basis of the embodiment corresponding to above-mentioned Fig. 8, Figure 13 is please referred to, it is provided in an embodiment of the present invention
In another embodiment of server 20,
The sending module 204 includes:
Transmission unit 2041, for sending the calling service relation information to the client in preset time, with
The client is set to show the calling service relation information.
Secondly, server can send calling service relationship letter to client in preset time in the embodiment of the present invention
Breath, so that client shows calling service relation information.By the above-mentioned means, server can notify customer service to call automatically
Relation information understands interface more real-timely convenient for user and more becomes situation, and also can be faster by calling service relation information
Orient which module goes wrong, more accurately with the application convenience of this lifting scheme.
Figure 14 is a kind of server architecture schematic diagram provided in an embodiment of the present invention, which can be because of configuration or property
Energy is different and generates bigger difference, may include one or more central processing units (central processing
Units, CPU) 322 (for example, one or more processors) and memory 332, one or more storages apply journey
The storage medium 330 (such as one or more mass memory units) of sequence 342 or data 344.Wherein, 332 He of memory
Storage medium 330 can be of short duration storage or persistent storage.The program for being stored in storage medium 330 may include one or one
With upper module (diagram does not mark), each module may include to the series of instructions operation in server.Further, in
Central processor 322 can be set to communicate with storage medium 330, execute on server 300 a series of in storage medium 330
Instruction operation.
Server 300 can also include one or more power supplys 326, one or more wired or wireless networks
Interface 350, one or more input/output interfaces 358, and/or, one or more operating systems 341, such as
Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM etc..
The step as performed by server can be based on server architecture shown in the Figure 14 in above-described embodiment.
Wherein, central processing unit 322 is for executing following steps:
Obtain log information to be analyzed;
The log information to be analyzed is tested using default test case, to obtain test result;
If the test result meets default alarm conditions, calling service relationship letter is generated according to the test result
Breath, wherein the calling service relation information is used to indicate the call relation between operation layer;
The calling service relation information is sent to client.
Optionally, central processing unit 322 is specifically used for executing following steps:
The log information to be analyzed is obtained by distributed information system kafka, wherein the log information to be analyzed
It is collected for result collection system flume.
Optionally, central processing unit 322 is also used to execute following steps:
Obtain test case set;
By the test case set typing into automated test tool ATT resources bank, wherein the ATT resources bank
For storing the default test case;
The default test case is extracted from the ATT resources bank.
Optionally, central processing unit 322 is specifically used for executing following steps:
It is generated in calling service sequence, service server title and address of service server according to the test result
At least one of.
Optionally, central processing unit 322 is also used to execute following steps:
The log information to be analyzed is stored in distributed cache system memcache and is deposited based on distributed document
In the database mongoDB of storage, wherein the memcache for store obtained corresponding to the test result it is described to
Log information is analyzed, the mongoDB is for storing the day to be analyzed that the default test case to be employed is tested
Will information.
Optionally, central processing unit 322 is specifically used for executing following steps:
The calling service relation information is sent to the client in preset time, so that the client shows institute
State calling service relation information.
It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description,
The specific work process of device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In several embodiments provided by the present invention, it should be understood that disclosed system, device and method can be with
It realizes by another way.For example, the apparatus embodiments described above are merely exemplary, for example, the unit
It divides, only a kind of logical function partition, there may be another division manner in actual implementation, such as multiple units or components
It can be combined or can be integrated into another system, or some features can be ignored or not executed.Another point, it is shown or
The mutual coupling, direct-coupling or communication connection discussed can be through some interfaces, the indirect coupling of device or unit
It closes or communicates to connect, can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple
In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme
's.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit
It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list
Member both can take the form of hardware realization, can also realize in the form of software functional units.
If the integrated unit is realized in the form of SFU software functional unit and sells or use as independent product
When, it can store in a computer readable storage medium.Based on this understanding, technical solution of the present invention is substantially
The all or part of the part that contributes to existing technology or the technical solution can be in the form of software products in other words
It embodies, which is stored in a storage medium, including some instructions are used so that a computer
Equipment (can be personal computer, server or the network equipment etc.) executes the complete of each embodiment the method for the present invention
Portion or part steps.And storage medium above-mentioned include: USB flash disk, mobile hard disk, read-only memory (Read-Only Memory,
ROM), random access memory (Random Access Memory, RAM), magnetic or disk etc. are various can store program
The medium of code.
The above, the above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;Although referring to before
Stating embodiment, invention is explained in detail, those skilled in the art should understand that: it still can be to preceding
Technical solution documented by each embodiment is stated to modify or equivalent replacement of some of the technical features;And these
It modifies or replaces, the spirit and scope for technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution.
Claims (12)
1. a kind of method that information is sent characterized by comprising
Obtain log information to be analyzed;
The log information to be analyzed is tested using default test case, to obtain test result;
If the test result meets default alarm conditions, calling service relation information is generated according to the test result,
In, the calling service relation information is used to indicate the call relation between operation layer;
The calling service relation information is sent to client.
2. the method according to claim 1, wherein described obtain log information to be analyzed, comprising:
The log information to be analyzed is obtained by distributed information system kafka, wherein the log information to be analyzed is day
Will collection system flume is collected.
3. the method according to claim 1, wherein described use default test case to the log to be analyzed
Before information is tested, the method also includes:
Obtain test case set;
By the test case set typing into automated test tool ATT resources bank, wherein the ATT resources bank is used for
Store the default test case;
The default test case is extracted from the ATT resources bank.
4. according to the method in any one of claims 1 to 3, which is characterized in that described to be generated according to the test result
Calling service relation information, comprising:
It is generated in calling service sequence, service server title and address of service server at least according to the test result
One.
5. the method according to claim 1, wherein it is described obtain log information to be analyzed after, the method
Further include:
The log information to be analyzed is stored in distributed cache system memcache and based on distributed document storage
In database mongoDB, wherein the memcache for store obtained it is described to be analyzed corresponding to the test result
Log information, the mongoDB are used to store the log letter to be analyzed that the default test case to be employed is tested
Breath.
6. the method according to claim 1, wherein described send the calling service relationship letter to client
Breath, comprising:
The calling service relation information is sent to the client in preset time, so that the client shows the industry
Business call relation information.
7. a kind of server characterized by comprising
First obtains module, for obtaining log information to be analyzed;
Test module, for using default test case to described first obtain the log information to be analyzed that module obtains into
Row test, to obtain test result;
Generation module, if meeting default alarm conditions for the test result that the test module obtains, according to
Test result generates calling service relation information, wherein the calling service relation information is used to indicate the tune between operation layer
With relationship;
Sending module, for sending the calling service relation information that the generation module generates to client.
8. server according to claim 7, which is characterized in that described first, which obtains module, includes:
Acquiring unit, for obtaining the log information to be analyzed by distributed information system kafka, wherein described wait divide
Analysing log information is that result collection system flume is collected.
9. server according to claim 7, which is characterized in that the server further include:
Second obtains module, for being surveyed using default test case to the log information to be analyzed in the test module
Before examination, test case set is obtained;
Recording module, for obtaining the test case set typing that module obtains to automated test tool for described second
In ATT resources bank, wherein the ATT resources bank is for storing the default test case;
Extraction module, for extracting the default test case from the ATT resources bank of the recording module typing.
10. server according to claim 7, which is characterized in that the server further include:
Memory module, after obtaining module acquisition log information to be analyzed for described first, by the log information to be analyzed
It is stored in the distributed cache system memcache and database mongoDB stored based on distributed document, wherein described
Memcache has obtained the log information to be analyzed, the mongoDB corresponding to the test result and has been used for for storing
Store the log information to be analyzed that the default test case to be employed is tested.
11. a kind of server characterized by comprising memory, processor and bus system;
Wherein, the memory is for storing program;
The processor is used to execute the program in the memory, includes the following steps:
Obtain log information to be analyzed;
The log information to be analyzed is tested using default test case, to obtain test result;
If the test result meets default alarm conditions, calling service relation information is generated according to the test result,
In, the calling service relation information is used to indicate the call relation between operation layer;
The calling service relation information is sent to client;
The bus system is for connecting the memory and the processor, so that the memory and the processor
It is communicated.
12. a kind of computer readable storage medium, including instruction, when run on a computer, so that computer executes such as
Method described in claim 1-6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710353011.1A CN108959041B (en) | 2017-05-18 | 2017-05-18 | Method for transmitting information, server and computer readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710353011.1A CN108959041B (en) | 2017-05-18 | 2017-05-18 | Method for transmitting information, server and computer readable storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108959041A true CN108959041A (en) | 2018-12-07 |
CN108959041B CN108959041B (en) | 2021-09-07 |
Family
ID=64462890
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710353011.1A Active CN108959041B (en) | 2017-05-18 | 2017-05-18 | Method for transmitting information, server and computer readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108959041B (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110221952A (en) * | 2019-04-18 | 2019-09-10 | 北京互金新融科技有限公司 | The processing method and processing device of business datum, business data processing system |
CN114205273A (en) * | 2020-08-26 | 2022-03-18 | 腾讯科技(深圳)有限公司 | System testing method, device and equipment and computer storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070006037A1 (en) * | 2005-06-29 | 2007-01-04 | Microsoft Corporation | Automated test case result analyzer |
CN102231686A (en) * | 2011-06-24 | 2011-11-02 | 北京天融信科技有限公司 | System and method for implementing automated test of network security equipment |
CN103077111A (en) * | 2011-10-26 | 2013-05-01 | 阿里巴巴集团控股有限公司 | Method and system for locating continuous integration failed case |
CN105207806A (en) * | 2015-08-20 | 2015-12-30 | 百度在线网络技术(北京)有限公司 | Monitoring method and apparatus of distributed service |
-
2017
- 2017-05-18 CN CN201710353011.1A patent/CN108959041B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070006037A1 (en) * | 2005-06-29 | 2007-01-04 | Microsoft Corporation | Automated test case result analyzer |
CN102231686A (en) * | 2011-06-24 | 2011-11-02 | 北京天融信科技有限公司 | System and method for implementing automated test of network security equipment |
CN103077111A (en) * | 2011-10-26 | 2013-05-01 | 阿里巴巴集团控股有限公司 | Method and system for locating continuous integration failed case |
CN105207806A (en) * | 2015-08-20 | 2015-12-30 | 百度在线网络技术(北京)有限公司 | Monitoring method and apparatus of distributed service |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110221952A (en) * | 2019-04-18 | 2019-09-10 | 北京互金新融科技有限公司 | The processing method and processing device of business datum, business data processing system |
CN110221952B (en) * | 2019-04-18 | 2023-04-07 | 北京互金新融科技有限公司 | Service data processing method and device and service data processing system |
CN114205273A (en) * | 2020-08-26 | 2022-03-18 | 腾讯科技(深圳)有限公司 | System testing method, device and equipment and computer storage medium |
CN114205273B (en) * | 2020-08-26 | 2023-09-15 | 腾讯科技(深圳)有限公司 | System test method, device and equipment and computer storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN108959041B (en) | 2021-09-07 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109327509B (en) | Low-coupling distributed streaming computing system of master/slave architecture | |
US11855850B2 (en) | Systems and methods for networked microservice modeling and visualization | |
US11934417B2 (en) | Dynamically monitoring an information technology networked entity | |
US9420068B1 (en) | Log streaming facilities for computing applications | |
US20200081891A1 (en) | Multi-phased execution of a search query | |
US11615082B1 (en) | Using a data store and message queue to ingest data for a data intake and query system | |
US20200081885A1 (en) | Self-contained files for generating a visualization of query results | |
CN110362544A (en) | Log processing system, log processing method, terminal and storage medium | |
WO2020087082A1 (en) | Trace and span sampling and analysis for instrumented software | |
CN107957940B (en) | Test log processing method, system and terminal | |
US11449371B1 (en) | Indexing data at a data intake and query system based on a node capacity threshold | |
CN108737549A (en) | A kind of log analysis method and device of big data quantity | |
CN114363042B (en) | Log analysis method, device, equipment and readable storage medium | |
EP3864516A1 (en) | Veto-based model for measuring product health | |
US11609913B1 (en) | Reassigning data groups from backup to searching for a processing node | |
US11579860B2 (en) | Model driven state machine transitions to configure an installation of a software program | |
US10606810B2 (en) | Clustered search head configurations synchronization with bloom filter | |
CN110928934A (en) | Data processing method and device for business analysis | |
CN109714222A (en) | The distributed computer monitoring system and its monitoring method of High Availabitity | |
CN108959041A (en) | Method, server and the computer readable storage medium that information is sent | |
US11892976B2 (en) | Enhanced search performance using data model summaries stored in a remote data store | |
CN109559121A (en) | Transaction path calls exception analysis method, device, equipment and readable storage medium storing program for executing | |
CN107480189A (en) | A kind of various dimensions real-time analyzer and method | |
US11734297B1 (en) | Monitoring platform job integration in computer analytics system | |
CN114756301B (en) | Log processing method, device and system |
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 |