DDF Developer's Guide
Table of Contents
- Developer's Documentation Guide — Establishes conventions used throughout the documentation
- Ensuring Compatibility
- Development Recommendations — provides general developer tips and recommendations for OSGi bundle development
- Working with OSGi — quick tutorials of OSGi basic concepts
- Developing Catalog Components — Describes how to create Catalog components. Used in conjunction with the Javadoc to begin extending the DDF Catalog.
- Developing at the Framework Level — Help with framework concepts and development.
- Developing Action Components — Describes how and why to create Action Components.
- Developing for the DDF Marketplace
- Developing Security Token Service Components
- Building
- DDF Camel Components
Introduction
This guide discusses the several extension points and components permitted by the Distributed Data Framework (DDF) Catalog API. Using code examples, diagrams, and references to specific instances of the Catalog API, this guide will provide details on how to develop and integrate various DDF components.
Development Prerequisites
It is recommended to understand the DDF Catalog fully before beginning development.
DDF is almost completely written in Java and requires a moderate amount of experience with the Java programming language along with Java terminology such as packages, methods, classes, and interfaces.
DDF uses a small OSGi runtime to deploy components and applications. Before developing for DDF it is necessary that developers have general knowledge on OSGi and the concepts used within. This includes, but is not limited to:
- Understanding the Service Registry
- How services are registered
- How to retrieve service references
- Understanding Bundles
- Their role in OSGi
- How they are developed
Documentation on OSGi can be viewed at the OSGi Alliance website (http://www.osgi.org). Books that some OSGi beginners found helpful are OSGi and Apache Felix 3.0 Beginner's Guide and OSGi in Action: Creating Modular Applications in Java. For specific code examples from DDF, source code can be seen in the Working with OSGi section.
Getting Setup
All that is necessary to develop on DDF is either access to the source code (Building DDF Offline from Source) or the DDF binary zip file ddf-2.0.0.zip
.
Integrated Development Environment (IDE)
The DDF source code is not tied to any particular IDE. However, if a developer is interested in setting up the Eclipse IDE, a developer can view the Sonatype guide on developing with Eclipse.
Directory Structure
During DDF installation, the following major directories (displayed in the table below) will created, modified, or replaced in the destination directory.
Directory Name
Description
bin
Scripts to start and stop DDF
data
The working directory of the system – installed bundles and their data data/log/ddf.log
Log file for DDF, logging all errors, warnings, and (optionally) debug statements. This log rolls up to 10 times, frequency based on a configurable setting (default=1 MB)
deploy
Hot-deploy directory – KARs and bundles added to this directory will be hot-deployed (Empty upon DDF installation)
docs
The DDF Catalog API Javadoc etc
Directory monitored for addition/modification/deletion of third party .cfg
configuration files
etc/ddf
Directory monitored for addition/modification/deletion of DDF-related .cfg
configuration files (e.g., Schematron configuration file)
etc/templates
Template .cfg
files for use in configuring DDF sources, settings, etc., by copying to the etc/ddf
directory.
lib
The system's bootstrap libraries. Includes the ddf-branding.jar
file which is used to brand the system console with the DDF logo.
licenses
Licensing information related to the system system
Local bundle repository. Contains all of the JARs required by DDF, including third-party JARs.
During DDF installation, the following major directories (displayed in the table below) will created, modified, or replaced in the destination directory.
Directory Name | Description |
---|---|
| Scripts to start and stop DDF |
data | The working directory of the system – installed bundles and their data |
| Log file for DDF, logging all errors, warnings, and (optionally) debug statements. This log rolls up to 10 times, frequency based on a configurable setting (default=1 MB) |
| Hot-deploy directory – KARs and bundles added to this directory will be hot-deployed (Empty upon DDF installation) |
docs | The DDF Catalog API Javadoc |
| Directory monitored for addition/modification/deletion of third party |
| Directory monitored for addition/modification/deletion of DDF-related |
| Template |
| The system's bootstrap libraries. Includes the |
licenses | Licensing information related to the system |
| Local bundle repository. Contains all of the JARs required by DDF, including third-party JARs. |
Additional Documentation
Additional documentation on developing with the core technologies used by DDF can be found on their respective websites.
Notably: