Jaca: a Reflective Fault Injection Tool based on Patterns
-
Upload
stone-caldwell -
Category
Documents
-
view
11 -
download
0
description
Transcript of Jaca: a Reflective Fault Injection Tool based on Patterns
![Page 1: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/1.jpg)
Institute ofComputing Jaca: a Reflective Fault
Injection Tool based on PatternsEliane Martins
Cecilia Rubira
Nelson Leme
Institute of Computing
State University of Campinas - Unicamp
Brasil
International Performance and Dependability Symposium — IPDS’2002Washington, D.C., USA • June 23 - 26, 2002
![Page 2: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/2.jpg)
2
Institute ofComputing
Contents
• Context
• Motivation and Objective
• Jaca
• Preliminary Experiments
• Conclusions
• Future Works
![Page 3: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/3.jpg)
3
Institute ofComputing
Fault Injection
• Deliberate introduction of faults into a system to observe its behavior– valuable approach to validate dependability properties
– useful to evaluate impact of error recovery mechanisms into performance
• Approaches:– simulation-based fault injection
– hardware fault injection software fault injection (SFI)
![Page 4: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/4.jpg)
4
Institute ofComputing
• Static injection (compile-time)
– source or Assembler code alteration • no extra code is needed• faults triggered when altered code is accessed
• needs extra code: fault injector and monitor• needs fault trigger mechanism
SFI Approaches
• Dynamic injection (runtime)–special process–interrupt routines–trace mode–code insertion
![Page 5: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/5.jpg)
5
Institute ofComputing
Motivation
• Typical runtime SFI tools work at machine code levelex.: corruption of CPU registers
useful to emulate consequences of hardware failures low intrusion into the target application great effort to emulate software faults
ex.: incorrect assignment of values to variables; incorrect array indexes; missing function
• Why is it important to emulate software faults ?• software faults are major cause of system failures
• COTS software components use is increasing, even for critical applications
![Page 6: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/6.jpg)
6
Institute ofComputing
Our Goals
• Problem:– Runtime injection at source-code level, affecting
objects’ attributes and methods
– Separation of concerns: fault injection and monitoring code separated from application code
• Approach used:– computational reflection
![Page 7: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/7.jpg)
7
Institute ofComputing
Computational Reflection• Capability of a system to reason
about or act upon itself
• Reflective systems manipulate – external data
– meta information: data representing system’s aspects
structural reflectionmanipulation of
structural aspectsex.: definition of a class or function
behavioral reflectionmanipulation of
system’s behaviorex.: method invocation
interception
• Reflective systems’
architecture:– base level: system’s functions
– meta level: interception and/or
alteration functions
![Page 8: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/8.jpg)
8
Institute ofComputing
Behavioral Reflection and OO
metaobject
meta-level
base-level
object X : classattribute A : type, valuemethod M1 : name, parameters
M1A B
M2 M3
object X
![Page 9: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/9.jpg)
9
Institute ofComputing Jaca
• Evolution of FIRE: runtime fault injection tool for
applications written in C++ showed feasibility of the approach source code dependency
• Main requirements:– validation of Java applications
– high portability
– source code independence
– ability to incorporate new fault models
![Page 10: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/10.jpg)
10
Institute ofComputing
• Design based on the Fault Injection Pattern set:– reuse of architectural solutions
already used to implement fault injection tools
• Code is written in pure Java• Use of Javassist reflection library:
– extends Java reflection API– requires no modification to the
standard JVM– performs reflection at bytecode level
during load time
Development Aspects
• portability• source code independence
• modularity• extensibility
![Page 11: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/11.jpg)
11
Institute ofComputing
Jaca’s Architecture
Interface
Controller
InjectorManager
Monitor Manager
ActivatorLogicalInjector
Logical Injector
LogicalMonitor
LogicalMonitor
… …
PhysicalInjector
PhysicalMonitor
…
Meta Level
Base LevelTarget Application
Fault List
Log File
Class List
Jaca
![Page 12: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/12.jpg)
12
Institute ofComputing
Application Instrumentation
Application’s Class Files
Metaobjects’ ClassFiles
byte code
byte code
Javassist library
Activator(class loader)
byte code +
hooks to metaobjects
Metaobject
Physical Injector
Physical Monitor
![Page 13: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/13.jpg)
13
Institute ofComputing
Preliminary Experiments• Experiments to show Jaca’s extensibility:
– Assembler-level fault injection
PhysicalInjector
JNIEXPORT void JNICALL Java_LowLevelRoutine (JNIEnv *param1, jobject param2){ int a, b, c, d, op, num ;
printf ( "\n###-> testing CPUID\n” ) ; op = 1;
asm ( "cpuid" : "=a" (a), "=b" (b), "=c" (c), "=d" (d) : "a" (op));
printf ( "\n###-> Register values: - EAX: %i, EBX: %i, ECX: %i, EDX: %i\n\n", a, b, c, d ) ;
... }
Low LevelFunctions
LowLevelRoutine( )
![Page 14: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/14.jpg)
14
Institute ofComputing
Conclusions and Future Works• Jaca:
– an extensible, portable software fault injector
– faults affect attributes and methods of Java applications
– fault injection uses computational reflection source code independent but ... dependent on reflection toolkit used
• Further works:– validate real world applications
• COTS ODBMS is being tested
– extend Jaca’s functionalities
– use of other reflection toolkits: Guaraná, Kava
– explore Assembler-level fault injection features
![Page 15: Jaca: a Reflective Fault Injection Tool based on Patterns](https://reader035.fdocuments.us/reader035/viewer/2022072013/56812b7b550346895d8f9a53/html5/thumbnails/15.jpg)
15
Institute ofComputing
Thank you !
• Our emails: