Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>At present this is what I can come up with</p> <p><strong>POM-First Pros (using maven-bundle-plugin)</strong></p> <ul> <li>Leverages existing Maven skills, repositories and tooling.</li> <li>Likely easier to find people who know how to manage pom.xml rather than MANIFEST.MF along with pom.xml</li> <li>Most of the information in MANIFEST.MF can be obtained from the pom.xml itself.</li> <li>Can work with other IDEs not just Eclipse based ones.</li> <li>Less invasive, just add the <strong>single</strong> plugin and change the packaging type to "bundle"</li> </ul> <p><strong>POM-First Cons</strong></p> <ul> <li><code>ClassNotFoundException</code> more likely to occur at runtime. However, this can be mitigated using pax-exam (although it is very complicated to set up).</li> <li>Still need to understand how the MANIFEST is setup to make sure the <code>instructions</code> configuration element is set correctly. </li> </ul> <p><strong>MANIFEST-first Pros (using tycho-maven-plugin)</strong></p> <ul> <li>Seems to be the recommended approach, or at least talked about as the recommended approach, but I can't really see why it has significant benefit. (Hence why this question was asked).</li> <li>Good for developing Eclipse plugins and integrates well with PDE</li> <li>Provides tooling for testing thus allowing <code>ClassNotFoundException</code> to appear during JUnit testing rather than runtime.</li> </ul> <p><strong>MANIFEST-first Cons</strong></p> <ul> <li>Seems to only work well on Eclipse based IDEs. You don't have to use Eclipse, but without the PDE would you want to?</li> <li>Violates DRY principles since I have to do put keep the names and versions from the POM and MANIFEST.MF in sync.</li> <li>Need to name things in a specific fashion</li> <li>You cannot mix, meaning existing Maven multi-project installations cannot just tack on OSGi support</li> <li>A lot more configuration compared to maven-bundle-plugin is needed to get less warnings: <a href="http://wiki.eclipse.org/Tycho/Reference_Card#Examplary_parent_POM" rel="noreferrer">http://wiki.eclipse.org/Tycho/Reference_Card#Examplary_parent_POM</a></li> <li>Have to make test cases a separate project. It won't run when built in src/test/java.</li> <li>Seems that it will only test classes that are exposed, in other words those in ".internal." is not testable.</li> </ul> <p>If I were asked for a recommendation for an enterprise that is using Maven already and want to move to OSGi then it would be <strong>POM first</strong></p> <p>If I were asked for a recommendation for someone who is doing Eclipse plugin development, then it is <strong>Manifest first -- with tycho</strong></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload