Caveat when converting an Eclipse Java project to a plug-in project

Based on some advise I got in the “Meet the Developers” lab at Lotusphere I converted a Java project to a plug-in project in Eclipse today. This will make it easier to manage my dependencies instead of manually having to export the model classes as a jar and including that. I tried it before but it didn’t work. Today I found out why.

The conversion via right-clicking and choosing “Convert Projects to Plug-in Projects” (in the “PDE Tools” section) went fine but afterwards the classes from the plug-in wasn’t found by my sidebar plug-in in Notes 8. Compilation in Eclipse went fine.

The issues turned out to be caused by Eclipse not automatically adding the compiled classes to the plug-in. To solve this I had to open the manifest (MANIFEST.MF), switch to the “Build” tab and in the “Runtime Information” section add a library named “.” (yes a period) on the top left and the source code folder I wanted to include on the top right.

Once I did that everything went smoothly.