Sun Microsystems has announced its contribution of Metadata Repository modules to the NetBeans open source project, supporting Object Management Group's (OMG's) Model Driven Architecture (MDA). "The Model Driven Architecture represents an advanced approach to software design based on models created using languages such as the Unified Modeling Language (UML); it helps protect organizations' software investments by capturing business logic (business processes and their appropriate interactions) in re-usable models. Sun has contributed the Metadata Repository (MDR) modules to NetBeans to make it easier for developers to support another programming languages without extensive extra programming, and to write NetBeans-based tools that interoperate with standards-based modeling tools. MDR implements the OMG's MOF (Meta Object Facility) standard based metadata repository, including a persistent storage mechanism for storing the metadata. The interface of the MOF repository is based on JMI (Java Metadata Interface) as specified in JSR-40. In addition to the provisional JMI implementation, MDR also defines an event notification mechanism and additional features that help to incorporate it into the IDE."
Key MDR Features
- Support for import of XMI 1.1/1.2 documents for both MOF 1.4 and MOF 1.3 (transparently converted to MOF 1.4) MDR is able to load any MOF 1.4 (and some of MOF 1.3) metamodels in form of XMI document. MOF 1.3 metamodels are automaticaly converted to MOF 1.4 metamodels if possible during the import process.
- Support for export of data stored in the repository to XMI 1.2 documents
- Generation of JMI compliant Java interfaces for any loaded MOF metamodel
- Instantiation of any MOF compliant metamodel
- Automatic run-time implementation of generated APIs; no need to restart the MDR
- Standalone repository access via DJava shell; MDR can work as a standalone application
- Integration with NetBeans IDE; special MDR looks for browsing the repository contents
From the announcement:
The NetBeans Metadata Repository provides support for modules that need to create, store and retrieve metadata. With its extensive support for the relevant standards, NetBeans will ultimately make it easier for developers to build model-driven programs. In addition, developers can support new programming languages without tediously writing APIs and custom support classes for each language.
The MDR implements OMG's Meta Object Facility (MOF) -- an abstract language for describing metamodels -- and integrates it into the NetBeans IDE. The MOF implementation uses the Java Metadata Interface, a standard for expressing metadata in the Java language that is currently in review by the Java Community Process as JSR-40. The MDR adds features such as event notification to help integrate it with the IDE. The MDR also supports XML Metadata Interchange (XMI), another OMG specification that has already been implemented by several leading vendors.
The MDR includes an engine library, the module integrating it with the NetBeans IDE, a development toolkit and tools for viewing and interacting with metadata. These tools represent the foundation for robust language-neutral refactoring support in the NetBeans IDE. The MDR can be used as a stand-alone library independent of the NetBeans IDE by third parties, such as modeling tools vendors that need a standards-compliant metadata repository.
The MDR offers a number of benefits to developers and vendors: It provides support for developers who implement modules that generate or use metadata. This makes it easier for developers to create tools or modules that interoperate with other tools that support these standards. For example, most leading UML tools already support XMI. Given a language model, the MDR will generate all the interfaces representing an API for support of that language within the IDE. The MDR provides a language-neutral standard, and saves developers the effort of writing their own APIs for each language. Some operations within the IDE will be faster when implemented using metadata. The MOF standard can be used to integrate various types of tools for modeling, code generation, code analyses, dependency management and so forth.
Principal references:
- Announcement 2002-05-07: Netbeans -- First Open Source Tools Platform to Implement Model Driven Architecture (MDA). MDA to Simplify Implementation of Web Services by Separating Architecture from Deployment Infrastructure."
- Metadata Repository (MDR) project website
- MDR Architecture
- MDR Module News
- First Steps with MDR
- MDR mailing lists
- JSR 40: The Java Metadata Interface (JMI) Specification
- NetBeans Platform and the NetBeans IDE
- the Object Management Group (OMG)
- See: "MDA Brings Standards-Based Modeling to EAI Teams." By Tushar K. Hazra. In Application Development Trends Volume 9, Number 5 (May 2002), pages 48-52.
- "XML Metadata Interchange (XMI)" - Main reference page.
- "OMG Model Driven Architecture (MDA)" - Main reference page.