[xwiki-devs] Cant Load Plugin xwiki 1.4
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. -Marlon
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/
My directory structure was wrong. I moved the class files up a directory and created the jar and every thing works fine now. $] jar cf my-plugin-1.0.jar com/xpn/plugin/myplugin/*.class rather than: $] jar cf my-plugin-1.0.jar com/xpn/plugin/myplugin/MyPlugin/*.class Thanks! -Marlon On Tue, Jun 3, 2008 at 5:52 PM, Sergiu Dumitriu <[email protected]> wrote:
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/ _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
participants (2)
-
marlon hendred -
Sergiu Dumitriu