librelist archives

« back to archive

Bosh connection

Bosh connection

From:
Daniel García Páez
Date:
2014-05-13 @ 22:33
Hi,

First, thanks for converse.js.
I'm trying to do prebind using Jbosh (smack bosh) to connect with Openfire
server. However I dont know how to get the RID and SID value.
I have implemented this code:

BOSHConnection connection = new BOSHConnection(false, "127.0.0.1", 7070,
"/http-bind/", "hostname");
connection.connect();
String sid = connection.getConnectionID();

Could you help me to get this values?

Thanks!

Re: [conversejs] Bosh connection

From:
Jc Brand
Date:
2014-05-14 @ 09:06
On Wed, May 14, 2014 at 12:33:49AM +0200, Daniel García Páez wrote:
>    Hi,
> 
>    First, thanks for converse.js. 
>    I'm trying to do prebind using Jbosh (smack bosh) to connect with Openfire
>    server. However I dont know how to get the RID and SID value. 
>    I have implemented this code:
> 
>    BOSHConnection connection = new BOSHConnection(false, "127.0.0.1", 7070,
>    "/http-bind/", "hostname");
>    connection.connect();
>    String sid = connection.getConnectionID();
> 
>    Could you help me to get this values?

I've never used Java for making a BOSH connection.

I would expect you to be able to get the SID and RID from the connection object
(of type BOSHConnection).

From this thread:
https://community.igniterealtime.org/thread/40768
it looks like you should just be able to call getRID to get the RID.

Re: [conversejs] Bosh connection

From:
jitu@ideas2it
Date:
2014-05-14 @ 05:34
Hope you can get by converse.getRID() and converse.getSID() ,

If you are using converse intialize method to intialize connection then you
can get this like above...

Sorry for my bad english... :)




On Wed, May 14, 2014 at 4:03 AM, Daniel García Páez <
daniegarcia254@gmail.com> wrote:

> Hi,
>
> First, thanks for converse.js.
> I'm trying to do prebind using Jbosh (smack bosh) to connect with Openfire
> server. However I dont know how to get the RID and SID value.
> I have implemented this code:
>
> BOSHConnection connection = new BOSHConnection(false, "127.0.0.1", 7070,
> "/http-bind/", "hostname");
> connection.connect();
> String sid = connection.getConnectionID();
>
> Could you help me to get this values?
>
> Thanks!
>