<html><head> | |
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> | |
<title>7. Developing OSGi Bundles using Plug-in Development Environment (PDE)</title><link rel="stylesheet" href="css/stylesheet.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.74.0"><link rel="home" href="index.html" title="Virgo Tools Guide"><link rel="up" href="index.html" title="Virgo Tools Guide"><link rel="prev" href="ch06s02.html" title="6.2 Editing the Manifest"><link rel="next" href="ch07s02.html" title="7.2 Server Runtime Wizard"><!--Begin Google Analytics code--><script type="text/javascript"> | |
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www."); | |
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); | |
</script><script type="text/javascript"> | |
var pageTracker = _gat._getTracker("UA-2728886-3"); | |
pageTracker._setDomainName("none"); | |
pageTracker._setAllowLinker(true); | |
pageTracker._trackPageview(); | |
</script><!--End Google Analytics code--></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">7. Developing OSGi Bundles using Plug-in Development Environment | |
(PDE) | |
</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ch06s02.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="ch07s02.html">Next</a></td></tr></table><hr></div><div class="chapter" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="developing_with_PDE"></a>7. Developing OSGi Bundles using Plug-in Development Environment | |
(PDE) | |
</h2></div></div></div> | |
This chapter assumes that the user is already familiar with the Plug-in Development Environment (PDE). Should this not be the case | |
it is recommended to read first the PDE documentation or one of the many tutorials available online. | |
<div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="pde_dependencies"></a>7.1 Resolving Bundle Dependencies</h2></div></div></div><p> | |
Starting from release 1.5.0 the Tools support developing OSGi | |
Bundles using the widely popular Eclipse Plug-in Development | |
Environment (PDE). | |
</p><p> | |
While working with OSGi bundles, one of the most important | |
aspects is defining the required dependencies in the MANIFEST.MF file. | |
When used in conjunction with the PDE, the Virgo Tools address this problem | |
by leveraging on the PDE tooling and in particular on the PDE Target Platform Definition. | |
A Target Platform Definition defines the bundles which your workspace will be built against. | |
</p><p> | |
At runtime however, a PDE Target Platform won't be available and | |
dependency resolution will always occur against the bundle | |
repositories configured for the Virgo Runtime Environment. The Tools | |
try to bridge runtime and development by providing a Server | |
wizard that creates a new PDE Target Platform Definition that | |
matches the Server repository configuration, | |
as defined in | |
<code class="code">org.eclipse.virgo.repository.properties</code> | |
. | |
</p><p> | |
The Virgo Runtime Environment supports watched, external and remote | |
repositories. Watched and external repositories correspond to | |
file system folders, while a remote repository is a remote Virgo | |
instance that can serve its repository content to other Virgo instances | |
for the purpose of dependency resolution. The PDE Target Platform allows its content | |
to be specified only as file system folders or P2 Update sites. As such, when the Tools create a | |
PDE Target Platform Definition from the runtime repository configuration only watched and | |
external repositories are considered. | |
</p><p> | |
Developers should properly setup a local Virgo Runtime Environment so that its bundle repositories | |
contain their application dependencies. Then they should use the Tools to setup a PDE Target Platform | |
so that their workspace projects are built and resolved against the same bundles that will be available | |
at runtime. | |
</p><p> | |
</p><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Note"><tr><td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="images/note.gif"></td><th align="left">Note</th></tr><tr><td align="left" valign="top"> | |
Note that when using the Tools together with PDE to develop for | |
Virgo it's not possible to use the MANIFEST.MF headers | |
<code class="code">Import-Bundle</code> | |
(not part of the standard OSGi specification but supported by | |
Virgo) | |
and <code class="code">Require-Bundle</code> | |
(part of the standard OSGi specification but not supported by Virgo). | |
Developers will have to declare all of their external dependencies | |
using the | |
<code class="code">Import-Package</code> | |
header only. | |
</td></tr></table></div><p> | |
</p></div></div><!--Begin LoopFuse code--><script src="http://loopfuse.net/webrecorder/js/listen.js" type="text/javascript"></script><script type="text/javascript"> | |
_lf_cid = "LF_48be82fa"; | |
_lf_remora(); | |
</script><!--End LoopFuse code--><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ch06s02.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="ch07s02.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">6.2 Editing the Manifest </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> 7.2 Server Runtime Wizard</td></tr></table></div></body></html> |