The Design and Implementation of Guaraná
Several reflective architectures have attempted to improve meta-object reuse by supporting composition of meta-objects, but have done so using limited mechanisms such as Chains of Responsibility. We advocate the adoption of the Composite pattern to define meta-configurations. In the meta-object protocol (MOP) of Guaraná, a composer meta-object can control reconfiguration of its component meta-objects and their interactions with base-level objects, resolving conflicts that may arise and establishing meta-level security policies. Guaraná is currently implemented as an extension of Kaffe OpenVM TM, a free implementation of the Java1 Virtual Machine. Nevertheless, most design decisions presented in this paper can be transported to other programming languages and MOPs, improving their flexibility, reconfigurability, security and meta-level code reuse. We present performance figures that show that it is possible to introduce run-time reflection support in a language like Java without much impact on execution speed.