JAXL XMPP Sand alone

Skip to first unread message

willard kurisa

Jan 10, 2014, 6:23:02 AM1/10/14
to ja...@googlegroups.com
Can I use JAXL XMPP as a stand alone server? Can some please explan what JAXL actualy does?

Jason Stackman

Jan 16, 2014, 6:37:00 PM1/16/14
to ja...@googlegroups.com
I'm kind of wondering this too.  JAXL seems to be a constant stream that you need to run, but PHP scripts usually time out after 30 seconds.  What is the overall idea behind setting up JAXL?  Am I just supposed to setup my PHP to never timeout?

What I want to do is have JAXL run and store information about users that connect.  Then when I query a URL like www.mysite.com/?action=GetOnlieList&access_token=[token] it will spit out a JSON result of the users online for that access token.  Can anyone give me a general idea of how to do that?

Abhinav Singh

Jan 16, 2014, 6:59:39 PM1/16/14
to ja...@googlegroups.com
Jaxl started as xmpp client library (not server). 

Later networking parts were abstracted out and put under what I call as "core". Later, I also added server writing utilities under "core".

"xmpp" and "http" components just work with "core" library and doesn't use any inbuilt php socket/stream method.

So yes, Jaxl can be used as a standalone server. http server (yes), xmpp server (i won't recommend).

There is a basic http server implementation included too.

Since both xmpp and http components are based out of same core, you can also mix and match and play, e.g. xmpp_rest server example.

xmpp_rest example starts an xmpp client and then allow u to reach that xmpp client object via http.

Since v3.x, xmpp clients also support communication via unix sockets (command line). So one can start an xmpp client (in the background) and then later attach to the running xmpp process. Execute (eval) arbitrary php code, Use existing xmpp client object etc. There is support for pipes too.

All this probably gives u endless possibilities to explore.


Jason S

Jan 16, 2014, 8:23:53 PM1/16/14
to ja...@googlegroups.com
Thanks for the information, much appreciated.

Going back to my example with making a query to www.mysite.com/?action=GetOnlineList&access_token=[token], what do you think the best way to implement this would be?  I'm actually looking to tie it up to Facebook to retrieve messages, send messages, and get the online friends of a person through a URL that returns JSON.

Jason S

Jan 19, 2014, 10:54:21 PM1/19/14
to ja...@googlegroups.com
Bump, anyone have any ideas?
Reply all
Reply to author
0 new messages