Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
1ee7d06a
Commit
1ee7d06a
authored
Aug 19, 2016
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Further document the `auto_reconnect` option
and drop the reconnection timeout to 3 seconds (from 5).
parent
59143c1c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
2 deletions
+14
-2
docs/source/configuration.rst
docs/source/configuration.rst
+12
-0
src/converse-core.js
src/converse-core.js
+2
-2
No files found.
docs/source/configuration.rst
View file @
1ee7d06a
...
...
@@ -256,6 +256,18 @@ auto_reconnect
Automatically reconnect to the XMPP server if the connection drops
unexpectedly.
This option works best when you have `authentication` set to `prebind` and have
also specified a `prebind_url` URL, from where converse.js can fetch the BOSH
tokens. In this case, converse.js will automaticallly reconnect when the
connection drops but also reestablish earlier lost connections (due to
network outages, closing your laptop etc.).
When `authentication` is set to `login`, then this option will only work when
the page hasn't been reloaded yet, because then the user's password has been
wiped from memory. This configuration can however still be useful when using
converse.js in desktop apps, for example those based on `CEF <https://bitbucket.org/chromiumembedded/cef>`_
or `electron <http://electron.atom.io/>`_.
auto_subscribe
--------------
...
...
src/converse-core.js
View file @
1ee7d06a
...
...
@@ -423,8 +423,8 @@
(
converse
.
disconnection_cause
===
Strophe
.
Status
.
DISCONNECTING
||
converse
.
disconnection_cause
===
Strophe
.
Status
.
DISCONNECTED
)
&&
converse
.
auto_reconnect
)
{
window
.
setTimeout
(
_
.
partial
(
converse
.
reconnect
,
condition
),
5
000
);
converse
.
log
(
'
RECONNECTING IN
5
SECONDS
'
);
window
.
setTimeout
(
_
.
partial
(
converse
.
reconnect
,
condition
),
3
000
);
converse
.
log
(
'
RECONNECTING IN
3
SECONDS
'
);
return
'
reconnecting
'
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment