CN114827249A - Method and device for extending grid agent - Google Patents

Method and device for extending grid agent Download PDF

Info

Publication number
CN114827249A
CN114827249A CN202210488502.8A CN202210488502A CN114827249A CN 114827249 A CN114827249 A CN 114827249A CN 202210488502 A CN202210488502 A CN 202210488502A CN 114827249 A CN114827249 A CN 114827249A
Authority
CN
China
Prior art keywords
extension
grid
proxy
agent
generating
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.)
Pending
Application number
CN202210488502.8A
Other languages
Chinese (zh)
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.)
Alibaba China Co Ltd
Original Assignee
Alibaba China 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 Alibaba China Co Ltd filed Critical Alibaba China Co Ltd
Priority to CN202210488502.8A priority Critical patent/CN114827249A/en
Publication of CN114827249A publication Critical patent/CN114827249A/en
Priority to PCT/CN2023/091968 priority patent/WO2023213262A1/en
Pending legal-status Critical Current

Links

Images

Classifications

    • 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/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/34Network arrangements or protocols for supporting network services or applications involving the movement of software or configuration parameters 

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The present disclosure provides a method and a device for extending a grid agent, wherein the method comprises the following steps: the method comprises the steps of obtaining a grid agent extension request initiated by a user, wherein the grid agent extension request comprises grid agent extension parameters and/or extension template data representing grid agent extension function requirements, generating grid agent extension configuration according to the grid agent extension request and a preset grid instance outline, and activating the extension plug-in capability serving a grid agent according to the grid agent extension configuration to realize grid agent extension.

Description

Method and device for extending grid agent
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a method and an apparatus for extending a grid proxy.
Background
The service grid provides a full-hosted service grid platform, is compatible with a community open source service grid, and is used for simplifying the management of services, including flow routing and splitting management between service calls, authentication security of communication between services and grid observability capability, thereby greatly reducing the workload of development and operation and maintenance.
The service grid is a software infrastructure layer for controlling and monitoring internal service-to-service traffic in microservice applications. It typically takes the form of a "data plane layer" deployed with application code as network agents and a "control plane layer" that interacts with these agents.
Disclosure of Invention
The present disclosure provides a method and an apparatus for extending a grid proxy, which are used to improve the accuracy and reliability of the grid proxy extension.
In a first aspect, an embodiment of the present disclosure provides a method for extending a grid proxy, where the method includes:
acquiring a grid agent extension request initiated by a user, wherein the grid agent extension request comprises grid agent extension parameters and/or extension template data representing the requirements of a grid agent extension function;
generating a grid proxy extension configuration according to the grid proxy extension request and a preset grid instance summary;
and configuring and activating the extension plug-in capability of the service grid proxy according to the grid proxy extension.
In an embodiment of the present disclosure, if the grid proxy extension request includes the grid proxy extension parameter, the obtaining the user-initiated grid proxy extension request includes:
generating a grid agent extension description category aiming at the historical grid agent extension requirement according to the historical grid agent extension requirement;
receiving the grid agent extension parameters input by the user based on the grid agent extension description category.
In an embodiment of the present disclosure, the generating a grid proxy extension configuration according to the grid proxy extension request and a preset grid instance summary includes:
analyzing the grid agent extension parameters according to the grid example outline to obtain the current grid agent extension requirement of the user;
and converting the current grid agent extension requirement into a grid agent extension resource object, and converting to obtain the grid agent extension configuration according to the grid agent extension resource object and the preset information of the application service instance bound with the current grid agent extension requirement.
In an embodiment of the present disclosure, if the grid proxy extension request includes the extension template data, generating a grid proxy extension configuration according to the grid proxy extension request and a preset grid instance summary, including:
and extracting target agent extension template contents corresponding to the template data from a preset grid agent extension template set, and generating the grid agent extension configuration according to the target agent extension template contents and the grid instance outline.
In one embodiment of the present disclosure, the generating the grid agent extension configuration according to the target agent extension template content and the grid instance summary comprises:
acquiring the extension configuration in the target agent extension template content;
and generating a proxy extension binding according to the grid instance summary, the extension configuration and preset information of the application service instance bound with the grid proxy extension function, and generating the grid proxy extension configuration according to the proxy extension binding, wherein the proxy extension binding is used for representing that the extension configuration is validated to the service grid proxy.
In an embodiment of the present disclosure, the generating the mesh proxy extension configuration according to the proxy extension binding includes:
and carrying out fusion processing on the proxy extension binding and a preset resource object to obtain a fusion resource object, and generating the grid proxy extension configuration according to the fusion resource object.
In one embodiment of the present disclosure, said configuring an extension plug-in capability that activates a serving grid agent according to said grid agent extension comprises:
and generating agent extension plug-in data according to the grid agent extension configuration, and activating the extension plug-in capability of the service grid agent according to the agent extension plug-in data.
In one embodiment of the present disclosure, the proxy extension plug-in data has a version attribute, and different versions of the proxy extension plug-in data are used to activate extension plug-in capabilities of different services grid agents.
In a second aspect, an embodiment of the present disclosure provides an apparatus for extending a configuration of a mesh proxy, where the apparatus includes:
the system comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring a grid proxy extension request initiated by a user, wherein the grid proxy extension request comprises grid proxy extension parameters and/or extension template data representing the requirements of a grid proxy extension function;
the generating unit is used for generating the grid proxy extension configuration according to the grid proxy extension request and the preset grid instance outline;
and the activation unit is used for activating the expansion plug-in capability of the service grid agent according to the grid agent expansion configuration.
In an embodiment of the present disclosure, if the mesh proxy extension request includes the mesh proxy extension parameter, the obtaining unit includes:
the first generation subunit is used for generating a grid agent extension description category aiming at the historical grid agent extension requirement according to the historical grid agent extension requirement;
a receiving subunit, configured to receive the grid proxy extension parameter input by the user based on the grid proxy extension description category.
In one embodiment of the present disclosure, the generating unit includes:
the analysis subunit is used for analyzing the grid agent extension parameters according to the grid instance summary to obtain the current grid agent extension requirement of the user;
and the conversion subunit is used for converting the current grid proxy extension requirement into a grid proxy extension resource object and converting the grid proxy extension configuration according to the grid proxy extension resource object and the preset information of the application service instance bound with the current grid proxy extension requirement.
In an embodiment of the present disclosure, if the grid proxy extension request includes the extension template data, the generating unit includes:
the extraction subunit is used for extracting the target proxy extension template content corresponding to the template data from a preset grid proxy extension template set;
and the second generation subunit is used for generating the grid proxy extension configuration according to the target proxy extension template content and the grid instance outline.
In one embodiment of the present disclosure, the second generating subunit includes:
the acquisition module is used for acquiring the extension configuration in the target agent extension template content;
and the generating module is used for generating a proxy extension binding according to the grid instance outline, the extension configuration and preset information of the application service instance bound with the grid proxy extension function, and generating the grid proxy extension configuration according to the proxy extension binding, wherein the proxy extension binding is used for representing that the extension configuration is validated to the service grid proxy.
In one embodiment of the present disclosure, the generating module includes:
the fusion submodule is used for fusing the proxy extension binding with a preset resource object to obtain a fusion resource object;
and the generation submodule is used for generating the grid proxy extension configuration according to the fusion resource object.
In one embodiment of the present disclosure, the activation unit includes:
the third generation subunit is used for generating proxy extension plug-in data according to the grid proxy extension configuration;
and the activating subunit is used for activating the expansion plug-in capability of the service grid proxy according to the proxy expansion plug-in data.
In one embodiment of the present disclosure, the agent extension plug-in data has a version attribute, and different versions of the agent extension plug-in data are used to activate extension plug-in capabilities of different service grid agents.
In a third aspect, an embodiment of the present disclosure provides an electronic device, including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the electronic device to perform the method of any one of the first aspect of the disclosure.
In a fourth aspect, embodiments of the present disclosure provide a computer-readable storage medium on which a computer program is stored, the computer program, when executed by a processor, implementing the method of any one of the first aspects of the present disclosure.
In a fifth aspect, the embodiments of the present disclosure provide a computer program product comprising a computer program that, when executed by a processor, implements the method of any one of the first aspects of the present disclosure.
The embodiment of the disclosure provides a method and a device for expanding a grid proxy, wherein the method comprises the following steps: the method comprises the steps of obtaining a grid agent extension request initiated by a user, wherein the grid agent extension request comprises grid agent extension parameters and/or extension template data representing grid agent extension function requirements, generating grid agent extension configuration according to the grid agent extension request and a preset grid instance outline, and activating the extension plug-in capability serving a grid agent according to the grid agent extension configuration to realize grid agent extension.
Drawings
In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present disclosure, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
FIG. 1 is a schematic diagram of a services grid according to one embodiment of the present disclosure;
FIG. 2 is a schematic diagram of a mesh proxy of an embodiment of the present disclosure;
FIG. 3 is a schematic diagram of a method of grid proxy extension of one embodiment of the present disclosure;
FIG. 4 is a schematic diagram of a method of grid proxy extension according to another embodiment of the present disclosure;
FIG. 5 is a schematic diagram of a method of grid proxy extension according to another embodiment of the present disclosure;
FIG. 6 is a schematic diagram of a services grid according to another embodiment of the present disclosure;
FIG. 7 is a schematic diagram of an apparatus for a grid proxy configuration extension of one embodiment of the present disclosure;
FIG. 8 is a schematic diagram of an apparatus for a grid proxy configuration extension in accordance with another embodiment of the present disclosure;
fig. 9 is a schematic diagram of a hardware structure of an electronic device according to an embodiment of the present disclosure.
With the foregoing drawings in mind, certain embodiments of the disclosure have been shown and described in more detail below. These drawings and written description are not intended to limit the scope of the disclosed concepts in any way, but rather to illustrate the concepts of the disclosure to those skilled in the art by reference to specific embodiments.
Detailed Description
To make the objects, technical solutions and advantages of the embodiments of the present disclosure more apparent, the technical solutions in the embodiments of the present disclosure will be described clearly and completely with reference to the drawings in the embodiments of the present disclosure, and it is obvious that the described embodiments are some, but not all embodiments of the present disclosure. All other embodiments, which can be derived by a person skilled in the art from the embodiments disclosed herein without making any creative effort, shall fall within the protection scope of the present disclosure.
The terms "first," "second," "third," and the like in the description and in the claims of the present disclosure and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the disclosure described herein are capable of operation in sequences other than those illustrated or otherwise described herein.
Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Fig. 1 is a schematic diagram of a service grid 100 according to an embodiment of the present disclosure, where the service grid 100 is mainly used to facilitate secure and reliable communication between multiple microservices, which means to decompose an application into multiple smaller services or instances and to run on different clusters/machines.
As shown in FIG. 1, the microservice includes an application service instance A and an application service instance B, which form a functional application layer of the services grid 100. In one embodiment, the application service instances a and B run in the form of containers/processes on the machine/workload container groups 108, 110 (PODs).
In one embodiment, application service instance a may be a commodity inquiry service and application service instance B may be a commodity ordering service.
As shown in FIG. 1, application service instance A and grid agent (sidecar)103 coexist in machine workload container group 114, and application service instance B and grid agent 105 coexist in machine workload container 116. Mesh agents 103 and 105 form a data plane layer (data plane) of service mesh 100. Where grid agents 103 and 105 are running in containers/processes 104, 106, respectively, and where two-way communication is possible between grid agent 103 and application service instance a and two-way communication is possible between grid agent 105 and application service instance B. In addition, two-way communication may also be provided between the grid agent 103 and the grid agent 105.
In one embodiment, all traffic for application service instance A is routed through the grid proxy 103 to the appropriate destination and all network traffic for application service instance B is routed through the grid proxy 105 to the appropriate destination. It should be noted that the network traffic mentioned herein includes, but is not limited to, forms of hypertext Transfer Protocol (HTTP), State transition (REST), Remote Procedure call system (gRPC), Remote Dictionary service (Remote Dictionary Server, Redis), and the like.
In one embodiment, the functionality of extending the data plane layer may be implemented by writing a custom Filter (Filter) for an agent (Envoy) in the services grid 100, which may be configured to allow the services grid to properly proxy service traffic, implement service interworking and service governance. The grid agents 103 and 105 may be configured to perform at least one of the following functions: service discovery (service discovery), health checking (health checking), Routing (Routing), Load Balancing (Load Balancing), authentication and authorization (authentication and authorization), and observability (observability).
As shown in fig. 1, the services grid 100 also includes a control plane layer. Where the control plane layer may be a set of services running in a dedicated namespace, these services are hosted by the hosting control plane component 101 at the machine/workload container set (machine/Pod) 102. As shown in fig. 1, the hosted control plane component 101 is in two-way communication with the mesh agent 103 and the mesh agent 105. The managed control plane component 101 is configured to perform some control management functions. For example, the hosted control plane component 101 receives telemetry data transmitted by the mesh agents 103 and 105, which may be further aggregated. These services, hosting the control plane component 101, may also provide user-oriented Application Programming Interfaces (APIs) to more easily manipulate network behavior, as well as provide configuration data to the grid agents 103 and 105, and the like.
Fig. 2 is a schematic diagram of a mesh proxy according to an embodiment of the present disclosure, taking an Envoy mesh proxy as an example, as shown in fig. 2, a callee Downstream (Downstream) host requests to connect to Envoy, and a Listener (Listener) is used to bind to an IP address/port and receive a connection from a Downstream host. By configuring the listener, the user can enable traffic management capabilities through Envoy and then enhance the data flow using multiple filters, which make up a Filter Chain (Filter Chain). Requests of downstream hosts, after being processed through the filter chain, are mapped to a logically identical set of upstream host clusters (clusters) to which the corresponding Envoy is connected, the role of which is to be responsible for connecting to a set of upstream node services and forwarding these requests using an associated load balancing policy.
It should be understood that the above examples are only for illustrating the principles of the grid agent by way of example and are not to be construed as limiting the grid agent. For example, the downstream host may be an upstream host in other embodiments, the number of filters in the filter chain may be greater or smaller, and so on, which are not listed here.
In some embodiments, in order to implement the extension of the mesh proxy, a manner of adding a filter may be adopted, such as inserting more filters in the filter chain of the above-mentioned embodiments, and the filter may be inserted in an artificial manner to implement the extension of the mesh proxy.
However, the types of filters are many, and the principle of Envoy is complex to implement, and if the extension of the mesh proxy is implemented by human, it is necessary to know Envoy in a relatively professional manner. Therefore, the extension of the grid proxy is realized in this way, and the technical problem of low accuracy may exist.
In order to avoid the above technical problems, the inventors of the present disclosure have made creative efforts to obtain the inventive concept of the present disclosure: and generating a grid agent extension configuration by combining grid agent extension parameters and/or extension template data for representing the requirements of the grid agent extension function so as to realize the extension of the grid agent.
Hereinafter, the technical solution of the present disclosure will be described in detail by specific examples. It should be noted that the following specific embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments.
Fig. 3 is a schematic diagram of a method for extending a grid proxy according to an embodiment of the present disclosure, as shown in fig. 3, the method includes:
s301: and acquiring a grid proxy extension request initiated by a user. The grid agent extension request comprises grid agent extension parameters and/or extension template data representing the requirements of the grid agent extension function.
For example, the execution subject of this embodiment may be a device of the grid proxy extension, where the device may be a server, a computer, a terminal device, a chip, a processor, and the like, and this embodiment is not limited.
The mesh proxy extension parameter refers to a parameter carried in the mesh proxy extension request to implement mesh proxy extension, that is, the extension of the mesh proxy is implemented by configuring the parameter.
The extension template data refers to logic codes carried in the grid proxy extension request for implementing the grid proxy extension, that is, the extension of the grid proxy is implemented by configuring the logic codes.
S302: and generating the grid proxy extension configuration according to the grid proxy extension request and the preset grid instance outline.
The grid implementation summary is used for characterizing information of the grid instance, such as the version of the grid instance.
In conjunction with the above analysis, in one example, a grid agent extension configuration may be generated in conjunction with a grid agent extension parameter and a grid instance summary, in another example, a grid agent extension configuration may be generated in conjunction with extension template data and a grid instance summary, and in yet another example, a grid agent extension configuration may be generated in conjunction with a grid agent extension parameter, extension template data, and a grid instance summary.
S303: and configuring the extension plug-in capability of the active service grid agent according to the grid agent extension so as to realize the grid agent extension.
The serving grid agents may be, among other things, grid agents 103 and 105 as in the embodiments described above.
Based on the above analysis, an embodiment of the present disclosure provides a method for extending a grid proxy, where the method includes: the method comprises the steps of obtaining a grid agent extension request initiated by a user, wherein the grid agent extension request comprises grid agent extension parameters and/or extension template data representing grid agent extension function requirements, generating grid agent extension configuration according to the grid agent extension request and a preset grid instance outline, and activating the extension plug-in capability serving a grid agent according to the grid agent extension configuration to realize grid agent extension.
For the reader to more deeply understand the implementation principles of the present disclosure, the method of grid proxy extension of the present disclosure is now set forth in detail in connection with FIG. 4 from the dimensions according to grid proxy extension parameters and a grid instance summary.
As shown in fig. 4, the method includes:
s401: and generating a grid agent extension description category aiming at the historical grid agent extension requirement according to the historical grid agent extension requirement.
It should be understood that, in order to avoid tedious statements, the technical features of the present embodiment that are the same as those of the above embodiments are not described again in this embodiment.
The description category of the grid proxy extension refers to a parameter configuration item for implementing the grid proxy extension, such as a local rate limiter (LocalRateLimiter), an ingress gateway (ingress gateway), and a workload tag selector (workload selector), which are not listed here.
S402: receiving grid proxy extension parameters input by a user based on the grid proxy extension description category.
For example, the device of the grid proxy extension can provide cloud native declarative API for the user, so that the user can input grid proxy extension parameters through the API.
For example, the device of the grid proxy extension may provide an API for the client to output the grid proxy extension description category, the user may fill in the grid proxy extension parameters, and accordingly, the device of the grid proxy extension receives the grid proxy extension parameters.
In this embodiment, by obtaining the mesh proxy extension parameters based on the mesh proxy extension description category, a dynamic extension mechanism can be implemented in a flexible extension manner to meet the mesh proxy extensions of different mesh proxy extension requirements.
S403: and analyzing the grid agent expansion parameters according to the preset grid example outline to obtain the current grid agent expansion requirement of the user.
S404: converting the current grid proxy extension requirements into a grid proxy extension resource object. The grid agent extension resource object is used for representing information such as insertion positions and quantity of the filter.
Illustratively, according to the analysis of the grid agent extension parameters by the grid instance summary, the grid agent extension requirements corresponding to the grid agent extension parameters (i.e. the current grid agent extension requirements) can be known, and after the current grid agent extension requirements are known, the current grid agent extension requirements can be converted to obtain the extension information of the filter corresponding to the current grid agent extension requirements, such as the insertion positions and/or the number of the filters.
S405: and converting to obtain the grid proxy extension configuration according to the grid proxy extension resource object and the preset information of the application service instance bound with the current grid proxy extension requirement.
The application service instances corresponding to different grid proxy extension requirements may be different, that is, different application service instances may support different grid proxy extensions based on the application services they provide. Therefore, in this embodiment, the grid proxy extension configuration can be converted by combining the information of the application service instance bound to the current grid proxy extension requirement.
In combination with the above analysis, in this embodiment, the grid proxy extension configuration is obtained by combining the grid proxy extension resource object, so that the disadvantages of low accuracy and the like caused by determining the grid proxy extension configuration based on an artificial manner in the related art can be avoided, and the accuracy and reliability of the grid proxy extension configuration are improved.
S406: and generating agent extension plug-in data according to the grid agent extension configuration, and activating the extension plug-in capability of the service grid agent according to the agent extension plug-in data so as to realize grid agent extension.
In some embodiments, the agent extension plug-in data has a version attribute, and different versions of the agent extension plug-in data are used to activate extension plug-in capabilities of different service grid agents.
For the reader to more deeply understand the implementation principles of the present disclosure, the method of grid proxy extension of the present disclosure is now set forth in detail in connection with FIG. 5 from the dimensions of the extension template data and the grid instance schema.
As shown in fig. 5, the method includes:
s501: and generating a grid agent expansion template set aiming at the historical grid agent expansion requirements according to the historical grid agent expansion requirements. Wherein, the grid agent expansion template set comprises agent expansion templates.
In order to avoid the tedious statement, the technical features of the present embodiment that are the same as those of the above embodiments are not described again.
In this embodiment, an agent extension template corresponding to each historical grid agent extension requirement may be generated according to different historical grid agent extension requirements.
That is, for a mesh proxy extension that implements the same data plane extension function, different proxy extension templates may be prepared in advance for different versions of the mesh proxy extension. When the agent extension is applied, which agent extension template is applied is dynamically determined according to the extension function requirement of the service grid agent to be applied and extended and the like.
S502: and receiving the expansion template data which is input by the user and characterizes the expansion function requirement of the grid agent.
Similarly, a user may enter extension template data through the system in the manner of a cloud-native declarative API.
S503: and extracting target agent extension template contents corresponding to the template data from the grid agent extension template set, and generating grid agent extension configuration according to the target agent extension template contents and the grid example outline.
Illustratively, different agent extension templates are included in the grid agent extension template set for realizing requirements of different grid agent extensions, and when extension template data which characterizes requirements of grid agent extension functions and is input by a user is received, an agent extension template (namely a target agent extension template) corresponding to the requirements of the grid agent extension functions can be extracted from the agent extension templates so as to generate grid agent extension configuration based on the content of the agent extension template (namely the content of the target agent extension template).
In combination with the above analysis, in this embodiment, the target agent extension template content corresponding to the extension template data can be dynamically extracted according to the extension template data, so that when the grid agent extension configuration is generated in combination with the target agent extension template content and the grid instance summary, the technical effects of flexibility, diversity and reliability of the generated grid agent extension configuration are improved.
In some embodiments, S503 may include the steps of:
the first step is as follows: and acquiring the extension configuration in the extension template content of the target agent.
Different agent extension template contents comprise different extension configurations, and the different extension configurations are used for realizing different grid agent extension requirements.
The second step: and generating a proxy extension binding according to the summary of the grid example, the extension configuration and the preset information of the application service example bound with the grid proxy extension function. Wherein the proxy extension binding is used to characterize validation of the extension configuration to the service grid proxy.
The third step: and generating the grid proxy extension configuration according to the proxy extension binding.
In the embodiment, the grid agent extension configuration is generated by combining the extension configuration, so that different grid agent extension configurations are generated based on different grid agent extension function requirements, and the different extension configurations are validated to different service grid agents, thereby improving the accuracy and reliability of generating the grid agent extension configuration.
In some embodiments, the third step may comprise the sub-steps of:
the first substep: and fusing the proxy extension binding with a preset resource object to obtain a fused resource object.
The resource object may include a workload tag selector, a preset grid agent extension configuration item, and the like, which are not listed here.
The second sub-step: and generating the grid proxy extension configuration according to the fusion resource object.
S504: and generating agent extension plug-in data according to the grid agent extension configuration, and activating the extension plug-in capability of the service grid agent according to the agent extension plug-in data so as to realize grid agent extension.
Similarly, the agent extension plug-in data has a version attribute, and different versions of the agent extension plug-in data are used to activate the extension plug-in capabilities of different service grid agents.
While the above embodiments have described the principle of the extension of the grid agent in detail from the dimension combining the grid instance schema and the grid agent extension parameter (for the sake of distinction, referred to as the first dimension), and from the dimension combining the grid instance schema and the extension template data (for the sake of distinction, referred to as the second dimension), respectively, the extension of the grid agent may be implemented in combination with the first dimension and the second dimension when the extension of the grid agent is implemented in combination with the grid agent extension parameter, the extension template data, and the grid instance schema. Illustratively, the grid proxy extensions may be implemented according to a first dimension grid proxy extension configuration and a second dimension grid proxy extension configuration. If the intersection is selected, the union may also be selected, and details are not described here.
And as can be known from the above analysis, the implementation of the mesh proxy extension from the first dimension is relatively more "rigid" to target a specific functional intent, i.e., the mesh proxy extension description category is more targeted and fixed, such as the mesh proxy extension parameters input for the local rate limiter, the mesh proxy extension parameters input for the ingress gateway, and so on. The grid agent expansion is relatively more dynamic from the second dimension, so that the dynamic mechanism is oriented, namely the expansion template data has more flexibility and diversity, and for example, a user can input different expansion template data based on different grid agent expansion requirements.
Now, with reference to the principle of the extension of the grid proxy of the above embodiment and fig. 1, the service grid of this embodiment is described in detail as follows:
fig. 6 is a schematic diagram of a service grid according to another embodiment of the present disclosure, where the service grid of this embodiment is mainly used to explain the principle of the grid proxy extension of the foregoing embodiment, and as shown in fig. 6, a service grid 600 includes a control plane layer, a data plane layer, and a function application layer.
Wherein the control plane layer comprises: grid proxy extension description category 611, grid instance schema 612, proxy extension controller 613, transformation engine 614, grid proxy extension template set 615, proxy extension template service engine 616, fusion engine 617, and proxy extension configuration generator 618.
The data plane layer includes: agent plug-in updater 621, service grid agent 622, and service grid agent 623. Wherein, the service grid agent may be referred to as the grid agent in the embodiment corresponding to fig. 1.
The function application layer comprises: an application service instance 631 and an application service instance 632.
In conjunction with the above analysis, in some embodiments, the control plane layer may receive user-entered mesh proxy extension parameters based on mesh proxy extension description category 611. Agent extension controller 613 may analyze the grid agent extension parameters according to grid instance summary 612 to obtain the user's grid agent extension requirements (i.e., the current grid agent extension requirements as described in the corresponding embodiment of FIG. 4), such as the type and number of filters used to implement the grid agent extension, and the filter insertion locations. Conversion engine 614 converts the grid proxy extension requirements to obtain a grid proxy extension resource object. Proxy extension configuration generator 618 generates a mesh proxy extension configuration from the mesh proxy extension resource object and transmits the mesh proxy extension configuration to proxy plugin updater 621 of the data plane layer.
Proxy plugin updater 621 generates proxy extension plugin data according to the grid proxy extension configuration, and activates the extension plugin capabilities of each of service grid agent 622 and service grid agent 623 according to the proxy extension plugin data.
The application service instance 631 and the application service instance 632 of the functional application layer make use of the extended plug-in capabilities. If the application service instance 631 uses the extended plug-in capabilities of the services grid agent 622, the application service instance 632 uses the extended plug-in capabilities of the services grid agent 623.
In other embodiments, the control plane layer may obtain extension template data characterizing the requirements of the mesh proxy extension functionality based on the API. The proxy extension template service engine 616 generates a proxy extension binding based on the extension template data, the grid instance summary 612, and the set of grid proxy extension templates 615.
For example, taking the Envoy proxy extension template as an example, the Envoy proxy extension binding applies the Envoy proxy parameters defined in the Envoy proxy extension template to a specific workload (i.e. an application service instance, such as the machine/workload container set described in the corresponding embodiment of fig. 1).
The Envoy proxy extension binding can include two parts of contents, one part is a specific Envoy proxy extension template item part for specifying the Envoy proxy extension binding, the part can specify the name of the bound Envoy proxy template through a name (name) field, and can also match a template item corresponding to a specific Envoy proxy Version in the Envoy proxy extension template through a Version (Version) field. The Envoy agent extension template comprises templates of different versions, and the templates of different versions are distinguished through version fields. That is, the proxy extension template item includes two parts of content, one part is the proxy version, and the other part is the specific template configuration of the version of the proxy extension template, i.e. the grid proxy configuration of the version of the proxy extension template.
The Envoy agent extension binds another part to workloads (workloads), wherein a tool load may comprise a series of workload tag selectors, wherein a selector (selector) field may be used to indicate the specific content of a workload tag selector, a namespace (namespace) field may be used to characterize the namespace in which the workload tag selector is effective, and a name field may be used to distinguish the Envoy agent (i.e., grid agent) selected by the workload tag selector.
The fusion engine 617 performs fusion processing on the proxy extension binding and a preset resource object (such as workload resource information) to obtain a fusion resource object. Proxy extension configuration generator 618 generates a mesh proxy extension configuration from the converged resource object and transmits the mesh proxy extension configuration to proxy plugin updater 621 of the data plane layer.
Similarly, proxy plugin updater 621 generates proxy extension plugin data according to the grid proxy extension configuration, and activates the extension plugin capabilities of service grid agent 622 and service grid agent 623, respectively, according to the proxy extension plugin data.
The application service instance 631 and the application service instance 632 of the functional application layer make use of the extended plug-in capabilities. If the application service instance 631 uses the extended plug-in capabilities of the services grid agent 622, the application service instance 632 uses the extended plug-in capabilities of the services grid agent 623.
Illustratively, the proxy extension binding binds the proxy extension template to the proxy of the ingress gateway service via a binding entry in the workload tag selector, and the generated grid proxy extension configuration includes the workload tag selector specified in the binding entry. The name and the name space of the grid agent extension configuration are determined by the name field and the name space field bound by the agent extension template. By the above example, the proxy of the ingress gateway service will be able to implement the mesh proxy extension function of adding request headers (X-Frame-Options).
Fig. 7 is a schematic diagram of an apparatus for extending a configuration of a mesh proxy according to an embodiment of the present disclosure, and as shown in fig. 7, the apparatus 700 for extending a configuration of a mesh proxy includes:
an obtaining unit 701, configured to obtain a grid proxy extension request initiated by a user, where the grid proxy extension request includes a grid proxy extension parameter and/or extension template data representing a requirement of a grid proxy extension function.
A generating unit 702, configured to generate a mesh proxy extension configuration according to the mesh proxy extension request and a preset mesh instance summary.
An activating unit 703, configured to activate the extension plug-in capability of serving the grid agent according to the grid agent extension configuration.
Fig. 8 is a schematic diagram of an apparatus for a grid proxy configuration extension according to another embodiment of the present disclosure, and as shown in fig. 8, the apparatus 800 for a grid proxy configuration extension includes:
an obtaining unit 801, configured to obtain a grid proxy extension request initiated by a user, where the grid proxy extension request includes a grid proxy extension parameter and/or extension template data representing a requirement of a grid proxy extension function.
In some embodiments, if the mesh proxy extension request includes the mesh proxy extension parameters, referring to fig. 8, the obtaining unit 801 includes:
a first generating subunit 8011 is configured to generate a mesh proxy extension description category for a historical mesh proxy extension requirement according to the historical mesh proxy extension requirement.
A receiving sub-unit 8012, configured to receive the grid proxy extension parameters input by the user based on the grid proxy extension description category.
A generating unit 802, configured to generate a mesh proxy extension configuration according to the mesh proxy extension request and a preset mesh instance summary.
As shown in connection with fig. 8, in some embodiments, the generating unit 802 includes:
and an analyzing subunit 8021, configured to analyze the grid agent expansion parameter according to the grid instance summary, so as to obtain the current grid agent expansion requirement of the user.
A conversion subunit 8022, configured to convert the current grid proxy extension requirement into a grid proxy extension resource object, and obtain the grid proxy extension configuration by conversion according to the grid proxy extension resource object and preset information of the application service instance bound to the current grid proxy extension requirement.
In some embodiments, if the mesh proxy extension request includes the extension template data, as shown in fig. 8, the generating unit 802 includes:
the extracting subunit 8023 is configured to extract, from a preset mesh proxy extension template set, a target proxy extension template content corresponding to the template data.
A second generating subunit 8024, configured to generate the grid agent extension configuration according to the target agent extension template content and the grid instance summary.
In some embodiments, the second generating subunit 8024, includes:
the acquisition module is used for acquiring the extension configuration in the target agent extension template content;
and the generating module is used for generating a proxy extension binding according to the grid instance outline, the extension configuration and preset information of the application service instance bound with the grid proxy extension function, and generating the grid proxy extension configuration according to the proxy extension binding, wherein the proxy extension binding is used for representing that the extension configuration is validated to the service grid proxy.
In some embodiments, the generating module comprises:
and the fusion submodule is used for fusing the proxy extension binding with a preset resource object to obtain a fusion resource object.
And the generation submodule is used for generating the grid proxy extension configuration according to the fusion resource object.
An activation unit 803, configured to activate an extension plug-in capability of the serving grid agent according to the grid agent extension configuration.
As shown in connection with fig. 8, in some embodiments, the activation unit 803 includes:
a third generating subunit 8031, configured to generate proxy extension plug-in data according to the mesh proxy extension configuration.
An activating subunit 8032, configured to activate, according to the agent extension plug-in data, an extension plug-in capability of the service grid agent.
In some embodiments, the agent extension plug-in data has a version attribute, and different versions of the agent extension plug-in data are used to activate extension plug-in capabilities of different service grid agents.
Fig. 9 is a schematic diagram of a hardware structure of an electronic device according to an embodiment of the present disclosure. As shown in fig. 9, an electronic device 900 of an embodiment of the present disclosure may include: at least one processor 901 (only one processor is shown in FIG. 9); and a memory 902 communicatively coupled to the at least one processor. The memory 902 stores instructions executable by the at least one processor 901, and the instructions are executed by the at least one processor 901, so that the electronic device 900 can execute the technical solution in any of the foregoing method embodiments.
Alternatively, the memory 902 may be separate or integrated with the processor 901.
When the memory 902 is a separate device from the processor 901, the electronic device 900 further comprises: a bus 903 for connecting the memory 902 and the processor 901.
The electronic device provided by the embodiment of the present disclosure may execute the technical solution of any one of the foregoing method embodiments, and the implementation principle and the technical effect are similar, which are not described herein again.
The embodiment of the present disclosure further provides a computer-readable storage medium, in which a computer program is stored, and when the computer program is executed by a processor, the computer program is used to implement the technical solution in any of the foregoing method embodiments.
The embodiment of the present disclosure provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, the computer program implements the technical solution in any of the foregoing method embodiments.
The embodiment of the present disclosure further provides a chip, including: a processing module and a communication interface, wherein the processing module can execute the technical scheme in the method embodiment.
Further, the chip further includes a storage module (e.g., a memory), where the storage module is configured to store instructions, and the processing module is configured to execute the instructions stored in the storage module, and the execution of the instructions stored in the storage module causes the processing module to execute the technical solution in the foregoing method embodiment.
It should be understood that the Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of a method disclosed in connection with the present invention may be embodied directly in a hardware processor, or in a combination of the hardware and software modules within the processor.
The memory may comprise a high-speed RAM memory, and may further comprise a non-volatile storage NVM, such as at least one disk memory, and may also be a usb disk, a removable hard disk, a read-only memory, a magnetic or optical disk, etc.
The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended ISA (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, the buses in the figures of the present disclosure are not limited to only one bus or one type of bus.
The storage medium may be implemented by any type or combination of volatile or non-volatile memory devices, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
An exemplary storage medium is coupled to the processor such the processor can read information from, and write information to, the storage medium. Of course, the storage medium may also be integral to the processor. The processor and the storage medium may reside in an Application Specific Integrated Circuits (ASIC). Of course, the processor and the storage medium may reside as discrete components in an electronic device.
Finally, it should be noted that: the above embodiments are only used for illustrating the technical solutions of the present disclosure, and not for limiting the same; while the present disclosure has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art will understand that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present disclosure.

Claims (12)

1. A method for grid proxy extension, the method comprising:
acquiring a grid agent extension request initiated by a user, wherein the grid agent extension request comprises grid agent extension parameters and/or extension template data representing the requirements of a grid agent extension function;
generating a grid proxy extension configuration according to the grid proxy extension request and a preset grid instance summary;
and configuring and activating the extension plug-in capability of the service grid proxy according to the grid proxy extension.
2. The method of claim 1, wherein if said grid proxy extension request includes said grid proxy extension parameters, said obtaining a user-initiated grid proxy extension request comprises:
generating a grid agent extension description category aiming at the historical grid agent extension requirement according to the historical grid agent extension requirement;
receiving the grid agent extension parameters input by the user based on the grid agent extension description category.
3. The method of claim 2, wherein said generating a grid proxy extension configuration based on said grid proxy extension request and a preset grid instance profile comprises:
analyzing the grid agent extension parameters according to the grid example outline to obtain the current grid agent extension requirement of the user;
and converting the current grid agent extension requirement into a grid agent extension resource object, and converting to obtain the grid agent extension configuration according to the grid agent extension resource object and the preset information of the application service instance bound with the current grid agent extension requirement.
4. The method according to any one of claims 1-3, wherein if the grid agent extension request includes the extension template data, generating a grid agent extension configuration according to the grid agent extension request and a preset grid instance summary, including:
and extracting target agent extension template contents corresponding to the template data from a preset grid agent extension template set, and generating the grid agent extension configuration according to the target agent extension template contents and the grid instance outline.
5. The method of claim 4, wherein said generating said grid agent extension configuration based on said target agent extension template content and said grid instance summary comprises:
acquiring the extension configuration in the target agent extension template content;
and generating a proxy extension binding according to the grid instance summary, the extension configuration and preset information of the application service instance bound with the grid proxy extension function, and generating the grid proxy extension configuration according to the proxy extension binding, wherein the proxy extension binding is used for representing that the extension configuration is validated to the service grid proxy.
6. The method of claim 5, wherein said generating the mesh proxy extension configuration according to the proxy extension binding comprises:
and carrying out fusion processing on the proxy extension binding and a preset resource object to obtain a fusion resource object, and generating the grid proxy extension configuration according to the fusion resource object.
7. The method of any of claims 1-6, wherein configuring an extension plug-in capability that activates a serving grid agent according to the grid agent extension comprises:
and generating agent extension plug-in data according to the grid agent extension configuration, and activating the extension plug-in capability of the service grid agent according to the agent extension plug-in data.
8. The method of claim 7, wherein the agent extension plug-in data has a version attribute, and wherein different versions of the agent extension plug-in data are used to activate extension plug-in capabilities of different service grid agents.
9. An apparatus for a mesh proxy configuration extension, the apparatus comprising:
the system comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring a grid proxy extension request initiated by a user, wherein the grid proxy extension request comprises grid proxy extension parameters and/or extension template data representing the requirements of a grid proxy extension function;
the generating unit is used for generating the grid proxy extension configuration according to the grid proxy extension request and the preset grid instance outline;
and the activation unit is used for activating the expansion plug-in capability of the service grid agent according to the grid agent expansion configuration.
10. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein, the first and the second end of the pipe are connected with each other,
the memory stores instructions executable by the at least one processor to enable the electronic device to perform the method of any of claims 1-8.
11. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the method of any one of claims 1 to 8.
12. A computer program product comprising a computer program which, when executed by a processor, implements the method of any one of claims 1 to 8.
CN202210488502.8A 2022-05-06 2022-05-06 Method and device for extending grid agent Pending CN114827249A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202210488502.8A CN114827249A (en) 2022-05-06 2022-05-06 Method and device for extending grid agent
PCT/CN2023/091968 WO2023213262A1 (en) 2022-05-06 2023-05-04 Mesh sidecar expansion method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210488502.8A CN114827249A (en) 2022-05-06 2022-05-06 Method and device for extending grid agent

Publications (1)

Publication Number Publication Date
CN114827249A true CN114827249A (en) 2022-07-29

Family

ID=82511004

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210488502.8A Pending CN114827249A (en) 2022-05-06 2022-05-06 Method and device for extending grid agent

Country Status (2)

Country Link
CN (1) CN114827249A (en)
WO (1) WO2023213262A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023213262A1 (en) * 2022-05-06 2023-11-09 阿里巴巴(中国)有限公司 Mesh sidecar expansion method and device

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090288104A1 (en) * 2008-05-19 2009-11-19 Rohati Systems, Inc. Extensibility framework of a network element
US20120079383A1 (en) * 2010-09-29 2012-03-29 Reghu Ram Thanumalayan Server independent deployment of plug-ins
WO2020206376A1 (en) * 2019-04-03 2020-10-08 Cisco Technology, Inc. Extending enterprise trusted policy framework to cloud native applications
CN113938520A (en) * 2021-08-31 2022-01-14 阿里巴巴(中国)有限公司 Service registration method, device and storage medium
CN113938527A (en) * 2021-08-31 2022-01-14 阿里巴巴(中国)有限公司 Extension processing method of API gateway, computing equipment and storage medium
CN113949702A (en) * 2021-08-30 2022-01-18 浪潮软件科技有限公司 Multi-layer network protocol processing method and device for service grid
CN114205230A (en) * 2021-12-13 2022-03-18 中国电信股份有限公司 Method, system, medium and electronic device for configuring cloud native network element

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112333229A (en) * 2020-09-16 2021-02-05 山东中创软件商用中间件股份有限公司 Method, device, equipment and storage medium for expanding kubernets nodes
US20210014303A1 (en) * 2020-09-25 2021-01-14 Intel Corporation Methods and apparatus to manage quality of service with respect to service level agreements in a computing device
CN114827249A (en) * 2022-05-06 2022-07-29 阿里巴巴(中国)有限公司 Method and device for extending grid agent

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090288104A1 (en) * 2008-05-19 2009-11-19 Rohati Systems, Inc. Extensibility framework of a network element
US20120079383A1 (en) * 2010-09-29 2012-03-29 Reghu Ram Thanumalayan Server independent deployment of plug-ins
WO2020206376A1 (en) * 2019-04-03 2020-10-08 Cisco Technology, Inc. Extending enterprise trusted policy framework to cloud native applications
CN113949702A (en) * 2021-08-30 2022-01-18 浪潮软件科技有限公司 Multi-layer network protocol processing method and device for service grid
CN113938520A (en) * 2021-08-31 2022-01-14 阿里巴巴(中国)有限公司 Service registration method, device and storage medium
CN113938527A (en) * 2021-08-31 2022-01-14 阿里巴巴(中国)有限公司 Extension processing method of API gateway, computing equipment and storage medium
CN114205230A (en) * 2021-12-13 2022-03-18 中国电信股份有限公司 Method, system, medium and electronic device for configuring cloud native network element

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023213262A1 (en) * 2022-05-06 2023-11-09 阿里巴巴(中国)有限公司 Mesh sidecar expansion method and device

Also Published As

Publication number Publication date
WO2023213262A1 (en) 2023-11-09

Similar Documents

Publication Publication Date Title
JP6912469B2 (en) Access request conversion method and device
US7620934B2 (en) System and method for a Web service definition
US8856735B2 (en) System and method of generating REST2REST services from WADL
US10956242B1 (en) Automating the migration of web service implementations to a service provider system
US9946520B1 (en) Conversion of interpretive language functions into web applications or services
JP2019512138A (en) Service implementation method, apparatus and system based on FIX protocol
CN110187986B (en) Command management method, system, device and computer readable storage medium
US8146111B2 (en) Calling services from a remote client
CN113806037A (en) Service calling method and device, storage medium and electronic equipment
CN111988418B (en) Data processing method, device, equipment and computer readable storage medium
CN111858727A (en) Multi-data-source data export system and method based on template configuration
WO2023213262A1 (en) Mesh sidecar expansion method and device
CN117194064A (en) Remote calling method and device
CN110022332B (en) Hypertext transfer security protocol proxy method, device, equipment and medium
CN109816462A (en) A kind of recognition methods of invoice information and device
US8499023B1 (en) Servlet-based grid computing environment using grid engines and switches to manage resources
CN112272202B (en) Method and system for communication between management software server and system internal components
CN109189753B (en) Method and device for adding user information in HUE
Spillner et al. RAFT-REST-A client-side framework for reliable, adaptive and fault-tolerant restful service consumption
CN113505036B (en) Application monitoring method, client and server
CN113901377B (en) Service calling method, device, storage medium and equipment of legacy system
CN105897938A (en) Resource requiring method and device
CN115713336A (en) Service processing method and device, electronic equipment and storage medium
CN115633074A (en) Micro service gateway for generating API (application program interface), generation method and related device
CN115865795A (en) Traffic routing method, device, storage medium, processor and server based on service grid

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