My favorites | Sign in
Project Logo
Project hosting will be READ-ONLY Wednesday at 8am PST due to brief network maintenance.
                

Latest News

2 Jan 2010: Treaty for Eclipse 2.1.1 released. Treaty is now dynamic, i.e. a contract registry is maintained when new bundles are installed/uninstalled. Treaty contains a new contract vizualisation framework (see snapshot below), and some example contracts for standard Eclipse extension points (some of which fail !). Contracts can now have triggers and actions (=they are based on ECA rules). This means that component lifecycle events can trigger contract verification. To try it, install the respective Eclipse plugins from the following update site: http://treaty.googlecode.com/svn/tags/release2.1.1/treaty-eclipse-updatesite/site.xml.

30 November 2009: We have submitted a proposal to talk about Treaty at EclipseCon.

26 March 2009: We have finished an experiment where we formalised existing contracts documented in Eclipse extension points, and then verified Eclipse against these contracts. There are some surprising results.

Introduction

Treaty is a contract framework for arbitrary component models. It supports the precise specification of relationships between collaborating components and verification with respect to these contracts. To explain this, consider a simple clock application in Eclipse (this application can be installed from the following update site: http://treaty.googlecode.com/svn/tags/release2.0.0/treaty-eclipse-updatesite/site.xml). The clock view provided by the plugin displays date and time, but the actual date formatting services are provided by additional plugin components. The relationship between these components is described by precise contracts that reference types defined in an ontology. The following contract types are used in the example:

The prototype uses a verification service to check the system for integrity as defined by these contracts. This is useful in complex dynamic systems that change often as new services (components) are discovered and integrated. Treaty is not invasive: contracts are just text files added to the plugin meta data (example). Treaty is open: the contract vocabulary consisting of types and relationships has an open modular design. In particular, the underlying component model itself can be used to make contributions to the contract vocabulary.

Relevant publications

Miscellaneous

Treaty for Eclipse contains a custom JUnit that allows constructor dependency injection. See also the discussion on the JUnit mailing list about unit testing and dependency injection.

Todos









Hosted by Google Code