CN110032392B - Service management method and device, storage medium and electronic equipment - Google Patents

Service management method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN110032392B
CN110032392B CN201910299969.6A CN201910299969A CN110032392B CN 110032392 B CN110032392 B CN 110032392B CN 201910299969 A CN201910299969 A CN 201910299969A CN 110032392 B CN110032392 B CN 110032392B
Authority
CN
China
Prior art keywords
service
component
micro
proxy
module
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
CN201910299969.6A
Other languages
Chinese (zh)
Other versions
CN110032392A (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 Netease Shuzhifan Technology Co ltd
Original Assignee
Hangzhou Langhe 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 Langhe Technology Co Ltd filed Critical Hangzhou Langhe Technology Co Ltd
Priority to CN201910299969.6A priority Critical patent/CN110032392B/en
Publication of CN110032392A publication Critical patent/CN110032392A/en
Application granted granted Critical
Publication of CN110032392B publication Critical patent/CN110032392B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The embodiment of the invention relates to the technical field of Internet, in particular to a service management method and device, a storage medium and electronic equipment. The method comprises the following steps: acquiring a call instruction for a target micro-service; invoking an agent component which corresponds to the target micro-service and comprises a service management component according to the invoking instruction; loading the proxy component including a service administration component to the target micro-service to invoke the target micro-service. According to the method and the device, the agent components are generated in advance according to the service governance components and are configured to the corresponding micro services, unified management and configuration of the service governance components corresponding to the micro services can be facilitated, and management cost of the service governance components is reduced.

Description

Service management method and device, storage medium and electronic equipment
Technical Field
The embodiment of the invention relates to the technical field of cloud computing, in particular to a service management method and device, a storage medium and electronic equipment.
Background
This section is intended to provide a background or context to the embodiments of the invention that are recited in the claims, and the description herein is not admitted to be prior art by inclusion in this section.
In the face of complex distributed system architecture, the application program can be split into a plurality of independent micro-service applications according to different business responsibilities by using a service management mechanism. For the related functions of service governance, continuous debugging is required to be carried out for each micro-service separately, so that each independent micro-service can have the related functions of service governance.
Disclosure of Invention
However, in some technologies, on one hand, after the single application is split into multiple micro-services, each micro-service needs to perform integrated development work on each service governance component, where the work includes but is not limited to relying on conflict checking, version compatibility, code adaptation and modification, start-up debugging, and the like, and the adaptation flow of the same component on different micro-service applications has a great deal of repetitive work; on the other hand, each service management component contains a plurality of configurable parameters, and if each parameter is configured incorrectly, the application is possibly abnormal in the calling process, so that a developer needs to inquire a large number of development documents and configuration files, and a large number of development costs are increased; on the other hand, in the distributed system architecture, the split micro-services may be dispersed in different physical machines, virtual machines or containers, so that the user cannot uniformly manage and configure the configuration files of the service treatments corresponding to each micro-service. Moreover, because of the large number of service administration components, each component has an independent configuration, and as the traffic increases, the configuration file becomes longer and longer, and becomes difficult to maintain.
Therefore, in the prior art, each application service management component under the micro-service architecture has the problems of complicated access, inconvenient configuration management and the like.
Therefore, an improved service management method and device, a storage medium and electronic equipment are very needed to solve the problems that access of each application service management component under a micro-service architecture is complex and configuration is not easy to manage.
In this context, embodiments of the present invention desire to provide a service governance method and apparatus, a storage medium, and an electronic device.
According to one aspect of the present disclosure, there is provided a service governance method comprising:
acquiring a call instruction for a target micro-service;
invoking an agent component which corresponds to the target micro-service and comprises a service management component according to the invoking instruction;
loading the proxy component including a service administration component to the target micro-service to invoke the target micro-service.
In one exemplary embodiment of the present disclosure, the call instruction includes address information of the target micro-service corresponding proxy component.
In an exemplary embodiment of the present disclosure, the invoking, according to the invoking instruction, a proxy component corresponding to the target micro-service includes:
Reading the proxy component of the target micro-service according to the address information;
the proxy component is preloaded.
In one exemplary embodiment of the present disclosure, the loading the proxy component into the target micro-service includes:
registering a first converter and performing byte code conversion on the proxy component by using the first converter;
performing byte code enhancement processing on the byte code conversion result of the proxy component;
and calling the proxy component after the byte code enhancement processing to load the proxy component into the target micro-service.
In one exemplary embodiment of the present disclosure, invoking the proxy component after bytecode enhancement processing to load to the target micro-service includes:
reading configuration files of each service management component in the proxy component;
registering a second converter, and performing byte code conversion on the service governance component by using the second converter based on the configuration file;
performing byte code enhancement processing on the byte code conversion result of the service governance component so as to insert the operation logic of the service governance component into the business logic of the target micro-service;
and synchronizing the proxy component which is enhanced by the byte code and contains the service governance component logic to the target micro-service.
In an exemplary embodiment of the present disclosure, the method further comprises:
collecting operation parameters of the micro-service through the proxy component;
and sending the operation parameters to a control background so as to facilitate the control background to monitor the micro-service.
In an exemplary embodiment of the present disclosure, the method further comprises:
receiving a service management component configuration instruction of a control background;
and synchronously updating the proxy components corresponding to the micro services according to the configuration instructions.
In an exemplary embodiment of the present disclosure, after the obtaining the call instruction to the target micro-service, the method further includes:
and carrying out fault tolerance verification on the call instruction.
In an exemplary embodiment of the present disclosure, the method further comprises:
service splitting is carried out on the target application program to obtain a plurality of split services;
extracting a common service governance component of each split service, packaging to generate a proxy component, and generating micro-services according to a business component of the split service;
the proxy component is configured for each of the micro-services.
In an exemplary embodiment of the present disclosure, the service remediation component includes any one or a combination of any of the following:
The system comprises a service registration discovery component, a routing and load balancing component, a service call protection component, a data monitoring and statistics component and a service authentication and authorization component.
According to one aspect of the present disclosure, there is provided a service governance device comprising:
the instruction reading module is used for acquiring a call instruction for the target micro-service;
the component calling module is used for calling the proxy component which corresponds to the target micro-service and comprises the service treatment component according to the calling instruction;
and the component loading module is used for loading the proxy component containing the service governance component to the target micro-service so as to call the target micro-service.
In one exemplary embodiment of the present disclosure, the call instruction includes address information of the target micro-service corresponding proxy component.
In an exemplary embodiment of the present disclosure, the component call module includes:
the address reading module is used for reading the proxy component of the target micro-service according to the address information;
and the preloading module is used for preloading the agent component.
In one exemplary embodiment of the present disclosure, the component loading module includes:
the first conversion module is used for registering a first converter and converting byte codes of the proxy component by utilizing the first converter;
The first enhancement module is used for carrying out byte code enhancement processing on the byte code conversion result of the proxy component;
and the calling module is used for calling the proxy component after the byte code enhancement processing to load the proxy component to the target micro-service.
In an exemplary embodiment of the present disclosure, the calling module includes:
the configuration reading module is used for reading the configuration file of each service management component in the proxy component;
the second conversion module is used for registering a second converter and converting byte codes of the service management component by using the second converter based on the configuration file;
the second enhancement module is used for performing byte code enhancement processing on the byte code conversion result of the service governance component so as to insert the operation logic of the service governance component into the business logic of the target micro-service;
and the logic synchronization module is used for synchronizing the proxy component which is enhanced by the byte code and contains the service management component logic to the target micro-service.
In an exemplary embodiment of the present disclosure, the apparatus further comprises:
the parameter acquisition module is used for acquiring the operation parameters of the micro-service through the proxy component;
and the parameter transmission module is used for sending the operation parameters to a control background so as to facilitate the control background to monitor the micro service.
In an exemplary embodiment of the present disclosure, the apparatus further comprises:
the configuration instruction receiving module is used for receiving a service management component configuration instruction of the control background;
and the configuration synchronization module is used for synchronously updating the proxy components corresponding to the micro services according to the configuration instruction.
In an exemplary embodiment of the present disclosure, the apparatus further comprises:
and the instruction verification module is used for carrying out fault tolerance verification on the calling instruction after the calling instruction of the target micro-service is acquired.
In an exemplary embodiment of the present disclosure, the apparatus further comprises:
the service splitting module is used for splitting the service of the target application program to obtain a plurality of split services;
the micro-service encapsulation module is used for extracting the common service management components of the split services, encapsulating the common service management components to generate proxy components and generating micro-services according to the business components of the split services;
and the proxy component configuration module is used for configuring the proxy components for each micro service.
In an exemplary embodiment of the present disclosure, the service remediation component includes any one or a combination of any of the following:
the system comprises a service registration discovery component, a routing and load balancing component, a service call protection component, a data monitoring and statistics component and a service authentication and authorization component.
According to one aspect of the present disclosure, there is provided a storage medium having stored thereon a computer program which, when executed by a processor, implements the service remediation method of any one of the above.
According to one aspect of the present disclosure, there is provided an electronic device including:
a processor; and
a memory for storing executable instructions of the processor;
wherein the processor is configured to perform any of the above methods of service remediation via execution of the executable instructions.
According to the service management method provided by the embodiment of the invention, when the target micro-service is required to be called, firstly, the proxy component which corresponds to the target micro-service and contains the service management component is called according to the calling instruction, and the proxy component is loaded to the target micro-service, so that the calling of the target micro-service is realized, the enhancement of the micro-service application program is realized, and the access program of the service management component is effectively simplified. The agent components are generated in advance according to the service management components and configured to the corresponding micro services, so that unified management and configuration of the service management components corresponding to the micro services can be facilitated, and the management cost of the service management components is reduced.
Drawings
The above, as well as additional purposes, features, and advantages of exemplary embodiments of the present invention will become readily apparent from the following detailed description when read in conjunction with the accompanying drawings. Several embodiments of the present invention are illustrated by way of example, and not by way of limitation, in the figures of the accompanying drawings and in which:
FIG. 1 schematically illustrates a flow chart of a service remediation method according to an embodiment of the present invention;
FIG. 2 schematically illustrates a flow chart of another service remediation method according to an embodiment of the present invention;
FIG. 3 schematically illustrates a flow diagram of a method of splitting a micro service and configuring a proxy component in accordance with an embodiment of the present invention;
FIG. 4 schematically illustrates a flow diagram of a method of loading a proxy component according to an embodiment of the invention;
FIG. 5 schematically shows a block diagram of a service remediation device according to an embodiment of the present invention;
FIG. 6 shows a schematic diagram of a storage medium according to an embodiment of the present invention; and
fig. 7 schematically shows a block diagram of an electronic device according to an embodiment of the invention.
In the drawings, the same or corresponding reference numerals indicate the same or corresponding parts.
Detailed Description
The principles and spirit of the present invention will be described below with reference to several exemplary embodiments. It should be understood that these embodiments are presented merely to enable those skilled in the art to better understand and practice the invention and are not intended to limit the scope of the invention in any way. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
Those skilled in the art will appreciate that embodiments of the invention may be implemented as a system, apparatus, device, method, or computer program product. Accordingly, the present disclosure may be embodied in the following forms, namely: complete hardware, complete software (including firmware, resident software, micro-code, etc.), or a combination of hardware and software.
According to an embodiment of the present invention, there is provided a service governance method, a service governance device, a storage medium, and an electronic apparatus.
Any number of elements in the figures are for illustration and not limitation, and any naming is used for distinction only, and not for any limiting sense.
The principles and spirit of the present invention are described in detail below with reference to several representative embodiments thereof.
Summary of The Invention
The present inventors have found that in the prior art, when implementing service governance functions for each micro-service of a single application, it is necessary to split the application into a plurality of micro-services and develop and configure related configuration files for service governance for each micro-service individually, each service governance component having an independent configuration file. Because the service management components with the same functions exist among the micro services, the configuration files of the service management are complex, the parameter configuration items are more, a great deal of repetitive work exists in the adaptation flow of the same components on different micro service applications, and the configuration process is excessively complex and complicated. In addition, in the distributed architecture, the split service may be distributed in different physical machines, virtual machines or containers, and the user cannot uniformly manage and control the service management configuration file corresponding to each micro service.
In view of the above, the basic idea of the invention is that: when the target micro-service needs to be called, calling a proxy component which corresponds to the target micro-service and contains a service management component according to a calling instruction, and loading the proxy component to the target micro-service. On the one hand, the access procedure of the service governance component can be effectively simplified. On the other hand, the service management components are generated into independent proxy components in advance and are configured to the corresponding micro services, so that unified management and configuration of the service management components corresponding to the micro services can be facilitated, the management cost of the service management components is reduced, and repeated development of the same service management components among the micro services is avoided.
Having described the basic principles of the present invention, various non-limiting embodiments of the invention are described in detail below.
Exemplary method
A service governance method according to an exemplary embodiment of the present invention is described below with reference to the accompanying drawings and examples.
Referring to fig. 1, the service governance method may include the steps of:
s110, acquiring a call instruction for a target micro-service;
s120, calling a proxy component which corresponds to the target micro-service and comprises a service treatment component according to the calling instruction;
S130, loading the proxy component containing the service governance component to the target micro-service to call the target micro-service.
In the service management method of the embodiment of the invention, when the target micro-service is required to be called, firstly, the proxy component which corresponds to the target micro-service and contains the service management component is called according to the calling instruction, and the proxy component is loaded to the target micro-service, so that the calling of the target micro-service is realized, and the access procedure of the service management component is effectively simplified. By generating the proxy component and configuring the proxy component to the corresponding micro-service in advance according to the service management component, unified management and configuration of the service management component corresponding to each micro-service can be facilitated, management cost of the service management component is reduced, and development flow of the service management component corresponding to the micro-service is simplified.
Referring to fig. 2, the service governance method may further include:
in step S100, the micro-service is split for the target application and the corresponding proxy component is configured.
In an exemplary embodiment of the present disclosure, specifically, referring to fig. 3, the step S100 described above may include the steps of:
step S1001, performing service splitting on the target application program to obtain a plurality of split services;
Step S1002, extracting the shared service management components of the split services, packaging to generate proxy components, and generating micro-services according to the business components of the split services;
step S1003, configuring the proxy component for each micro service.
For a single application, the target application may be split into multiple micro-services according to rules or conditions of business, functionality, etc. For example, an application is split into micro-services such as user services, comment services, and payment services. Generally, a micro-service may comprise two parts, business logic and service governance related logic. For example, the business logic of the user service may include business logic of related functions such as user registration, user login, and the like; the service governance related logic may then include: routing and load balancing, data monitoring and statistics, and so on. Therefore, for each split micro service, only the service logic related to the service of the micro service can be reserved, and the shared or universal service management logic among the micro services is split to form a proxy component, and the proxy component integrates all the functions related to service management; and a corresponding Agent component (Agent) is configured for each micro-service.
For example, the proxy component may be embodied in the form of a jar package file, and the proxy component may include: the system comprises a service registration discovery component, a routing and load balancing component, a service call protection component, a data monitoring and statistics component, a service authentication and authentication component and other service management components. Of course, in other exemplary embodiments of the present disclosure, the proxy component may further include: a fuse protection component, a current limiting component, a fault tolerance verification component, and the like. The relevant content of the service governance component in the proxy component can be defined according to the service instruction function related to each micro-service entity. The present disclosure is not particularly limited thereto.
In step S110, a call instruction to a target micro service is acquired.
In an exemplary embodiment of the present disclosure, the above-mentioned call instruction to the target micro-service may be a call instruction to the target micro-service triggered when the user uses the application program, for example, when the user submits comment information at the intelligent terminal, the call instruction to the comment service may be triggered; alternatively, the call instruction to the user service (i.e., the target micro-service) may be triggered when a new user is registered. Alternatively, in other exemplary embodiments of the present disclosure, the above-mentioned call instruction to the target micro-service may also be a call instruction triggered between micro-services within an application program; for example, when a user submits comment information, the user is identified as not logging in, and the comment service can initiate the call of the user service, so that the user logs in or registers in the intelligent terminal.
In step S120, a proxy component including a service governance component corresponding to the target micro-service is called according to the call instruction.
In an exemplary embodiment of the present disclosure, specifically, the above-mentioned call instruction may be used as a start command of a micro service, and the call instruction may include address information of a proxy component corresponding to the target micro service.
Specifically, the step S120 may include:
s1201, reading a proxy component of the target micro-service according to the address information;
s1202, preloading the agent component.
By adding address information of the proxy component corresponding to the target micro service in the call instruction, the designated proxy component can be read according to the path. After reading the proxy component of the target microservice, jvm (Java Virtual Machine ) can execute premain functions, preloading the proxy component. By preloading the proxy component, the loading time of the proxy component can be shortened, and the loading flow of the proxy component can be optimized.
In step S130, the proxy component including a service governance component is loaded to the target micro-service to invoke the target micro-service.
In an exemplary embodiment of the present disclosure, specifically, referring to fig. 4, loading the proxy component into the target micro-service may include the steps of:
step S1301, registering a first converter and performing byte code conversion on the proxy component by using the first converter;
step S1302, performing byte code enhancement processing on the byte code conversion result of the proxy component;
step S1303, call the proxy component after the byte code enhancement processing to load the target micro service.
In this example embodiment, a first translator (translator) may be registered at jvm and utilized to perform byte code conversion on each service governance component in the proxy component, returning converted byte code in the callback function, i.e., modified byte code containing the service governance logic. And performing byte code enhancement processing on the converted byte code at jvm, and generating a corresponding class file. And loading the proxy component subjected to the byte code enhancement processing to the target micro-service to realize external loading of the proxy component. For example, the byte code enhancement may be performed by a tool such as ASM, javaasist, and the specific process may be implemented by a conventional method, which is not described in detail in this disclosure.
Specifically, the foregoing invoking the proxy component after the bytecode enhancement process to load the target micro service may specifically include the following:
step S201, reading configuration files of each service management component in the agent component;
step S202, registering a second converter, and performing byte code conversion on the service management component by using the second converter based on the configuration file;
step 203, performing byte code enhancement processing on the byte code conversion result of the service governance component, so as to insert the operation logic of the service governance component into the business logic of the target micro-service;
step S204, synchronizing the proxy component, which is enhanced by the byte code and contains the service governance component logic, to the target micro-service.
In this example embodiment, after the proxy component is loaded into the micro-service, for the inside of the proxy component, after the proxy component is started, a configuration file of each service governance component may be read, where the configuration file may include content such as relevant parameter information, address information, and the like of service governance. The second translator may then be registered and a determination made in the class loader as to whether byte code enhancement of the service administration component is required. If the current service governance component is the service governance component which is needed to be used currently, byte code enhancement processing is carried out on the class file corresponding to the service governance component, so that the operation logic of the service governance component is inserted into the business logic of the target micro-service and is synchronized to the local of the target micro-service, and the service governance component is loaded into the micro-service in a non-invasive mode.
In addition, in other exemplary embodiments of the present disclosure, the target micro-service may also perform fault-tolerant verification on the call instruction through the proxy component after obtaining the call instruction. For example, a fault tolerant mechanism component may also be included in the proxy component for validating call instructions and retrying when a call error occurs. The proxy component may verify the call instruction through the component.
Furthermore, in some exemplary embodiments of the present disclosure, the method described above may further include:
step S310, collecting the operation parameters of the micro-service through the proxy component;
step S320, sending the operation parameter to a control background so that the control background can monitor the micro service.
In this example embodiment, the agent component may further include a monitoring component. In the running process of each micro service, the running parameters of the micro service and the running parameters of each service management component in the agent component can be collected through the component. And uploading the monitoring parameters to a control background in a real-time or regular mode, so that the control background can aggregate and analyze the data and can generate a corresponding database or report according to the data according to the requirements of users.
In some exemplary embodiments of the present disclosure, the above-described method may further include:
step S410, receiving a service management component configuration instruction of a control background;
step S420, synchronously updating the proxy components corresponding to the micro services according to the configuration instruction.
In this exemplary embodiment, each proxy component may be further configured with a communication module, and each proxy component may perform data communication with the control background in a long connection manner, for example, using grpc as a communication manner. The user can issue configuration instructions to the proxy components corresponding to the micro services respectively or uniformly through the control background, wherein the configuration instructions can comprise configuration files of the service instruction components, or configuration modification data, service governance component addition and the like. Therefore, the unified management and control of the service management components are realized, and the unified management of the service management components of a plurality of micro services by a user is facilitated.
In summary, by extracting the related logic of the service governance in the micro service of the application program in advance and forming the independent proxy component, the micro service only maintains its own business logic, and configures the corresponding proxy component for each micro service, the management cost of the service governance component can be effectively reduced, and the development flows of the micro service and the service governance component can be saved. When the micro service is deployed, only the starting parameters of the proxy component are added, so that the micro service can have functions related to service management, and the access procedure of the service management component is simplified. For the existing micro-services, the enhancement of service governance can be realized under the condition of not modifying codes, and unified control and configuration of service governance components corresponding to different micro-services are facilitated.
Exemplary apparatus
Having introduced the service governance method of the exemplary embodiment of the present invention, next, the service governance apparatus of the exemplary embodiment of the present invention will be described with reference to fig. 5.
Referring to fig. 5, a service administration apparatus 500 of an exemplary embodiment of the present invention may include: an instruction fetch module 501, a component call module 502, and a component load module 503. Wherein, the liquid crystal display device comprises a liquid crystal display device,
the instruction fetch module 501 may be configured to obtain call instructions to a target microservice.
The component calling module 502 may be configured to call, according to the call instruction, a proxy component corresponding to the target micro-service and including a service governance component.
The component loading module 503 may be configured to load the proxy component including a service administration component into the target micro-service to invoke the target micro-service.
In the service management device, the instruction reading device obtains the calling instruction of the target micro-service, and the component calling module is enabled to call the proxy component corresponding to the target micro-service according to the calling instruction, and the proxy component is loaded to the target micro-service, so that the related logic of service management is loaded to the business logic of the target micro-service, and the access procedure of the service management component is simplified. By generating the independent proxy component from the service management component in advance and configuring the independent proxy component to the corresponding micro-service, unified management and configuration of the service management component corresponding to each micro-service can be facilitated, management cost of the service management component is reduced, and repeated development of the same service management component among the micro-services is avoided.
According to an exemplary embodiment of the present disclosure, the call instruction includes address information of the target micro-service corresponding proxy component.
According to an exemplary embodiment of the present disclosure, the component invocation module 502 may include: an address reading module, a preloading module (not shown in the figure). Wherein, the liquid crystal display device comprises a liquid crystal display device,
the address reading module may be configured to read a proxy component of the target micro-service according to the address information.
The preloading module may be configured to preload the proxy component.
By setting the preloading module, the agent component can be preloaded, so that the loading flow of the agent component is optimized, and the loading time is shortened.
According to an exemplary embodiment of the present disclosure, the component loading module 503 may include: the first conversion module, the first enhancement module and the calling module (not shown in the figure). Wherein, the liquid crystal display device comprises a liquid crystal display device,
the first translation module may be configured to register a first translator and utilize the first translator to bytecode the proxy component.
The first enhancement module may be configured to perform a byte code enhancement process on a byte code conversion result of the proxy component.
The calling module may be configured to call the proxy component after the bytecode enhancement process to load the proxy component into the target micro-service.
According to an exemplary embodiment of the present disclosure, the calling module may include: the reading module, the second converting module, the second enhancing module and the logic synchronizing module (not shown in the figure) are configured. Wherein, the liquid crystal display device comprises a liquid crystal display device,
the configuration reading module can be used for reading the configuration file of each service governance component in the proxy component.
The second conversion module may be configured to register a second converter and utilize the second converter to perform byte code conversion on the service administration component based on the configuration file.
The second enhancement module may be configured to perform a byte code enhancement process on a byte code conversion result of the service governance component, so as to insert operation logic of the service governance component into business logic of the target micro-service.
The logic synchronization module may be configured to synchronize the proxy component, which is enhanced with the bytecode and contains the service administration component logic, to the target micro-service.
According to an exemplary embodiment of the present disclosure, the apparatus further comprises: a parameter acquisition module and a parameter transmission module (not shown in the figure). Wherein, the liquid crystal display device comprises a liquid crystal display device,
the parameter acquisition module may be used to acquire operating parameters of the micro-service through the proxy component.
The parameter transmission module may be configured to send the operating parameter to a control background to facilitate the control background monitoring the micro-service.
The micro-service operation parameters are collected and sent to the control background periodically, so that a user can monitor the micro-service through the control background.
According to an exemplary embodiment of the present disclosure, the apparatus further comprises: a configuration instruction receiving module and a configuration synchronization module (not shown in the figure). Wherein, the liquid crystal display device comprises a liquid crystal display device,
the configuration instruction receiving module may be configured to receive a service administration component configuration instruction for controlling a background.
The configuration synchronization module can be used for synchronously updating the proxy components corresponding to the micro services according to the configuration instructions.
By setting the configuration synchronization module, the proxy components corresponding to different micro services can synchronously update the configuration file or parameters. The method is convenient for unified management and control of the service management components of each micro-service.
According to an exemplary embodiment of the present disclosure, the apparatus further comprises: an instruction verification module (not shown).
The instruction verification module can be used for performing fault tolerance verification on the call instruction after the call instruction for the target micro-service is acquired.
According to an exemplary embodiment of the present disclosure, the apparatus further comprises: a service splitting module, a micro-service encapsulation module, and a proxy component configuration module (not shown). Wherein, the liquid crystal display device comprises a liquid crystal display device,
the service splitting module may be configured to split a service of a target application to obtain a plurality of split services.
The micro-service encapsulation module may be configured to extract a common service governance component of each split service and encapsulate the common service governance component to generate a proxy component, and generate a micro-service according to a business component of the split service.
The proxy component configuration module may be configured to configure the proxy component for each of the micro-services.
According to an exemplary embodiment of the present disclosure, the service remediation component includes any one or a combination of any of the following:
the system comprises a service registration discovery component, a routing and load balancing component, a service call protection component, a data monitoring and statistics component and a service authentication and authorization component.
Since each functional module of the service management device in the embodiment of the present invention is the same as that in the embodiment of the present invention of the service management method, the description thereof is omitted herein.
Exemplary storage Medium
Having described the audio playing method and apparatus, the audio sharing method and apparatus of the exemplary embodiment of the present invention, next, a storage medium of the exemplary embodiment of the present invention will be described with reference to fig. 6.
Referring to fig. 6, a program product 600 for implementing the above-described method according to an embodiment of the present invention is described, which may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a device, such as a personal computer. However, the program product of the present invention is not limited thereto, and in this document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium can be, for example, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium would include the following: an electrical connection having one or more wires, a portable disk, a hard disk, random Access Memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
The computer readable signal medium may include a data signal propagated in baseband or as part of a carrier wave with readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C++ or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on a remote computing device, or entirely on the remote computing device or server. In the case of remote computing devices, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., connected via the Internet using an Internet service provider).
Exemplary electronic device
Having described the storage medium of the exemplary embodiment of the present invention, next, an electronic device of the exemplary embodiment of the present invention will be described with reference to fig. 7.
The electronic device 800 shown in fig. 7 is merely an example and should not be construed as limiting the functionality and scope of use of embodiments of the present invention.
As shown in fig. 7, the electronic device 800 is embodied in the form of a general purpose computing device. Components of electronic device 800 may include, but are not limited to: the at least one processing unit 810, the at least one storage unit 820, a bus 830 connecting the different system components (including the storage unit 820 and the processing unit 810), and a display unit 840.
Wherein the storage unit stores program code that is executable by the processing unit 810 such that the processing unit 810 performs steps according to various exemplary embodiments of the present invention described in the above section of the "exemplary method" of the present specification. For example, the processing unit 810 may perform steps S110 to S130 as shown in fig. 1, or the processing unit 810 may perform steps S100 to S130 as shown in fig. 2.
The storage unit 820 may include volatile storage units such as a Random Access Memory (RAM) 8201 and/or a cache memory 8202, and may further include a Read Only Memory (ROM) 8203.
Storage unit 820 may also include a program/utility 8204 having a set (at least one) of program modules 8205, such program modules 8205 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each or some combination of which may include an implementation of a network environment.
Bus 830 may include a data bus, an address bus, and a control bus.
The electronic device 800 may also communicate with one or more external devices 900 (e.g., keyboard, pointing device, bluetooth device, etc.) via an input/output (I/O) interface 850. The electronic device 800 further comprises a display unit 840 connected to an input/output (I/O) interface 850 for displaying. Also, electronic device 800 may communicate with one or more networks such as a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network, such as the Internet, through network adapter 860. As shown, network adapter 860 communicates with other modules of electronic device 800 over bus 830. It should be appreciated that although not shown, other hardware and/or software modules may be used in connection with electronic device 800, including, but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, data backup storage systems, and the like.
It should be noted that while in the above detailed description several modules or sub-modules of the service remediation device and the service remediation device are mentioned, this division is merely exemplary and not mandatory. Indeed, the features and functionality of two or more units/modules described above may be embodied in one unit/module in accordance with embodiments of the present invention. Conversely, the features and functions of one unit/module described above may be further divided into ones that are embodied by a plurality of units/modules.
Furthermore, although the operations of the methods of the present invention are depicted in the drawings in a particular order, this is not required to either imply that the operations must be performed in that particular order or that all of the illustrated operations be performed to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step to perform, and/or one step decomposed into multiple steps to perform.
While the spirit and principles of the present invention have been described with reference to several particular embodiments, it is to be understood that the invention is not limited to the disclosed embodiments nor does it imply that features of the various aspects are not useful in combination, nor are they useful in any combination, such as for convenience of description. The invention is intended to cover various modifications and equivalent arrangements included within the spirit and scope of the appended claims.

Claims (16)

1. A method of service remediation, comprising:
acquiring a call instruction for a target micro-service; the call instruction comprises address information of a proxy component corresponding to the target micro service; the target micro-service pre-configures a corresponding proxy component; wherein the micro-services comprise business logic and service governance related logic; the split target micro-service only keeps the business logic related to the business of the target micro-service;
invoking an agent component which corresponds to the target micro-service and comprises a service management component according to the invoking instruction; the agent component comprises shared or universal service management logic among the split micro services; the agent component is used for integrating all functions related to service management; the related content of the service management component in the proxy component is defined according to the service instruction function related to each micro-service entity;
loading the proxy component including a service administration component into the target micro-service, comprising: registering a first converter and performing byte code conversion on the proxy component by using the first converter; performing byte code enhancement processing on the byte code conversion result of the proxy component; reading configuration files of each service management component in the proxy component; registering a second converter, and performing byte code conversion on the service governance component by using the second converter based on the configuration file; performing byte code enhancement processing on the byte code conversion result of the service governance component to insert the operation logic of the service governance component into the business logic of the target micro-service, so as to realize loading the service governance component into the micro-service in a non-invasive manner; synchronizing a proxy component, which is enhanced by the byte code and contains the service governance component logic, to the target micro-service; to invoke the target micro-service.
2. The method of claim 1, wherein the invoking the proxy component corresponding to the target micro-service according to the invocation instruction comprises:
reading the proxy component of the target micro-service according to the address information;
the proxy component is preloaded.
3. The method according to claim 1, wherein the method further comprises:
collecting operation parameters of the micro-service through the proxy component;
and sending the operation parameters to a control background so as to facilitate the control background to monitor the micro-service.
4. The method according to claim 1, wherein the method further comprises:
receiving a service management component configuration instruction of a control background;
and synchronously updating the proxy components corresponding to the micro services according to the configuration instructions.
5. The method of claim 1, wherein after the obtaining the call instruction to the target micro-service, the method further comprises:
and carrying out fault tolerance verification on the call instruction.
6. The method according to claim 1, wherein the method further comprises:
service splitting is carried out on the target application program to obtain a plurality of split services;
Extracting a common service governance component of each split service, packaging to generate a proxy component, and generating micro-services according to a business component of the split service;
the proxy component is configured for each of the micro-services.
7. The method of claim 1 or 6, wherein the service remediation component comprises any one or a combination of any of the following:
the system comprises a service registration discovery component, a routing and load balancing component, a service call protection component, a data monitoring and statistics component and a service authentication and authorization component.
8. A service remediation device, comprising:
the instruction reading module is used for acquiring a call instruction for the target micro-service; the call instruction comprises address information of a proxy component corresponding to the target micro service; the target micro-service pre-configures a corresponding proxy component; wherein the micro-services comprise business logic and service governance related logic; the split target micro-service only keeps the business logic related to the business of the target micro-service;
the component calling module is used for calling the proxy component which corresponds to the target micro-service and comprises the service treatment component according to the calling instruction; the agent component comprises shared or universal service management logic among split micro services; the agent component is used for integrating all functions related to service management; the related content of the service management component in the proxy component is defined according to the service instruction function related to each micro-service entity;
The component loading module is used for loading the proxy component containing the service governance component to the target micro-service to call the target micro-service; the component calling module comprises: the first conversion module is used for registering a first converter and converting byte codes of the proxy component by utilizing the first converter; the first enhancement module is used for carrying out byte code enhancement processing on the byte code conversion result of the proxy component; the calling module is used for calling the proxy component after the byte code enhancement processing to load the proxy component to the target micro-service; the calling module comprises: the configuration reading module is used for reading the configuration file of each service management component in the proxy component; the second conversion module is used for registering a second converter and converting byte codes of the service management component by using the second converter based on the configuration file; the second enhancement module is used for performing byte code enhancement processing on the byte code conversion result of the service governance component so as to insert the operation logic of the service governance component into the business logic of the target micro-service and realize that the service governance component is loaded into the micro-service in a non-invasive manner; and the logic synchronization module is used for synchronizing the proxy component which is enhanced by the byte code and contains the service management component logic to the target micro-service.
9. The apparatus of claim 8, wherein the component invocation module comprises:
the address reading module is used for reading the proxy component of the target micro-service according to the address information;
and the preloading module is used for preloading the agent component.
10. The apparatus of claim 8, wherein the apparatus further comprises:
the parameter acquisition module is used for acquiring the operation parameters of the micro-service through the proxy component;
and the parameter transmission module is used for sending the operation parameters to a control background so as to facilitate the control background to monitor the micro service.
11. The apparatus of claim 8, wherein the apparatus further comprises:
the configuration instruction receiving module is used for receiving a service management component configuration instruction of the control background;
and the configuration synchronization module is used for synchronously updating the proxy components corresponding to the micro services according to the configuration instruction.
12. The apparatus of claim 8, wherein the apparatus further comprises:
and the instruction verification module is used for carrying out fault tolerance verification on the calling instruction after the calling instruction of the target micro-service is acquired.
13. The apparatus of claim 8, wherein the apparatus further comprises:
the service splitting module is used for splitting the service of the target application program to obtain a plurality of split services;
the micro-service encapsulation module is used for extracting the common service management components of the split services, encapsulating the common service management components to generate proxy components and generating micro-services according to the business components of the split services;
and the proxy component configuration module is used for configuring the proxy components for each micro service.
14. The apparatus of claim 8 or 13, wherein the service remediation component comprises any one or a combination of any of the following:
the system comprises a service registration discovery component, a routing and load balancing component, a service call protection component, a data monitoring and statistics component and a service authentication and authorization component.
15. A storage medium having stored thereon a computer program, wherein the computer program when executed by a processor implements the service governance method of any of claims 1 to 7.
16. An electronic device, comprising:
a processor; and
a memory for storing executable instructions of the processor;
Wherein the processor is configured to perform the service remediation method of any one of claims 1 to 7 via execution of the executable instructions.
CN201910299969.6A 2019-04-15 2019-04-15 Service management method and device, storage medium and electronic equipment Active CN110032392B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910299969.6A CN110032392B (en) 2019-04-15 2019-04-15 Service management method and device, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910299969.6A CN110032392B (en) 2019-04-15 2019-04-15 Service management method and device, storage medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN110032392A CN110032392A (en) 2019-07-19
CN110032392B true CN110032392B (en) 2023-05-09

Family

ID=67238421

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910299969.6A Active CN110032392B (en) 2019-04-15 2019-04-15 Service management method and device, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN110032392B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111131193B (en) * 2019-12-10 2022-05-20 四川新网银行股份有限公司 Distributed service management method supporting multi-protocol heterogeneous non-code intrusion
CN113765944A (en) * 2020-06-01 2021-12-07 中移(苏州)软件技术有限公司 Micro-service management method, device, equipment and storage medium
CN111917838B (en) * 2020-07-14 2023-08-29 浙江大华技术股份有限公司 Micro-service-based processing method and device, storage medium and electronic device
CN111953735A (en) * 2020-07-15 2020-11-17 烽火通信科技股份有限公司 System microservice transformation method, device, equipment and storage medium
CN112463211A (en) * 2020-07-28 2021-03-09 上海汇招信息技术有限公司 System architecture transformation method compatible with multiple development architectures and system architecture
CN112612804B (en) * 2020-12-22 2023-03-31 新华三大数据技术有限公司 Service management parameter updating method and device
CN113315748B (en) * 2021-03-18 2023-04-18 阿里巴巴新加坡控股有限公司 Communication method and device
CN113312037B (en) * 2021-06-15 2023-11-24 北京百度网讯科技有限公司 Data processing method, device, equipment and storage medium applied to micro-service
CN113590231A (en) * 2021-08-17 2021-11-02 上海微盟企业发展有限公司 Component loading method, system, device and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106610836A (en) * 2016-12-23 2017-05-03 国网信息通信产业集团有限公司 Micro-service operation management tool
CN106612188A (en) * 2015-10-21 2017-05-03 中兴通讯股份有限公司 Method and device for extending software function based on micro service architecture
CN109150978A (en) * 2018-07-24 2019-01-04 北京百度网讯科技有限公司 The method and apparatus for debugging micro services
CN109491653A (en) * 2018-11-21 2019-03-19 泰康保险集团股份有限公司 Component sharing method under micro services framework, device, electronic equipment

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10348838B2 (en) * 2016-07-22 2019-07-09 Cisco Technology, Inc. Scaling service discovery in a micro-service environment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106612188A (en) * 2015-10-21 2017-05-03 中兴通讯股份有限公司 Method and device for extending software function based on micro service architecture
CN106610836A (en) * 2016-12-23 2017-05-03 国网信息通信产业集团有限公司 Micro-service operation management tool
CN109150978A (en) * 2018-07-24 2019-01-04 北京百度网讯科技有限公司 The method and apparatus for debugging micro services
CN109491653A (en) * 2018-11-21 2019-03-19 泰康保险集团股份有限公司 Component sharing method under micro services framework, device, electronic equipment

Also Published As

Publication number Publication date
CN110032392A (en) 2019-07-19

Similar Documents

Publication Publication Date Title
CN110032392B (en) Service management method and device, storage medium and electronic equipment
CN109274731B (en) Method and device for deploying and calling web service based on multi-tenant technology
US8627310B2 (en) Capturing multi-disk virtual machine images automatically
CN109002297B (en) Deployment method, device, equipment and storage medium of consensus mechanism
US7725888B2 (en) Systems and methods for dynamically linking application software into a running operating system kernel
US8347318B2 (en) Application component communication apparatus of SCA-based system and method thereof
US10146942B2 (en) Method to protect BIOS NVRAM from malicious code injection by encrypting NVRAM variables and system therefor
US7984456B2 (en) Interceptor framework using java dynamic proxies
CN112764792B (en) Method and device for upgrading associated server version application and electronic equipment
US9473461B2 (en) Transparent tunneling architecture for a secured database
CN112685020A (en) Method and device for dynamically creating service interface, electronic equipment and storage medium
CN110221840B (en) Function implementation method and device of application program, equipment and storage medium
CN109343970B (en) Application program-based operation method and device, electronic equipment and computer medium
CN110096543B (en) Data operation method, device, server and medium of application program
US11803786B2 (en) Enterprise integration platform
CN110275701B (en) Data processing method, device, medium and computing equipment
US8280950B2 (en) Automatic client-server code generator
US10394610B2 (en) Managing split packages in a module system
CN112287327B (en) Method, device, medium and equipment for easily reconstructing single sign-on system
CN115794372A (en) Method and system for communication between cross-language application systems
CN112394907A (en) Container-based delivery system construction method, application delivery method and delivery system
KR20220051224A (en) Access docking component, system, and method and apparatus applying the access docking component
CN111797337A (en) Method and device for generating export page
Nakandala et al. Anatomy of the SEAGrid science gateway
CN111782990B (en) Interface encapsulation 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
CP01 Change in the name or title of a patent holder
CP01 Change in the name or title of a patent holder

Address after: 310052 Room 301, Building No. 599, Changhe Street Network Business Road, Binjiang District, Hangzhou City, Zhejiang Province

Patentee after: Hangzhou NetEase Shuzhifan Technology Co.,Ltd.

Address before: 310052 Room 301, Building No. 599, Changhe Street Network Business Road, Binjiang District, Hangzhou City, Zhejiang Province

Patentee before: HANGZHOU LANGHE TECHNOLOGY Ltd.