[JDEV] Multithreading at Jabber Server
Trejkaz Xaoza
trejkaz at xaoza.net
Tue Jan 6 02:26:13 CST 2004
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Tue, 6 Jan 2004 19:08, Nauman Khan wrote:
> Hi All,
>
> Will Jabber Server take care of multiple clients at the same time or we
> need to write some component which takes care of clients and then
> communictaes with Jabber Server. I assume that it will be an additional
> layer. Please comment.
Jabberd 1.x series and Jabberd2 can both take care of many, many clients at
once. Also for what it's worth you don't need multiple threads to take care
of multiple network connections (the only development environment where this
is the case is Java before version 1.4.)
> Also in case we need to implement some extra features in the clients -
> which might not be supported by Jabber Server, would we need some component
> to interact with Server so that our component can take care of extra
> functionality and simply forward the Jabber supported requests.
I see where you're going now. You were looking at proxying the real server.
This is not the way it's usually done. A Jabber component generally connects
to the server, logs in as a component, and gets packets forwarded to it based
on its name amongst other things.
Whether you need to write such a component depends on the feature. Some
features can be implemented entirely by the client. For instance, when you
make a "jabber:iq:version" query to a user, the query goes straight to the
user, their client responds, and the response comes straight back.
However, if it's a feature which needs server-like facilities, such as any
persistent storage or multi-user collaboration, you will need to write a
component which the server will forward relevant packets to, and which will
handle these packets and whatever logic is required. For instance, I
recently wrote a kind of 'waiting room' component which hears users join and
gives customer service an anonymised list of users, but removes users from
the list when the customer service staff ask to speak with them.
Hope this helps. Actually I'm feeling a bit scattered tonight so I can
explain further if you want. :-)
TX
- --
'Every sufficiently advanced technology is indistinguishable from magic' -
Arthur C Clarke
'Every sufficiently advanced magic is indistinguishable from technology' - Tom
Graves
Email: Trejkaz Xaoza <trejkaz at xaoza.net>
Web site: http://xaoza.net/trejkaz/
Jabber ID: trejkaz at jabber.xaoza.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
iD8DBQE/+nEnmifzwBMPxxoRAgq6AJ9pM4gQADMRD4j+hmbjkYSL0yuGFwCgkUCG
3zRvBKbkrgSFQzcuM35gw5Y=
=g7M1
-----END PGP SIGNATURE-----
More information about the JDev
mailing list