Your browser does not support JavaScript!
http://iet.metastore.ingenta.com
1887

Hidden truth behind .NET's exception handling today

Hidden truth behind .NET's exception handling today

For access to this article, please select a purchase option:

Buy article PDF
£12.50
(plus tax if applicable)
Buy Knowledge Pack
10 articles for £75.00
(plus taxes if applicable)

IET members benefit from discounts to all IET publications and free access to E&T Magazine. If you are an IET member, log in to your account and the discounts will automatically be applied.

Learn more about IET membership 

Recommend Title Publication to library

You must fill out fields marked with: *

Librarian details
Name:*
Email:*
Your details
Name:*
Email:*
Department:*
Why are you recommending this title?
Select reason:
 
 
 
 
 
IET Software — Recommend this title to your library

Thank you

Your recommendation has been sent to your librarian.

The emergence of exception handling (EH) mechanisms in modern programming languages made available a different way of communicating errors between procedures. For years, programmers trusted in correct documentation of error codes returned by procedures to correctly handle erroneous situations. Now, they have to focus on the documentation of exceptions for the same effect. But to what extent can exception documentation be trusted? Moreover, is there enough documentation for exceptions? And in what way do these questions relate to the discussion on checked against unchecked exceptions? For a given set of Microsoft .NET applications, code and documentation were thoroughly parsed and compared. This showed that exception documentation tends to be scarce. In particular, it showed that 90% of exceptions are undocumented. Furthermore, programmers were demonstrated to be keener to document exceptions they explicitly throw while typically leaving exceptions resulting from method calls undocumented. This conclusion lead to another question: how do programmers use the EH mechanisms available in modern programming languages? More than 16 different .NET applications were examined in order to provide an answer. The major conclusion of this work is that exceptions are not being correctly used as an error-handling mechanism. These results contribute to the assessment of the effectiveness of the unchecked exceptions approach.

References

    1. 1)
      • ‘Javadoc tool home page’, available at: http://java.sun.com/j2se/javadoc/.
    2. 2)
      • Fu, C., Martin, R.P., Nagaraja, K., Nguyen, T.D., Ryder, B., Wonnacott, D.: `Compiler-directed program-fault coverage for highly available Java internet services', Proc. 2003 Int. Conf. Dependable Systems and Networks (DSN ’03), 2003, IEEE Press.
    3. 3)
      • Cabral, B., Marques, P.: `Making exception handling work', Proc. Workshop on Hot Topics in System Dependability (HotDep'06), November 2006, USENIX, Seattle, USA.
    4. 4)
      • Gosling, J., Joy, B., Steele, G., Bracha, G.: `The Java language specification', Sun Microsystems, Inc., 2000, Mountain View, California, USA, ISBN 0-201-31008-21.
    5. 5)
      • F.P. Brooks . (1995) The mythical man-month.
    6. 6)
      • ‘Sourceforge.net’, available at: http://sf.net.
    7. 7)
      • S. Sinha , M. Harrold . Analysis and testing of programs with exception-handling constructs. IEEE Trans. Softw. Eng. , 9 , 849 - 871
    8. 8)
      • Cheng, Y.C., Chen, C., Jwo, J.: `Exception handling: an architecture model and utility support', Proc. 12th Asia-Pacific Software Engineering Conf. (APSEC'05), December 2005, Taiwan, China.
    9. 9)
      • ‘Visual studio home’, available at: http://msdn.microsoft.com/vstudio/.
    10. 10)
      • Miller, R., Tripathi, A.: `Issues with exception handling in object-oriented systems', Proc. ECOOP'97, LNCS 1241, 1997, Springer-Verlag, p. 85–103.
    11. 11)
      • ‘The Microsoft shared source CLI implementation’, available at: http://msdn.microsoft.com/net/sscli.
    12. 12)
      • DeVale, J., Koopman, P.: `Robust software – no more excuses', Proc. Int. Conf. Dependable Systems and Networks 2002 (DSN'02), 2002, IEEE Press.
    13. 13)
      • ‘Ruby home page’, available at: http://www.ruby-lang.org.
    14. 14)
      • SharpZipLib, The Zip, GZip, BZip2 and Tar Implementation For .NET', available at: http://www.icsharpcode.net/OpenSource/SharpZipLib/Default.aspx.
    15. 15)
      • R.A. Maxion , R.T. Olszewski . Eliminating exception handling errors with dependability cases: a comparative, empirical study. IEEE Trans. Softw. Eng. , 9 , 888 - 906
    16. 16)
      • Candea, G., Delgado, M., Chen, M., Fox, A.: `Automatic failure-path inference: a generic introspection technique for internet applications', Proc. 3rd IEEE Workshop on Internet Applications (WIAPP), 2003, IEEE Press.
    17. 17)
      • Ferreira, G.R.M., Rubira, C.M.F., Lemos, R.: `Explicit representation of exception handling in the development of dependable component-based systems', Proc. 6th IEEE Int. Symp. High Assurance Systems Engineering (HASE'01), 2001, IEEE Press.
    18. 18)
      • Cabral, B., Marques, P., Silva, L.: `RAIL: code instrumentation for .NET', Proc. 2005 ACM Symp. Applied Computing (SAC'05), 2005, Santa Fe, New Mexico, USA, ACM Press.
    19. 19)
      • ‘NDoc code documentation generator for .NET’, available at: http://ndoc.sourceforge.net.
    20. 20)
      • B. Adelson , E. Soloway . The role of domain experience in software design. IEEE Trans. Softw. Eng , 11 , 1351 - 1360
    21. 21)
      • A. Garcia , C. Rubira , A. Romanovsky , J. Xu . A comparative study of exception handling mechanisms for building dependable object-oriented software. J. Syst. Softw. , 197 - 222
    22. 22)
      • M.P. Robilliard , G.C. Murphy . Static analysis to support the evolution of exception structure in object-oriented systems. ACM Trans. Softw. Eng. Methodol. , 2 , 191 - 221
    23. 23)
      • ECMA-335 Common Language Infrastructure (CLI), ECMA Standard, 2003.
    24. 24)
      • Robillard, M.P., Murphy, G.C.: `Designing robust Java programs with exceptions', Proc. 8th ACM SIGSOFT Int. Symp. Foundations of Software Engineering, 2000, 25, ACM Press, (6).
    25. 25)
      • B.G. Ryder , M.L. Soffa . Influences on the design of exception handling', ACM SIGSOFT project on the impact of software engineering research on programming language design. ACM SIGSOFT Softw. Eng. Notes , 6 , 16 - 22
    26. 26)
      • Lippert, M., Lopes, C.: `A study on exception detection and handling using aspect-oriented programming', Proc. 22nd Int. Conf. Software Engineering, 2000, Ireland, ACM Press, 2000.
    27. 27)
      • ‘The code project – free source code and tutorials’, available at: http://www.codeproject.com/.
    28. 28)
      • ‘NAnt – a .NET build tool’, available at: http://nant.sourceforge.net.
    29. 29)
      • ‘Mono’, available at: http://www.go-mono.com.
    30. 30)
      • Robillard, M.P., Murphy, G.C.: `Designing robust JAVA programs with exceptions', Proc. 8th ACM SIGSOFT Int. Symp. Foundations of Software Engineering, 2000, 25ACM Press, .
    31. 31)
      • J.B. Goodenough . Exception handling: issues and a proposed notation. Commun. ACM , 12 , 683 - 696
    32. 32)
      • Cristian, F.: `Exception handling and software fault tolerance', Proc. FTCS-25, 3(IEEE, 1996), (reprinted from FTCS-IO 1980, 97–103).
    33. 33)
      • P.A. Buhr , W.Y.R. Mok . Advanced exception handling mechanisms. IEEE Trans. Softw. Eng. , 9 , 820 - 836
    34. 34)
      • A. Koenig , B. Stroustrup . (1993) Exception handling for C++’ ‘The evolution of C++: language design in the marketplace of ideas.
    35. 35)
      • Maxion, R.A., Olszewski, R.T.: `Improving software robustness with dependability cases', 28thInt. Symp. Fault-Tolerant Computing, 1998, Munich, Germany, IEEE Computer Society Press, p. 346–355.
    36. 36)
      • ‘CpSphere Email Component for .NET’, available at: http://www.codeproject.com/dotnet/cpSphereEmailComponent.asp.
    37. 37)
      • Reimer, D., Srinivasan, H.: `Analyzing exception usage in large Java applications', Proc. ECOOP'03 Workshop on Exception Handling in Object-Oriented Systems, July 2003.
    38. 38)
      • T. Parr . (2006) ANTLR – another tool for language recognition.
http://iet.metastore.ingenta.com/content/journals/10.1049/iet-sen_20070017
Loading

Related content

content/journals/10.1049/iet-sen_20070017
pub_keyword,iet_inspecKeyword,pub_concept
6
6
Loading
This is a required field
Please enter a valid email address