CN113923609B - Short message distribution method and device based on multiple short message channels and electronic equipment - Google Patents
Short message distribution method and device based on multiple short message channels and electronic equipment Download PDFInfo
- Publication number
- CN113923609B CN113923609B CN202111141788.4A CN202111141788A CN113923609B CN 113923609 B CN113923609 B CN 113923609B CN 202111141788 A CN202111141788 A CN 202111141788A CN 113923609 B CN113923609 B CN 113923609B
- Authority
- CN
- China
- Prior art keywords
- channel
- short message
- channels
- main channel
- standby
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 74
- 238000012544 monitoring process Methods 0.000 claims abstract description 38
- 238000005070 sampling Methods 0.000 claims description 40
- 238000012545 processing Methods 0.000 claims description 14
- 230000002159 abnormal effect Effects 0.000 claims description 10
- 238000004590 computer program Methods 0.000 claims description 7
- 230000008569 process Effects 0.000 claims description 7
- 230000004044 response Effects 0.000 claims description 6
- 238000001914 filtration Methods 0.000 claims description 4
- 238000012163 sequencing technique Methods 0.000 claims description 4
- 230000007547 defect Effects 0.000 abstract description 4
- 230000006870 function Effects 0.000 description 12
- 238000010586 diagram Methods 0.000 description 8
- 230000000694 effects Effects 0.000 description 6
- 230000015556 catabolic process Effects 0.000 description 5
- 238000006731 degradation reaction Methods 0.000 description 5
- 230000005540 biological transmission Effects 0.000 description 4
- 238000011084 recovery Methods 0.000 description 4
- 238000012360 testing method Methods 0.000 description 4
- 238000004891 communication Methods 0.000 description 3
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 238000012423 maintenance Methods 0.000 description 3
- 230000008447 perception Effects 0.000 description 3
- 238000012216 screening Methods 0.000 description 3
- 238000005034 decoration Methods 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000003287 optical effect Effects 0.000 description 2
- 238000001514 detection method Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 238000007619 statistical method Methods 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/12—Messaging; Mailboxes; Announcements
- H04W4/14—Short messaging services, e.g. short message services [SMS] or unstructured supplementary service data [USSD]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W24/00—Supervisory, monitoring or testing arrangements
- H04W24/04—Arrangements for maintaining operational condition
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W24/00—Supervisory, monitoring or testing arrangements
- H04W24/08—Testing, supervising or monitoring using real traffic
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D30/00—Reducing energy consumption in communication networks
- Y02D30/70—Reducing energy consumption in communication networks in wireless communication networks
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 short message distribution method and device based on a plurality of short message channels and electronic equipment. Wherein, the method comprises the following steps: acquiring channel route and flow ratio of each short message channel in a plurality of short message channels; dividing the short message channels into a main channel and a first standby channel according to the channel route and the flow ratio; monitoring a first arrival rate, wherein the first arrival rate is the arrival rate of a first short message sent by the main channel when the main channel is used as a current short message channel; if the first arrival rate is smaller than the arrival rate threshold, the short message flow of the main channel is transferred to the first standby channel, and the main channel is switched to a second standby channel, so that the first standby channel serves as a new main channel to send a second short message. The invention solves the technical problem of low short message distribution efficiency caused by the defect of short message channel management in the prior art.
Description
Technical Field
The invention relates to the technical field of communication, in particular to a short message distribution method and device based on a plurality of short message channels and electronic equipment.
Background
When short messages are sent in batch or in a user-defined mode, corresponding channels are generally required to be selected from a plurality of short message channels for sending the short messages, and the short message channel selection result directly images the short message sending quality, so that the user experience is influenced.
However, in the prior art, the related technical scheme of short message distribution based on multiple short message channels cannot realize effective management of the multiple short message channels, cannot accurately determine the current most effective short message channel, and thus causes the situation of short message arrival delay, a user cannot receive related short messages in time, sometimes even the situation of short message transmission failure occurs, and when a short message transmission failure state is returned, the reason analysis aiming at the short message transmission failure is lacked; in addition, in the prior art, the short message is sent only according to the load of the short message channel, so that the channel suitable for the current mobile phone number cannot be accurately selected, certain flow loss and other cost factors can be generated in the short message transmission process, and the effect of minimizing the cost cannot be achieved.
In view of the above problems, no effective solution has been proposed.
Disclosure of Invention
The embodiment of the invention provides a short message distribution method and device based on a plurality of short message channels and electronic equipment, and aims to at least solve the technical problem of low short message distribution efficiency caused by the defect of short message channel management in the prior art.
According to one aspect of the embodiment of the invention, a short message distribution method based on a plurality of short message channels is provided, which comprises the following steps: acquiring channel route and flow ratio of each short message channel in a plurality of short message channels; dividing a plurality of short message channels into a main channel and a first standby channel according to the channel route and the flow ratio; monitoring a first arrival rate, wherein the first arrival rate is the arrival rate of a first short message sent by the main channel when the main channel is used as a current short message channel; if the first arrival rate is smaller than the arrival rate threshold, the short message flow of the main channel is transferred to the first standby channel, and the main channel is switched to a second standby channel, so that the first standby channel serves as a new main channel to send a second short message.
Optionally, the obtaining of the channel route and the traffic ratio of each short message channel in the plurality of short message channels includes: acquiring a channel score of each short message channel in a plurality of short message channels; and setting a channel route for each short message channel based on the channel score, and determining the flow ratio of each short message channel.
Optionally, the obtaining a channel score of each short message channel in the multiple short message channels includes: and performing data sampling processing on the plurality of short message channels in a sliding window mode to obtain a plurality of sampling results, wherein the sampling results comprise at least one of the following results: arrival rate, arrival timeliness, arrival cost, channel restrictions, availability; and scoring the plurality of short message channels according to the sampling result to obtain the channel score of each short message channel.
Optionally, after dividing the plurality of short message channels into a main channel and a first standby channel according to the channel route and the traffic ratio, the method further includes: acquiring error code monitoring information when the main channel is used as the current short message channel; and if the error code monitoring information contains the callback error code corresponding to the main channel, marking the main channel as an abnormal channel, transferring the short message flow of the main channel to the first standby channel, and switching the main channel into a second standby channel so as to upgrade the first standby channel into a new main channel to send the second short message.
Optionally, dividing a plurality of the short message channels into a main channel and a first standby channel according to the channel route and the traffic ratio includes: determining a plurality of short message channel pools to which the short message channels belong, wherein each short message channel pool corresponds to a short message type; determining the sequencing data of a plurality of short message channels in the short message channel pool according to the channel route and the flow ratio; and determining a predetermined number of short message channels in the plurality of short message channels as the main channel and determining the rest channels in the plurality of short message channels as the first standby channel according to the sorting data.
Optionally, in a short message distribution process, filtering a first channel to be removed and a second channel to be removed from the plurality of short message channels, wherein the first channel to be removed is determined based on a channel blacklist, a region limit and a frequency limit, and the second channel to be removed is a channel which is obtained based on a load balancer and reaches a response time threshold; selecting a designated short message channel from the main channel by adopting a channel selector; if the designated short message channel is a first traffic channel, directly forwarding the first short message to the first traffic channel; and if the designated short message channel is the second traffic channel, forwarding the first short message according to a preset short message distribution rule.
Optionally, selecting a designated short message channel from the main channel by using a channel selector, including: determining a currently generated random number and a random number range to which the random number belongs, wherein the random number range comprises a plurality of random number intervals; and selecting the appointed short message channel from the main channel based on a random number interval in which the random number falls, and starting the first standby channel when the available main channel does not exist, wherein the short message distribution rule of the first standby channel is consistent with the short message distribution rule of the main channel.
Optionally, after selecting the designated short message channel from the main channel by using a channel selector, the method further includes: detecting whether the designated short message channel has manual intervention; and if the designated short message channel is manually intervened, converting the designated short message channel into a manual preset short message channel, wherein the manual preset short message channel is used for preventing the flow loss under the emergency.
Optionally, monitoring the first arrival rate comprises: receiving sending state information and callback state information from an operator, wherein the operator is used for monitoring the sending state and the callback state of the first short message sent when the main channel is used as the current short message channel; determining an arrival error code based on the sending status information and the callback status information; and calculating to obtain the first arrival rate based on the sending times of the first short message and the arrival error code.
Optionally, the arrival error code includes a retry error code, and sending the second short message by using the first backup channel upgrade as a new main channel includes: determining a retry strategy based on the retry error code, wherein the retry strategy includes at least one of: whether the current short message type touch mode can be retried or not, whether the retry times reach the limit or not, whether a retriable channel exists or not, whether the retry time is within the retriable time or not and whether the retry time exceeds the limit or not; and distributing the second short message to the new main channel according to the retry strategy so as to send the second short message by adopting the new main channel.
Optionally, the arrival error code comprises a retriable error code, and the method further comprises: and adopting a statistical mode of a sliding window, and taking the correlation indexes of the short message channels as labels, wherein the correlation indexes comprise at least one of the following indexes: fluctuation rate of arrival rate, fluctuation rate of consumed time, error proportion and fluctuation rate of arrival time; predicting a failed lane within a future time period of the sliding window based on the label; and setting the fault channel as the first standby channel.
According to another aspect of the embodiments of the present invention, there is also provided a device for distributing short messages based on multiple short message channels, including: the acquisition module is used for acquiring the channel route and the flow ratio of each short message channel in a plurality of short message channels; a dividing module, configured to divide the plurality of short message channels into a main channel and a first standby channel according to the channel route and the traffic ratio; the monitoring module is used for monitoring a first arrival rate, wherein the first arrival rate is the arrival rate of a first short message sent by the main channel when the main channel is used as a current short message channel; and the channel switching module is used for transferring the short message flow of the main channel to the first standby channel and switching the main channel into a second standby channel if the first arrival rate is smaller than the arrival rate threshold value, so that the first standby channel is used as a new main channel to send a second short message.
According to another aspect of the embodiments of the present invention, there is also provided an electronic device, including: at least one processor; and a memory communicatively coupled to the at least one processor; the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute any one of the short message distribution methods based on multiple short message channels.
According to another aspect of the embodiments of the present invention, there is also provided a non-transitory computer readable storage medium storing computer instructions, the non-transitory computer readable storage medium storing a plurality of instructions, the computer instructions being configured to cause the computer to execute any one of the above short message distribution methods based on a plurality of short message channels.
According to another aspect of the embodiments of the present invention, there is also provided a computer program product, including a computer program, where the computer program, when executed by a processor, implements any one of the above short message distribution methods based on multiple short message channels.
In the embodiment of the invention, a short message distribution mode based on a plurality of short message channels is adopted, and the channel route and the flow ratio of each short message channel in the plurality of short message channels are obtained; dividing a plurality of short message channels into a main channel and a first standby channel according to the channel route and the flow ratio; monitoring a first arrival rate, wherein the first arrival rate is the arrival rate of a first short message sent by the main channel when the main channel is used as a current short message channel; if the first arrival rate is smaller than the arrival rate threshold, the short message flow of the main channel is transferred to the first standby channel, and the main channel is switched to the second standby channel, so that the first standby channel serves as a new main channel to send a second short message, and the purpose of selecting and/or switching the short message channel based on short message channel management is achieved, the technical effects of reducing short message flow loss and reducing the short message arrival delay/failure condition are achieved, and the technical problem of low short message distribution efficiency caused by the fact that short message channel management has defects in the prior art is solved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
fig. 1 is a flowchart of a short message distribution method based on multiple short message channels according to an embodiment of the present invention;
FIG. 2 is a flowchart of an alternative short message distribution method based on multiple short message channels according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of an alternative channel score management according to an embodiment of the present invention;
FIG. 4 is a schematic diagram illustrating an alternative channel routing according to an embodiment of the present invention;
FIG. 5 is a flowchart of another alternative short message distribution method based on multiple short message channels according to an embodiment of the present invention;
FIG. 6 is a flow chart of an optional short message channel screening according to an embodiment of the present invention;
FIG. 7 is a flowchart of an alternative method for distributing short messages based on multiple short message channels according to an embodiment of the present invention;
FIG. 8 is a flowchart illustrating an alternative method for distributing short messages based on multiple short message channels according to an embodiment of the present invention;
FIG. 9 is a flow chart illustrating an alternative intelligent SMS distribution and retry logic according to an embodiment of the present invention;
fig. 10 is a schematic diagram illustrating an optional short message distribution management flow according to an embodiment of the present invention;
fig. 11 is a schematic structural diagram of a short message distribution device based on multiple short message channels according to an embodiment of the present invention.
Detailed Description
In order to make the technical solutions of the present invention better understood, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Example 1
In accordance with an embodiment of the present invention, there is provided a method for distributing short messages based on multiple short message channels, it should be noted that the steps shown in the flowchart of the drawings may be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in an order different from that shown.
Fig. 1 is a flowchart of a short message distribution method based on multiple short message channels according to an embodiment of the present invention, as shown in fig. 1, the method includes the following steps:
step S102, obtaining channel route and flow ratio of each short message channel in a plurality of short message channels;
step S104, dividing a plurality of short message channels into a main channel and a first standby channel according to the channel route and the flow ratio;
step S106, monitoring a first arrival rate;
and step S108, if the first arrival rate is smaller than the arrival rate threshold, transferring the short message flow of the main channel to the first standby channel, and switching the main channel into a second standby channel so that the first standby channel is used as a new main channel to send a second short message.
Optionally, the channel route may include, but is not limited to, a main channel and a first standby channel; the method comprises the steps of obtaining a channel score of each short message channel in a plurality of short message channels, setting a channel route for each short message channel based on the channel score, and determining the flow ratio of each short message channel; and dividing the short message channels into a main channel and a first standby channel according to the channel route and the traffic ratio, wherein the channel score is obtained by sampling data of each short message channel in a sliding window mode and scoring the channels according to scores of the channels through sampling.
Optionally, the first arrival rate is an arrival rate of a first short message sent when the main channel serves as a currently used short message channel, the main channel and the first standby channel include at least one short message channel, and when the arrival rate of each short message channel in the main channel is smaller than an arrival rate threshold, the main channel is switched to a second standby channel, so that the first standby channel serves as a new main channel to send a second short message.
Optionally, when the channel monitoring information shows that a callback error code exists in a currently used short message, that is, each short message channel in the main channel is unavailable, the main channel is switched to a second standby channel, so that the first standby channel serves as a new main channel to send a second short message.
It should be noted that, because there are many short message channels, based on the management and maintenance of the short message channels required by the user, data sampling is performed on each short message channel in a sliding window manner, based on the sampling result, a score of the short message channel is determined, then based on the score of each channel, routing rules are automatically allocated, a main channel and a standby channel and a flow ratio are set, by monitoring the real-time arrival rate of the channels, if the arrival rate is lower than a threshold value, the current channel is automatically degraded, the flow is automatically transferred to other channels, and by intelligently distributing the short message channels, maintenance and management work of the multiple channels can be better solved, so that management and maintenance are intelligentized, and the arrival rate of short messages is improved.
In the embodiment of the invention, a short message distribution mode based on a plurality of short message channels is adopted, and the channel route and the flow ratio of each short message channel in the plurality of short message channels are obtained; dividing the short message channels into a main channel and a first standby channel according to the channel route and the flow ratio; monitoring a first arrival rate, wherein the first arrival rate is the arrival rate of a first short message sent by the main channel when the main channel is used as a current short message channel; if the first arrival rate is smaller than the arrival rate threshold, the short message flow of the main channel is transferred to the first standby channel, and the main channel is switched to the second standby channel, so that the first standby channel is used as a new main channel to send a second short message, and the purpose of selecting and/or switching the short message channel based on short message channel management is achieved, and therefore the technical effects of reducing short message flow loss and reducing short message arrival delay/failure conditions are achieved, and the technical problem of low short message distribution efficiency caused by the defect of short message channel management in the prior art is solved.
In an optional embodiment, the obtaining of the channel route and the traffic ratio of each short message channel in the plurality of short message channels includes:
step S202, channel scores of each short message channel in a plurality of short message channels are obtained;
and step S204, setting channel routes for each short message channel based on the channel scores, and determining the flow ratio of each short message channel.
Optionally, a sliding window manner is adopted to perform data sampling processing on the plurality of short message channels to obtain a plurality of sampling results, and the plurality of short message channels are scored according to the sampling results to obtain a channel score of each short message channel, where the channel score processing time may be, but is not limited to, a preset time, for example, the preset time is one week, that is, channel scoring is performed once per week.
Optionally, setting a channel route for each short message channel based on the channel score includes: and sequencing the channel scores of each short message channel, selecting a preset number of short message channels with the channel scores ranked in the front row to determine the short message channels as the main channels, and taking the rest channels as first standby channels, wherein the main channels and the first standby channels comprise at least one channel.
In an optional embodiment, the obtaining the channel score of each of the plurality of short message channels includes:
step S302, a sliding window mode is adopted to carry out data sampling processing on a plurality of short message channels to obtain a plurality of sampling results;
step S304, scoring the plurality of short message channels according to the sampling result to obtain the channel score of each short message channel.
Optionally, the sampling result includes at least one of the following: arrival efficiency, arrival timeliness, arrival cost, channel restrictions, availability.
Optionally, scoring a plurality of the short message channels according to the sampling result to obtain a channel score of each short message channel includes: and acquiring each sampling result weight value, and calculating a channel score of each short message channel based on each sampling result weight value, wherein the flow ratio of each channel is the proportion of the channel score of each channel in the total score of the main channel or the standby channel.
It should be noted that, by adopting a sliding window manner, data sampling processing is performed on a plurality of short message channels to obtain a plurality of sampling results; the channel scoring mechanism established in a way of scoring a plurality of short message channels according to the sampling result to obtain the channel score of each short message channel is combined with channel related attributes (such as arrival rate, arrival time, arrival cost, channel limitation, availability and the like) to score the channels, and the intelligent management of the short message channels can be better realized according to the routing rule of the intelligently configured channels of the channel scoring result.
In an optional embodiment, after dividing the plurality of short message channels into a main channel and a first standby channel according to the channel route and the traffic ratio, the method further includes:
step S402, acquiring error code monitoring information when the main channel is used as the current short message channel;
step S404, if the error code monitoring information includes the callback error code corresponding to the main channel, marking the main channel as an abnormal channel, transferring the short message traffic of the main channel to the first backup channel, and switching the main channel to a second backup channel, so that the first backup channel is upgraded to a new main channel to send the second short message.
In this embodiment, when the channel monitoring information shows that the currently used short message has the callback error code, each short message channel in the main channel is unavailable, the main channel is marked as an abnormal channel, the main channel is degraded, that is, the short message flow of the main channel is transferred to the first standby channel, and the main channel is switched to the second standby channel, so that the first standby channel is upgraded to a new main channel to send the second short message.
As an optional embodiment, fig. 2 is a flowchart of an optional short message distribution method based on multiple short message channels according to an embodiment of the present invention, and as shown in fig. 2, dividing the multiple short message channels into a main channel and a first backup channel according to the channel route and the traffic ratio includes:
step S502, determining a plurality of short message channel pools to which the short message channels belong, wherein each short message channel pool corresponds to a short message type;
step S504, according to the above-mentioned channel route and above-mentioned flowrate match, confirm the order data in the above-mentioned message channel pool of multiple above-mentioned message channels;
step S506, according to the sorting data, determining a predetermined number of short message channels in the plurality of short message channels as the primary channel, and determining the rest of the plurality of short message channels as the first backup channel.
Optionally, the channel route may include, but is not limited to, a main channel and a first backup channel, and the channel score of each short message channel is calculated by obtaining a weight value of each sampling result and based on the weight value of each sampling result, where the traffic ratio of each channel is a ratio of the channel score of each channel to a total sum of the scores of the main channel and the backup channel.
As an alternative embodiment, fig. 3 is a schematic diagram of an alternative channel score management according to an embodiment of the present invention. As shown in fig. 3, the channel pool includes a plurality of channels (channel 1, channel 2 \ 8230; channel n), and performs data sampling processing on the plurality of short message channels in a sliding window manner to obtain a plurality of sampling results, i.e., cost, availability, arrival rate of the present period, arrival time, and obtain a weight value of each sampling result, and calculates a channel score of each short message channel based on the weight value of each sampling result. Fig. 4 is a schematic diagram illustrating an optional channel routing according to an embodiment of the present invention, and as shown in fig. 4, the short message channels are sorted based on the channel scores, a predetermined number of short message channels with channel scores ranked in the front are selected to be determined as the main channels, and the remaining channels are used as the first backup channels, and a traffic ratio of each short message channel is determined based on the score of each channel, where the traffic ratio is a ratio of the channel score of each channel to a total sum of the main channel or the backup channel scores. For example, the channels with the channel scores ranked in the first four positions (i.e., channel 1, channel 2, channel 3, and channel 4) are determined as the main channels, the channel scores of the four channels are sequentially 10, 9, 8, and 7, the sum of the channel scores in the main channel is 34, the flow ratios of the four channels are 10/34, 9/34, 8/34, and 7/34, respectively, and the configuration method of the flow ratios of the backup channels is the same as the above method.
As an alternative embodiment, fig. 5 is a flowchart of another alternative short message distribution method based on multiple short message channels according to an embodiment of the present invention, and as shown in fig. 5, the method further includes:
step S602, in the process of distributing the short message, filtering out a first channel to be eliminated and a second channel to be eliminated from a plurality of short message channels;
step S604, selecting a designated short message channel from the main channel by adopting a channel selector;
step S606, if the designated short message channel is a first traffic channel, the first short message is directly forwarded to the first traffic channel; and if the designated short message channel is the second traffic channel, forwarding the first short message according to a preset short message distribution rule.
Optionally, the first channel to be rejected is determined based on a channel blacklist, a region limit, and a frequency limit, the second channel to be rejected is determined based on a channel obtained by the load balancer and reaching a response time threshold, the response time threshold may include, but is not limited to, a query rate per second of each short message channel, and the first traffic channel may be, but is not limited to, a low traffic channel.
Optionally, the selecting, by the channel selector, a specified short message channel from the main channel includes: determining a random number generated currently and a random number range to which the random number belongs; and selecting the designated short message channel from the main channel based on the random number interval in which the random number falls, and starting the first standby channel when the available main channel does not exist, wherein the short message distribution rule of the first standby channel is consistent with the short message distribution rule of the main channel.
Optionally, the preset short message distribution rule may be, but is not limited to: when the main channel has an abnormal channel, determining that the random number range is a total scoring result of the main channel, and when the random number falls into a certain random number interval, determining that a short message channel in which the certain random number interval is positioned is an appointed short message channel; and when one or more channels in the main channel have faults or need to be eliminated, eliminating the scores of the channels with the faults or need to be eliminated, and reassigning the scores of the rest channels to the random number range. For example, the channel scores of four channels (i.e., channel 1, channel 2, channel 3, and channel 4) in the main channel are sequentially 10, 9, 8, and 7, the sum of the channel scores in the main channel is 34, when the current main channel is normal and no channel can be removed, the value range of the random number is 1-34, if the generated random number falls between 1-10, the channel 1 is hit, and if the generated random number is 11-19, the channel 2 is hit, and so on; if one of the channels fails, for example, channel 1 fails or needs to be eliminated, the range of the generated random number (9 +8+ 7) is 1-24, and if the generated random number hits 1-9, it indicates that channel 2 is hit, and so on. And when the main channel has no available channel, namely the channels 1-4 are unavailable, starting the standby channel, wherein the distribution rule of the standby channel is consistent with the distribution rule of the main channel.
It should be noted that, in the method for distributing short messages based on multiple short message channels in this embodiment, a small-flow sensing module is provided, and by marking the channel degradation times and the caused fault types in the test period, a small-flow test is periodically and automatically started for an abnormal channel meeting the conditions, that is, whether the short message channel is a small-flow channel is detected, and whether the channel fault is recovered is verified and sensed through the small flow, so that the technical effect of intelligent recovery of the channel is achieved.
In an optional embodiment, selecting a designated short message channel from the main channel by using a channel selector includes:
step S702, determining the currently generated random number and the random number range to which the random number belongs;
step S704, based on the random number interval in which the random number falls, selects the designated short message channel from the main channel, and activates the first backup channel when there is no available main channel.
Optionally, the random number range includes a plurality of random number intervals, and the short message distribution rule of the first backup channel is consistent with the short message distribution rule of the main channel.
As an alternative embodiment, fig. 6 is a flow chart of an alternative short message channel screening according to an embodiment of the present invention, and as shown in fig. 6, the flow chart of the short message channel screening includes: in the short message distribution process, channel blacklists, region limits, frequency limits and channels reaching a response time threshold are filtered from the short message channels, and a specified short message channel is selected from the main channel by adopting a channel selector; judging whether the designated channel is a small flow channel, if so, directly forwarding the first short message to the small flow channel (namely the first flow channel), otherwise, forwarding the first short message according to a preset short message distribution rule; judging whether the main channel has an abnormal channel, when the main channel does not have the abnormal channel, determining a short message channel according to a short message distribution rule of the main channel, namely determining that the random number range is a total score result of the main channel, and when the random number falls into a certain random number interval, determining that the short message channel in which the certain random number interval is located is an appointed short message channel; when the main channel has an abnormal channel, judging whether the main channel has no available channel, if so, determining a new short message distribution rule of the main channel, namely rejecting the channel score with fault or needing to be rejected, re-assigning the score sum of the other channels to the random number range, and re-assigning the random number range according to the re-assigned random number range; if the main channel is a non-available channel, judging whether a standby channel exists, if the standby channel does not exist or is unavailable, determining a short message channel by adopting a short message distribution rule of the main channel excluding the overload channel; and if the standby channel is available, determining the short message channel according to the short message distribution rule of the standby channel, wherein the short message distribution rule of the standby channel is consistent with the short message distribution rule of the main channel.
In an optional embodiment, after selecting the designated short message channel from the main channel by using the channel selector, the method further includes:
step S802, detecting whether the specified short message channel has manual intervention;
step S804, if the designated short message channel is manually intervened, the designated short message channel is converted into a manually scheduled short message channel, wherein the manually scheduled short message channel is used for preventing flow loss under an emergency.
It should be noted that, after a short message channel is designated, manual channel plan processing is performed on the designated short message channel, whether manual intervention exists in the designated short message channel is judged, and if manual intervention exists, the designated short message channel is converted into a manual preset short message channel, so that the technical effect of avoiding traffic loss caused by an emergency is achieved to the maximum extent.
As an alternative embodiment, fig. 7 is a flowchart of another alternative short message distribution method based on multiple short message channels according to an embodiment of the present invention, and as shown in fig. 7, monitoring a first arrival rate includes:
step S902, receiving sending state information and callback state information from an operator;
step S904, determining an arrival error code based on the sending status information and the callback status information;
step S906, calculating the first arrival rate based on the sending times of the first short message and the arrival error code.
Optionally, the operator is configured to monitor a sending status and a callback status of the first short message sent by the main channel when the main channel serves as the currently used short message channel.
It should be noted that the first arrival rate is calculated in real time according to the sending status information and the callback status information (i.e., the status information of the sent short message and the callback short message), the gateway status when the short message channel is called is monitored, the arrival rate information and the error code information of the main channel are obtained in real time through the arrival rate monitoring and the error code monitoring, and the arrival rate information and the error code information are given to perform channel degradation and channel recovery processing on the channel in real time.
In an optional embodiment, the arrival error code includes a retry error code, and sending the second short message by using the first backup channel upgrade as a new main channel includes:
step S1002, determining a retry strategy based on the retry-able error code;
step S1004, the second short message is distributed to the new main channel according to the retry strategy, so as to send the second short message by using the new main channel.
Optionally, the content of the retry policy includes at least one of: whether the current short message type touch mode can be retried or not, whether the retry times reach the limit or not, whether a retriable channel exists or not, whether the retry time is within the retriable time or not and whether the retry time exceeds the limit or not; the second short message is a retry short message, namely a short message capable of being redistributed.
Optionally, the retry policy may be, but not limited to, establishing a retry policy adapted to a short message type for different short message types, for example: the verification code retry strategy is set to be short messages with the sending time within 30s from the retry sending time.
It should be noted that, by receiving a callback of an operator, analyzing an operator arrival error code, and determining a retry policy for a retriable error code, the method includes: whether the current short message type touch mode can be retried or not, whether the retry times reach the limit or not, whether a retriable channel exists or not, whether the retriable time is within the retriable time or not, whether the retriable time exceeds the limit or not and the like, the retriable short message is distributed to other channels for the second time through a retrial strategy, the arrival rate of the short message is improved through the second time and multiple times of retrial, the arrival failure caused by the problem of the channel is solved, and the technical problem of short message sending failure caused by the reasons of keyword limitation, channel capacity limitation, number portability data incompleteness, a blacklist, frequency limitation, stability and the like is solved.
In this embodiment, a retry strategy is determined based on the retry error code, the second short message is distributed to the new main channel according to the retry strategy, an intelligent retry strategy is established by analyzing the arrival state of the channel short message in a manner of sending the second short message through the new main channel, and different retry strategies are established for different types of short messages, so that the problem of short message arrival failure caused by channel reasons can be eliminated to the greatest extent, and the technical effect of improving the short message arrival rate is achieved.
As an alternative embodiment, fig. 8 is a flowchart of another alternative method for distributing a short message based on multiple short message channels according to an embodiment of the present invention, where as shown in fig. 8, the arrival error code includes a retriable error code, and the method further includes:
step S1102, adopting a statistical mode of a sliding window, and taking the correlation index of the short message channel as a label;
step S1104, predicting a failure channel in a future time period of the sliding window based on the label;
step S1106 sets the failed channel as the first standby channel.
Optionally, the correlation index includes at least one of the following: fluctuation rate of arrival rate, fluctuation rate of consumed time, error ratio and fluctuation rate of arrival time.
Optionally, by using a statistical manner of a sliding window, the correlation index of the short message channel is used as a label, a failure channel in a future time period of the sliding window is predicted based on the label, and degradation processing is performed on a channel that may fail, that is, a main channel that is about to have a failure is set as a first standby channel.
In this embodiment, the statistical manner using the sliding window is to use the correlation index of the short message channel as a label; predicting a failed lane within a future time period of the sliding window based on the label; the short message distribution method for setting the fault channel as the first backup channel is realized through a perception prediction model, as shown in fig. 9, the perception prediction model predicts a channel which may have a fault in the time of a future window by using a statistical method of a sliding window and using indexes capable of reflecting channel correlation, including but not limited to arrival rate fluctuation rate, time-consuming fluctuation rate, error ratio, fluctuation rate when arriving, and the like as labels, and degrades the channel as a backup channel, so that the flow loss caused by excessive delay found through monitoring can be directly avoided, and the auxiliary capacity of a prediction and perception model module is monitored at the same time.
As an alternative embodiment, fig. 10 is a schematic diagram of an alternative short message distribution management flow according to an embodiment of the present invention, as shown in fig. 10, determining whether each channel in the primary channel set reaches an arrival rate threshold based on the arrival rate monitoring information and the error code monitoring information, and determining degradation and recovery of each channel in the primary channel set according to the determination; predicting a channel which is possibly failed in a future time period of each channel in the standby channel set based on a perceptual prediction model, and determining degradation and recovery of each channel in the standby channel set based on the prediction result, wherein the correlation index predicted by the perceptual prediction model comprises at least one of the following indexes: fluctuation rate of arrival rate, time-consuming fluctuation rate, error ratio, and fluctuation rate of arrival time. (ii) a And distributing the retriable short message to a new available short message channel based on a retry strategy so as to send the second short message by adopting the new main channel, wherein the content of the retry strategy comprises at least one of the following contents: whether the current short message type touch mode can be retried or not, whether the retry times reach the limit or not, whether a retriable channel exists or not, whether the retry time is within the retriable time or not and whether the retry time exceeds the limit or not; and detecting the standby channel through a small flow test and/or an AB test, and determining whether to restore the standby channel to the main channel set or not based on the detection result.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the invention. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required by the invention.
Through the description of the foregoing embodiments, it is clear to those skilled in the art that the method according to the foregoing embodiments may be implemented by software plus a necessary general hardware platform, and certainly may also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
Example 2
According to an embodiment of the present invention, an embodiment of an apparatus for implementing the method for distributing short messages based on multiple short message channels is further provided, and fig. 11 is a schematic structural diagram of a device for distributing short messages based on multiple short message channels according to an embodiment of the present invention, as shown in fig. 11, the device for distributing short messages based on multiple short message channels includes: an obtaining module 120, a dividing module 122, a monitoring module 124, and a channel switching module 126, where:
the obtaining module 120 is configured to obtain a channel route and a traffic ratio of each short message channel in the plurality of short message channels; the dividing module 122 is configured to divide the plurality of short message channels into a main channel and a first standby channel according to the channel route and the traffic ratio; the monitoring module 124 is configured to monitor a first arrival rate, where the first arrival rate is an arrival rate of a first short message sent by the main channel when the main channel is currently used as a short message channel; the channel switching module 126 is configured to transfer the short message traffic of the main channel to the first standby channel and switch the main channel to a second standby channel if the first arrival rate is smaller than the arrival rate threshold, so that the first standby channel serves as a new main channel to send a second short message.
It should be noted that the above modules may be implemented by software or hardware, for example, for the latter, the following may be implemented: the modules can be located in the same processor; alternatively, the modules may be located in different processors in any combination.
It should be noted here that the acquiring module 120, the dividing module 122, the monitoring module 124, and the channel switching module 126 correspond to steps S102 to S108 in embodiment 1, and the modules are the same as the corresponding steps in the implementation example and application scenario, but are not limited to the disclosure in embodiment 1. It should be noted that the modules described above may be implemented in a computer terminal as part of an apparatus.
It should be noted that, reference may be made to the relevant description in embodiment 1 for optional or preferred embodiments of this embodiment, and details are not described here again.
The short message distribution device based on multiple short message channels may further include a processor and a memory, where the obtaining module 120, the dividing module 122, the monitoring module 124, the channel switching module 126, and the like are all stored in the memory as program units, and the processor executes the program units stored in the memory to implement corresponding functions.
The processor comprises a kernel, and the kernel calls a corresponding program unit from the memory, wherein one or more than one kernel can be arranged. The memory may include volatile memory in a computer readable medium, random Access Memory (RAM) and/or nonvolatile memory such as Read Only Memory (ROM) or flash memory (flash RAM), and the memory includes at least one memory chip.
Embodiments of a non-transitory computer readable storage medium having computer instructions stored thereon are also provided according to embodiments of the present application. Optionally, in this embodiment, the computer-readable storage medium includes a stored program, where the program, when running, controls a device in which the computer-readable storage medium is located to execute any of the above short message distribution methods based on multiple short message channels.
Alternatively, in this embodiment, the non-transitory computer-readable storage medium storing the computer instructions may be located in any one of a group of computer terminals in a computer network or in any one of a group of mobile terminals, and the non-transitory computer-readable storage medium includes a stored program.
Alternatively, the apparatus in which the non-transitory computer-readable storage medium is controlled to execute the following functions when the program is executed: acquiring channel route and flow ratio of each short message channel in a plurality of short message channels; dividing the short message channels into a main channel and a first standby channel according to the channel route and the flow ratio; monitoring a first arrival rate, wherein the first arrival rate is the arrival rate of a first short message sent by the main channel when the main channel is used as a current short message channel; if the first arrival rate is smaller than the arrival rate threshold, the short message flow of the main channel is transferred to the first standby channel, and the main channel is switched to a second standby channel, so that the first standby channel serves as a new main channel to send a second short message.
Alternatively, the apparatus in which the non-transitory computer-readable storage medium is controlled to execute the following functions when the program is executed: the above obtaining the channel route and the flow ratio of each short message channel in the plurality of short message channels includes: acquiring a channel score of each short message channel in a plurality of short message channels; and setting a channel route for each short message channel based on the channel score, and determining the flow ratio of each short message channel.
Alternatively, an apparatus in which the non-transitory computer-readable storage medium is controlled when the program is executed performs the following functions: the above-mentioned channel score of obtaining each short message channel in a plurality of short message channels includes: and performing data sampling processing on the plurality of short message channels in a sliding window mode to obtain a plurality of sampling results, wherein the sampling results comprise at least one of the following: arrival rate, arrival timeliness, arrival cost, channel restrictions, availability; and scoring the plurality of short message channels according to the sampling result to obtain the channel score of each short message channel.
Alternatively, an apparatus in which the non-transitory computer-readable storage medium is controlled when the program is executed performs the following functions: after dividing the plurality of short message channels into a main channel and a first standby channel according to the channel route and the traffic ratio, the method further comprises: acquiring error code monitoring information when the main channel is used as the current short message channel; and if the error code monitoring information contains the callback error code corresponding to the main channel, marking the main channel as an abnormal channel, transferring the short message flow of the main channel to the first standby channel, and switching the main channel into a second standby channel so as to upgrade the first standby channel into a new main channel to send the second short message.
Alternatively, the apparatus in which the non-transitory computer-readable storage medium is controlled to execute the following functions when the program is executed: dividing the plurality of short message channels into a main channel and a first standby channel according to the channel route and the flow ratio, including: determining a plurality of short message channel pools to which the short message channels belong, wherein each short message channel pool corresponds to a short message type; determining the sequencing data of a plurality of short message channels in the short message channel pool according to the channel route and the flow ratio; and determining a predetermined number of short message channels in the plurality of short message channels as the main channel and the rest channels in the plurality of short message channels as the first standby channel according to the sorting data.
Alternatively, an apparatus in which the non-transitory computer-readable storage medium is controlled when the program is executed performs the following functions: in the short message distribution process, filtering a first channel to be removed and a second channel to be removed from a plurality of short message channels, wherein the first channel to be removed is determined based on a channel blacklist, a region limit and a frequency limit, and the second channel to be removed is obtained based on a load balancer and reaches a response time threshold; selecting a designated short message channel from the main channel by adopting a channel selector; if the designated short message channel is a first traffic channel, directly forwarding the first short message to the first traffic channel; and if the designated short message channel is the second traffic channel, forwarding the first short message according to a preset short message distribution rule.
Alternatively, an apparatus in which the non-transitory computer-readable storage medium is controlled when the program is executed performs the following functions: selecting a designated short message channel from the main channel by adopting a channel selector, wherein the channel selector comprises the following steps: determining a currently generated random number and a random number range to which the random number belongs, wherein the random number range comprises a plurality of random number intervals; and selecting the appointed short message channel from the main channel based on a random number interval in which the random number falls, and starting the first standby channel when the available main channel does not exist, wherein the short message distribution rule of the first standby channel is consistent with the short message distribution rule of the main channel.
Alternatively, the apparatus in which the non-transitory computer-readable storage medium is controlled to execute the following functions when the program is executed: after selecting the appointed short message channel from the main channel by adopting the channel selector, the method also comprises the following steps: detecting whether the designated short message channel has manual intervention; and if the designated short message channel is manually intervened, converting the designated short message channel into a manual preset short message channel, wherein the manual preset short message channel is used for preventing the flow loss under the emergency.
Alternatively, the apparatus in which the non-transitory computer-readable storage medium is controlled to execute the following functions when the program is executed: monitoring a first arrival rate, comprising: receiving sending state information and callback state information from an operator, wherein the operator is used for monitoring the sending state and the callback state of the first short message sent when the main channel is used as the current short message channel; determining an arrival error code based on the sending status information and the callback status information; and calculating to obtain the first arrival rate based on the sending times of the first short message and the arrival error code.
Alternatively, the apparatus in which the non-transitory computer-readable storage medium is controlled to execute the following functions when the program is executed: the above-mentioned arrival error code includes the error code of retrying, adopt the above-mentioned first standby channel to upgrade as the new main channel and send the second message, including: determining a retry strategy based on the retriable error code, wherein the retry strategy comprises at least one of: whether the current short message type touch mode can be retried or not, whether the retry times reach the limit or not, whether a retriable channel exists or not, whether the retry time is within the retriable time or not and whether the retry time exceeds the limit or not; and distributing the second short message to the new main channel according to the retry strategy so as to send the second short message by adopting the new main channel.
Alternatively, the apparatus in which the non-transitory computer-readable storage medium is controlled to execute the following functions when the program is executed: the arriving error code includes a retriable error code, and the method further includes: and adopting a statistical mode of a sliding window, and taking the correlation index of the short message channel as a label, wherein the correlation index comprises at least one of the following indexes: fluctuation rate of arrival rate, time-consuming fluctuation rate, error ratio, fluctuation rate of arrival time; predicting a failed lane within a future time period of the sliding window based on the label; and setting the fault channel as the first standby channel.
According to an embodiment of the present application, there is also provided an embodiment of a processor. Optionally, in this embodiment, the processor is configured to execute a program, where the program executes any one of the methods for distributing short messages based on multiple short message channels when running.
According to an embodiment of the present application, an embodiment of an electronic device is further provided, which includes a memory and a processor, where the memory stores a computer program, and the processor is configured to run the computer program to execute any one of the above short message distribution methods based on multiple short message channels.
According to an embodiment of the present application, there is further provided an embodiment of a computer program product, which is adapted to execute a program initialized with any of the above short message distribution method steps based on multiple short message channels when executed on a data processing device.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
In the above embodiments of the present invention, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the embodiments provided in the present application, it should be understood that the disclosed technology can be implemented in other ways. The above-described apparatus embodiments are merely illustrative, and for example, the division of the units may be a logical division, and in actual implementation, there may be another division, for example, multiple units or components may be combined or may be integrated into another system, or some features may be omitted, or may not be executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, units or modules, and may be in an electrical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one position, or may be distributed on a plurality of units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention, which is substantially or partly contributed by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a computer readable storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned computer-readable storage media comprise: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic or optical disk, and other various media capable of storing program codes.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present invention, and these modifications and decorations should also be regarded as the protection scope of the present invention.
Claims (14)
1. A short message distribution method based on a plurality of short message channels comprises the following steps:
acquiring channel route and flow ratio of each short message channel in a plurality of short message channels;
dividing the short message channels into a main channel and a first standby channel according to the channel route and the flow ratio, wherein the main channel and the first standby channel both comprise a plurality of short message channels;
monitoring a first arrival rate, wherein the first arrival rate is the arrival rate of a first short message sent by the main channel when the main channel is used as a current short message channel;
if the first arrival rate is smaller than an arrival rate threshold, transferring the short message flow of the main channel to the first standby channel, and switching the main channel into a second standby channel so that the first standby channel serves as a new main channel to send a second short message;
the method for acquiring the channel route and the flow ratio of each short message channel in the plurality of short message channels comprises the following steps:
based on a sliding window mode, carrying out data sampling processing on the plurality of short message channels to obtain a plurality of sampling results;
obtaining a weight value of each sampling result in the plurality of sampling results;
scoring the plurality of short message channels according to the weight values to obtain a channel score of each short message channel;
and setting a channel route for each short message channel based on the channel score, and determining the flow ratio of each short message channel.
2. The method of claim 1, wherein the sampling results comprise at least one of: arrival efficiency, arrival timeliness, arrival cost, channel restrictions, availability.
3. The method of claim 1, wherein after dividing the plurality of short message channels into a main channel and a first backup channel according to the channel route and the traffic proportion, the method further comprises:
acquiring error code monitoring information when the main channel is used as the current short message channel;
if the error code monitoring information contains a callback error code corresponding to the main channel, marking the main channel as an abnormal channel, transferring the short message flow of the main channel to the first standby channel, and switching the main channel into a second standby channel, so that the first standby channel is upgraded to a new main channel to send the second short message.
4. The method of claim 1, wherein dividing the plurality of short message channels into a main channel and a first backup channel according to the channel route and the traffic ratio comprises:
determining short message channel pools to which a plurality of short message channels belong, wherein each short message channel pool corresponds to one short message type;
determining the sequencing data of the short message channels in the short message channel pool according to the channel route and the flow ratio;
and determining a preset number of short message channels in the plurality of short message channels as the main channels according to the sorting data, and determining the rest channels in the plurality of short message channels as the first standby channels.
5. The method of claim 1, wherein the method further comprises:
in the short message distribution process, filtering a first channel to be removed and a second channel to be removed from a plurality of short message channels, wherein the first channel to be removed is determined based on a channel blacklist, a region limit and a frequency limit, and the second channel to be removed is a channel which reaches a response time threshold value and is obtained based on a load balancer;
selecting a designated short message channel from the main channel by adopting a channel selector;
if the appointed short message channel is a first traffic channel, directly forwarding the first short message to the first traffic channel; and if the designated short message channel is the second traffic channel, forwarding the first short message according to a preset short message distribution rule.
6. The method of claim 5, wherein selecting a designated short message channel from the main channel by using a channel selector comprises:
determining a currently generated random number and a random number range to which the random number belongs, wherein the random number range comprises a plurality of random number intervals;
and selecting the designated short message channel from the main channel based on a random number interval in which the random number falls, and starting the first standby channel when the available main channel does not exist, wherein the short message distribution rule of the first standby channel is consistent with the short message distribution rule of the main channel.
7. The method of claim 5, wherein after selecting a designated short message channel from the main channel using a channel selector, the method further comprises:
detecting whether manual intervention exists in the designated short message channel;
and if the designated short message channel is subjected to manual intervention, converting the designated short message channel into a manual preset short message channel, wherein the manual preset short message channel is used for preventing flow loss under an emergency.
8. The method of claim 5, wherein monitoring a first arrival rate comprises:
receiving sending state information and callback state information from an operator, wherein the operator is used for monitoring the sending state and the callback state of the first short message when the main channel is used as the current short message channel;
determining an arrival error code based on the sending status information and the callback status information;
and calculating to obtain the first arrival rate based on the sending times of the first short message and the arrival error code.
9. The method of claim 8, wherein the arrival error code comprises a retriable error code, and sending the second short message as a new primary channel with the first backup channel upgrade comprises:
determining a retry policy based on the retriable error code, wherein the contents of the retry policy include at least one of: whether the current short message type touch mode can be retried or not, whether the retry times reach the limit or not, whether a retriable channel exists or not, whether the retry time is within the retriable time or not and whether the retry time exceeds the limit or not;
and distributing the second short message to the new main channel according to the retry strategy so as to send the second short message by adopting the new main channel.
10. The method of claim 9, wherein the arrival error code comprises a retriable error code, the method further comprising:
and taking the correlation indexes of the short message channels as labels in a statistical mode of a sliding window, wherein the correlation indexes comprise at least one of the following indexes: fluctuation rate of arrival rate, time-consuming fluctuation rate, error ratio, fluctuation rate of arrival time;
predicting a failed lane within a future time period of the sliding window based on the label;
and setting the fault channel as the first standby channel.
11. A short message distribution device based on a plurality of short message channels comprises:
the acquisition module is used for acquiring the channel route and the flow ratio of each short message channel in a plurality of short message channels;
the dividing module is used for dividing the short message channels into a main channel and a first standby channel according to the channel route and the flow ratio, and the main channel and the first standby channel both comprise a plurality of short message channels;
the monitoring module is used for monitoring a first arrival rate, wherein the first arrival rate is the arrival rate of a first short message sent by the main channel when the main channel is used as a current short message channel;
the channel switching module is used for transferring the short message flow of the main channel to the first standby channel and switching the main channel to a second standby channel if the first arrival rate is smaller than an arrival rate threshold value, so that the first standby channel serves as a new main channel to send a second short message;
wherein, divide the module, still be used for:
based on a sliding window mode, carrying out data sampling processing on the plurality of short message channels to obtain a plurality of sampling results;
obtaining a weight value of each sampling result in the plurality of sampling results;
scoring the plurality of short message channels according to the weight values to obtain a channel score of each short message channel;
and setting a channel route for each short message channel based on the channel score, and determining the flow ratio of each short message channel.
12. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-10.
13. A non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method of any one of claims 1-10.
14. A computer program which, when executed by a processor, implements the method according to any one of claims 1-10.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111141788.4A CN113923609B (en) | 2021-09-28 | 2021-09-28 | Short message distribution method and device based on multiple short message channels and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111141788.4A CN113923609B (en) | 2021-09-28 | 2021-09-28 | Short message distribution method and device based on multiple short message channels and electronic equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113923609A CN113923609A (en) | 2022-01-11 |
CN113923609B true CN113923609B (en) | 2023-04-07 |
Family
ID=79236756
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111141788.4A Active CN113923609B (en) | 2021-09-28 | 2021-09-28 | Short message distribution method and device based on multiple short message channels and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113923609B (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115226050B (en) * | 2022-06-22 | 2024-04-19 | 百果园技术(新加坡)有限公司 | Traffic distribution method, traffic distribution device, traffic distribution apparatus, traffic distribution storage medium, and traffic distribution program product |
CN115278563B (en) * | 2022-07-28 | 2024-04-19 | 江苏苏宁银行股份有限公司 | Short message channel intelligent selection method and system based on influence factors |
CN117202117B (en) * | 2023-09-18 | 2024-04-16 | 广州市玄武无线科技股份有限公司 | System and method for fusing and degrading short message channel |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107347182A (en) * | 2016-05-04 | 2017-11-14 | 北京京东尚科信息技术有限公司 | Short message distribution method and system |
CN107567000B (en) * | 2017-09-18 | 2020-12-29 | 广东电网有限责任公司信息中心 | Method and system for intelligently selecting short message sending channel |
CN108513271B (en) * | 2018-06-22 | 2021-06-25 | 武汉斑马快跑科技有限公司 | Short message distribution method and device based on multiple short message channels |
CN109168135A (en) * | 2018-11-09 | 2019-01-08 | 上海银赛计算机科技有限公司 | Selection method, device, SMS platform and the storage medium of short message sendaisle |
CN112261596B (en) * | 2020-09-30 | 2022-07-15 | 汉海信息技术(上海)有限公司 | Short message channel resource allocation method, device, equipment and storage medium |
CN112004202A (en) * | 2020-10-29 | 2020-11-27 | 北京淇瑀信息科技有限公司 | Short message channel routing method and device and electronic equipment |
CN112654003A (en) * | 2020-12-14 | 2021-04-13 | 北京健康之家科技有限公司 | Method, device, storage medium and electronic equipment for sending message |
-
2021
- 2021-09-28 CN CN202111141788.4A patent/CN113923609B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN113923609A (en) | 2022-01-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN113923609B (en) | Short message distribution method and device based on multiple short message channels and electronic equipment | |
CN105072191B (en) | Method for determining target communication channel and server | |
CN101442762B (en) | Method and apparatus for analyzing network performance and locating network fault | |
CN102257848B (en) | Main and secondary apparatuses conversion method betwenn communication equipment, communication equipment and system, and request equipment of system and service | |
CN101084693B (en) | Method and system for policy enforcement in a communication system | |
CN109756382B (en) | Fault positioning method and device | |
EP2093935A1 (en) | Method, device and system of test access equipment configuration identification | |
CN103731866A (en) | Method and system for detecting performance of subscriber terminals | |
CN101437175A (en) | Method, apparatus and system for processing disaster-tolerating switch | |
CN106488416B (en) | Industry short message sending method and device | |
CN106488495A (en) | Base station selecting method and device based on base station signal quality | |
CN108737260A (en) | A kind of industry short message sending method, controller, interchanger and system | |
JP3097057B2 (en) | Anomaly impact assessment system for communication networks | |
EP1876787B1 (en) | Network call routing method and network calling center | |
CN113518156B (en) | Telephone switching method and device and electronic equipment | |
CN113132247B (en) | Management method, system and storage medium suitable for distributed flow collection | |
CN115002042B (en) | Special line flow control method and device based on machine learning and computer equipment | |
JPH04109728A (en) | Management equipment for communication network | |
CN112203312B (en) | Method, device and equipment for identifying problem cell and computer storage medium | |
US6393009B1 (en) | Method for managing trunk status of a CDMA mobile communication exchange | |
CN113316207B (en) | Cell switching method and device | |
JP2005252765A (en) | Network failure decision apparatus, network maintenance system, network failure decision method and program | |
CN110536328A (en) | Cell fault monitoring method and device | |
CN110309045B (en) | Method, apparatus, medium and computing device for determining future state of server | |
CN117978627A (en) | Fault positioning method and device for base station service bearing equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |