CN109151016B - Flow forwarding method and device, service system, computing device and storage medium - Google Patents

Flow forwarding method and device, service system, computing device and storage medium Download PDF

Info

Publication number
CN109151016B
CN109151016B CN201810928478.9A CN201810928478A CN109151016B CN 109151016 B CN109151016 B CN 109151016B CN 201810928478 A CN201810928478 A CN 201810928478A CN 109151016 B CN109151016 B CN 109151016B
Authority
CN
China
Prior art keywords
experimental
experiment
traffic
application
specified
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
CN201810928478.9A
Other languages
Chinese (zh)
Other versions
CN109151016A (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.)
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 CN201810928478.9A priority Critical patent/CN109151016B/en
Publication of CN109151016A publication Critical patent/CN109151016A/en
Application granted granted Critical
Publication of CN109151016B publication Critical patent/CN109151016B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • 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/50Network service management, e.g. ensuring proper service fulfilment according to agreements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a flow forwarding method and device for an experimental example, a service system, computing equipment and a storage medium. The method comprises the following steps: acquiring attribution information of an online experiment example from a name service, wherein the attribution information comprises experiment applications to which the experiment example belongs and clusters to which the experiment applications belong; in response to a traffic request of a specified experimental application, in the presence of available experimental examples attributed to the specified experimental application, selecting an experimental example from the available experimental examples attributed to the specified experimental application, and forwarding the traffic request to the selected experimental example; in the absence of available experimental instances attributed to the specified experimental application, an experimental instance is selected among the experimental instances attributed to the cluster to which the specified experimental application belongs, and the traffic request is forwarded to the selected experimental instance. Therefore, the experimental examples are managed and the flow requests are forwarded according to the preset experimental rules, so that the service stability is ensured to the maximum extent.

Description

Flow forwarding method and device, service system, computing device and storage medium
Technical Field
The invention relates to the technical field of internet, in particular to a flow forwarding method and device, a service system, computing equipment and a storage medium for an experimental example.
Background
In the age of rapid development of the internet nowadays, massive information is generated every day, and the way for people to acquire information from the internet mainly depends on two ways of searching and recommending. The service effect is an important index for searching and recommending whether products are successful or not, namely whether the content which is most interesting to the user can be quickly found out from massive information or not is pushed to the user. The improvement of the service effect cannot be separated from iteration once and again, a small amount of actual flow needs to be introduced for effect verification in each iteration, and the effect verification can be completed on line if the effect verification passes.
However, the high-frequency effect test inevitably brings problems to the operation and maintenance of the system and the stability of the service: on one hand, in order to ensure the consistency of the flow, adding and deleting an experimental version needs an upstream calling party to adjust the flow distribution mode. Therefore, the effect verification at each time needs upstream cooperation, the operation and maintenance cost is improved, and the working efficiency is reduced.
On the other hand, the experimental version is to be verified, the probability that the effect and the stability of the experimental version have problems is high, once the experimental version has problems and cannot provide services normally, the traffic forwarded to the experimental version is discarded, and the service stability of the whole system is greatly influenced.
Accordingly, there remains a need for an improved traffic forwarding scheme.
Disclosure of Invention
The invention provides a traffic forwarding method and device for an experimental example, which are used for forwarding a traffic request to the experimental example according to a preset experimental rule so as to ensure the service stability to the maximum extent.
According to an aspect of the present invention, there is provided a traffic forwarding method for an experimental example, including: acquiring attribution information of an online experiment example from a name service, wherein the attribution information comprises experiment applications to which the experiment example belongs and clusters to which the experiment applications belong; in response to a traffic request of a specified experimental application, in the presence of available experimental examples attributed to the specified experimental application, selecting an experimental example from the available experimental examples attributed to the specified experimental application, and forwarding the traffic request to the selected experimental example; in the absence of available experimental instances attributed to the specified experimental application, an experimental instance is selected among the experimental instances attributed to the cluster to which the specified experimental application belongs, and the traffic request is forwarded to the selected experimental instance.
Therefore, under the condition that no available experiment example belonging to the specified experiment application exists, the forwarding request of the experiment application can be converted into the forwarding request of the cluster, and the stability of the service is ensured through the compatibility of the high-level resources with the low-level resources.
Optionally, the method may further include: and responding to the traffic request of the specified cluster, selecting an experiment example from the experiment examples belonging to the specified cluster, and forwarding the traffic request to the selected experiment example.
Therefore, the flow requests are combed into a plurality of groups and are accessed according to the clusters or the experimental applications, and the operation and maintenance operation and upstream and downstream communication costs are reduced. The three-level resource management mode in the request forwarding process can effectively ensure that the flow is not lost, when the experiment application level cannot decide a proper experiment example due to the offline of the experiment or the service fault, the cluster level to which the experiment application belongs is automatically decided, and the automatic distribution of the flow when the experiment is online or offline can be realized.
Optionally, the method may further include: and constructing a tree structure based on the attribution information, wherein in the tree structure, the experiment examples are subnodes of the experiment application to which the tree structure belongs, and the experiment applications are subnodes of the cluster to which the tree structure belongs, and the experiment examples are selected based on the tree structure.
Therefore, the downstream service resources are collected through the service discovery mechanism and are organized and managed in a tree form.
Optionally, the method may further include: and reporting the attribution information of the online experiment example to the name service while registering the online experiment example to the name service.
Alternatively, attribution information for online experimental instances may be obtained periodically from a name service.
Optionally, one experimental example belongs to only one experimental application, and one experimental application belongs to only one cluster; and one cluster can host one or more experimental applications, and one experimental application can host one or more experimental instances.
Optionally, the traffic request is a traffic request for an experiment from an upstream traffic issuing module.
According to another aspect of the present invention, there is also provided a traffic forwarding apparatus for an experimental example, including: the information acquisition device is used for acquiring attribution information of the online experiment example from the name service, and the attribution information comprises the experiment application to which the experiment example belongs and a cluster to which the experiment application belongs; the first forwarding device is used for responding to the flow request of the specified experiment application, selecting an experiment example from the available experiment examples belonging to the specified experiment application under the condition that the available experiment examples belonging to the specified experiment application exist, and forwarding the flow request to the selected experiment example; and the second forwarding device is used for selecting the experimental example from the experimental examples belonging to the cluster to which the specified experimental application belongs and forwarding the traffic request to the selected experimental example under the condition that no available experimental example belonging to the specified experimental application exists.
Optionally, the traffic forwarding apparatus may further include: and the third forwarding device is used for responding to the traffic request of the specified cluster, selecting an experimental example from the experimental examples belonging to the specified cluster, and forwarding the traffic request to the selected experimental example.
Optionally, the traffic forwarding apparatus may further include: and the tree structure construction device is used for constructing a tree structure based on the attribution information, wherein in the tree structure, the experiment example is a child node of the experiment application to which the tree structure belongs, and the experiment application is a child node of the cluster to which the tree structure belongs, and the experiment example is selected based on the tree structure.
Alternatively, the attribution information may be reported to the name service by the online experiment instance while registered with the name service.
According to another aspect of the present invention, there is also provided an experimental traffic service system, including: the experimental example registers to the name service and reports the attribution information of the experimental example to the name service, wherein the attribution information comprises the experimental application to which the experimental example belongs and the cluster to which the experimental application belongs; the experimental traffic forwarding module is used for acquiring attribution information of online experimental examples from a name service, receiving traffic requests for experiments from upstream and forwarding the traffic requests to the experimental examples, wherein in response to the traffic requests of the specified experimental applications, under the condition that the available experimental examples belonging to the specified experimental applications exist, the experimental traffic forwarding module selects the experimental examples from the available experimental examples belonging to the specified experimental applications and forwards the traffic requests to the selected experimental examples; in the absence of available experimental instances attributed to the specified experimental application, the experimental traffic forwarding module selects an experimental instance among the experimental instances attributed to the cluster to which the specified experimental application belongs and forwards the traffic request to the selected experimental instance.
Optionally, in response to the traffic request of the designated cluster, the experimental traffic forwarding module selects an experimental instance from the experimental instances belonging to the designated cluster, and forwards the traffic request to the selected experimental instance.
According to another aspect of the present invention, there is also provided a computing device comprising: a processor; and a memory having executable code stored thereon, which when executed by the processor, causes the processor to perform the method as described above.
According to another aspect of the present invention, there is also provided a non-transitory machine-readable storage medium having stored thereon executable code, which when executed by a processor of an electronic device, causes the processor to perform the method as described above.
Therefore, by introducing the experiment flow forwarding module and constructing the tree structure, the upstream flow request is uniformly received, the experiment examples are downwards managed according to the experiment rules and the flow request is forwarded, and the service stability can be ensured to the maximum extent when the experiment examples are in failure.
Drawings
The above and other objects, features and advantages of the present disclosure will become more apparent by describing in greater detail exemplary embodiments thereof with reference to the attached drawings, in which like reference numerals generally represent like parts throughout.
FIG. 1 shows a schematic block diagram of an experimental traffic service system according to one embodiment of the invention.
Fig. 2 shows a schematic diagram of a tree structure according to an embodiment of the invention.
Fig. 3 shows a schematic flow diagram of a traffic forwarding method according to another embodiment of the invention.
Fig. 4 shows a schematic flow diagram of a traffic forwarding method according to another embodiment of the invention.
Fig. 5 is a block diagram illustrating a structure of a traffic forwarding apparatus according to an embodiment of the present invention.
Fig. 6 shows a schematic block diagram of a traffic forwarding device according to another embodiment of the present invention.
FIG. 7 illustrates a schematic structural diagram of a computing device according to an embodiment of the invention.
Detailed Description
Preferred embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While the preferred embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. 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.
As described above, in order to solve the problem of influence of high-frequency effect tests on system operation, maintenance and service stability in the prior art, the invention provides a traffic forwarding method and device, wherein an experimental traffic forwarding module is introduced to forward a received upstream request to a corresponding experimental example according to an experimental rule, and to ensure service stability to the maximum extent when the experimental example fails.
In one embodiment, the traffic forwarding method of the present invention is implemented based on an experimental traffic service system. FIG. 1 shows a schematic block diagram of an experimental traffic service system according to one embodiment of the invention.
As shown in fig. 1, an experiment traffic service system 100 (hereinafter referred to as a service system) of the present invention may be a distributed system, and the service system may include a name service 110, an experiment instance 120, and an experiment traffic forwarding module 130. The connecting lines in the drawings indicate that information interaction exists among the modules, and the connecting lines can be wired connection, wireless connection or any form of connection capable of carrying out information transmission.
An experimental instance 120 may register with name service 110 and report its own attribution information to name service 110
The attribution information may include the experimental application to which the experimental instance belongs and the cluster to which the experimental application belongs. When the experimental example registers with the name service, the metadata reported by the experimental example may include the attribution information.
In a distributed system, a service usually deploys many experimental examples in order to improve the overall service capacity. Here, experimental instances providing the same service are collectively referred to as clusters (cluster), and each experimental instance is referred to as a Node (Node). In general, one experimental application may use one or more clusters.
In a preferred embodiment, one experimental example is attributed to only one experimental application and one experimental application is attributed to only one cluster. Moreover, one cluster can host one or more experimental applications, and one experimental application can host one or more experimental instances. Therefore, the affiliation relationship of the three is simplified, and the high-level resources can be compatible with the low-level resources.
The experiment traffic forwarding module 130 obtains attribution information of the online experiment instance from the name service, receives a traffic request for an experiment from upstream, and forwards the traffic request to the experiment instance.
Experiment traffic forwarding module 130 may periodically or periodically obtain attribution information of online experiment instances from a name service.
The online experimental example is an experimental example incorporated into an experimental traffic forwarding system, and includes, but is not limited to, new online of an experimental application, recovery from a failure, or new online. The online experimental example registers with the name service, and the metadata reported to the name service contains the attribution information of the online experimental example.
The traffic request is a traffic request for an experiment from an upstream traffic issuing module. The upstream traffic issuing module may issue the traffic request for the experiment to the experiment traffic forwarding module 130, and other traffic requests may be issued directly to the corresponding service instances, or may be issued in other manners. The specific issuing mode is not related to the present invention, and the present invention is not limited to this.
The traffic request may be a traffic request for a specified experimental application.
In one embodiment, in response to a traffic request of a specific experimental application, the experimental traffic forwarding module 130 may first determine whether there is an available experimental example belonging to the specific experimental application based on attribution information obtained from the name service, and then select the available experimental example for traffic forwarding by a predetermined selection manner. The present invention is not limited to the predetermined selection method.
In response to a traffic request for a specified experimental application, where there are available experimental instances attributed to the specified experimental application, experimental traffic forwarding module 130 may select an experimental instance from the available experimental instances attributed to the specified experimental application and forward the traffic request to the selected experimental instance. Where, for example, a routine flow allocation may be employed to select an experimental instance from a plurality of available experimental instances attributed to the experimental application.
In the event that the selected experimental instance fails to perform the traffic request, other available experimental instances attributed to the experimental application may be selected and the traffic request forwarded to the selected experimental instance.
In some cases, there may not be available experimental examples attributed to the specified experimental application. For example, the attribution information obtained from the name service may have expired, or in the case of obtaining the attribution information periodically (periodically), between two times of obtaining, a case where an application is offline or an experimental instance fails, or the like occurs.
In the absence of available experimental instances attributed to the specified experimental application, experimental traffic forwarding module 130 may select an experimental instance among the experimental instances attributed to the cluster to which the specified experimental application belongs and forward the traffic request to the selected experimental instance.
Therefore, when all the experiment examples under one experiment application are not available, the flow of the experiment application is appointed to be turned to the experiment examples belonging to other experiment applications under the cluster, smooth flow forwarding is achieved, flow loss is avoided, and service stability is guaranteed due to the compatibility of high-level resources with low-level resources.
The traffic request as described above may also be a traffic request for a given cluster.
In response to the traffic request of the specified cluster, experimental traffic forwarding module 130 may select an experimental instance among the experimental instances belonging to the specified cluster and forward the traffic request to the selected experimental instance.
Here, a routine traffic distribution may also be employed to select an experimental instance among a plurality of available experimental instances assigned to the cluster.
In the event that the selected experiment instance fails to perform the traffic request, other available experiment instances belonging to the specified cluster may be selected and the traffic request forwarded to the selected experiment instance.
Therefore, the flow forwarding mechanism can realize smooth flow forwarding and avoid flow loss.
In addition, for convenience of management, the experiment traffic forwarding module 130 may further construct a tree structure based on the attribution information, and the experiment traffic forwarding module 130 may select an experiment instance based on the tree structure.
In a preferred embodiment, a tree structure can be constructed for the downstream service resources through three levels of clusters, experimental applications and experimental examples, wherein the experimental examples are child nodes of the experimental applications to which the experimental examples belong, the experimental applications are child nodes of the clusters to which the experimental applications belong,
fig. 2 shows a schematic diagram of a tree structure according to an embodiment of the invention.
As shown in fig. 2, the management of the experiment instance by the experiment traffic forwarding module 130(Dispatcher) can be divided into three stages: clustering (Group), application of experiments (App), experimental examples (Instance).
The Instance corresponds to an ip: port actual service, and the Group and the App are the partitions of the Instance on different granularities. In this case, one Instance can only belong to one App, one App can only belong to one Group, and so on, one Instance can only belong to one Group. In contrast, one Group can administer multiple apps.
When the experimental example registers to the name service, the reported meta information includes the attribution information.
When the experiment traffic forwarding module 130 is started, the three-level information can be immediately obtained from the name service, and the tree topology shown in fig. 2 is constructed in the memory. During its lifetime, the experiment traffic forwarding module 130 may also periodically or periodically obtain the latest attribution information from the name service, and accordingly update/rebuild the tree structure.
The upstream caller may specify a cluster (Group) or an experiment application (App) to initiate the call.
If a Group access is designated, the experimental traffic forwarding module 130 may select one experimental example from all available experimental examples administered by the Group based on the tree structure and according to a load balancing policy, and forward a traffic request to the selected experimental example.
In the event that the selected experimental instance fails to perform the traffic request, other available experimental instances belonging to the cluster may be selected and the traffic request forwarded to the selected experimental instance.
Generally, the number of experimental examples under the jurisdiction of Group is large, and unless the whole cluster is unavailable, the traffic request can be forwarded to a certain normal available experimental example;
if the access of the experimental application (App) is designated, the experimental traffic forwarding module 130 may preferentially select one experimental example from the experimental examples governed by the experimental application (App) to forward the traffic request according to the load balancing policy.
In the experimental scenario, an App may only correspond to one experimental example, or the App may not correspond to a specific experimental example due to offline of the experiment.
When no specific experiment example exists under the experiment application node or no available experiment example exists due to the fact that the experiment examples under the recorded/found experiment application all have faults, the request for the App at this time can not be forwarded by the available experiment example.
In this case, the APP node may trace to the Group node according to the tree information of the tree structure, convert the traffic request for the specified APP this time into a traffic request for the specified Group, and select another available experimental example belonging to the specified Group.
Therefore, under the condition that no available experiment example belonging to the specified experiment application exists, the forwarding request of the experiment application is converted into the forwarding request of the cluster, and the compatibility of high-level resources with low-level resources preferentially ensures that the flow request is not lost, thereby ensuring the stability of system service.
As described above, the acquisition of the attribution information from the name service by the experiment traffic forwarding module 130 is periodic, and the occurrence of an abnormality in the experiment instance cannot be sensed in time in the period.
Therefore, the invention can also add an intervention mechanism of the forwarding request return state to the experimental example state, and when the forwarding request to a certain experimental example fails and the experimental example is confirmed to be abnormal, the example can be marked as abnormal and the tree structure can be rebuilt.
If the experimental example is recovered to be normal, the experimental example can be recovered in the reconstructed tree structure when the tree structure is reconstructed next time.
Therefore, the invention collects the downstream service resources through the service discovery mechanism, and organizes and manages the tree structure. The upstream calling party can comb the flow requests into a plurality of groups and access the flow requests according to the Group or App respectively, and the on-line of the subsequent experimental flow does not need the upstream tangent flow cooperation, so that the operation and maintenance operation and upstream and downstream communication cost are reduced.
In the process of request forwarding, the flow can be effectively guaranteed not to be discarded by the three-level resource management mode, when the App level cannot make a decision to obtain a proper experimental example due to an experiment offline or service fault, the App level can automatically make a decision from the Group level to which the App belongs, therefore, the forwarding request of the App can be converted into the forwarding request of the Group, the stability of service is guaranteed through the compatibility of high-level resources with low-level resources, meanwhile, the automatic distribution of the experimental online flow can be realized, and the effect of automatic traffic cutting away after the experiment offline is achieved.
The traffic forwarding scheme for the experimental example of the present invention may be implemented as a traffic forwarding method for the experimental example.
Fig. 3 shows a schematic flow diagram of a traffic forwarding method according to an embodiment of the invention. The method may be performed by experimental traffic forwarding module 130 shown in fig. 1.
As shown in fig. 3, in step S310, attribution information of the online experiment example is obtained from the name service, where the attribution information includes the experiment application to which the experiment example belongs and the cluster to which the experiment application belongs.
Here, experiment traffic forwarding module 130 periodically obtains attribution information of the online experiment instance from a name service. One experimental example belongs to only one experimental application, and one experimental application belongs to only one cluster; and one cluster can host one or more experimental applications, and one experimental application can host one or more experimental instances.
The online experimental example registers with the name service, and the metadata reported to the name service contains the attribution information of the online experimental example.
The experiment traffic forwarding module 130 receives a traffic request for an experiment from the upstream traffic issuing module, where the traffic request may be a traffic request of a specific experiment application.
In step S315, it is determined whether there are available experimental instances that are attributed to the specified experimental application.
In response to a traffic request for a specified experimental application, in the presence of available experimental instances attributed to the specified experimental application, in step S320, an experimental instance is selected from the available experimental instances attributed to the specified experimental application, and the traffic request is forwarded to the selected experimental instance. The flow request is a flow request for experiment from an upstream flow issuing module.
In case there is no available experimental instance attributed to the specified experimental application, in step S330, an experimental instance is selected among the experimental instances attributed to the cluster to which the specified experimental application belongs, and the traffic request is forwarded to the selected experimental instance.
The traffic request may also be a traffic request of a designated cluster, and in this case, in response to the traffic request of the designated cluster, in step S320, an experimental example is selected from the experimental examples belonging to the designated cluster, and the traffic request is forwarded to the selected experimental example.
Fig. 4 shows a schematic flow diagram of a traffic forwarding method according to another embodiment of the invention. The method may be performed by experimental traffic forwarding module 130 shown in fig. 1.
As shown in fig. 4, in step S410, attribution information of the online experiment instance is obtained from the name service, where the attribution information includes the experiment application to which the experiment instance belongs and the cluster to which the experiment application belongs.
In step S420, a tree structure is constructed based on the attribution information, in which the experimental instances are child nodes of the experimental application to which the experimental instances belong, the experimental applications are child nodes of the cluster to which the experimental applications belong,
in step S430, in response to a traffic request specifying an experimental application or a cluster, an experimental instance is selected based on the tree structure, and the traffic request is forwarded to the selected experimental instance.
So far, the schematic flow of the traffic forwarding method for experimental example of the present invention has been briefly described with reference to fig. 3 to 4.
In addition, the traffic forwarding method for the experimental example can also be realized by a traffic forwarding device for the experimental example.
Fig. 5 is a block diagram showing the structure of a traffic forwarding apparatus according to an embodiment of the present invention. The functional blocks of the traffic forwarding apparatus 500 may be implemented by hardware, software or a combination of hardware and software for implementing the principles of the present invention. It will be appreciated by those skilled in the art that the functional blocks described in fig. 5 may be combined or divided into sub-blocks to implement the principles of the invention described above. Thus, the description herein may support any possible combination, or division, or further definition of the functional modules described herein.
The traffic forwarding apparatus 500 shown in fig. 5 may be used to implement the traffic forwarding method shown in fig. 3-4, and only the functional modules that the traffic forwarding apparatus 500 may have and the operations that each functional module may perform are briefly described below, and for the details related thereto, reference may be made to the description above in conjunction with fig. 3-4, and details are not repeated here.
As shown in fig. 5, a traffic forwarding device 500 for an experimental example of the present invention may include an information obtaining device 510, a first forwarding device 520, and a second forwarding device 530.
The information obtaining device 510 may be configured to obtain attribution information of the online experiment instance from the name service, where the attribution information includes an experiment application to which the experiment instance belongs and a cluster to which the experiment application belongs, and the attribution information is reported to the name service while the online experiment instance is registered with the name service.
The first forwarding device 520 may be configured to, in response to a traffic request of a specified experimental application, select an experimental instance from available experimental instances belonging to the specified experimental application in the presence of the available experimental instances belonging to the specified experimental application, and forward the traffic request to the selected experimental instance;
the second forwarding device 530 may be configured to select an experimental instance among experimental instances belonging to a cluster to which the specified experimental application belongs and forward the traffic request to the selected experimental instance, in case there is no available experimental instance belonging to the specified experimental application.
In a preferred embodiment, the traffic forwarding device 500 may further include a third forwarding device 540 (see fig. 6 below).
The third forwarding device may be configured to select an experimental instance among experimental instances belonging to the specified cluster in response to the traffic request of the specified cluster, and forward the traffic request to the selected experimental instance.
It should be understood that the descriptions of "first," "second," and "third" herein are intended to distinguish between the objects described, and not to specify any order or magnitude, unless otherwise indicated or implied.
Fig. 6 shows a schematic block diagram of a traffic forwarding device according to another embodiment of the present invention.
As shown in fig. 6, the traffic forwarding apparatus 500 of the present invention may further include a tree structure constructing apparatus 550.
The tree structure constructing device 550 may be configured to construct a tree structure based on the attribution information, where the experimental example is a child node of the experimental application to which the experimental example belongs, and the experimental application is a child node of the cluster to which the experimental application belongs, and the first/second/third forwarding devices may select the experimental example based on the tree structure and forward the traffic.
Therefore, the flow request is uniformly received upwards through the flow forwarding device, and each experimental example is managed downwards and forwarded to the flow request. Each experimental example registers to a name service and reports self attribution information, the flow forwarding device regularly acquires experimental version information from the name service to construct tree structure management, the tree structure is reconstructed after the information is changed, and flow forwarding is carried out by combining a request and a downstream node with proper tree information decision.
Fig. 7 is a schematic structural diagram of a computing device that can be used to implement the traffic forwarding method according to an embodiment of the present invention.
Referring to fig. 7, computing device 700 includes memory 710 and processor 720.
Processor 720 may be a multi-core processor or may include multiple processors. In some embodiments, processor 720 may include a general-purpose host processor and one or more special purpose coprocessors such as a Graphics Processor (GPU), Digital Signal Processor (DSP), or the like. In some embodiments, processor 720 may be implemented using custom circuits, such as an Application Specific Integrated Circuit (ASIC) or a Field Programmable Gate Array (FPGA).
The memory 710 may include various types of storage units, such as system memory, Read Only Memory (ROM), and permanent storage. Wherein the ROM may store static data or instructions that are required by processor 720 or other modules of the computer. The persistent storage device may be a read-write storage device. The persistent storage may be a non-volatile storage device that does not lose stored instructions and data even after the computer is powered off. In some embodiments, the persistent storage device employs a mass storage device (e.g., magnetic or optical disk, flash memory) as the persistent storage device. In other embodiments, the permanent storage may be a removable storage device (e.g., floppy disk, optical drive). The system memory may be a read-write memory device or a volatile read-write memory device, such as a dynamic random access memory. The system memory may store instructions and data that some or all of the processors require at runtime. In addition, the memory 710 may include any combination of computer-readable storage media, including various types of semiconductor memory chips (DRAM, SRAM, SDRAM, flash memory, programmable read-only memory), magnetic and/or optical disks, may also be employed. In some embodiments, memory 710 may include a removable storage device that is readable and/or writable, such as a Compact Disc (CD), a digital versatile disc read only (e.g., DVD-ROM, dual layer DVD-ROM), a Blu-ray disc read only, an ultra-dense disc, a flash memory card (e.g., SD card, min SD card, Micro-SD card, etc.), a magnetic floppy disk, or the like. Computer-readable storage media do not contain carrier waves or transitory electronic signals transmitted by wireless or wired means.
The memory 710 has stored thereon executable code that, when processed by the processor 720, causes the processor 720 to perform the traffic forwarding methods described above.
The traffic forwarding method and apparatus, and the service system for the experimental example according to the present invention have been described in detail above with reference to the accompanying drawings.
Furthermore, the method according to the invention may also be implemented as a computer program or computer program product comprising computer program code instructions for carrying out the above-mentioned steps defined in the above-mentioned method of the invention.
Alternatively, the invention may also be embodied as a non-transitory machine-readable storage medium (or computer-readable storage medium, or machine-readable storage medium) having stored thereon executable code (or a computer program, or computer instruction code) which, when executed by a processor of an electronic device (or computing device, server, etc.), causes the processor to perform the steps of the above-described method according to the invention.
Those of skill would further appreciate that the various illustrative logical blocks, modules, circuits, and algorithm steps described in connection with the disclosure herein may be implemented as electronic hardware, computer software, or combinations of both.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems and methods according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
Having described embodiments of the present invention, the foregoing description is intended to be exemplary, not exhaustive, and not limited to the embodiments disclosed. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The terminology used herein is chosen in order to best explain the principles of the embodiments, the practical application, or improvements made to the technology in the marketplace, or to enable others of ordinary skill in the art to understand the embodiments disclosed herein.

Claims (15)

1. A traffic forwarding method for conducting experiments on experimental applications, comprising:
acquiring attribution information of an online experiment example from a name service, wherein the attribution information comprises experiment applications to which the experiment example belongs and clusters to which the experiment applications belong;
in response to a traffic request of a specified experimental application, in the presence of available experimental instances attributed to the specified experimental application, selecting an experimental instance from the available experimental instances attributed to the specified experimental application and forwarding the traffic request to the selected experimental instance;
in the absence of available experimental instances attributed to the specified experimental application, selecting an experimental instance among the experimental instances attributed to the cluster to which the specified experimental application belongs, and forwarding the traffic request to the selected experimental instance.
2. The traffic forwarding method of claim 1, further comprising:
and responding to the traffic request of the specified cluster, selecting an experiment example from the experiment examples belonging to the specified cluster, and forwarding the traffic request to the selected experiment example.
3. The traffic forwarding method of claim 1, further comprising:
constructing a tree structure based on the attribution information, wherein in the tree structure, the experiment example is the child node of the experiment application to which the experiment example belongs, the experiment application is the child node of the cluster to which the experiment application belongs,
wherein an experimental instance is selected based on the tree structure.
4. The traffic forwarding method of claim 1, further comprising:
and reporting the attribution information of the online experiment example to the name service while registering the online experiment example to the name service.
5. The traffic forwarding method of claim 4,
attribution information of the online experimental instance is periodically obtained from a name service.
6. The traffic forwarding method of claim 1,
one experimental example belongs to only one experimental application, and one experimental application belongs to only one cluster; and is
One cluster can host one or more experimental applications, and one experimental application can host one or more experimental instances.
7. The traffic forwarding method of claim 1,
the flow request is a flow request for experiment from an upstream flow issuing module.
8. A traffic forwarding device for conducting experiments on experimental applications, comprising:
the information acquisition device is used for acquiring attribution information of the online experiment example from the name service, and the attribution information comprises experiment applications to which the experiment example belongs and clusters to which the experiment applications belong;
the first forwarding device is used for responding to the flow request of the specified experiment application, selecting an experiment example from available experiment examples belonging to the specified experiment application under the condition that the available experiment examples belonging to the specified experiment application exist, and forwarding the flow request to the selected experiment example;
and the second forwarding device is used for selecting an experimental example from the experimental examples belonging to the cluster to which the specified experimental application belongs and forwarding the traffic request to the selected experimental example in the case that no available experimental example belonging to the specified experimental application exists.
9. The traffic forwarding device of claim 8, further comprising:
and the third forwarding device is used for responding to the traffic request of the specified cluster, selecting an experimental example from the experimental examples belonging to the specified cluster, and forwarding the traffic request to the selected experimental example.
10. The traffic forwarding device of claim 8, further comprising:
a tree structure construction device for constructing a tree structure based on the attribution information, wherein the experimental examples are subnodes of the experimental application to which the experimental examples belong and the subnodes of the cluster to which the experimental applications belong,
wherein an experimental instance is selected based on the tree structure.
11. The traffic forwarding device of claim 8,
the attribution information is reported to the name service when the online experiment example registers to the name service.
12. An experiment flow service system for conducting experiments on an experiment application, comprising:
the experimental example registers to the name service and reports the attribution information of the experimental example to the name service, wherein the attribution information comprises the experimental application to which the experimental example belongs and the cluster to which the experimental application belongs; and
an experiment flow forwarding module for obtaining the attribution information of the online experiment example from the name service, receiving the flow request for experiment from the upstream and forwarding the flow request to the experiment example,
wherein, in response to a traffic request of a specified experimental application, in the presence of available experimental examples belonging to the specified experimental application, the experimental traffic forwarding module selects an experimental example from the available experimental examples belonging to the specified experimental application and forwards the traffic request to the selected experimental example;
in the absence of available experimental instances attributed to the specified experimental application, the experimental traffic forwarding module selects an experimental instance among the experimental instances attributed to the cluster to which the specified experimental application belongs and forwards the traffic request to the selected experimental instance.
13. The experimental traffic service system of claim 12,
in response to a traffic request of a designated cluster, the experimental traffic forwarding module selects an experimental instance from the experimental instances belonging to the designated cluster and forwards the traffic request to the selected experimental instance.
14. A computing device, comprising:
a processor; and
a memory having executable code stored thereon, which when executed by the processor, causes the processor to perform the method of any of claims 1-7.
15. A non-transitory machine-readable storage medium having stored thereon executable code, which when executed by a processor of an electronic device, causes the processor to perform the method of any of claims 1-7.
CN201810928478.9A 2018-08-10 2018-08-10 Flow forwarding method and device, service system, computing device and storage medium Active CN109151016B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810928478.9A CN109151016B (en) 2018-08-10 2018-08-10 Flow forwarding method and device, service system, computing device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810928478.9A CN109151016B (en) 2018-08-10 2018-08-10 Flow forwarding method and device, service system, computing device and storage medium

Publications (2)

Publication Number Publication Date
CN109151016A CN109151016A (en) 2019-01-04
CN109151016B true CN109151016B (en) 2021-07-30

Family

ID=64789526

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810928478.9A Active CN109151016B (en) 2018-08-10 2018-08-10 Flow forwarding method and device, service system, computing device and storage medium

Country Status (1)

Country Link
CN (1) CN109151016B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111698326B (en) * 2020-06-12 2023-01-31 北京百度网讯科技有限公司 Method and device for determining cost attribution of cloud service resources

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101932034A (en) * 2009-06-26 2010-12-29 华为技术有限公司 Method and system for enhancing service quality and application network element
CN102571605A (en) * 2012-02-17 2012-07-11 杭州华三通信技术有限公司 Method and device for preventing traffic from interrupting
CN103391254A (en) * 2012-05-09 2013-11-13 百度在线网络技术(北京)有限公司 Method and device for managing distributed CDN flows
CN104767685A (en) * 2015-04-17 2015-07-08 杭州华三通信技术有限公司 Flow forwarding method and device
CN107820694A (en) * 2015-03-24 2018-03-20 脸谱公司 The technology for media share by message transfer service and mixing again

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10542057B2 (en) * 2016-12-30 2020-01-21 Akamai Technologies, Inc. Multicast overlay network for delivery of real-time video

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101932034A (en) * 2009-06-26 2010-12-29 华为技术有限公司 Method and system for enhancing service quality and application network element
CN102571605A (en) * 2012-02-17 2012-07-11 杭州华三通信技术有限公司 Method and device for preventing traffic from interrupting
CN103391254A (en) * 2012-05-09 2013-11-13 百度在线网络技术(北京)有限公司 Method and device for managing distributed CDN flows
CN107820694A (en) * 2015-03-24 2018-03-20 脸谱公司 The technology for media share by message transfer service and mixing again
CN104767685A (en) * 2015-04-17 2015-07-08 杭州华三通信技术有限公司 Flow forwarding method and device

Also Published As

Publication number Publication date
CN109151016A (en) 2019-01-04

Similar Documents

Publication Publication Date Title
CN107943421B (en) Partition division method and device based on distributed storage system
CN107450979B (en) Block chain consensus method and device
US10379951B2 (en) Hierarchic storage policy for distributed object storage systems
CN107040582B (en) Data processing method and device
CN108351806A (en) Database trigger of the distribution based on stream
KR101871383B1 (en) Method and system for using a recursive event listener on a node in hierarchical data structure
CN106933843B (en) Database heartbeat detection method and device
US8930501B2 (en) Distributed data storage system and method
CN108540315B (en) Distributed storage system, method and device
US10169085B2 (en) Distributed computing of a task utilizing a copy of an original file stored on a recovery site and based on file modification times
US8931051B2 (en) Scalable and highly available clustering for large scale real-time applications
CN112291082B (en) Disaster recovery processing method, terminal and storage medium for machine room
CN107920101B (en) File access method, device and system and electronic equipment
CN108390914B (en) Service updating method, device and system
CN115756955A (en) Data backup and data recovery method and device and computer equipment
CN112860412B (en) Service data processing method and device, electronic equipment and storage medium
CN109151016B (en) Flow forwarding method and device, service system, computing device and storage medium
CN110298031B (en) Dictionary service system and model version consistency distribution method
US20180060974A1 (en) Social networking relationships processing method, system, and storage medium
CN115629901A (en) Log playback method and device, data recovery method and device and electronic equipment
CN115292280A (en) Cross-region data scheduling method, device, equipment and storage medium
US10511656B1 (en) Log information transmission integrity
CN113419901A (en) Data disaster recovery method and device and server
CN116501255A (en) Data migration method, device, computing equipment and storage medium
CN115016738A (en) Data migration method, device, system, electronic equipment and medium

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
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20200818

Address after: 310052 room 508, floor 5, building 4, No. 699, Wangshang Road, Changhe street, Binjiang District, Hangzhou City, Zhejiang Province

Applicant after: Alibaba (China) Co.,Ltd.

Address before: 510627 Guangdong city of Guangzhou province Whampoa Tianhe District Road No. 163 Xiping Yun Lu Yun Ping square B radio tower 13 layer self unit 01

Applicant before: Guangdong Shenma Search Technology Co.,Ltd.

GR01 Patent grant
GR01 Patent grant