| Article ID: | 297 |
| Last updated: | January 12, 2007 |
| User Opinions |
|
No users have voted.
|
|
Thank you for rating this answer.
|
SUMMARY
This article explains how to debug issues related to Java exceptions encountered when calling into a voice application.
SYMPTOMS
When calling into a voice application, it terminates with an error message and Java exceptions are logged in the activity and error logs.
RESOLUTION
Java exceptions are always thrown on the Call Services side and almost always indicate a problem. The errors will be logged in the application’s activity and error logs or the global error log (if the exception was thrown before reaching an application).
In most cases exceptions are thrown by custom code added to Call Services. The first step to address those issues should be to turn on stack trace logging. This will generate detailed stack trace logs for the Java exception allowing developers to locate the root cause of the problem.
However, if the stack traces are not helpful in isolating the problem, the suggested way to locate the root cause is:
- Reduce code to the bare minimum and keep only the required methods. The custom functionality should be disabled, and only required API methods for an element should be used.
- Add each code block back, one by one up to the moment when exceptions start to show up.
Additionally, custom System.out.println() statements can be added throughout the code, outputting debug messages such as sequential numbers (1, 2, 4, etc.) to trace the code execution flow in logs. The last number that is printed out should indicate where the problem occurs. Note that the printouts will be directed to your application server’s console or an application server log file.
Exceptions are logged in two places – the application’s activity logs as brief information about the exception and in the application’s error log, most likely with a full stack trace. You can use the Audium call ID from the activity log to find the matching entry in the error log.
The following articles might be helpful when debugging Java exception issues:
|