librelist archives

« back to archive

Bosh Session disconnects after 1 min

Bosh Session disconnects after 1 min

From:
Hari Krishna Sunkari
Date:
2014-11-04 @ 12:00
Hi

I’m using converse and openfire with prebind session from server. Below is
my config.



require(['converse'], *function* (converse) {

    converse.initialize({

       prebind: *true*,

       bosh_service_url: 'http://localhost:8081/http-bind/',

        jid: '<fromserver>',

        sid: '<fromserver>',

        rid: '<fromserver>',

        debug : *true*,

        allow_contact_requests:*false*,

        allow_muc : *false*,

        hide_muc_server: *false*,

        i18n: locales['en'],

        forward_messages: *true*,

        play_sounds: *true*,

        fullname : '${userSession.itwUser.name
<http://usersession.itwuser.name/>}',

        show_controlbox_by_default: *true*,



    });

});



On page load the BOSH Session gets established and will be active during
the chat interaction, I'm able to chat and send messages etc., but once the
page is left idle for 1min, the BOSH Session gets terminated.



Can anyone please let me know how to overcome this. I want the bosh session
to be active as long as the user doesn’t logout or until the user is in the
same page, so that I can use a single page for the whole app.





Regards
Hari

Re: [conversejs] Bosh Session disconnects after 1 min

From:
Nayana Hettiarachchi
Date:
2014-11-04 @ 13:58
use twisted punjab as a connection manager to solve this problem.
https://github.com/twonds/punjab

On Tue, Nov 4, 2014 at 7:00 PM, Hari Krishna Sunkari <
harikrishnasunkari@gmail.com> wrote:

> Hi
>
> I’m using converse and openfire with prebind session from server. Below is
> my config.
>
>
>
> require(['converse'], *function* (converse) {
> < p class="MsoNormal" style="font-family:arial,sans-serif;font-size:13px">
> converse.initialize({
>
>        prebind: *true*,
>
>        bosh_service_url: 'http://localhost:8081/http-bind/',
>
>         jid: '<fromserver>',
>
>         sid: '<fromserver>',
>
>         rid: '<fromserver>',
>
>         debug : *true*,
>
>         allow_contact_requests:*false*,
>
>         allow_muc : *false*,
>
>         hide_muc_server: *false*,
>
>         i18n: locales['en'],
>
>         forward_messages: *true*,
>
>         play_sounds: *true*,
>
>         fullname : '${userSession.itwUser.name
> <http://usersession.itwuser.name/>}',
>
>         show_controlbox_by_default: *true*,
>
>
>
>     });
>
> });
>
>
>
> On page load the BOSH Session gets established and will be active during
> the chat interaction, I'm able to chat and send messages etc., but once the
> page is left idle for 1min, the BOSH Session gets terminated.
>
>
>
> Can anyone please let me know how to overcome this. I want the bosh
> session to be active as long as the user doesn’t logout or until the user
> is in the same page, so that I can use a single page for the whole app.
>
>
>
>
>
> Regards
> Hari
>
>

Re: [conversejs] Bosh Session disconnects after 1 min

From:
Juan Jose Huelga
Date:
2014-11-04 @ 13:51
Log in into the Openfire admin console and check out this settings:

Server -> Server Settings -> Clients Connections (Idle Connections Policy).

I have read about Openfire's BOSH service disconnecting people, check
out this guide:

https://github.com/candy-chat/candy/wiki/Installing-a-XMPP-server

Regards

On 11/4/14, Hari Krishna Sunkari <harikrishnasunkari@gmail.com> wrote:
> Hi
>
> I’m using converse and openfire with prebind session from server. Below is
> my config.
>
>
>
> require(['converse'], *function* (converse) {
>
>     converse.initialize({
>
>        prebind: *true*,
>
>        bosh_service_url: 'http://localhost:8081/http-bind/',
>
>         jid: '<fromserver>',
>
>         sid: '<fromserver>',
>
>         rid: '<fromserver>',
>
>         debug : *true*,
>
>         allow_contact_requests:*false*,
>
>         allow_muc : *false*,
>
>         hide_muc_server: *false*,
>
>         i18n: locales['en'],
>
>         forward_messages: *true*,
>
>         play_sounds: *true*,
>
>         fullname : '${userSession.itwUser.name
> <http://usersession.itwuser.name/>}',
>
>         show_controlbox_by_default: *true*,
>
>
>
>     });
>
> });
>
>
>
> On page load the BOSH Session gets established and will be active during
> the chat interaction, I'm able to chat and send messages etc., but once the
> page is left idle for 1min, the BOSH Session gets terminated.
>
>
>
> Can anyone please let me know how to overcome this. I want the bosh session
> to be active as long as the user doesn’t logout or until the user is in the
> same page, so that I can use a single page for the whole app.
>
>
>
>
>
> Regards
> Hari
>

Re: [conversejs] Bosh Session disconnects after 1 min

From:
Derrick Katungi
Date:
2014-11-04 @ 14:13
Hello,

Thanks for the feedback.
It was actually a cross domain issue that i solved by uncommenting
proxy_http_modules
in xampp httpd.conf.

Adding below lines at the bottom of httpd.conf

ProxyRequests Off

ProxyPass /http-bind/ http://127.0.0.1:7070/http-bind/

ProxyPassReverse /http-bind/ http://127.0.0.1:7070/http-bind/


Using bosh_service_url: '/http-bind/'


All is well now. Thanks Team