[英文]多線程IVR開發(fā)
Multithreading in IVR Development
Fouad Jennawi 2010/10/29
Multithreading is one of the very interesting subjects of programming; end users know it as the reason that keeps their computers highly responsive, and developers use it as one of the techniques to improve the performance of the products that they are developing.

Pronexus VBVoice™ Interactive Voice Response (IVR) software is multi-threaded by design. It separates, on one hand, processing channels from each other and, on the other hand, from the application code. However, the IVR application code is usually done on one thread; the thread that instantiated the VBVoice controls which is called the main thread. This same thread also instantiates and handles the GUI (Graphical User Interface) code.
As application developers started doing more asynchronous coding using multithreading, Pronexus was asked to simplify this process. This is when the WorkerThread control was added to the VBVoice’s collection of controls. WorkerThread not only offers management of a pool of user threads but it also synchronizes them with both the main thread (the thread that all application code is executing) and the particular channel thread.
Simplicity is the key here; the IVR solution developer wraps his code to be executed in a worker thread in a class that implements IVBVRunnable interface. During a call, in the WorkerThread Enter event, the application creates an object that contains the set of parameters to be passed to the worker thread and an instance of wrapper class. VBVoice will kick in the worker thread with the custom code while playing music to the caller and listening to actions, such as hanging up or keying in digits. Later, when the custom code is done, the control exits by firing its Exit event and providing any results from the worker thread plus some useful flags.
The key benefits of the WorkerThread control are:
1.IVR developers don't need to have extensive knowledge of multithreading programming and sophisticated thread synchronization which can get tricky.
2.WorkerThread suggests the recommended way of writing custom thread code which saves time.
3.It offers the best synchronization to telephony functionality.
4.It simplifies debugging, as you only have to set the WorkerThread timeout to a high value and put a break point in your custom code.
5.It is extensible, as application developers can add more threads if they need to and implement other ways of synchronization to the worker thread as well as the main thread.
Responses to “Multithreading in IVR Development”
1.Sean says:
October 28, 2010 at 1:17 pm
In my experience, IVR programmers should consider multithreading for example for any applications which will do database lookups. In particular with high-density IVR systems, channel stability can be impacted by blocking the main thread. In a telephony platform, milliseconds count, and delays on the main thread cause instability. A multithread approach in application design will ensure you have the foundation of a robust IVR.
2.KO says:
October 28, 2010 at 2:34 pm
There is a case study that talks to some of the benefits that you mention. Check out http://tinyurl.com/callcenter-casestudy. To give you an idea, a large call center was able to reduce code lines (and therefore time and costs) by 50% using multithreading to develop their dialer application.
CTI論壇報(bào)道
相關(guān)閱讀:
定襄县|
南川市|
瓦房店市|
米易县|
皮山县|
郎溪县|
灵石县|
罗平县|
尼勒克县|
米林县|
通榆县|
象山县|
古丈县|
海林市|
镇赉县|
揭阳市|
东安县|
商城县|
东光县|
永州市|
平和县|
尚志市|
阳东县|
萨嘎县|
长治县|
丽水市|
黄石市|
普宁市|
德保县|
巴南区|
枝江市|
巴彦淖尔市|
长兴县|
武强县|
肇东市|
通渭县|
苗栗县|
清流县|
海门市|
桑植县|
岳阳县|