ez all
i'm pretty new with whack and i have some perplexities about the weather example...i built it, run it: now what? how i can use it? i suppose i have to write a client plugin but...
thanks!
Hi, for testing you can use Psi for example, add your weather component in your buddy list and send him a message with a weather station from http://weather.noaa.gov/ (see the attached screenshot).But for a comfortable usage, yeah, maybe you can write a client ![]()
I read that the weather example was in a sample folder in the source. I downloaded the source zip and did not find it.
Q: Where are you getting the weather example these days?
Thanks,
You can get it via subversion
svn co http://svn.igniterealtime.org/svn/repos/whack/trunk whack
But currently I think you can't compile the trunk if you don't fix some old references. See my attached patch to compile and run the actual revision (11087).
Best regards
I changed the whack.jar build compile target includes in order to pick up the xmpp classes. That allowed me to use whack.jar in my component project. I hope I'm on the right track..
Thanks!
<target name="jar" depends="compile" unless="jar.uptodate" description="Produces whack.jar">
<jar destfile="${jar.dest.dir}/whack.jar"
basedir="${compile.dir}"
includes="org/**/*.class" />
<!-- includes="org/jivesoftware/whack/**/*.class" -->
</target>
1) I rebuild whack.jar from SVN - just needed to modify the build.xml to include more classes in whack.jar.
2) I got the weather sample to compile against these jars:
commons-httpclient.jar
dom4j.jar
jweather.jar
tinder-1.0.0.jar
xpp3.jar
commons-logging.jar
jakarta-oro.jar
log4j.jar
whack.jar
2) When I try to run the weather example I get:
Exception in thread "main" java.lang.NoClassDefFoundError: org/jivesoftware/stringprep/IDNA
at org.xmpp.packet.JID.init(JID.java:369)
at org.xmpp.packet.JID.<init>(JID.java:248)
at org.jivesoftware.whack.ExternalComponentManager.addComponent(ExternalComponentM anager.java:212)
at org.jivesoftware.whack.ExternalComponentManager.addComponent(ExternalComponentM anager.java:191)
at org.jivesoftware.weather.ExternalWeatherComponent.main(ExternalWeatherComponent .java:32)
Caused by: java.lang.ClassNotFoundException: org.jivesoftware.stringprep.IDNA
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 5 more
3) It looks like the missing class is required by the tinder jar. My goal is to run the weather example.
Woops, sorry - found stringprep.jar to fix my runtime problem
Weather example is running, thanks!
I fixed the current trunk version of whack for the updated API and libraries.