©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 1 Critical systems development 2.

Slides:



Advertisements
Similar presentations
1 Note content copyright © 2004 Ian Sommerville. NU-specific content copyright © 2004 M. E. Kabay. All rights reserved. Critical Systems Development IS301.
Advertisements

Defect testing Objectives
Critical systems development
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 30 Slide 1 Security Engineering 2.
Chapter 16: Recovery System
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 1 Slide 1 المحاضرة الثانية.
©Ian Sommerville 1995/2000 (Modified by Spiros Mancoridis 1999) Software Engineering, 6th edition. Chapter 18 Slide 1 Dependable software development l.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 24 Slide 1 Critical Systems Validation 2.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 1 Critical systems development.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 15 Slide 1 Real-time Systems 2.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 23 Slide 1 Software testing.
Critical systems development
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 30 Slide 1 Security Engineering.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 23 Slide 1 Software testing.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 23 Slide 1 Software testing 2.
Modified from Sommerville’s originals Software Engineering, 7th edition. Chapter 20 Slide 1 Critical systems development.
Modified from Sommerville’s originals Software Engineering, 7th edition. Chapter 20 Slide 1 Critical systems development.
SWE Introduction to Software Engineering
Developing Dependable Systems CIS 376 Bruce R. Maxim UM-Dearborn.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 9 Slide 1 Critical Systems Specification.
CS 603 Communication and Distributed Systems April 15, 2002.
Evaluating Architectures Quality control: rarely fun, but always necessary
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 10 Slide 1 Formal Specification.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 22 Slide 1 Verification and Validation.
©Ian Sommerville 2004Software Engineering, 7th edition. Insulin Pump Slide 1 An automated insulin pump.
©Ian Sommerville 2004Software Engineering, 7th edition. Insulin Pump Slide 1 The portable insulin pump Developing a dependability specification for the.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 30 Slide 1 Security Engineering.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 2 Slide 1 Systems engineering 1.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 10 Slide 1 Critical Systems Specification 3 Formal Specification.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 10 Slide 1 Formal Specification.
Chapter 3 Software Processes.
Chapter 24 - Quality Management Lecture 1 1Chapter 24 Quality management.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 15 Slide 1 Real-time Systems 1.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 23 Slide 1 Software testing.
Software Reliability Categorising and specifying the reliability of software systems.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 27 Slide 1 Quality Management 1.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 23 Slide 1 Software testing Slightly adapted by Anders Børjesson.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 23 Slide 1 Software testing.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 22 Slide 1 Verification and Validation.
Chapter 13, Slide 1 Exception Handling Exception handling is a language feature that allows the programmer to handle runtime "exceptional conditions."
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 20 Slide 1 Integration testing l Tests complete systems or subsystems composed of integrated.
Critical systems development. Objectives l To explain how fault tolerance and fault avoidance contribute to the development of dependable systems l To.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 9 Slide 1 Critical Systems Specification 2.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 32 Slide 1 Aspect-oriented Software Development 1.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 3 Slide 1 Critical Systems 1.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 22 Slide 1 Software Verification, Validation and Testing.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 1 Critical systems development 3.
Critical Systems Development IS301 – software Engineering Lecture #19 – M. E. Kabay, PhD, CISSP Dept of Computer Information Systems Norwich.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Chapter 19 Verification and Validation.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 9 Slide 1 Critical Systems Specification 1.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 4 Slide 1 Slide 1 Use Case Packets.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 1 Critical systems development.
Chapter 11 Data Validation. Question Should your program assume the data is correct, or should your program edit the data to ensure it is correct?
Design Principles and Common Security Related Programming Problems
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 4 Slide 1 Software Processes.
©Ian Sommerville 2000Dependability Slide 1 Chapter 16 Dependability.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 23 Slide 1 Software testing.
SENG521 (Fall SENG 521 Software Reliability & Testing Fault Tolerant Software Systems: Techniques (Part 4a) Department of Electrical.
1 Software Testing and Quality Assurance Lecture 38 – Software Quality Assurance.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
Critical Systems Development
CMSC 345 Defensive Programming Practices from Software Engineering 6th Edition by Ian Sommerville.
Critical systems development
Dependable software development
Critical Systems Development
Presentation transcript:

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 1 Critical systems development 2

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 2 Exception handling l A program exception is an error or some unexpected event such as a power failure. l Exception handling constructs allow for such events to be handled without the need for continual status checking to detect exceptions. l Using normal control constructs to detect exceptions needs many additional statements to be added to the program. This adds a significant overhead and is potentially error-prone.

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 3 Importance of exception handling l All exceptions should be handled explicitly by the program where these exceptions may arise. l You should never rely on default exception handling - this will vary from one run-time system to another. Unhandled exceptions will be unpredictable. l Failure to handle a common exception (numeric overflow) resulted in the total loss of the Ariane 5 launch vehicle. Discussed in a later case study.

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 4 Exceptions in Java 1

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 5 Exceptions in Java 2

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 6 A temperature controller l Exceptions can be used as a normal programming technique and not just as a way of recovering from faults. l Consider an example of a freezer controller that keeps the freezer temperature within a specified range. l Switches a refrigerant pump on and off. l Sets off an alarm is the maximum allowed temperature is exceeded. l Uses exceptions as a normal programming technique.

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 7 Freezer controller 1

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 8 Freezer controller 2

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 9 Fault tolerance l In critical situations, software systems must be fault tolerant. l Fault tolerance is required where there are high availability requirements or where system failure costs are very high. l Fault tolerance means that the system can continue in operation in spite of software failure. l Even if the system has been proved to conform to its specification, it must also be fault tolerant as there may be specification errors or the validation may be incorrect.

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 10 Fault tolerance actions l Fault detection The system must detect that a fault (an incorrect system state) has occurred. l Damage assessment The parts of the system state affected by the fault must be detected. l Fault recovery The system must restore its state to a known safe state. l Fault repair The system may be modified to prevent recurrence of the fault. As many software faults are transitory, this is often unnecessary.

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 11 Fault detection and damage assessment l The first stage of fault tolerance is to detect that a fault (an erroneous system state) has occurred or will occur. l Fault detection involves defining constraints that must hold for all legal states and checking the state against these constraints.

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 12 Insulin pump state constraints

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 13 Fault detection l Preventative fault detection The fault detection mechanism is initiated before the state change is committed. If an erroneous state is detected, the change is not made. l Retrospective fault detection The fault detection mechanism is initiated after the system state has been changed. This is used when a incorrect sequence of correct actions leads to an erroneous state or when preventative fault detection involves too much overhead.

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 14 l Preventative fault detection really involves extending the type system by including additional constraints as part of the type definition. l These constraints are implemented by defining basic operations within a class definition. Type system extension

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 15 PositiveEvenInteger 1

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 16 PositiveEvenInteger 2

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 17 Damage assessment l Analyse system state to judge the extent of corruption caused by a system failure. l The assessment must check what parts of the state space have been affected by the failure. l Generally based on ‘validity functions’ that can be applied to the state elements to assess if their value is within an allowed range.

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 18 Robust array 1

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 19 Robust array 2

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 20 l Checksums are used for damage assessment in data transmission. l Redundant pointers can be used to check the integrity of data structures. l Watch dog timers can check for non- terminating processes. If no response after a certain time, a problem is assumed. Damage assessment techniques

©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 21 l Exceptions are used to support error management in dependable systems. l All exceptions should be explicitly handled in the program where these exceptions arise. l Fault tolerance means continuing execution in spite of the existence of program faults. It is used in systems with high availability requirements. l The four aspects of program fault tolerance are failure detection, damage assessment, fault recovery and fault repair. Key points