I just compiled whack library and the sample weather component I checked out a few days ago.
Now, I want to use it with a jabberd1.4 server (or jabberd2.0 - I work for two different teams: the first want to test jabberd and XCP, the second one jabberd and Jive Messenger, but deadlines are different, and I have to test jabberd2 first).
To use it, I registered weather component like the (so-called well known bandersnatch. That’'s to say, the weather component received message as blind copy. XML stream received by the component is like: .
As as consequence, the weather component shut down by an “Unknown packet type was read: route” exception (at org.jivesoftware.whack.SocketReadThread.readStream(SocketReadThread.java:107).
I suppose that I have to set up jabberd in a different way, but I don’'t know how.
I know it isn’'t the jabberd mailing-list, but it may not be a jabberd configuration problem but a wrong usage of the weather component. What do you think about it?
I don’'t know how to plug the weather component on a jabber server. Does it works only with Jive Messenger?
Eventually, my goal is to write a component which will intercept messages between two JID of my domain to filter messages or to modify them. Is component way the correct way to do this?
I think that by default, jabberd may not follow the JEP-114 protocol. Instead, it puts all packets in a wrapper packet. You’'d need to make jabberd use the standard component protocol instead to make it work with Whack.
Eventually, my goal is to write a component which will intercept
messages between two JID of my domain to filter messages or to
modify them. Is component way the correct way to do this?
I think you also posted on jdev about this? As I mentioned there, the easiest thing to do would be to write a plugin that acts as a packet interceptor. It would be very hard to implement this feature using external components since external components only listen for the traffic on a subdomain of a server. So, the “foo” component would get all traffic to “foo.example.com” on the “example.com” server. Jive Messenger packet interceptors get to listen to all packets so are much more flexible.
I think that by default, jabberd may not follow the JEP-114 protocol.
…
After a second try, using weather component as a service for a subdomain instead of using it as a bcc component, jabberd1.4 and whack succeed to work together.
…
I think you also posted on jdev about this?
…
yes
I’'ll try to write a module for jabberd 2.0 in order to intercept packets.