Difference between revisions of "Routing by Percent"
Line 2: | Line 2: | ||
This type of routing | This type of routing selects a route by percentage value of Providers. | ||
It is similar to Priority based routing except that here Providers are selected randomly with greater or lesser probability. | It is similar to Priority-based routing, except that here Providers are selected randomly with greater or lesser probability. | ||
[[Image:route_by_percent.png]] | [[Image:route_by_percent.png]] | ||
Line 11: | Line 11: | ||
== Example 1 == | == Example 1 == | ||
For example we have | For example, we have three providers with the following preferences: | ||
A - 50% | A - 50% | ||
Line 17: | Line 17: | ||
C - 20% | C - 20% | ||
This means that: | |||
* Provider A '''will be chosen FIRST''' with 50% probability | * Provider A '''will be chosen FIRST''' with 50% probability. | ||
* Provider B '''will be chosen FIRST''' with 30% probability | * Provider B '''will be chosen FIRST''' with 30% probability. | ||
* Provider C '''will be chosen FIRST''' with 20% probability | * Provider C '''will be chosen FIRST''' with 20% probability. | ||
MOR orders these | MOR orders these providers using the following algorithm: | ||
As a first step, it randomly selects the first provider. There is a 50% chance that Provider A will be selected, 30% for B, and 20% for C. | |||
Lets say randomly selected Provider is B. | Lets say the randomly selected Provider is B. | ||
At the second step MOR selects from remaining | At the second step, MOR selects from the remaining providers: | ||
A - 50% | A - 50% | ||
C - 20% | C - 20% | ||
There is a much greater chance that A will be randomly selected than C. So let's say A is selected. | |||
The final order of our providers will be: | |||
B - A - C | B - A - C | ||
Every time order is RANDOMLY | Every time, the order is RANDOMLY done in the same way, using percent values for probability. | ||
So we can get various results, such as A-B-C, A-C-B, B-A-C, C-A-B etc | So we can get various results, such as A-B-C, A-C-B, B-A-C, C-A-B etc. BUT, following mathematical reasoning, when we make a huge amount of tries (going till infinity), sets will follow the rule in the first step: the Provider selected first will be A in 50% of the cases, B in 30%, and C in 20%. | ||
== Example 2 == | == Example 2 == | ||
To better illustrate the method, | To better illustrate the method, let's take a simpler situation. We have two providers with these percentages: | ||
A - 99% | A - 99% | ||
B - 1% | B - 1% | ||
Now Provider A will be selected first 99% of the time, | Now Provider A will be selected first 99% of the time, so that when we have many ordered lists, they will look like: | ||
A-B, A-B, A-B, A-B, A-B, ........., '''B-A''', A-B,........A-B, .......... | A-B, A-B, A-B, A-B, A-B, ........., '''B-A''', A-B,........A-B, .......... | ||
The probability that the provider order will be B-A is just 1%. | |||
Line 63: | Line 63: | ||
This LCR ordering still keeps Fail-Over intact. | This LCR ordering still keeps Fail-Over intact. | ||
That is, after we have ordered the Provider list, if the first Provider in the list fails, the second will be dialed and so on. |
Revision as of 01:23, 16 May 2010
This functionality is available from MOR 8.
This type of routing selects a route by percentage value of Providers.
It is similar to Priority-based routing, except that here Providers are selected randomly with greater or lesser probability.
Example 1
For example, we have three providers with the following preferences:
A - 50% B - 30% C - 20%
This means that:
- Provider A will be chosen FIRST with 50% probability.
- Provider B will be chosen FIRST with 30% probability.
- Provider C will be chosen FIRST with 20% probability.
MOR orders these providers using the following algorithm:
As a first step, it randomly selects the first provider. There is a 50% chance that Provider A will be selected, 30% for B, and 20% for C.
Lets say the randomly selected Provider is B.
At the second step, MOR selects from the remaining providers:
A - 50% C - 20%
There is a much greater chance that A will be randomly selected than C. So let's say A is selected.
The final order of our providers will be:
B - A - C
Every time, the order is RANDOMLY done in the same way, using percent values for probability.
So we can get various results, such as A-B-C, A-C-B, B-A-C, C-A-B etc. BUT, following mathematical reasoning, when we make a huge amount of tries (going till infinity), sets will follow the rule in the first step: the Provider selected first will be A in 50% of the cases, B in 30%, and C in 20%.
Example 2
To better illustrate the method, let's take a simpler situation. We have two providers with these percentages:
A - 99% B - 1%
Now Provider A will be selected first 99% of the time, so that when we have many ordered lists, they will look like:
A-B, A-B, A-B, A-B, A-B, ........., B-A, A-B,........A-B, ..........
The probability that the provider order will be B-A is just 1%.
Fail-over
This LCR ordering still keeps Fail-Over intact.
That is, after we have ordered the Provider list, if the first Provider in the list fails, the second will be dialed and so on.