[xwiki-devs] Cant Load Plugin xwiki 1.4
Sergiu Dumitriu
sergiu at xwiki.com
Wed Jun 4 02:52:17 CEST 2008
marlon hendred wrote:
> Hi,
>
> I developed a plugin using the source i checked out of the trunk. I
> have build the war several times (with maven) to test the plugin and
> all has worked fine. Eventually after i was satisfied with my plugin.
> I jared up the classfiles using:
>
> $] jar cf my-plugin-1.0.jar com/xpn/plugin/myplugin/MyPlugin/*.class
>
>
> then i downloaded xwiki 1.4 from the xwiki site, and dropped my jar
> into the xwiki/WEB-INF/lib dir.
>
> Then i added:
>
> com.xpn.plugin.myplugin.MyPlugin
>
> to the list of active plugins in xwiki.cfg
>
>
> But when i tail catalina.out i see it complaining about not being able
> to find my plugin. Am i doing something wrong? Can someone please help
> me asap as we would like to go to production with this plugin. Thanks
> in advance.
>
If you didn't write it wrong in this mail, then the error is that
jar cf my-plugin-1.0.jar com/xpn/plugin/myplugin/MyPlugin/*.class
does not include a file called com.xpn.plugin.myplugin.MyPlugin
The best way to create a plugin is to write a distinct maven
module/project, you can start by copying and adapting
trunks/xwiki-platform-plugins/jodatime, for example. Then you just have
to execute 'mvn install' and the jar will be created.
--
Sergiu Dumitriu
http://purl.org/net/sergiu/
More information about the devs
mailing list