[jdev] newbie Q: how can I use jabber to share file access P2P?
lists-2006 at tobias-thierer.de
Tue Apr 18 22:06:20 CDT 2006
I hope this is the right place to ask - otherwise I'd be glad to get some
pointers to better places. I have a task for which SOAP over XMPP (JEP-0072,
http://www.jabber.org/jeps/jep-0072.html ) might be the right tool. However,
I am entirely new to Jabber and web services, so I would like to get
feedback on the following questions:
1.) Is XMPP / SOAP over XMPP the right technology to use for my problem
(see below for a detailed description)?
2.) If yes, then which existing Java libraries would allow me to get the
job done most efficiently? I know of the Smack and the JSO (jabber
stream objects) libraries which implement XMPP (but not SOAP over
XMPP), but don't know which of them is suitable, stable and easy to
use. I don't know of any existing implementation of SOAP over XMPP.
3.) If XMPP/SOAP is not the right technology to use for my problem, what
else should I use?
Here comes a description of my current status, and of what I would want to
I've written an application in Java that allows users to organise documents
(e.g. DNA sequences, journal articles, protein structure) and perform
operations on them, and to import such documents from public databases. The
documents are XML files, typically a couple KBytes large, and there would be
typically 100-1000 (up to ~ 10,000) documents in a client's repository.
Now as a new feature, I'd like to give users the option of making the
documents that they have locally in their repository available to other
users. To avoid firewall issues, traffic between the clients would probably
have to be relayed by a server that I provide. The clients would have
contact lists (stored on the server) of people with whom they want to share
Obviously Jabber / XMPP suggests itself as a protocol for maintaining the
contact list. However, I am not really writing an instant messenger but
rather a P2P filesharing program, so I am not sure if XMPP is suitable (is
Specifically, after Romeo finds out that Juliet has shared her repository,
he must be able to perform the following operations:
1.) Send a filter (e.g. a search query) to Juliet and get a list of
documents in return that match the filter. This list should not
contain the actual files, but only some description (filename, filetype,
2.) Retrieve a specific shared file (identified through its description)
3.) in the future, there would be additional operations.
This sounds like SOAP (although I don't need interaction with other
languages, so I could use RMI or any other sort of RPC facility). Does it
seem right to use XMPP as the transport for SOAP? Or should I rely on other
lower-level protocols for enhanced performance?
a) Use XMPP for everything, as outlined above
b) Use XMPP for the contact list and to find out with whom to share data,
but then use SOAP over some other transport, or Java RMI, or anything
else, for the remaining communication?
c) Use something completely different altogether?
Which libraries should I use, and how feasible does the whole thing sounds?
Any other hints on how I should proceed?
I'd appreciate any feedback on the matter - as I said, I am very new to
Jabber and Web services, and I don't know how these things are typically
done. Of course, I don't want to make avoidable errors that others have made
Best regards, and thanks in advance for any help and pointers.
More information about the JDev