Intelligent switching method and system for multiple channels
Through intelligent evaluation and adjustment of channel priorities, combined with the self-test mechanism, the problem of manual processing delay in multi-channel environments is solved, efficiency is improved and costs is reduced, and automated channel recovery and control is achieved.
Patent Information
- Application Number
- CN202411188771.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-28
- Publication Date
- 2024-12-13
AI Technical Summary
In a multi-channel environment, manual failure to deal with product abnormalities in time will result in recovery delays, low processing efficiency, affecting business operations, and lack of automated priority adjustment and recovery mechanisms.
By evaluating the stability, technical capabilities and costs of each channel, prioritize, and set trigger rules according to abnormal situations, intelligently adjust channel priority, create self-test tasks, detect recovery situations regularly, and restore the original priority after normal recovery, class.
It realizes the priority adjustment and recovery of automated channel without manual intervention, improves work efficiency, reduces labor costs, and provides a unified channel management method.
Smart Images

Figure CN119127589A_ABST
Abstract
Description
Technical Field
[0001] This document relates to the field of computer technology, and more particularly to a method and system for intelligent switching of multiple channels. Background Art
[0002] At present, due to the diversity of products on the market, each product has its own advantages and disadvantages. We need to prioritize the use of products according to their advantages and disadvantages, and give priority to products that we think are more in line with the requirements; when a product has a problem during use, we need to switch to the next product in time to ensure the normal operation of the business and repair the problematic product at the same time. Since we prefer to give priority to the use of better products, we need to resume use of the product as soon as possible after the product is repaired. In this process, there are often problems such as manual failure to handle product anomalies in a timely manner, and failure to be aware of and resume use in a timely manner after recovery, and low processing efficiency, which affects business use. Summary of the invention
[0003] One or more embodiments of this specification provide a multi-channel intelligent switching method, including:
[0004] Evaluate each channel based on its stability, technical capabilities, and cost, and prioritize the channels based on the evaluation results from best to worst;
[0005] According to different abnormal situations of the channel, set the channel abnormality collection and trigger rule pool;
[0006] Based on the actual abnormal situation and rules of the channel, determine the trigger channel priority adjustment and adjust the priority of the abnormal channel to the lowest;
[0007] Create a channel self-check task to periodically detect channel recovery. When the channel returns to normal, the self-check task ends and the original multi-channel priority is restored.
[0008] Furthermore, the abnormal situation is obtained by classifying according to the channel return error, including any one or more of request timeout, other exceptions and return errors; the channel exception set includes the channel number, exception code and cumulative number of exceptions; the rule pool sets the rules for triggering channel priority adjustment according to different channels and exception returns, that is, sets the rule pool.
[0009] Furthermore, the triggering rules of the rule pool include immediate triggering and triggering by sequence; the immediate triggering means triggering the channel priority adjustment immediately when an exception occurs; the triggering by sequence means setting the number of triggers, and triggering the channel priority adjustment by setting X consecutive or X cumulative exceptions, and setting corresponding triggering rules according to different channels.
[0010] Furthermore, the channel priority adjustment is to adjust the priority of the abnormal channel to the lowest according to the current priority ranking of the channel, so as to poll;
[0011] Based on the actual abnormal situation of the channel and the trigger rules, the trigger channel priority is intelligently adjusted.
[0012] Furthermore, after the channel priority is adjusted intelligently, the creation of a channel self-check task is immediately triggered;
[0013] The channel self-check task continuously detects the recovery of the abnormal channel according to the self-check rules in the self-check rule pool. When the channel returns to normal, the priority of the channel is adjusted, the priority sorting of the channel is restored to the original state, and the abnormal set of the channel is cleared.
[0014] Furthermore, the self-checking rules may define self-checking modes, self-checking cycles and self-checking times according to different channels, and set a self-checking rule pool; wherein the self-checking mode includes an interface request;
[0015] The interface request specifically includes: regularly requesting the abnormal interface at a certain time period or a certain time point, and when the request is successful, the self-check task is completed;
[0016] After the self-test task is completed, the priority order of the channel is restored to the original state, and the self-test task status of the channel is adjusted to the completed state.
[0017] Furthermore, the specific method for evaluating the channels according to the stability, technical capabilities and cost of each channel is as follows:
[0018] The stability of the channel is judged according to the error rate of the channel. The lower the error rate, the stronger the stability.
[0019] The technical capability of a channel is determined by whether it meets business demand scenarios. The more scenarios it can meet, the stronger its technical capability is.
[0020] The cost of the channel is evaluated by judging the price of the channel. The higher the price, the higher the cost, and the lower the price, the lower the cost.
[0021] One or more embodiments of this specification provide a multi-channel intelligent switching system, including:
[0022] Channel sorting module: used to evaluate the channels according to their stability, technical capabilities and channel costs, and prioritize the channels according to the evaluation results from best to worst;
[0023] Rule setting module: used to set channel exception collection and trigger rule pool according to different abnormal situations of channels;
[0024] Priority adjustment module: used to determine the trigger channel priority adjustment based on the actual abnormal situation and rules of the channel, and adjust the priority of the abnormal channel to the lowest;
[0025] Recovery module: used to create channel self-check tasks and regularly detect channel recovery status. When the channel returns to normal, the self-check task ends and the original multi-channel priority is restored.
[0026] One or more embodiments of the present specification provide an electronic device, including a processor; and,
[0027] A memory is arranged to store computer executable instructions, which, when executed, enable the processor to implement the steps of the above-mentioned intelligent switching method for multiple channels.
[0028] One or more embodiments of the present specification provide a storage medium for storing computer executable instructions, wherein the computer executable instructions implement the steps of the above-mentioned intelligent switching method for multiple channels when executed.
[0029] By adopting the embodiments of the present invention, when using multiple channels, there is no need to manually troubleshoot problems and manually adjust the priority of channel use. The channel recovery status can be known in time and the channel priority sorting can be restored, which improves work efficiency and can provide a unified channel management and control method in different environments, reducing labor costs.
[0030] The above description is only an overview of the technical solution of the present invention. In order to more clearly understand the technical means of the present invention, it can be implemented according to the contents of the specification. In order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] In order to more clearly illustrate one or more embodiments of this specification or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0032] Figure 1 A flowchart of a multi-channel intelligent switching method provided for one or more embodiments of this specification;
[0033] Figure 2 A flow chart of channel abnormality and triggering intelligent adjustment of channel priority provided in one or more embodiments of this specification;
[0034] Figure 3A flow chart for calling a channel according to a new priority after intelligent adjustment of one or more embodiments of this specification;
[0035] Figure 4 A flow chart of channel self-check and channel priority restoration provided for one or more embodiments of this specification;
[0036] Figure 5 A flow chart for calling after channel priority restoration provided in one or more embodiments of this specification;
[0037] Figure 6 A schematic diagram of a composition of a multi-channel intelligent switching system provided in one or more embodiments of this specification;
[0038] Figure 7 A schematic diagram of the structure of an electronic device provided for one or more embodiments of this specification. DETAILED DESCRIPTION
[0039] In order to enable those skilled in the art to better understand the technical solutions in one or more embodiments of this specification, the following will be combined with the drawings in one or more embodiments of this specification to clearly and completely describe the technical solutions in one or more embodiments of this specification. Obviously, the described embodiments are only part of the embodiments of this specification, not all of the embodiments. Based on one or more embodiments of this specification, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this document.
[0040] Method Embodiment
[0041] According to an embodiment of the present invention, a smart switching method for multiple channels is provided. Figure 1 A flowchart of a multi-channel intelligent switching method provided in one or more embodiments of this specification, such as Figure 1 As shown, the intelligent switching method for multiple channels according to an embodiment of the present invention specifically includes:
[0042] S1. Evaluate each channel based on its stability, technical capabilities, and channel costs, and prioritize the channels based on the evaluation results from best to worst.
[0043] Specifically, the stability of the channel is determined by the error rate of the channel. The lower the error rate, the stronger the stability. The technical capability of the channel is determined by whether the channel meets the business demand scenarios. The more scenarios that can be met, the stronger the technical capability. The cost of the channel is evaluated by judging the price of the channel. The higher the price, the higher the cost, and the lower the price, the lower the cost. After sorting the channels according to priority, the channel is called according to the channel priority sorting.
[0044] S2. According to different abnormal situations of the channel, set the channel exception set and trigger rule pool.
[0045] Among them, the different exception conditions returned by each channel call are classified according to the channel return errors. In this embodiment, the channel exception conditions include any one or more of request timeout, other exceptions and other return errors; the channel exception set includes the channel number, exception code and exception information, including the cumulative number of exceptions; the rule pool sets the rules for triggering channel priority adjustment according to different channels and exception returns, that is, sets the rule pool.
[0046] The triggering rules of the rule pool include immediate triggering and triggering by sequence; the immediate triggering means triggering the channel priority adjustment immediately when an exception occurs; the triggering by sequence means setting the number of triggers, and triggering the channel priority adjustment by setting X consecutive or cumulative exceptions, and setting corresponding triggering rules according to different channels.
[0047] S3. Based on the actual abnormal situation and rules of the channel, determine the trigger channel priority adjustment and adjust the priority of the abnormal channel to the lowest.
[0048] The channel priority adjustment is to adjust the abnormal channel priority to the lowest and the normal channel priority to a higher priority according to the current channel priority, and poll in this way; the priority adjustment is not limited to a single switch, but also applies to multiple intelligent switches of multiple channels.
[0049] Based on the actual abnormal situation of the channel, that is, the abnormal set, the trigger channel priority is determined to be intelligently adjusted according to the trigger rules.
[0050] Figure 2 and Figure 3 The flowcharts of channel abnormality and triggering channel priority intelligent adjustment and the flowchart of calling according to the new priority after the channel intelligent adjustment are provided in one or more embodiments of this specification, such as Figure 2 , 3 As shown, assume that the original priority of the channel is ABC, call channel A according to the channel priority, and judge whether the call is successful according to the returned result. If successful, return the call completion result. If failed, query the call failure record according to the rule pool to judge whether it meets the trigger priority adjustment rule. If it meets the rule, adjust the priority of the channel that failed to call to the lowest. After adjustment, the new priority becomes BCA. After the channel priority is intelligently adjusted, the channel self-check task is triggered. After the call of channel A fails, continue to call channel B according to the priority order. The process is the same as above. S4. Create a channel self-check task, regularly detect the channel recovery status, and when the channel returns to normal, the self-check task ends and the original multi-channel priority is restored.
[0051] After the channel priority is adjusted intelligently, the channel self-check task is immediately triggered.
[0052] The channel self-check task is to continuously detect the recovery of abnormal channels according to the self-check rules in the self-check rule pool. When the channel returns to normal, the priority of the channel is adjusted, the priority sorting of the channel is restored to the original state, and the abnormal set of the channel is cleared.
[0053] The self-checking rules can define the self-checking mode, self-checking cycle and self-checking time according to different channels, and set the self-checking rule pool; wherein, the self-checking mode includes interface request. The interface request is: regularly requesting the abnormal interface in a certain time period or a certain time point, and when the request is successful, the self-checking task is completed.
[0054] After the self-test task is completed, the channel priority order is restored to the original order, and the self-test task status of the channel is adjusted to the completed status to solve the current channel abnormality. The system intelligently adjusts the channel priority without manual intervention to ensure the normal use of the product. The technical problem, as well as the business problem of intelligently reducing costs by prioritizing low-cost channels.
[0055] Figure 4 , 5 A flow chart of channel self-check and channel priority restoration and a flow chart of calling after channel priority restoration are provided for one or more embodiments of this specification, such as Figure 4 , 5 As shown in the figure, after creating a self-check task, self-check is performed according to the self-check rules. The self-check cycle and self-check time can be configured. An attempt is made to call the abnormal channel and the call result is returned. If the call fails, the self-check continues. If the call succeeds, the self-check task ends, the channel recovery program is notified, and the initial priority of the channel is restored.
[0056] The beneficial effects of the present invention are as follows:
[0057] By adopting the embodiments of the present invention, when using multiple channels, there is no need to manually troubleshoot problems and manually adjust the priority of channel use. The channel recovery status can be known in time and the channel priority sorting can be restored, which improves work efficiency and can provide a unified channel management and control method in different environments, reducing labor costs.
[0058] System Example
[0059] According to an embodiment of the present invention, a multi-channel intelligent switching system is provided. Figure 6 A schematic diagram of a multi-channel intelligent switching system provided in one or more embodiments of this specification, such as Figure 6 As shown, the intelligent switching system for multiple channels according to an embodiment of the present invention specifically includes:
[0060] Channel sorting module 60: used to evaluate the channels according to the stability, technical capabilities and cost of each channel, and sort the channels by priority according to the evaluation results in descending order;
[0061] Rule setting module 62: used to set channel exception set and trigger rule pool according to different abnormal conditions of the channel;
[0062] Priority adjustment module 64: used to determine the trigger channel priority adjustment based on the actual abnormal situation of the channel and the rules, and adjust the priority of the abnormal channel to the lowest;
[0063] Recovery module 66: used to create a channel self-check task, regularly detect the channel recovery status, and when the channel returns to normal, the self-check task ends and the original multi-channel priority is restored.
[0064] The embodiment of the present invention is a system embodiment corresponding to the above-mentioned method embodiment. The specific operations of each module can be understood by referring to the description of the method embodiment, which will not be repeated here.
[0065] Device Example 1
[0066] An embodiment of the present invention provides an electronic device, such as Figure 7 As shown, it includes: a memory 70, a processor 72, and a computer program stored in the memory 70 and executable on the processor 72. When the computer program is executed by the processor 72, the following method steps are implemented:
[0067] S1. Evaluate the channels according to their stability, technical capabilities, and channel costs, and prioritize the channels according to the evaluation results from best to worst;
[0068] S2. Set channel exception collection and trigger rule pool according to different abnormal situations of the channel;
[0069] S3. Based on the actual abnormal situation and rules of the channel, determine the trigger channel priority adjustment and adjust the priority of the abnormal channel to the lowest;
[0070] S4. Create a channel self-check task to periodically check the channel recovery status. When the channel returns to normal, the self-check task ends and the original multi-channel priority is restored.
[0071] Device Example 2
[0072] An embodiment of the present invention provides a computer-readable storage medium, on which a program for implementing information transmission is stored. When the program is executed by the processor 72, the following method steps are implemented:
[0073] S1. Evaluate the channels according to their stability, technical capabilities, and channel costs, and prioritize the channels according to the evaluation results from best to worst;
[0074] S2. Set channel exception collection and trigger rule pool according to different abnormal situations of the channel;
[0075] S3. Based on the actual abnormal situation and rules of the channel, determine the trigger channel priority adjustment and adjust the priority of the abnormal channel to the lowest;
[0076] S4. Create a channel self-check task to periodically check the channel recovery status. When the channel returns to normal, the self-check task ends and the original multi-channel priority is restored.
[0077] The computer-readable storage medium in this embodiment includes, but is not limited to, ROM, RAM, magnetic disk or optical disk, etc.
[0078] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A multi-channel intelligent switching method, characterized in that: include: Evaluate each channel based on its stability, technical capabilities, and cost, and prioritize the channels based on the evaluation results from best to worst; According to different abnormal situations of the channel, set the channel exception collection and trigger rule pool; Based on the actual abnormal situation and rules of the channel, determine the trigger channel priority adjustment and adjust the priority of the abnormal channel to the lowest; Create a channel self-check task to periodically detect channel recovery. When the channel returns to normal, the self-check task ends and the original multi-channel priority is restored.
2. The method according to claim 1, characterized in that The abnormal situation is obtained by classifying the channel return error, including any one or more of request timeout, other exceptions and return errors; the channel exception set includes the channel number, exception code and cumulative number of exceptions; the rule pool sets the rules for triggering channel priority adjustment according to different channels and exception returns, that is, sets the rule pool.
3. The method according to claim 2, characterized in that The triggering rules of the rule pool include immediate triggering and triggering by sequence; the immediate triggering means triggering the channel priority adjustment immediately when an exception occurs; the triggering by sequence means setting the number of triggers, and triggering the channel priority adjustment by setting X consecutive or X cumulative exceptions, and setting corresponding triggering rules according to different channels.
4. The method according to claim 1, characterized in that: The channel priority adjustment is to adjust the priority of the abnormal channel to the lowest according to the current priority order of the channel, and then poll; Based on the actual abnormal situation of the channel and the trigger rules, the priority of the trigger channel is intelligently adjusted.
5. The method according to claim 1, characterized in that After the channel priority is adjusted intelligently, the channel self-check task is immediately triggered; The channel self-check task continuously detects the recovery of the abnormal channel according to the self-check rules in the self-check rule pool. When the channel returns to normal, the priority of the channel is adjusted, the priority sorting of the channel is restored to the original state, and the abnormal set of the channel is cleared.
6. The method according to claim 5, characterized in that The self-checking rules can define the self-checking mode, self-checking cycle and self-checking time according to different channels, and set the self-checking rule pool; wherein, the self-checking mode includes an interface request; The interface request specifically includes: regularly requesting the abnormal interface at a certain time period or a certain time point, and when the request is successful, the self-check task is completed; After the self-test task is completed, the priority order of the channel is restored to the original state, and the self-test task status of the channel is adjusted to the completed state.
7. The method according to claim 1, characterized in that The specific method for evaluating the channels according to the stability, technical capabilities and cost of each channel is as follows: The stability of the channel is judged according to the error rate of the channel. The lower the error rate, the stronger the stability. The technical capability of a channel is determined by whether it meets the business requirements. The more scenarios it can meet, the stronger its technical capability is. The cost of the channel is evaluated by judging the price of the channel. The higher the price, the higher the cost, and the lower the price, the lower the cost.
8. An intelligent switching system for multiple channels, characterized in that: include: Channel sorting module: used to evaluate the channels according to their stability, technical capabilities and channel costs, and prioritize the channels according to the evaluation results from best to worst; Rule setting module: used to set channel exception collection and trigger rule pool according to different abnormal situations of channels; Priority adjustment module: used to determine the trigger channel priority adjustment based on the actual abnormal situation and rules of the channel, and adjust the priority of the abnormal channel to the lowest; Recovery module: used to create channel self-check tasks and regularly detect channel recovery status. When the channel returns to normal, the self-check task ends and the original multi-channel priority is restored.
9. An electronic device, characterized in that: include: processor; as well as, A memory arranged to store computer executable instructions, wherein when the computer executable instructions are executed, the processor implements the steps of the intelligent switching method for multiple channels as claimed in any one of claims 1 to 7.
10. A storage medium, characterized in that: Used to store computer executable instructions, which, when executed, implement the steps of the intelligent switching method for multiple channels as claimed in any one of claims 1 to 7.
