Bogor-Java Environment for Eclipse

35
Bogor-Java Environment for Eclipse MSE Presentation III Yong Peng

description

Bogor-Java Environment for Eclipse. MSE Presentation III Yong Peng. Outline. Component Design Assessment Evaluation Project Evaluation Future Work Conclusion Demo Questions & Comments. Component Design. Component design is the detailed design for each component. - PowerPoint PPT Presentation

Transcript of Bogor-Java Environment for Eclipse

Page 1: Bogor-Java Environment for Eclipse

Bogor-Java Environmentfor EclipseMSE Presentation III

Yong Peng

Page 2: Bogor-Java Environment for Eclipse

Outline

Component Design Assessment Evaluation Project Evaluation Future Work Conclusion Demo Questions & Comments

Page 3: Bogor-Java Environment for Eclipse

Component Design

Component design is the detailed design for each component.

This project includes three new plug-ins and one updated plug-in.

In the following several slides, incremental compilation plug-in will be used as an example for component design.

Page 4: Bogor-Java Environment for Eclipse

Component Design (Cont.)

High-level component diagram of incremental compilation plug-in.

Page 5: Bogor-Java Environment for Eclipse

Component Design (Cont.)

This class handles the life cycle of the plug-in. It provides the error and log methods to log errors. Eclipse uses this class and the plug-inconfiguration XML to register this plug-in into Eclipse environment.

BytecodeToBirIncrementalPlugin

BytecodeToBirIncrementalPlugin()start(context : BundleContext) : voidstop(context : BundleContext) : voidgetDefault() : BytecodeToBirIncrementalPlugingetImageDescriptor(path : Logical View::java::lang::String) : ImageDescriptorgetShell() : Shellerror(messageID : Logical View::java::lang::String, error : Throwable) : voidlog(error : Throwable, statusID : int) : void

(from incremental)

Life cycle methods

Error and log methods

Page 6: Bogor-Java Environment for Eclipse

Component Design (Cont.)

: eclipseadd delta vistor :

BytecodeToBirBuilder : BirHandler

1. full build

eclipse listens the action: full build or delta build.1. if it's a full build

2. if it's a delta build

1.1. fullBuild(monitor : IProgressMonitor)

1.2. add resource vistor

1.3. createBir(resource : IResource)

1.4. writeBIR(resource : IResource, monitor : IProgressMonitor)

2. delta build

2.1. incrementalBuild(delta : IResourceDelta, monitor : IProgressMonitor)

2.2. add delta visitor

2.3. create/delete BIR

2.4. if delete: deleteBIR(resource : IResource, monitor : IProgressMonitor)

2.5. if write: writeBIR(resource : IResource, monitor : IProgressMonitor)

Page 7: Bogor-Java Environment for Eclipse

Component Design (Cont.)

This class handles Bytecode-to-BIR full and delta build. Method “createBir” and “deleteBir” are two helper methods. Full and deltabuild methods use those two helper methods to create and deleteBIR files in file system.

BytecodeToBirBuilder

BUILDER_ID : Logical View::java::lang::String = "edu.ksu.cis.projects.bogor.incremental.bytecodeToBirBuilder"

build(kind : int, args : Map, monitor : IProgressMonitor) : IProject[]fullBuild(monitor : IProgressMonitor) : voidincrementalBuild(delta : IResourceDelta, monitor : IProgressMonitor) : voidcreateBir(resource : IResource) : voiddeleteBir(resource : IResource) : void

(from builder)

Full and delta build methods

Create and delete BIR methods

Page 8: Bogor-Java Environment for Eclipse

Component Design (Cont.)

This is the helper class that perform delete and write BIR files functions. The “createBir” and “deleteBir” in BytecodeToBirBuilder class use “writeBIR”

and “deleteBIR” methods to delete and write BIR files in file system.

BirHandler

BirHandler()getClassFullyQualifiedName(resource : IResource) : Logical View::java::lang::StringwriteBIR(resource : IResource, monitor : IProgressMonitor) : voiddeleteBIR(resource : IResource, monitor : IProgressMonitor) : void

(from translator)

Page 9: Bogor-Java Environment for Eclipse

Component Design (Cont.)

The details for other plug-ins can be found in component design document. The following is the URL of design document.

http://www.cis.ksu.edu/~yongpeng/phase3/ComponentDesign.pdf

Page 10: Bogor-Java Environment for Eclipse

Assessment Evaluation

Test Case# Test Unit SR(s) Tested Result

1.1Incremental compilation

1.2 Pass

1.2 Add nature 1.1 Pass

2.1 Launcher 2.1, 2.2, 2.3 Pass

2.2Model checking output

2.4 Pass

3 Trace error 3 Pass

4 BogorVM view 4.1, 4.2, 4.3 Pass

Page 11: Bogor-Java Environment for Eclipse

Assessment Evaluation (Cont.)

TPTP Automated GUI Recorder This tool allows users to record GUI actions in the Eclipse

platform and play them back to verify the functionality of their product.

It is used to do automate regression tests. It is part of Eclipse TPTP test framework.

This tool comes out on August, 2005. Since this tool is still in the technology preview stage and has incomplete features, I only used its “Quick Run” function. The “Quick Run” function uses the currently running workbench

as the context to run the selected test cases.

Page 12: Bogor-Java Environment for Eclipse

Assessment Evaluation (Cont.)

Page 13: Bogor-Java Environment for Eclipse

Project Evaluation

Problems Encountered Comprehending Project Requirements

Require more Bogor and Eclipse knowledge to understand requirement

Understanding Eclipse Frameworks Steep learning curve Lacking development document

FSM for the formal specification System states and actions missing

Page 14: Bogor-Java Environment for Eclipse

Project Evaluation(Cont.)

The total SLOC predicted: 6000 The actual SLOC implemented for each plug-in

Incremental compilation: 556 BogorVM view: 2556 Launcher: 1429 Error trace in Java: 200 Total: 4741

Page 15: Bogor-Java Environment for Eclipse

Project Evaluation(Cont.)

Phase Expected finish time

Actual finish time

Phase I August 7, 2005 August 7, 2005

Phase II October 18, 2005 November 11, 2005

Phase III December 12, 2005

December 12, 2005

The problems encountered when created formal specifications during the second phase was the cause of delay.

Page 16: Bogor-Java Environment for Eclipse

Project Evaluation(Cont.)

Total hours: 242 hours

Project Breakdown by Phase

Phase II36%

Phase III21%

Phase I43%

Phase I Phase II Phase III

Page 17: Bogor-Java Environment for Eclipse

Project Evaluation – Phase I

Phase I

Design & Document

17%

Build Prototype49%

Study PDE&JDT

34%

Design & Document Build Prototype Study PDE&JDT

Page 18: Bogor-Java Environment for Eclipse

Project Evaluation – Phase II

Phase II

Design & Document

44%Coding56%

Design & Document Coding

Page 19: Bogor-Java Environment for Eclipse

Project Evaluation – Phase III

Phase III

Design7%

Coding29%

Document43%

Testing21%

Design Coding Document Testing

Page 20: Bogor-Java Environment for Eclipse

Future Work

Making the counter example view as usable as the Eclipse Java debugger add break-point function when tracing errors change error trace fully to Java level etc.

Improving configuration tab in launch pad Adding syntax highlighting function to BogorVM view

Page 21: Bogor-Java Environment for Eclipse

Conclusion

Learnt new technology JFace, SWT Frameworks JDT, PDE TPTP’s Automated GUI Recorder

Went through full Software Development Life Cycle Applied iterative process in this project

Learnt the importance of documentation For example: Tracing back to Vision Document for the

system requirements details

Page 22: Bogor-Java Environment for Eclipse

Demo

Create a demo java project and Deadlock.java

Page 23: Bogor-Java Environment for Eclipse

Demo (cont.)

Add Bytecode-to-BIR Builder

Page 24: Bogor-Java Environment for Eclipse

Demo (cont.)

BIR files are generated.

Page 25: Bogor-Java Environment for Eclipse

Demo (cont.)

Open BogorVM BIR View

Page 26: Bogor-Java Environment for Eclipse

Demo (cont.)BIR displays in the BogorVM BIR view.

Page 27: Bogor-Java Environment for Eclipse

Demo (cont.)

BIR is highlighted if click on Java code in Java editor.

Page 28: Bogor-Java Environment for Eclipse

Demo (cont.)

Open launcher, create a new Bogor VM configuration.

Page 29: Bogor-Java Environment for Eclipse

Demo (cont.)

Default Bogor configuration will be load from a properties file

Page 30: Bogor-Java Environment for Eclipse

Demo (cont.)

Add a “test” parameter into config.

Page 31: Bogor-Java Environment for Eclipse

Demo (cont.)The newly added parameter shows in the Bogor Config tab.

Page 32: Bogor-Java Environment for Eclipse

Demo (cont.) Remove the “test” parameter, and click Run. A bogor-trail file is

generated and the result is output in eclipse console.

Page 33: Bogor-Java Environment for Eclipse

Demo (cont.)

Double click on the trail file, it opens Bogor counter examples view, bogor-trails editor, and Java editor.

Page 34: Bogor-Java Environment for Eclipse

Demo (cont.)

Step through the error trace

Page 35: Bogor-Java Environment for Eclipse

Questions & Comments