Scriptable Routing Engine

From TBwiki
(Difference between revisions)
Jump to: navigation, search
(replace old steps with script pool)
Line 76: Line 76:
  
 
*[[Routing script tutorial]]
 
*[[Routing script tutorial]]
 +
 +
[[Category:Needs revising‏‎]]

Revision as of 11:10, 5 March 2013

Toolpack v2.3 introduces a scriptable routing engine that complements the existing approach to building call routes. This new approach is based on the Ruby programming language, which offers a high-level, natural language-like approach to programming known as scripting. With Ruby, no code compilation is required to use routing scripts; in fact, you write scripts within your web browser. A high-level overview of how to write scripts is available upon request by contacting the TelcoBridges support team.

As part of the initial release, TelcoBridges is providing a number of ready-to-use scripts such as percentage routing, round-robin routing, least-cost routing, SIP trunking, PRI reselling with over-subscription, etc., with additional scripts to be made available as we go forward. This new approach is meant to supplement the current approach to building routes. It should also make it possible for your service provider customers, once properly trained by you, to modify routing tables on their own.


Contents

Prerequisites

There is no additional software required to use the scriptable routing engine. All necessary software is installed by the Toolpack installer application. While the Ruby language is natural language-like and easily approachable, some understanding of programming or Ruby is required in order to modify existing scripts. The Ruby scripts provided with Toolpack essentially consist of a series of mini scripts or sub-scripts (akin to classes in C++); therefore creating a script from scratch does require more experience. Please see the Ruby site for additional information on Ruby. That site features a helpful tutorial called “Ruby in 20 minutes”. There is also a section called “Ruby from Other Languages” which will help you understand Ruby if your frame of reference is C++, Java, or a scripting language such as Perl, PHP, or Python.

The Toolpack scriptable routing engine is based on the 1.8.x branch of Ruby.


Script routing overview

The Scriptable Routing Engine is asked, for every incoming call leg, to take a routing decision which indicates how the outgoing call leg must be created. The script will match one or multiple routes based on information from the incoming call leg

  • calling number
  • called number
  • NAP

Each route determines NAP to use to make outgoing call, and may modify some of the call parameters:

  • calling number
  • called number
  • nature of address
  • numbering plan
  • calling presentation
  • etc.

Multiple routes can match a given incoming call, in which case routes can be sorted using various criteria:

  • round robin
  • least cost
  • availability percent
  • etc.

An outgoing call will be made based on the first matching route. If this call fails with that route (maximum capacity reached, network or protocol error), another outgoing call attempt will be made using the next matching route. Note: This Route retry feature is available only in Toolpack version 2.5 and up.

Routing script pool

TelcoBridges provide a wide variety of routing script examples which customers can apply directly in their web configuration according to their needs by following just a few simple steps.

Tutorial guide

To learn how to use the Scriptable Routing Engine, click the following link to go to the Script Routing Tutorial.


Mini development guide

To learn about the parameters available in for each object go read the Script Routing Mini Development Guide.


Testing this feature

To test this feature, you will want to modify some of the provided scripts by changing variables such as route costing or NAP targets.


Known limitations

The following are known limitations with the Scriptable Routing Engine as of version 2.5:

  • Scripts (including script sub-components provided by TelcoBridges) are not modified when Toolpack is upgraded to new version (for example, to the release version of v2.3.0, v2.3.1, etc.). This means that if there is an update (bug fix) of the basic script, you will need to manually update any existing scripts.
  • If you are using dynamic fields (using the Creating New Route Column or the Create New Nap Column option) with routing scripts and you plan to use NAP names, those NAP names need to be all capital letters (i.e.: not just the first letter needs to be capitalized.)


References

Personal tools