CN108847989B - Log processing method based on micro-service architecture, service system and electronic equipment - Google Patents

Log processing method based on micro-service architecture, service system and electronic equipment Download PDF

Info

Publication number
CN108847989B
CN108847989B CN201810703464.7A CN201810703464A CN108847989B CN 108847989 B CN108847989 B CN 108847989B CN 201810703464 A CN201810703464 A CN 201810703464A CN 108847989 B CN108847989 B CN 108847989B
Authority
CN
China
Prior art keywords
log
service
micro
processing request
service processing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810703464.7A
Other languages
Chinese (zh)
Other versions
CN108847989A (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.)
Hangzhou Dbappsecurity Technology Co Ltd
Original Assignee
Hangzhou Dbappsecurity 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 Hangzhou Dbappsecurity Technology Co Ltd filed Critical Hangzhou Dbappsecurity Technology Co Ltd
Priority to CN201810703464.7A priority Critical patent/CN108847989B/en
Publication of CN108847989A publication Critical patent/CN108847989A/en
Application granted granted Critical
Publication of CN108847989B publication Critical patent/CN108847989B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/06Management of faults, events, alarms or notifications
    • H04L41/069Management of faults, events, alarms or notifications using logs of notifications; Post-processing of notifications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/02Network architectures or network communication protocols for network security for separating internal from external traffic, e.g. firewalls
    • H04L63/0227Filtering policies
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/12Applying verification of the received information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/63Routing a service request depending on the request content or context

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The invention provides a log processing method based on a micro-service architecture, a business service system and electronic equipment, and relates to the technical field of log management, wherein the log processing method based on the micro-service architecture comprises the following steps: receiving a service processing request sent by a user; routing the service processing request to a corresponding micro service module; receiving service processing feedback information fed back by the corresponding micro service module based on the service processing request; according to the feedback information, the log data is managed according to the preset log rule, and the technical problem that the management efficiency of the log is low in the prior art is solved.

Description

Log processing method based on micro-service architecture, service system and electronic equipment
Technical Field
The invention relates to the technical field of log management, in particular to a log processing method based on a micro-service architecture, a business service system and electronic equipment.
Background
With the rapid development of network service complexity and globalization, the deployment mode and the monitoring mode of the existing software system have challenges. The continuous development of micro-service research represented by container (Docker) is a new trend to replace the traditional resource virtualization.
At present, the resource utilization rate based on the micro service container is very high, and the purpose of using according to the requirement can be really realized. The container is used as a logical abstraction of physical resources, has the characteristics of less resource occupation, fast resource supply and the like, is suitable for an internet application mode with sudden workload change, and is particularly a novel service paradigm facing a micro-service architecture. The micro-service architecture reflects the design idea of internet application, the core concept of the micro-service architecture is fine-grained module division, service interface packaging and lightweight communication interaction, and the micro-service has good expansibility and gradually becomes a mainstream architecture mode for constructing the internet application. Wherein each business microservice has its own log logic coupled to the business logic.
However, for the existing business microservices, the collection service needs to pull the logs on each microservice to perform unified log storage and management, which results in low log management efficiency.
Disclosure of Invention
In view of the above, an object of the present invention is to provide a log processing method based on a micro service architecture, a service system and an electronic device, so as to solve the technical problem in the prior art that the management efficiency of logs is low.
In a first aspect, an embodiment of the present invention provides a log processing method based on a microservice architecture, which is applied to a first log gateway in a log gateway unit, and the method includes:
receiving a service processing request sent by a user;
routing the service processing request to a corresponding micro service module;
receiving service processing feedback information fed back by the corresponding micro service module based on the service processing request;
and managing the log data according to a preset log rule according to the feedback information.
With reference to the first aspect, an embodiment of the present invention provides a first possible implementation manner of the first aspect, where the routing the service processing request to the corresponding micro service module specifically includes:
filtering the service processing request according to a safety degree to obtain a filtering result, wherein the safety degree represents whether network safety attack data exists in the service processing request or not;
verifying the service processing request according to an authorization condition to obtain a verification result, wherein the authorization condition represents whether a user ID for sending the service processing request is authorized;
determining whether a security authorization request is generated according to the filtering result and the checking result;
and under the condition that the generation of the security authorization request is confirmed, taking the security authorization request as the service processing request, and routing the security authorization request to a micro service module.
With reference to the first aspect, an embodiment of the present invention provides a second possible implementation manner of the first aspect, where the method further includes:
and if the safety authorization request is determined not to be generated based on the filtering result and the checking result, the service processing request is not routed to a micro service module, and a target log is recorded, wherein the target log represents that the checking and/or filtering of the service request is not passed.
With reference to the first aspect, an embodiment of the present invention provides a third possible implementation manner of the first aspect, where the method further includes:
acquiring configuration information sent by a configuration center;
and modifying the preset log rule based on the configuration information.
With reference to the first aspect, an embodiment of the present invention provides a fourth possible implementation manner of the first aspect, where the routing the service processing request to the corresponding micro service module specifically includes:
acquiring an incidence relation between a micro-service module and a first log gateway in the log gateway unit;
determining a micro-service module corresponding to the first log gateway based on the incidence relation;
and routing the service processing request to the corresponding micro service module.
In a second aspect, an embodiment of the present invention further provides a service system based on a microservice architecture, including: the system comprises a service processing unit and a log gateway unit; the service processing unit comprises a plurality of micro service modules; the log gateway unit comprises at least one log gateway, and the plurality of micro service modules and the at least one log gateway comprise an incidence relation;
each log gateway in the log gateway unit is configured to manage log data of the associated microservice module according to a preset log rule, where the preset log rule includes at least one of: the management format of the log, and the operation performed on the log.
With reference to the second aspect, an embodiment of the present invention provides a first possible implementation manner of the second aspect, where a management format of the log includes: a unified digital fingerprint identification field and a unified log format.
With reference to the second aspect, an embodiment of the present invention provides a second possible implementation manner of the second aspect, where the method further includes: and the configuration unit is used for configuring the incidence relation between the micro service modules and the at least one log gateway and/or configuring the preset log rule.
In a third aspect, an embodiment of the present invention further provides an electronic device, including a memory and a processor, where the memory stores a computer program operable on the processor, and the processor implements the steps of the method according to the first aspect when executing the computer program.
In a fourth aspect, the present invention also provides a computer-readable medium having non-volatile program code executable by a processor, where the program code causes the processor to execute the method according to the first aspect.
The technical scheme provided by the embodiment of the invention has the following beneficial effects: in the log processing method based on the micro-service architecture, the service system and the electronic device provided by the embodiment of the invention, the log processing method based on the micro-service architecture is applied to a first log gateway in a log gateway unit, and the method comprises the following steps: firstly, a service processing request sent by a user is received, then the service processing request is routed to a corresponding micro-service module, then service processing feedback information fed back by the corresponding micro-service module based on the service processing request is received, finally, log data is managed according to preset log rules according to the feedback information, logs of all micro-services are uniformly managed through a log gateway in a log gateway unit, decoupling of service logic and log logic is achieved, logging, storage, management and the like can be directly carried out through an independent log gateway unit, therefore, the log content of each micro-service does not need to be collected and pulled, the management efficiency of the logs is improved, and the technical problem that the log management efficiency is low in the prior art is solved.
Additional features and advantages of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention will be realized and attained by the structure particularly pointed out in the written description and drawings.
In order to make the aforementioned and other objects, features and advantages of the present invention comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and other drawings can be obtained by those skilled in the art without creative efforts.
FIG. 1 is a flow chart of a method for processing a log based on a microservice architecture according to an embodiment of the present invention;
FIG. 2 is a flowchart illustrating a method for processing a log based on a microservice architecture according to a second embodiment of the present invention;
fig. 3 is a schematic structural diagram illustrating a business service system based on a microservice architecture according to a third embodiment of the present invention;
fig. 4 shows a schematic structural diagram of an electronic device according to a fourth embodiment of the present invention.
Icon: 3-a business service system based on a micro-service architecture; 31-a service processing unit; 311-micro service module; 32-a log gateway unit; 321-a log gateway; 33-a configuration unit; 34-a registration unit; 4-an electronic device; 41-a memory; 42-a processor; 43-bus; 44-communication interface.
Detailed Description
To make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
At present, for the prior art, how to utilize log data generated by each micro service is the most difficult to perform association analysis and comprehensive mining, the prior art mainly records the obtained communication request data between the services in logs through a point-burying operation, each service micro service has its own log logic and is coupled with the service logic, and the log logic, the log format and the log configuration of each service micro service all need to pull the logs on each micro service by an acquisition service to perform uniform log storage and management. Moreover, the log format of each business microservice is not uniform, and log data is dispersed in each microservice, so that log association tracing between businesses is difficult.
Based on this, the log processing method, the business service system and the electronic device based on the microservice architecture provided by the embodiment of the invention can solve the technical problem of low log management efficiency in the prior art.
To facilitate understanding of the embodiment, first, a log processing method, a service system, and an electronic device based on a micro-service architecture disclosed in the embodiment of the present invention are described in detail.
The first embodiment is as follows:
the log processing method based on the microservice architecture provided by the embodiment of the present invention is applied to a first log gateway in a log gateway unit, and can be used as a log management method, as shown in fig. 1, the method includes:
s11: and receiving a service processing request sent by a user.
As a preferred implementation of this embodiment, the log gateway receives all external service requests.
S12: and routing the service processing request to the corresponding micro service module.
S13: and receiving service processing feedback information fed back by the corresponding micro service module based on the service processing request.
Specifically, the micro service module is responsible for specific service logic processing and is a core service module. And the micro service module returns a response to the log gateway after the business service processing is finished, namely the micro service module feeds back business processing feedback information to the log gateway based on the business processing request so that the log gateway can receive the business processing feedback information conveniently.
S14: and managing the log data according to the feedback information and a preset log rule.
In this step, the log gateway matches a corresponding preset log rule according to the service processing feedback information, that is, the information returned by the response of the micro service module, records the log according to the rule, and finally returns a response.
As a preferred scheme, the log gateway uses a framework of Spring Cloud Zuul (a framework based on a micro service gateway) to develop a custom routing rule and a filter, and all logs are uniformly recorded, stored and managed.
It should be noted that Spring Cloud is an ordered set of a series of frames. The development convenience of the Spring Boot (a framework) is utilized to simplify the development of infrastructure of a distributed system, such as service discovery registration, a configuration center, a message bus, load balancing, a circuit breaker, data monitoring and the like, and the Spring Boot can be used for one-key starting and deployment in a development style. The Spring Cloud does not repeatedly manufacture wheels, only combines the service frames which are developed at present and are relatively mature and can withstand practical tests, and encapsulates and shields the complex configuration and implementation principle through the Spring Boot style, thereby finally providing a set of distributed system development toolkit which is simple and easy to understand, deploy and maintain.
Therefore, the log gateway unit in this embodiment is directly responsible for recording, storing, and managing, so that it is not necessary to collect and pull the log content of each microservice, thereby improving the management efficiency of the log.
Example two:
the log processing method based on the microservice architecture provided by the embodiment of the present invention is applied to a first log gateway in a log gateway unit, and can be used as a log management method, as shown in fig. 2, the method includes:
s21: and receiving a service processing request sent by a user.
In practical application, the log gateway receives service requests sent by all external users.
S22: and acquiring the association relationship between the micro-service module and a first log gateway in the log gateway unit.
Preferably, the log gateway utilizes a log gateway framework such as Spring Cloud Zuul to develop a custom routing rule, i.e. an association relationship between the micro service module and the log gateway in the log gateway unit. In this step, the association relationship is obtained, so that in the subsequent step, the routing action is executed based on the association relationship.
S23: and determining a micro-service module corresponding to the first log gateway based on the incidence relation.
S24: and routing the service processing request to the corresponding micro service module.
Further, in this step, the service processing request may be filtered and checked first, and then the routing process is performed. The method comprises the following specific steps:
firstly, filtering the service processing request according to the security degree to obtain a filtering result, wherein the security degree represents whether network security attack data exists in the service processing request. The network security attack data can be data which has aggressivity to network security, such as cross-site scripts, SQL injection and the like.
And verifying the service processing request according to the authorization condition to obtain a verification result, wherein the authorization condition represents whether the user ID for sending the service processing request is authorized.
And then, determining whether to generate a security authorization request according to the filtering result and the checking result.
In one implementation, in the case that the generation of the security authorization request is confirmed, the security authorization request is used as a service processing request, and the security authorization request is routed to the micro service module. Therefore, after passing the checking and filtering, the data is routed to the corresponding business service, namely the micro-service module.
In another implementation, if it is determined that the security authorization request is not generated based on the filtering result and the checking result, the service processing request is not routed to the micro service module, and a target log is recorded, wherein the target log represents that the checking and/or filtering of the service request fails.
S25: and receiving service processing feedback information fed back by the corresponding micro service module based on the service processing request.
In this embodiment, the micro service module is responsible for specific service logic processing and is a core service module. And the micro service module returns a response to the log gateway after the business service processing is finished, namely the micro service module feeds back business processing feedback information to the log gateway based on the business processing request so that the log gateway can receive the business processing feedback information conveniently.
S26: and managing the log data according to the feedback information and a preset log rule.
In a preferred embodiment of this embodiment, the log gateway matches a corresponding preset log rule according to the service processing feedback information, that is, information returned by the micro service module in response, records a log according to the rule, and finally returns a response.
Further, the log processing method based on the microservice architecture may further include: acquiring configuration information sent by a configuration center; and modifying the preset log rule based on the configuration information. As another implementation manner of this embodiment, after the unified configuration center modifies the preset log rule, it will dynamically notify the log gateway, and in combination with the function of the configuration center, the modification of the log configuration can make all services of the log gateway take effect in real time. Therefore, the configuration center is used for configuring various rule switches related to the log and the route, actively pushing the log to the log gateway after dynamic modification, and flexibly starting or closing corresponding log recording operation.
Example three:
the service system based on the micro-service architecture provided in the embodiment of the present invention can be used as a service and log processing system based on the micro-service architecture, as shown in fig. 3, the service system 3 based on the micro-service architecture includes: a service processing unit 31 and a log gateway unit 32. The service processing unit comprises a number of micro service modules 311. The log gateway unit comprises at least one log gateway 321, and the plurality of micro service modules and the at least one log gateway comprise an association relationship.
It should be noted that the service processing unit includes a plurality of micro service modules. The service processing unit is responsible for specific service logic processing and is a core service module. The service processing unit is composed of a series of different micro service modules according to the division of the actual application system.
In addition, each log gateway in the log gateway unit is configured to manage log data of the micro service module associated therewith according to a preset log rule, where the preset log rule includes at least one of: the management format of the log, and the operation performed on the log.
The management format of the log comprises: a unified digital fingerprint identification field and a unified log format. For example, in a session period, the log records of each micro-service module involved in the session have a unique digital fingerprint identification field and a uniform log format, so that the log records, storage and management formats of all the micro-service modules are consistent and uniform, so that the follow-up tracing and correlation analysis of the interface call links of each micro-service are facilitated, and the log management efficiency is also improved.
In practical application, the log gateway is used for receiving all external service requests, filtering and verifying the security and authorization of the requests, routing the requests to the corresponding micro service modules after the requests are passed, returning a response to the log gateway after the micro service modules finish processing, matching the corresponding log rules by the log gateway according to the information returned by the request response, and recording, storing and managing the logs according to the rules. Preferably, the log gateway can develop custom routing rules and filters using a log gateway framework such as Spring Cloud Zuul.
All logs are uniformly recorded, stored and managed through the log gateway unit, service logic and log logic decoupling is achieved, log recording and management are carried out through the independent log gateway unit, and therefore collection and pulling of log contents of all micro services are not needed.
As a preferred scheme, the framework of the log gateway unit adopts Spring Cloud Zuul to better adapt to and exert various ecological abilities of the Spring technology, thereby reducing the development cost and improving the development efficiency.
In addition, the business service system based on the micro-service architecture further comprises: the configuration unit 33 is configured to configure association relations included between the plurality of micro service modules and the at least one log gateway, and/or configure a preset log rule.
The configuration unit can also be a uniform configuration center, and the configuration unit can dynamically inform the log gateway after modifying the preset log rule, and the modification of the log configuration can enable all services of the log gateway to take effect in real time by combining the function of the configuration center. Therefore, the configuration center can be used for configuring various rule switches related to the log and the route, actively pushing the log to the log gateway after dynamic modification, and flexibly starting or closing corresponding log recording operation.
In addition, the business service system based on the micro-service architecture may further include: and the registering unit 34 is configured to adjust the number of micro service modules and/or the number of log gateways. Specifically, the registration unit is responsible for service registration and discovery of the log gateway, the service application and the configuration center, and realizes the free arrangement and combination of micro services and the horizontal expansion of processing capacity, so that each part can dynamically increase nodes, and high availability and high expansion are realized. Preferably, the registration unit is used as a registration center, and can dynamically expand all services including the log gateway, thereby realizing high availability and high expansion. In addition, the log gateway can also distribute the number of services in a gray scale in combination with the function of the registration center, so that the log gateway can be flexibly expanded or reduced according to the pressure load condition.
Therefore, the business service system based on the micro-service architecture is formed by freely arranging and combining a series of micro-services, business functions can be independently deployed and called, the processing capacity can be transversely expanded in a container level, the elastic distribution of physical resources is realized, various scenes and requirements are flexibly met, the practicability and the interactivity are improved, and the operation is stable and reliable. Moreover, the business service system based on the micro service architecture provided by the embodiment replaces a virtual machine mode, so that the resource utilization rate of the server is improved.
The business service system based on the micro-service architecture provided by the embodiment of the invention has the same technical characteristics as the log processing method based on the micro-service architecture provided by the embodiment, so that the same technical problems can be solved, and the same technical effect can be achieved.
Example four:
as shown in fig. 4, the electronic device 4 includes a memory 41 and a processor 42, where the memory stores a computer program that can run on the processor, and the processor executes the computer program to implement the steps of the method provided in the first embodiment or the second embodiment.
Referring to fig. 4, the electronic device further includes: a bus 43 and a communication interface 44, the processor 42, the communication interface 44 and the memory 41 being connected by the bus 43; the processor 42 is for executing executable modules, such as computer programs, stored in the memory 41.
The Memory 41 may include a high-speed Random Access Memory (RAM) and may also include a non-volatile Memory (non-volatile Memory), such as at least one disk Memory. The communication connection between the network element of the system and at least one other network element is realized through at least one communication interface 44 (which may be wired or wireless), and the internet, a wide area network, a local network, a metropolitan area network, and the like can be used.
The bus 43 may be an ISA bus, a PCI bus, an EISA bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one double-headed arrow is shown in FIG. 4, but that does not indicate only one bus or one type of bus.
The memory 41 is used for storing a program, the processor 42 executes the program after receiving an execution instruction, and the method executed by the apparatus defined by the flow process disclosed in any of the foregoing embodiments of the present invention may be applied to the processor 42, or implemented by the processor 42.
The processor 42 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by instructions in the form of hardware, integrated logic circuits, or software in the processor 42. The Processor 42 may be a general-purpose Processor, and includes a Central Processing Unit (CPU), a Network Processor (NP), and the like; the device can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components. The various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in a memory 41, and a processor 42 reads information in the memory 41 and performs the steps of the method in combination with hardware thereof.
Example five:
in an embodiment of the present invention, a computer-readable medium having a non-volatile program code executable by a processor is provided, where the program code causes the processor to execute the method provided in the first embodiment or the second embodiment.
Unless specifically stated otherwise, the relative steps, numerical expressions, and values of the components and steps set forth in these embodiments do not limit the scope of the present invention.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the system and the apparatus described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In all examples shown and described herein, any particular value should be construed as merely exemplary, and not as a limitation, and thus other examples of example embodiments may have different values.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The computer-readable medium having the processor-executable nonvolatile program code provided in the embodiments of the present invention has the same technical features as the microservice architecture-based log processing method, the service system, and the electronic device provided in the embodiments, so that the same technical problems can be solved, and the same technical effects can be achieved.
Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance.
The computer program product for performing the log processing method based on the microservice architecture provided by the embodiment of the present invention includes a computer readable storage medium storing a nonvolatile program code executable by a processor, where instructions included in the program code may be used to execute the method described in the foregoing method embodiment, and specific implementation may refer to the method embodiment, and will not be described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one logical division, and there may be other divisions when actually implemented, and for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of devices or units through some communication interfaces, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
Finally, it should be noted that: the above-mentioned embodiments are only specific embodiments of the present invention, which are used for illustrating the technical solutions of the present invention and not for limiting the same, and the protection scope of the present invention is not limited thereto, although the present invention is described in detail with reference to the foregoing embodiments, those skilled in the art should understand that: any person skilled in the art can modify or easily conceive the technical solutions described in the foregoing embodiments or equivalent substitutes for some technical features within the technical scope of the present disclosure; such modifications, changes or substitutions do not depart from the spirit and scope of the embodiments of the present invention, and they should be construed as being included therein. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (5)

1. A log processing method based on a micro-service architecture is applied to a first log gateway in a log gateway unit, and comprises the following steps:
receiving a service processing request sent by a user;
routing the service processing request to a corresponding micro service module;
receiving service processing feedback information fed back by the corresponding micro service module based on the service processing request;
managing the log data according to a preset log rule according to the feedback information;
the routing the service processing request to the corresponding micro service module specifically includes:
filtering the service processing request according to a safety degree to obtain a filtering result, wherein the safety degree represents whether network safety attack data exists in the service processing request or not;
verifying the service processing request according to an authorization condition to obtain a verification result, wherein the authorization condition represents whether a user ID for sending the service processing request is authorized;
determining whether a security authorization request is generated according to the filtering result and the checking result;
under the condition that the generation of the security authorization request is confirmed, taking the security authorization request as the service processing request, and routing the security authorization request to a micro service module;
the method further comprises the following steps:
and if the safety authorization request is determined not to be generated based on the filtering result and the checking result, the service processing request is not routed to a micro service module, and a target log is recorded, wherein the target log represents that the checking and/or filtering of the service request is not passed.
2. The microservice architecture-based log processing method of claim 1, wherein the method further comprises:
acquiring configuration information sent by a configuration center;
and modifying the preset log rule based on the configuration information.
3. The microservice architecture-based log processing method according to claim 1, wherein the routing the service processing request to the corresponding microservice module specifically comprises:
acquiring an incidence relation between a micro-service module and a first log gateway in the log gateway unit;
determining a micro-service module corresponding to the first log gateway based on the incidence relation;
and routing the service processing request to the corresponding micro service module.
4. An electronic device comprising a memory and a processor, wherein the memory stores a computer program operable on the processor, and wherein the processor implements the steps of the method of any of claims 1 to 3 when executing the computer program.
5. A computer-readable medium having non-volatile program code executable by a processor, wherein the program code causes the processor to perform the method of any of claims 1 to 3.
CN201810703464.7A 2018-06-29 2018-06-29 Log processing method based on micro-service architecture, service system and electronic equipment Active CN108847989B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810703464.7A CN108847989B (en) 2018-06-29 2018-06-29 Log processing method based on micro-service architecture, service system and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810703464.7A CN108847989B (en) 2018-06-29 2018-06-29 Log processing method based on micro-service architecture, service system and electronic equipment

Publications (2)

Publication Number Publication Date
CN108847989A CN108847989A (en) 2018-11-20
CN108847989B true CN108847989B (en) 2021-07-06

Family

ID=64200996

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810703464.7A Active CN108847989B (en) 2018-06-29 2018-06-29 Log processing method based on micro-service architecture, service system and electronic equipment

Country Status (1)

Country Link
CN (1) CN108847989B (en)

Families Citing this family (30)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109714193B (en) * 2018-12-05 2022-01-18 国云科技股份有限公司 Method for taking over object storage service based on zuul routing forwarding mode
CN109859036A (en) * 2019-02-14 2019-06-07 锋泾(中国)建材集团有限公司 Financial process method and micro services framework
CN109889416B (en) * 2019-02-18 2020-06-19 西安交通大学 Intelligent home system based on micro-service architecture and construction method
CN110096437A (en) * 2019-04-12 2019-08-06 平安普惠企业管理有限公司 The test method and Related product of micro services framework
CN110460584B (en) * 2019-07-16 2022-02-01 北京奇艺世纪科技有限公司 Access request processing method and device, electronic equipment and computer readable medium
CN110427299B (en) * 2019-07-19 2022-02-11 腾讯科技(深圳)有限公司 Log processing method, related device and system for micro-service system application
CN111767157B (en) * 2019-08-07 2024-05-17 北京京东尚科信息技术有限公司 Request processing method and device based on service grid
CN110704483A (en) * 2019-09-06 2020-01-17 平安普惠企业管理有限公司 User routing process positioning method, device, storage medium and device
CN110798502B (en) * 2019-09-18 2022-06-17 平安科技(深圳)有限公司 Grayscale publishing method and device based on micro-service framework and computer equipment
CN110545328A (en) * 2019-09-25 2019-12-06 杭州安恒信息技术股份有限公司 Non-invasive service function expansion enhancing method and device and server
CN111258864A (en) * 2019-12-03 2020-06-09 佛山欧神诺云商科技有限公司 Program access log recording method and device and storage medium
CN111212038B (en) * 2019-12-23 2021-02-09 江苏国泰新点软件有限公司 Open data API gateway system based on big data artificial intelligence
CN111193733A (en) * 2019-12-27 2020-05-22 杭州安恒信息技术股份有限公司 Gateway system based on intranet microservice architecture
CN111176951A (en) * 2019-12-31 2020-05-19 上海擎感智能科技有限公司 Log output configuration/log processing method/system, medium, and server
CN111258565B (en) * 2020-01-21 2023-06-06 深圳乐信软件技术有限公司 Method, system, server and storage medium for generating applet
CN111586097A (en) * 2020-04-01 2020-08-25 车智互联(北京)科技有限公司 Network request processing method, computing device and storage medium
CN111651637B (en) * 2020-05-26 2022-06-21 南京领行科技股份有限公司 Service data management method and device
CN113765944A (en) * 2020-06-01 2021-12-07 中移(苏州)软件技术有限公司 Micro-service management method, device, equipment and storage medium
CN111913923A (en) * 2020-07-15 2020-11-10 上海眼控科技股份有限公司 Log recording method, apparatus, device and storage medium
CN112104715A (en) * 2020-08-31 2020-12-18 银盛支付服务股份有限公司 Link tracking method and system based on microservice log
CN112118242A (en) * 2020-09-09 2020-12-22 厦门安胜网络科技有限公司 Zero trust authentication system
CN112202598B (en) * 2020-09-10 2022-12-27 青岛海信网络科技股份有限公司 Log recording method and device
CN114501391B (en) * 2020-10-26 2023-07-21 中国移动通信集团设计院有限公司 Micro-service business processing system and method
CN112306811A (en) * 2020-11-09 2021-02-02 重庆易宠科技有限公司 PHP micro-service control method, system, terminal and medium
CN113010378B (en) * 2021-03-04 2023-02-03 万翼科技有限公司 Log processing method and device of microservice module, storage medium and electronic device
CN113472808B (en) * 2021-07-16 2023-07-14 浙江大华技术股份有限公司 Log processing method and device, storage medium and electronic device
CN113592471A (en) * 2021-07-29 2021-11-02 中国人民银行清算总中心 Payment transaction application system and method
CN114301893B (en) * 2021-12-30 2023-11-07 胜斗士(上海)科技技术发展有限公司 Log management method, system and readable storage medium
CN114710562B (en) * 2022-03-31 2022-11-08 珠海市鸿瑞信息技术股份有限公司 Big data-based equipment application log correlation analysis system and method
CN114844771B (en) * 2022-05-05 2024-03-08 亚信科技(中国)有限公司 Method, device, storage medium and program product for monitoring micro service system

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103856534B (en) * 2012-12-05 2018-02-13 腾讯科技(深圳)有限公司 A kind of daily record gathering method and system based on peer-to-peer network
CN105243009B (en) * 2015-11-12 2018-03-30 北京金山安全软件有限公司 Method and device for determining use log
CN106254144B (en) * 2016-09-06 2020-02-14 华为技术有限公司 Fault positioning platform, fault positioning method and device
CN106161480B (en) * 2016-09-28 2019-06-21 四川长虹电器股份有限公司 SMS platform service scheduling method based on gateway resource pond
CN107181675B (en) * 2017-06-20 2020-03-03 北京奇艺世纪科技有限公司 Service calling method and device
CN107590048A (en) * 2017-07-31 2018-01-16 北京北信源软件股份有限公司 A kind of micro services log-output method and device
CN108234653A (en) * 2018-01-03 2018-06-29 马上消费金融股份有限公司 A kind of method and device of processing business request

Also Published As

Publication number Publication date
CN108847989A (en) 2018-11-20

Similar Documents

Publication Publication Date Title
CN108847989B (en) Log processing method based on micro-service architecture, service system and electronic equipment
US10129118B1 (en) Real time anomaly detection for data streams
CN107493310B (en) Cloud resource processing method and cloud management platform
CN106326219B (en) Method, device and system for checking business system data
US11561849B1 (en) Intelligently adaptive log level management of a service mesh
CN111580884B (en) Configuration updating method, device, server and electronic equipment
CN108351806A (en) Database trigger of the distribution based on stream
US9229758B2 (en) Passive monitoring of virtual systems using extensible indexing
CN107111510B (en) Method and device for operating VNF packet
CN112925647A (en) Cloud edge coordination system, and control method and device of cluster resources
CN105765533B (en) Method and apparatus for firmware virtualization
CN105653425A (en) Complicated event processing engine based monitoring system
CN105095103A (en) Storage device management method and device used for cloud environment
CN112702167B (en) Cluster feature code obtaining method and device and electronic equipment
CN111651170B (en) Instance dynamic adjustment method and device and related equipment
CN110149307A (en) A kind of IDC safety management system
CN111064626A (en) Configuration updating method, device, server and readable storage medium
CN107426012B (en) Fault recovery method and device based on super-fusion architecture
CN108228310B (en) Balanced deployment method and device of virtual network function
CN112395357A (en) Data collection method and device and electronic equipment
US9912545B2 (en) High performance topology resolution for non-instrumented nodes
CN114895879B (en) Management system design scheme determining method, device, equipment and storage medium
CN112448833B (en) Multi-management-domain communication method and device
US20200099788A1 (en) Context data management interface for contact center
CN111708677A (en) Cloud hard disk usage amount acquisition method in cloud computing environment

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: No. 188, Lianhui street, Xixing street, Binjiang District, Hangzhou, Zhejiang Province, 310000

Applicant after: Hangzhou Anheng Information Technology Co.,Ltd.

Address before: 310051 15-storey Zhejiang Zhongcai Building, No. 68 Tonghe Road, Binjiang District, Hangzhou City, Zhejiang Province

Applicant before: Hangzhou Anheng Information Technology Co.,Ltd.

GR01 Patent grant
GR01 Patent grant