Add HTTP Binding support (BOSH / XEP-0124)

Description

Add support for Smack to connect to XMPP servers via HTTP binding.
XEP: http://xmpp.org/extensions/xep-0124.html

Environment

None
100% Done
Loading...

Activity

Show:

Florian Schmaus November 5, 2013 at 7:57 PM

Ge0rg's patch for https://igniterealtime.atlassian.net/browse/SMACK-463#icft=SMACK-463 needs to be applied to the BOSHConnection, from SMACK-187, too.

Neustradamus November 2, 2013 at 8:33 AM

Any news one year after my comment?

Kevin Kocher January 18, 2013 at 9:31 PM

I ran into the SSL version of a configuraion timing out as well, identical to Marjan's code above. I think I debugged the root cause to org.xlightweb.client.HttpClient

He's throwing an IOException being caught at line 130 in com.kenai.jbosh.XLightWebResponse
The detailMeassage is: ssl connection are not supported (use pool sslContext parameter constructor)
Has this already been solved, or is some other workaround in place? I'm new to all of this so I'm not sure what layer in all of this would be the one to try and implement a work around. Any ideas?
Thanks,
-Kevin

csh November 26, 2012 at 3:26 PM

I tried Guenther's implementation. It seems to work with my Smack 3.2.1 client, but I had to do some minor changes:
In the login method, put the authenticated = true BEFORE you load the roster, otherwise it throws IllegalStateException.

authenticated = true; anonymous = false; if (config.isRosterLoadedAtLogin()) { this.roster.reload(); }

Second, in the getRoster() I added:

synchronized (this) { // if connection is authenticated the roster is already set by login() // or a previous call to getRoster() if (!isAuthenticated() || isAnonymous()) { if (roster == null) { roster = new Roster(this); } return roster; } }

as it is done in XMPPConnection, since I have to add a RosterListener to the roster before I login. (otherwise I my Roster didn't load properly (with XMPPConnection)).

Mike Cumings November 19, 2012 at 4:07 AM

No news, sorry. I no longer have a need for this functionality and still have a noticeable lack of time for personal projects. The code for the JBOSH library can be found at:

http://kenai.com/projects/jbosh

or at a fork by another dev who was leveraging this for Android:

https://github.com/zewt/jbosh

If you wnt project administrative or committer rights to the kenai instance, just let me know.

Fixed

Details

Assignee

Reporter

Labels

Components

Fix versions

Affects versions

Priority

Created February 5, 2007 at 4:48 AM
Updated August 17, 2014 at 1:11 PM
Resolved February 19, 2014 at 10:28 PM