Overview and Evaluation of Constraint Validation Approaches in Java

Integrity is a dependability attribute partially ensured through runtime validation of integrity constraints. A wide range of different constraint validation approaches exists-ranging from simple if conditions over explicit constraint validation methods and contract specifications to constraints as first class runtime entities of an application. However, increased support for explicitness and flexibility often comes at the price of increased performance costs. To address this issue, we contribute with an overview and evaluation of different constraint validation approaches for the Java programming language with respect to implementation, maintainability and performance. Our results show that the benefits of some of the more advanced approaches are certainly worth their costs by introducing a runtime overhead of only two to ten times the runtime of the fastest approach while other approaches introduce runtime overheads of more than 100, which might be simply too slow in certain applications.

[1]  Douglas C. Schmidt,et al.  Ultra-large-scale systems , 2006, OOPSLA '06.

[2]  R. Kramer iContract - The Java(tm) Design by Contract(tm) Tool , 1998 .

[3]  Ragnhild Van Der Straeten,et al.  Specifying and implementing the operational use of constraints in object-oriented applications , 2002 .

[4]  Albert L. Baker,et al.  JML: A Notation for Detailed Design , 1999, Behavioral Specifications of Businesses and Systems.

[5]  Carl E. Landwehr,et al.  Basic concepts and taxonomy of dependable and secure computing , 2004, IEEE Transactions on Dependable and Secure Computing.

[6]  MeyerBertrand,et al.  Design by Contract , 1997 .

[7]  John L. Bruno,et al.  jContractor: A Reflective Java Library to Support Design by Contract , 1999, Reflection.

[8]  Aditya P. Mathur,et al.  Interceptor based constraint violation detection , 2005, 12th IEEE International Conference and Workshops on the Engineering of Computer-Based Systems (ECBS'05).

[9]  J. J. Whelan,et al.  5th international conference on software engineering , 1981, SOEN.

[10]  Gary T. Leavens,et al.  Forcing behavioral subtyping through specification inheritance , 1996, Proceedings of IEEE 18th International Conference on Software Engineering.

[11]  Gunter Saake,et al.  Consistency management in object‐oriented databases , 2001, Concurr. Comput. Pract. Exp..

[12]  Martin Lackner,et al.  Supporting Design by Contract in Java , 2002, J. Object Technol..

[13]  H. V. Jagadish,et al.  Integrity Maintenance in Object-Oriented Databases , 1992, VLDB.

[14]  W. Alex Gray,et al.  An integrity constraint management framework in engineering design , 2002, Comput. Ind..

[15]  Xiaolei,et al.  Integrity Maintenance in an Object-Oriented Database , 1992 .

[16]  Andrew Duncan,et al.  Adding Contracts to Java with Handshake , 1998 .

[17]  Cristina V. Lopes,et al.  Aspect-oriented programming , 1999, ECOOP Workshops.

[18]  Martin Gogolla,et al.  Validating UML Models and OCL Constraints , 2000, UML.

[19]  Lorenz Froihofer,et al.  Trading Integrity for Availability by Means of Explicit Runtime Constraints , 2006, 30th Annual International Computer Software and Applications Conference (COMPSAC'06).

[20]  Reinhold Plösch,et al.  Evaluation of Assertion Support for the Java Programming Language , 2002, J. Object Technol..

[21]  Bertrand Meyer,et al.  Applying 'design by contract' , 1992, Computer.

[22]  Heike Wehrheim,et al.  Jass - Java with Assertions , 2001, RV@CAV.