This is me in Manaus,
      Amazonas, having dinner after my talk at I Encontro de Software
      Livre do Amazonas, in October, 2003.  Picture taken by Paulino
      Michelazzo. The Guaraná Family

Guaraná

Releases Documentation Gallery Mail Links
Guaraná (pronounced gwadda-naa, with American accent; also known as Guarana, for the ISO-8859-1 challenged :-) is a reflective architecture that aims at simplicity, flexibility, security and reuse of meta-level code. It features a run-time meta-object protocol that provides for easy composition of meta-objects and allows for dynamic reconfiguration. If you're not familiar with reflection and meta-objects, you may want to read this first.

Meta-objects can be combined through composers, that provide the glue code for them to work together, delegating control to them and resolving conflicts when they arise. Since composers are meta-objects, they can be further composed. Such a hierarchical composition mechanism is unique to Guaraná.

Richard Stallman with a can of Guaraná Unlike other reflective architectures, Guaraná was designed with security in mind, i.e., when a meta-object is associated with an object, it is impossible to steal control from it unless it is willing to waive it. Furthermore, composers can limit the reflective abilities of their component meta-objects and overrule their decisions. Meta-objects can create arbitrary operations addressed to objects they control, but composers can restrict the kind of operations their components can create.

In order to improve security, the identity of meta-objects is hidden from the base- and even from the meta-level. Nevertheless, Guaraná provides a mechanism to allow meta-objects to exchange information, or to introduce themselves to each other. To the best of our knowledge, Guaraná is the only reflective architecture with this kind of security concern.

Tim Wilkinson meets Guaraná without Kaffe Guaraná is language-independent and can be implemented atop other MOPs. We have implemented it by modifying the Kaffe OpenVM, a Free implementation of the Java(TM) Virtual Machine Specification originally by Tim Wilkinson (in the second picture on the right), CEO of Transvirtual Technologies, Inc. Note, however, that neither the Java programming language nor the Java bytecode format were modified, so any existing Java application can be made reflective by running it on our modified virtual machine.


When Doug Lea first met Guaraná

Gallery

The first picture on the right was taken just after my MSc presentation, in August, 1998. Everybody was obviously drinking guaraná. :-) The ones on the left are my parents; in the center is Professor Luiz Eduardo Buzato, my advisor. Islene, my fiancée, is just in front of me. My aunt, Sofia, is the one behind the camera. :-)

Richard Stallman (in the first picture on the left), the creator of the GNU project, has appreciated guaraná (a Brazilian soda :-) during his short visit to Brazil in 1996.

Juerg Gutknech with a bottle of Guaraná Tim Wilkinson (in the second picture on the right) invited me and Professor Buzato for some coffee (or should I say Kaffe? :-) in our short stay in California in October, 1998.

Roy Campbell's first can of Guaraná Doug Lea (in the second picture on the left), the author of the book Concurrent Programming in Java: Design Principles and Patterns, has pleased me with his presence at my presentation at the OOPSLA'98 Workshop on Reflective Programming in C++ and Java.

Jürg Gutknecht (in the third picture on the right), that created the Oberon system with Niklaus Wirth, has enjoyed guaraná (the soft-drink) when he came over for the Second Brazilian Symposium on Programming Languages, in 1997.

Roy Campbell (in the third picture on the left), the creator of the Choices reflective operating system, at the CS Department of the University of Illinois at Urbana-Champaign, has enjoyed the fact that, in the can of soft-drink he was given, he read ``Guaraná Champagne'' (that's the full name of Antárctica's guaraná soda :-).

On the right of the on-line documentation links, are pictures of some of the people I have met at COOTS'99: Douglas C. Schmidt, the main designer and developer of ACE and TAO; Robert C. Martin, from Object Mentor, lecturer and writer on OO modeling and XP; Steve Vinoski, from IONA Technologies, author of many articles, columns and one book about CORBA. Also on the right, I hold a bottle of Guaraná among the best-placed Brazilian team in the 1999 South American Regional Programming Contest, part of the ACM International Collegiate Programming Contest.


On-line documentation


Releases


Related Work

GDK, the Guaraná Development Kit, is a toolkit to ease the development of reflective applications, introducing higher-level components that build upon the MOP of Guaraná. dejavu, a debugging and reverse-engineering tool built with Guaraná and GDK, is available at the same web-page.

A list of Java-based reflective architectures are listed below. This list should probably be expanded to include other reflective architectures, based on other programming languages, as well as other open architecture efforts.


Why not 100% Pure Java?

We have decided to modify the Kaffe OpenVM, instead of dynamically modifying Java bytecodes through ClassLoader preprocessing because this dynamic modification is likely to lead to poor performance and arbitrary limitations in reflective abilities. There are several issues involved: Add to this the fact that Kaffe OpenVM is the most portable existing Java Virtual Machine, JIT compilation is available on most of the supported platforms, and it is Free Software, and you'll understand why we decided to modify it instead of trying a limited 100% Pure Java implementation... :-) Anyway, we haven't yet discarded the possibility of implementing the reflective architecture of Guaraná with dynamic translation of bytecodes. Even though some operations just can't be intercepted, and some classes can't be made reflective, it might be interesting to compare the performance and the limitations of this implementation with the one we already have. Some nice starting points would be Soot, a set of tools for Java bytecode generation and processing and GNU bytecode, part of the Kawa Java-based Scheme interpreter.

Mailing List

A mailing list has been set up for discussing Guaraná: the reflective architecture, its implementation and applications. To subscribe, send an empty e-mail to guarana-subscribe@yahoogroups.com, or browse the archives.
Guaraná was created as my Master Thesis project, with a lot of help from my advisor (Luiz Eduardo Buzato, PhD) and my wife (Islene Calciolari Garcia, PhD).

This project might not have been possible without the financial support provided by FAPESP, that has provided scholarships for individual students and equipment for the Laboratory of Distributed Systems. We have also had support from CNPq.


Unrelated Work

Guaraná (Paullinia cupana) is the name of an Amazonian fruit that contains guaranine, a substance very similar with caffeine, but much more powerful. You may find a lot of information about the fruit and the soda at www.guarana.com. Hans van Rijsse, who maintains that site, has been nice enough to provide me with an e-mail address @guarana.com.

Matthew and Bernard Duggan, other fans of guaraná, that own guarana.org, were also very kind in maintaining a link to this web page and an e-mail address @guarana.org. Thank you all, folks!

For some botanical information about Guaraná, see this. Thanks to Mike Corbeil for the URL.


If you have any suggestions, comments or questions, feel free to send e-mail to Alexandre Oliva. This is not an official publication of IC-Unicamp nor Unicamp, and the opinions expressed here do not necessarily represent the opinions of the University.

This page is Best Viewed With Any Browser

Last modified: 2004-03-20