Method and device for adjusting gray scale release rule, storage medium and electronic device
By acquiring and matching canary release rules at the target gateway, the application programming interface is automatically adjusted, solving the tedious manual operation and maintenance problem in canary release and improving release efficiency and stability.
Patent Information
- Application Number
- CN202310316628.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-28
- Publication Date
- 2025-12-23
- Estimated Expiration
- 2043-03-28
AI Technical Summary
In existing technologies, the manual maintenance workload during the canary release process is large, resulting in inconvenient maintenance and the risk of human error.
By obtaining the application programming interface (API) from the target gateway, receiving the canary release rules determined by the target object, matching them with historical rules, and adjusting the rules of the API based on the matching results, the canary release rule adjustment can be automated.
It reduces repetitive manual maintenance work, improves the efficiency and stability of canary releases, and reduces the risk of human error.
Smart Images

Figure CN116546106B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of smart home, in particular to a gray release rule adjustment method and device, a storage medium and an electronic device. BACKGROUND
[0002] Currently, R&D personnel often implement blue-green deployment and gray release functions through a traffic control plug-in of a gateway, but because of the load of a business system, the gateway is configured with many routes of services, and the number of routes is greater than 100. In a traditional manual operation and maintenance mode, a large amount of manual operation and maintenance cost is consumed, and a heavy workload is required for the system to perform one-time gray release online or offline function verification, and the instability factor caused by human errors is increased.
[0003] Therefore, in view of the technical problem in the related art that a large amount of repeated manual operation and maintenance work leads to inconvenient operation and maintenance, an effective solution has not yet been proposed. SUMMARY
[0004] Embodiments of the present application provide a gray release rule adjustment method and device, a storage medium and an electronic device to at least solve the technical problem of low starting efficiency of application software in the related art.
[0005] According to one of the embodiments of the present application, a gray release rule adjustment method is provided, including: sending a query request carrying a filtering condition to a target gateway, obtaining a plurality of application programming interfaces for supporting gray release of a target application fed back by the target gateway; receiving a target gray release rule determined by a target object from a plurality of preset gray release rules; matching the target gray release rule with a historical gray release rule corresponding to the application programming interface, and determining a target application programming interface for which a rule modification is to be performed according to a matching result; and in a case where it is determined that the gray release rule corresponding to the application programming interface is to be adjusted to the target gray release rule, determining that the target object successfully modifies the gray release rule corresponding to the target application.
[0006] In one exemplary embodiment, before the query request carrying the filtering condition is sent to the target gateway, the method further includes: obtaining login information of the target object; in a case where the login information passes verification, determining that the target object has the permission to send the query request; and in a case where it is determined that the target object has the permission, requesting the target gateway to open the application programming interface of the target application through a backend of a gray release system.
[0007] In an example embodiment, the method for opening an application programming interface of a target application by a target gateway through a backend request of a gray release system comprises: obtaining a response feedback made by the target gateway to the backend request of the gray release system; determining to allow the target object to make an adjustment of a gray release rule corresponding to the target application through the target gateway in a case where the response feedback indicates that the target gateway has opened the application programming interface of the target application; and determining to prohibit the target object to make the adjustment of the gray release rule corresponding to the target application through the target gateway in a case where the response feedback indicates that the target gateway has not opened the application programming interface of the target application.
[0008] In an example embodiment, the method for receiving a target gray release rule determined by a target object from a plurality of preset gray release rules comprises: determining an application type corresponding to a target application to be adjusted by the target object; determining the plurality of preset gray release rules from a database corresponding to a gray release system according to the application type, and displaying the plurality of preset gray release rules on a target interface bound by the target object; and obtaining a selection instruction triggered by the target object on the target interface, so as to determine a target gray release rule from the plurality of preset gray release rules by the selection instruction.
[0009] In an example embodiment, after the target gray release rule determined by the target object from the plurality of preset gray release rules is received, the method further comprises: displaying a plurality of target rule conditions included in the target gray release rule on a target interface bound by the target object; and receiving a confirmation result of the plurality of target rule conditions by the target object, so as to obtain an actual gray release rule corresponding to the target gray release rule.
[0010] In an example embodiment, after the target application programming interface for which the rule modification is to be performed is determined according to the matching result, the method further comprises: initiating a modification of a historical gray release rule in the target application programming interface in a case where a modification instruction is issued by the target object; determining a rule difference between the historical gray release rule and the target gray release rule; and modifying a plurality of rule conditions corresponding to the historical gray release rule based on the rule difference.
[0011] In an example embodiment, the modification of the plurality of rule conditions corresponding to the historical gray release rule based on the rule difference comprises: determining a modification priority corresponding to the plurality of rule conditions; and sorting the plurality of rule conditions in a modification order by the modification priority.
[0012] According to another embodiment of the present application, there is also provided an adjusting device of a gray release rule, comprising: a sending module configured to send a query request carrying a screening condition to a target gateway, and acquire a plurality of application programming interfaces for supporting gray release of a target application fed back by the target gateway; a receiving module configured to receive a target gray release rule determined by a target object from a plurality of preset gray release rules; a matching module configured to match the target gray release rule with a historical gray release rule corresponding to the application programming interface, and determine a target application programming interface for which a rule modification is to be performed according to a matching result; and a determining module configured to determine that the target object successfully modifies the gray release rule corresponding to the target application in a case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule.
[0013] According to still another aspect of the present application, there is also provided a computer readable storage medium having a computer program stored therein, wherein the computer program is configured to execute the above-mentioned adjusting method of a gray release rule when running.
[0014] According to still another aspect of the present application, there is also provided an electronic device comprising a memory, a processor, and a computer program stored in the memory and capable of running on the processor, wherein the processor executes the above-mentioned adjusting method of a gray release rule through the computer program.
[0015] In the embodiments of the present application, the query request carrying the screening condition is sent to the target gateway, and the plurality of application programming interfaces for supporting gray release of the target application fed back by the target gateway are acquired; the target gray release rule determined by the target object from the plurality of preset gray release rules is received; the target gray release rule is matched with the historical gray release rule corresponding to the application programming interface, and the target application programming interface for which the rule modification is to be performed is determined according to the matching result; and in a case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule, it is determined that the target object successfully modifies the gray release rule corresponding to the target application; by using the above technical solution, the technical problem of inconvenient operation and maintenance caused by a large amount of repeated manual operation and maintenance is solved, and thus the release efficiency can be improved. BRIEF DESCRIPTION OF DRAWINGS
[0016] The accompanying drawings, which are incorporated herein and form a part of the specification, illustrate embodiments consistent with the present application and, together with the description, further serve to explain the principles of the present application.
[0017] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, for those skilled in the field, other drawings can also be obtained based on these drawings without any creative effort.
[0018] Figure 1 Fig. 1 is a hardware environment schematic diagram of a gray release rule adjustment method according to an embodiment of the present application;
[0019] Figure 2 Fig. 2 is a flow chart of a gray release rule adjustment method according to an embodiment of the present application;
[0020] Figure 3 Fig. 3 is a flow schematic diagram of a gray release rule adjustment method according to an embodiment of the present application;
[0021] Figure 4 Fig. 4 is a structural block diagram of a gray release rule adjustment device according to an embodiment of the present application (1);
[0022] Figure 5 Fig. 5 is a structural block diagram of a gray release rule adjustment device according to an embodiment of the present application (2). DETAILED DESCRIPTION
[0023] In order to make the person skilled in the art better understand the present application, the following will combine the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without any creative effort should be within the scope of protection of the present application.
[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and do not necessarily describe a specific order or sequence. It should be understood that the data thus used can be interchanged under appropriate circumstances, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device including a series of steps or units does not necessarily limit to those steps or units clearly listed, but can include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0025] According to an aspect of the embodiments of the present application, a method for adjusting a gray release rule is provided. The method for adjusting the gray release rule is widely applied to smart home, smart home, smart home device ecology, intelligence house ecology and other whole-house intelligent digital control application scenarios. Optionally, in the embodiments, the method for adjusting the gray release rule can be applied to the hardware environment composed of the terminal device 102 and the server 104 as shown in the figure. Figure 1 As shown in the figure. Figure 1 The server 104 is connected with the terminal device 102 through a network, which can be used to provide services (such as application services, etc.) for the terminal or the client installed on the terminal, a database can be set on the server or independently of the server, which is used to provide data storage services for the server 104, cloud computing and / or edge computing services can be configured on the server or independently of the server, which is used to provide data operation services for the server 104.
[0026] The network can include but is not limited to at least one of the following: wired network, wireless network. The wired network can include but is not limited to at least one of the following: wide area network, metropolitan area network, local area network. The wireless network can include but is not limited to at least one of the following: WIFI (Wireless Fidelity), Bluetooth. The terminal device 102 can not be limited to PC, mobile phone, tablet computer, smart air conditioner, smart oven, smart refrigerator, smart oven, smart oven, smart washing machine, smart water heater, smart washing equipment, smart dishwasher, smart projection equipment, smart television, smart clothesline, smart curtain, smart audio and video, smart socket, smart sound, smart sound box, smart fresh air equipment, smart kitchen and bathroom equipment, smart bathroom equipment, smart sweeping robot, smart window cleaning robot, smart mopping robot, smart air purification equipment, smart steamer, smart microwave oven, smart kitchen treasure, smart purifier, smart water dispenser, smart door lock, etc.
[0027] In the embodiments, a method for adjusting a gray release rule is provided, which is applied to a computer terminal, Figure 2 is a flowchart of the method for adjusting the gray release rule according to the embodiments of the present application, which includes the following steps:
[0028] Step S202, sending a query request carrying a filtering condition to a target gateway, and obtaining a plurality of application programming interfaces for supporting gray release of a target application fed back by the target gateway;
[0029] Step S204, receiving a target gray release rule determined by a target object from a plurality of preset gray release rules;
[0030] Step S206, matching the target gray release rule with the historical gray release rule corresponding to the application programming interface, and determining the target application programming interface for which the rule modification is performed according to the matching result.
[0031] Step S208, in the case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule, it is determined that the target object successfully modifies the gray release rule corresponding to the target application.
[0032] By the above steps, the query request carrying the filtering condition is sent to the target gateway, and the multiple application programming interfaces for supporting the gray release of the target application are obtained according to the feedback of the target gateway; the target object determines the target gray release rule from the multiple preset gray release rules; the target gray release rule is matched with the historical gray release rule corresponding to the application programming interface, and the target application programming interface for which the rule modification is performed is determined according to the matching result; in the case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule, it is determined that the target object successfully modifies the gray release rule corresponding to the target application. The technical problem of inconvenient operation caused by a large amount of repeated manual operation in the related art is solved, and the release efficiency is improved.
[0033] In one example embodiment, before the query request carrying the filtering condition is sent to the target gateway, the method further comprises: obtaining the login information of the target object; in the case where the login information is verified, it is determined that the target object has the permission to send the query request; in the case where it is determined that the target object has the permission, the target gateway is requested to open the application programming interface of the target application through the backend of the gray release system.
[0034] That is, by determining the permission of the user, it is determined whether the user can determine the opening of the programming interface of the target application.
[0035] Optionally, the method of determining that the target object has the permission comprises: first determining whether the identity of the target object is verified, and in the case where the identity of the target object is verified, determining the permission of the target object.
[0036] The process of determining whether the identity of the target object is verified comprises: obtaining the identity information of the target object, wherein the identity information can be biological information of the target object, such as pupil information, voiceprint information, fingerprint information, face information, etc., or a preset digital id of the target object.
[0037] In the case of obtaining the biological information of the target object, the biological information is analyzed to obtain a plurality of analysis segments, and in the case that the information contained in the analysis segment corresponds to the preset information consistent with the target object, it is determined that the target object identity passes the verification.
[0038] In the case of obtaining the digital ID of the target object, the digital ID is compared with the preset id database, wherein the id database contains a plurality of preset digital ids, and in the case that there is a preset digital id consistent with the digital id in the preset id database, it is determined that the target object identity passes the verification.
[0039] After the target object identity passes the verification, the target object's authority is determined from the preset authority information library. Wherein, the authority information library includes: preset target object identity information, and the authority corresponding to the preset target object identity information.
[0040] In one example embodiment, the target gateway opens the application programming interface of the target application through the backend request of the gray release system, including: obtaining the response feedback made by the target gateway to the backend request of the gray release system; in the case that the response feedback indicates that the target gateway has opened the application programming interface of the target application, it is determined that the target object is allowed to adjust the gray release rule corresponding to the target application through the target gateway; in the case that the response feedback indicates that the target gateway has not opened the application programming interface of the target application, it is determined that the target object is prohibited to adjust the gray release rule corresponding to the target application through the target gateway.
[0041] That is, first, the response feedback made by the gateway to the backend request is obtained, and according to the result of the response feedback, it is determined whether the gray release rule corresponding to the target application can be adjusted. The gateway opens the application programming interface, and the target object can adjust the gray release rule, and the gateway does not open the application programming interface, and the target object cannot adjust the gray release rule.
[0042] The process of determining whether the gateway sends feedback can include:
[0043] Step 1: determining whether the gateway makes a response within a preset time period after the backend request is sent;
[0044] Step 2: in the case that the gateway responds within the preset time period, confirming whether the type of the response sent by the gateway is the target response type;
[0045] Step 3: in the case that the response type is the target response type, confirming that the gateway sends feedback.
[0046] It should be noted that the response type includes: normal response, abnormal response.
[0047] In actual application process, there is a case that the backend issues a request but the gateway does not receive it, or the gateway response is delayed due to other abnormal reasons. At this time, it is necessary to determine whether the gateway has issued a response, and whether the response of the gateway is valid. In the case that the response issued by the gateway is valid, it is confirmed that the gateway has issued a feedback.
[0048] In an example embodiment, the target object receives the target gray release rule determined from the plurality of preset gray release rules, including: determining the application type corresponding to the target application to be adjusted by the target object; determining the plurality of preset gray release rules corresponding to the application type from the database of the gray release system, and displaying the plurality of preset gray release rules on the target interface bound by the target object; obtaining the selection instruction triggered by the target object on the target interface, and determining the target gray release rule from the plurality of preset gray release rules by the selection instruction.
[0049] In an example embodiment, after the target object receives the target gray release rule determined from the plurality of preset gray release rules, the method further includes: displaying a plurality of target rule conditions included in the target gray release rule on the target interface bound by the target object; receiving the confirmation result of the target object on the plurality of target rule conditions, and obtaining the actual gray release rule corresponding to the target gray release rule.
[0050] It should be noted that different application types correspond to different gray release rules, so it is necessary to determine the application type corresponding to the target application. Then, a plurality of alternative preset gray release rules are obtained according to the application type, and are displayed. The user selects the displayed release rule, and the user's selection instruction includes at least one of the following: selection of IP white list, selection of request header key, selection of request header value, selection of request parameter key, selection of request parameter value, and selection of gateway environment. According to the user's selection, the target gray release rule is determined.
[0051] In an example embodiment, after the matching result is determined, the method further includes: in the case that the target object issues a modification instruction, initiating modification of the historical gray release rule in the target application programming interface; determining the rule difference between the historical gray release rule and the target gray release rule; and modifying a plurality of rule conditions corresponding to the historical gray release rule based on the rule difference.
[0052] That is, in the case where the user issues an instruction to modify the gray release rule, the historical gray release rule is not modified in an "overriding" manner, but the difference between the historical gray release rule and the target gray release rule is first confirmed, and only the difference part is modified.
[0053] In one example embodiment, modifying the plurality of rule conditions corresponding to the historical gray release rule based on the rule difference comprises: determining a modification priority corresponding to the plurality of rule conditions; and sorting the plurality of rule conditions in a modification order based on the modification priority.
[0054] That is, different rule conditions correspond to different priorities, and the rule conditions with high priorities are modified in a limited manner.
[0055] Optionally, after confirming the priorities corresponding to the different rule conditions, the historical modification times of the rule conditions are confirmed, and the rule conditions with more historical modification times are modified first.
[0056] In order to better understand the process of the above-mentioned gray release rule adjustment method, the implementation method flow of the above-mentioned gray release rule adjustment will be described in combination with optional embodiments below, but not used to limit the technical solutions of the embodiments of the present application.
[0057] In this embodiment, a gray release rule adjustment method is provided, Figure 3 is a schematic diagram of the gray release rule adjustment method according to the embodiments of the present application, as Figure 3 shown, the above-mentioned gray release rule adjustment method can be realized based on the business module, Gradle and UpInitCompiler module (equivalent to the above-mentioned compiler). Gradle is a modern automation tool, which is a software development for project construction automation.
[0058] Specifically, the implementation steps are as follows:
[0059] Step S301: querying the gateway routing, the method comprising:
[0060] Step S3011, the user logs in the gray release management page, inputs the screening conditions, and clicks the query button;
[0061] Step S3012, the gray release management system sends a routing query request to the gateway;
[0062] Step S3013: the gateway returns the routing list information to the gray release management system;
[0063] Step S3014: the gray release management system returns the routing list information to the user.
[0064] Step S302: Batch modification of gray release rules, wherein step S302 further comprises the following steps:
[0065] Step S3021: The user multi-selects or selects all route records and clicks the gray release rule modification button, and the above-mentioned click information is sent to the gray release management system;
[0066] Step S3022: The gray release management system opens the corresponding form input page;
[0067] Step S3023: The user inputs the gray shunting rule, selects the gateway environment, and clicks the confirm button;
[0068] Step S3024: The gray release management system calls the route modification API in a loop to submit the route modification information request and sends it to the gateway;
[0069] Step S3025: The gateway returns success to the gray release management system;
[0070] Step S3025: The gray release management system returns success to the user.
[0071] Step S303: Batch enable / disable of gray release rules, wherein step S303 further comprises the following steps:
[0072] Step S3031: The user multi-selects or selects all route records and clicks the gray online / offline button;
[0073] Step S3032: The gray release management system opens the corresponding form input page;
[0074] Step S3033: The user selects the gateway environment and clicks the confirm button;
[0075] Step S3034: The gray release management system calls the route modification API in a loop to submit the route modification information request;
[0076] Step S3035: The gateway returns success to the gray release management system;
[0077] Step S3036: The gateway returns operation success to the user.
[0078] In general, multi-environment gateway route query: the user logs in to the gray release management system, clicks the gray release function menu, and opens the gray release management page. Input the screening conditions, which include: selecting the gateway environment, inputting the route name, label, url prefix, etc., and clicking the "query" button. The gray release management system backend requests the gateway open API, calls the route query API, the gateway returns the route information list to the gray release management system after processing successfully, and the gray release management system front end renders the route list data.
[0079] Batch modification of gray release rules: the user operates multiple selection or full selection of routing records, clicks the "modify gray rules" button, opens the form input page, the user inputs the gray distribution rules, such as: IP whitelist, request header key, request header value, request parameter key, request parameter value, selects the gateway environment, and clicks the confirm button. The gray release management system backend requests the corresponding gateway system, calls the routing modification API in a loop, submits the routing modification information request, and returns success information to the gray release management system after the gateway handles successfully. The front end of the gray release management system prompts the operation success.
[0080] Batch enable / disable of gray release rules: the user operates multiple selection or full selection of routing records, clicks the "gray online" button, opens the form input page, the user selects the gateway environment, and clicks the confirm button. The gray release management system backend requests the corresponding gateway system, calls the routing modification API in a loop, submits the routing modification request, and returns success information to the gray release management system after the gateway handles successfully. The front end of the gray release management system prompts the operation success.
[0081] Through the above steps, the gray release management system is used to uniformly manage the traffic distribution plug-ins of the gateway routing, realizes the unified management of the multi-environment gateway routing, batch modification of the gray release rules, and batch enable / disable of the gray release rules, and solves the technical problem of inconvenient operation caused by a large number of repeated manual operation and maintenance.
[0082] Through the description of the above embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be realized by means of software and necessary general hardware platform, of course, it can also be realized by hardware, but in many cases, the former is a better embodiment. Based on such understanding, the technical solutions of the present application can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes a plurality of instructions for making a terminal device (which can be a mobile phone, computer, server, or network device) execute the method of each embodiment of the present application.
[0083] Figure 4 is a structural block diagram of a gray release rule adjustment device according to an embodiment of the present application (one); as Figure 4 shown, comprising:
[0084] The sending module 42 is configured to send a query request carrying a filtering condition to a target gateway, and obtain a plurality of application programming interfaces for supporting gray release of a target application fed back by the target gateway.
[0085] The receiving module 44 is configured to receive a target gray release rule determined by the target object from a plurality of preset gray release rules.
[0086] The matching module 46 is configured to match the target gray release rule with a historical gray release rule corresponding to the application programming interface, and determine a target application programming interface that needs to be modified according to a matching result.
[0087] The determining module 48 is configured to determine that the target object successfully modifies the gray release rule of the target application in a case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule.
[0088] By the above device, a query request carrying a screening condition is sent to a target gateway, a plurality of application programming interfaces for supporting gray release of a target application are obtained according to feedback of the target gateway, a target gray release rule determined by a target object from a plurality of preset gray release rules is received, the target gray release rule is matched with a historical gray release rule corresponding to the application programming interface, and a target application programming interface that needs to be modified is determined according to a matching result, and it is determined that the target object successfully modifies the gray release rule of the target application in a case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule. The technical problem of inconvenient operation and maintenance caused by a large amount of repeated manual operation and maintenance is solved, and the release efficiency is improved.
[0089] In an example embodiment, the receiving module 44 is further configured to determine an application type of a target application to be adjusted by the target object, determine the plurality of preset gray release rules from a database corresponding to a gray release system according to the application type, and display the plurality of preset gray release rules on a target interface bound by the target object, and obtain a selection instruction triggered by the target object on the target interface, and determine a target gray release rule from the plurality of preset gray release rules according to the selection instruction.
[0090] Figure 5 is a structural block diagram of a gray release rule adjustment device according to an embodiment of the present application (two); as Figure 5 shown, in addition to all modules in the package block Figure 4 , the device further includes a request module 52, a display module 54, and a modification module 56.
[0091] The request module 52 is configured to acquire login information of a target object, determine that the target object has the permission to send a query request if the login information is verified, and request, through a backend of a gray release system, a target gateway to open an application programming interface of a target application.
[0092] The request module 52 is further configured to acquire response feedback of the target gateway to the request of the backend of the gray release system, determine to allow the target object to adjust a gray release rule corresponding to the target application through the target gateway if the response feedback indicates that the target gateway has opened the application programming interface of the target application, and determine to prohibit the target object to adjust the gray release rule corresponding to the target application through the target gateway if the response feedback indicates that the target gateway has not opened the application programming interface of the target application.
[0093] The display module 54 is configured to display a plurality of target rule conditions included in the target gray release rule on a target interface bound by the target object, and receive a confirmation result of the target object to the plurality of target rule conditions to obtain an actual gray release rule corresponding to the target gray release rule.
[0094] The modification module 56 is configured to initiate modification of a historical gray release rule in the target application programming interface if it is determined that the target object issues a modification instruction, determine a rule difference between the historical gray release rule and the target gray release rule, and modify a plurality of rule conditions corresponding to the historical gray release rule based on the rule difference.
[0095] The modification module 56 is further configured to determine a modification priority corresponding to the plurality of rule conditions, and sort the plurality of rule conditions in a modification order based on the modification priority.
[0096] Embodiments of the present application also provide a storage medium including a stored program, wherein the program performs any of the above methods when executed.
[0097] Optionally, in the present embodiment, the storage medium can be configured to store program code for performing the following steps:
[0098] S1, sending a query request carrying a screening condition to a target gateway, and acquiring a plurality of application programming interfaces for supporting gray release of a target application fed back by the target gateway;
[0099] S2, receiving a target gray release rule determined by a target object from a plurality of preset gray release rules;
[0100] S3, match the target gray release rule with the historical gray release rule corresponding to the application programming interface, and determine the target application programming interface for performing rule modification according to a matching result;
[0101] S4, in a case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule, determine that the target object successfully modifies the gray release rule corresponding to the target application.
[0102] Embodiments of the present application also provide an electronic device including a memory and a processor, the memory storing a computer program, and the processor being configured to execute the computer program to perform the steps in any of the above method embodiments.
[0103] Optionally, the electronic device described above can further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.
[0104] Optionally, in the present embodiment, the processor can be configured to perform the following steps through the computer program:
[0105] S1, sending a query request carrying a screening condition to a target gateway to obtain a plurality of application programming interfaces for supporting gray release of a target application fed back by the target gateway;
[0106] S2, receiving a target gray release rule determined by a target object from a plurality of preset gray release rules;
[0107] S3, matching the target gray release rule with the historical gray release rule corresponding to the application programming interface, and determining the target application programming interface for performing rule modification according to a matching result;
[0108] S4, in a case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule, determining that the target object successfully modifies the gray release rule corresponding to the target application.
[0109] Optionally, in the present embodiment, the storage medium can include but is not limited to a U disk, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and various media that can store program codes.
[0110] Optionally, specific examples in the present embodiment can refer to examples described in the above embodiments and optional implementation manners, and the present embodiment will not be described here again.
[0111] It is apparent that those skilled in the art can, without departing from the spirit of the present application, make various changes and modifications of the modules or steps of the present application described above, which can be implemented by general computing devices, and can be centralized on a single computing device or distributed on a network composed of multiple computing devices, and optionally, can be implemented by program codes executable by computing devices, so that they can be stored in storage devices and executed by computing devices, and in some cases, the steps shown or described can be executed in different order, or can be made into individual integrated circuit modules, or multiple modules or steps can be made into a single integrated circuit module. Thus, the present application is not limited to any particular combination of hardware and software.
[0112] The above description is only the preferred embodiments of the present application, and it should be pointed out that those skilled in the art can make several improvements and refinements without departing from the principles of the present application, and these improvements and refinements should be considered as the protection scope of the present application.
Claims
1. A method of adjusting a gray scale release rule, characterized by, The method comprises the following steps: sending a query request carrying a filtering condition to a target gateway to obtain a plurality of application programming interfaces fed back by the target gateway for supporting gray release of a target application; receiving a target gray release rule determined by a target object from a plurality of preset gray release rules; matching the target gray release rule with a historical gray release rule corresponding to the application programming interface, and determining a target application programming interface for executing rule modification according to a matching result; in a case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule, determining that the target object successfully modifies the gray release rule corresponding to the target application.
2. The method of adjusting a gray scale release rule according to claim 1, wherein, Before sending the query request carrying the filtering condition to the target gateway, the method further comprises the following steps: obtaining login information of the target object; in a case where the login information is verified, determining that the target object has the permission to send the query request; in a case where it is determined that the target object has the permission, requesting the target gateway to open the application programming interface of the target application through a backend of the gray release system.
3. The method of adjusting a gray scale release rule according to claim 2, wherein, Requesting the target gateway to open the application programming interface of the target application through the backend of the gray release system comprises the following steps: obtaining a response feedback made by the target gateway to the request of the backend of the gray release system; in a case where the response feedback indicates that the target gateway has opened the application programming interface of the target application, determining to allow the target object to adjust the gray release rule corresponding to the target application through the target gateway; in a case where the response feedback indicates that the target gateway has not opened the application programming interface of the target application, determining to prohibit the target object to adjust the gray release rule corresponding to the target application through the target gateway.
4. The method of claim 1, wherein, Receiving the target gray release rule determined by the target object from the plurality of preset gray release rules comprises the following steps: determining an application type corresponding to a target application to be adjusted by the target object; determining the plurality of preset gray release rules from a database corresponding to the gray release system according to the application type, and displaying the plurality of preset gray release rules on a target interface bound by the target object; obtaining a selection instruction triggered by the target object on the target interface, and determining a target gray release rule from the plurality of preset gray release rules by the selection instruction.
5. The method of adjusting a gray scale release rule according to claim 1, wherein, After receiving the target gray release rule determined by the target object from the plurality of preset gray release rules, the method further comprises the following step: displaying a plurality of target rule conditions included in the target gray release rule on a target interface bound by the target object; 6. The method of adjusting a gray scale release rule according to claim 1, wherein, receiving a confirmation result of the target object on the plurality of target rule conditions to obtain an actual gray release rule corresponding to the target gray release rule. After determining the target application programming interface for executing rule modification according to the matching result, the method further comprises the following steps: in a case where it is determined that the target object issues a modification instruction, initiating modification of a historical gray release rule in the target application programming interface; determining a rule difference between the historical gray release rule and the target gray release rule; The rule difference is used to modify a plurality of rule conditions corresponding to the historical gray release rule.
7. The method of adjusting a gray scale release rule according to claim 6, wherein, The rule difference is used to modify a plurality of rule conditions corresponding to the historical gray release rule, including: A modification priority corresponding to the plurality of rule conditions is determined. The plurality of rule conditions are sorted according to modification order based on the modification priority.
8. An apparatus for adjusting a gray scale release rule, the apparatus comprising: a gray scale release rule adjuster configured to adjust a gray scale release rule based on a user input. Including: A sending module configured to send a query request carrying a screening condition to a target gateway, and obtain a plurality of application programming interfaces for supporting gray release of a target application fed back by the target gateway; A receiving module configured to receive a target gray release rule determined by a target object from a plurality of preset gray release rules; A matching module configured to match the target gray release rule with a historical gray release rule corresponding to the application programming interface, and determine a target application programming interface for which a rule modification is to be performed according to a matching result; A determining module configured to determine that the target object successfully modifies a gray release rule corresponding to a target application in a case where it is determined that the gray release rule corresponding to the application programming interface is adjusted to the target gray release rule.
9. A computer readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein the program executes the method described in any one of claims 1 to 7 when executed. 10.An electronic device comprising a memory and a processor, the electronic device characterized by, The memory stores a computer program, and the processor is configured to execute the method described in any one of claims 1 to 7 by using the computer program.
Citation Information
Patent Citations
Gray release method, configuration center server, user terminal, system and medium
CN111209032A
API grayscale release method and apparatus based on cloud gateway, and computer device
WO2022100393A1