Computer Languages, Systems & Structures 36 (2010) 123 -- 141 Contents lists available at ScienceDirect Computer Languages, Systems & Structures journal homepage: www.elsevier.com/locate/cl Extending object-oriented languages with backward error recovery integrated support Daniel Fernández Lanvin , Raúl Izquierdo Castanedo, Aquilino Adolfo Juan Fuente, Alberto Manuel Fernández Álvarez University of Oviedo, Dept. Informática, Oviedo 33007, Spain ARTICLE INFO ABSTRACT Article history: Received 26 June 2008 Received in revised form 16 March 2009 Accepted 16 May 2009 Keywords: Recoverability Object-oriented Error recovery Reconstructor Software robustness One of the requirements of software robustness is controlling and managing runtime errors that might arise at certain points of application execution. In most object-oriented program- ming languages, this requirement is commonly implemented by means of exception handling. Although exception handling is a powerful tool to avoid system failure arising, there are still many situations where it is not sufficient to restore the system to a consistent state. Exception handling allows the developer to detect and locate errors, but it gives no information or tools to cover the error recovering task. Therefore, we propose an extension of the semantics of com- mon object-oriented languages to restore the previous consistent state of the system in the presence of runtime errors, avoiding some of the tasks that exception-handling mechanisms delegate to developers. Our proposed solution is centered in the concept of “reconstructor”, a declarative component oriented to automatically return the system to its last stable state. Based on this concept, we develop a non-intrusive code enrichment tool for Java, and we ap- ply it to a real application in order to check the feasibility of the proposal. We evaluated the performance of the resulting code, obtaining reasonable and viable rates and overload. © 2009 Elsevier Ltd. All rights reserved. 1. Introduction Ever since the NATO conference on software development in 1968, this task was viewed as an engineering process, and conse- quently a new objective emerged in every software project: every product needed to reach minimum levels of software quality. Thirty years later, a great number of research lines are still devoted to obtaining new techniques and technologies to increase software quality. This work considers a specific factor of software quality: software robustness. Software robustness can be defined as the degree to which a system or component can function correctly in the presence of invalid inputs or stressful environmental conditions [1,15]. It depends on two complementary factors: technological support and the developer's professional capacities. The wider the technological coverage given by the platform, the easier the developer's task of implementing robust software. The logic needed to implement recovery mechanisms in low-level languages was therefore more complicated and harder to maintain than the logic needed nowadays when developed with more mature technologies like modern object-oriented platforms. The current exception-handling mechanism, present in almost all object-oriented languages, covers the tasks of detection and localization of the error source, but does not help to solve the third task that must be carried out to maintain consistency in the presence of any critical error: error recovering. This task is delegated to the developer who, as it will be seen later in this Corresponding author. Tel.: +34 985 105 094. E-mail addresses: dflanvin@uniovi.es (D. Fernández Lanvin), raul@uniovi.es (R. Izquierdo Castanedo), aajuan@uniovi.es (A.A. Juan Fuente), alb@uniovi.es (A.M. Fernández Álvarez). 1477-8424/$ - see front matter © 2009 Elsevier Ltd. All rights reserved. doi:10.1016/j.cl.2009.05.001