Hi guys
im a bit confused as to how to go about building a plugin that im creating. I have provided the code for the plugin as an attachment.
My plugin is a very simple plugin that **does not require the admin console **since there is nothing to set . The only jar file the plugin needs is the openfire.jar file.
i have already seen the plugin development help page and im familiar with the directory structure the plugin need to be complied correctly by the openfire build script.
with the above details i have assumed that my plugin directory structure should look like this:
ConExLock/
-| plugin.xml
-| src
-| java
-| ConExLock
-| ConceptionExLock.java
My question is do i need any of the other folder/files mentioned in the help page?
as i see it i dont need
-the classes folder (no properties)
-the lib folder (only jar im using is the openfire.jar)
-the database folder in the src folder
-the web folder in the src folder (since i dont need admin console controls)
I put my plugin folder in the src/plugin folder of the openfire source directory and ran the build using ant plugins and i get the message saying the build was successful.
The problem im having right now is when i run the openfire server my plugin does not load and i get the following error:
2009.10.08 04:29:10 [org.jivesoftware.openfire.container.PluginManager.loadPlugin(PluginManager.jav a:507)
] **Error loading plugin: C:\SreesApplications\Openfire\plugins\conexlock **
**java.lang.ClassNotFoundException: org.example.ExamplePlugin **
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at org.jivesoftware.openfire.container.PluginManager.loadPlugin(PluginManager.java :385)
at org.jivesoftware.openfire.container.PluginManager.access$300(PluginManager.java :47)
at org.jivesoftware.openfire.container.PluginManager$PluginMonitor.run(PluginManag er.java:1032)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(Unknown Source)
at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101 (Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodi c(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknow n Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
I dumbfounded… can someone please tell me wht im doing wrong?
Thanks in advance
Sreejit
plugin.xml (1197 Bytes)
ConceptionExLock.java.zip (1569 Bytes)