IDEMPIERE-4676 Browser hangs after restarting iDempiere or refreshing… (#557)
* IDEMPIERE-4676 Browser hangs after restarting iDempiere or refreshing ui.zk, on macos sometimes during work * IDEMPIERE-4678 Save log informing Notice created when background job stop immediately when server is not reachable
This commit is contained in:
parent
fd3fef9e7b
commit
3d70b5dd63
|
@ -45,7 +45,7 @@ Copyright (C) 2007 Ashley G Ramdass (ADempiere WebUI).
|
|||
</component>
|
||||
|
||||
<javascript-module name="org.idempiere.websocket" version="202011211500"/>
|
||||
<javascript-module name="jawwa.atmosphere" version="202101150800"/>
|
||||
<javascript-module name="jawwa.atmosphere" version="202101290100"/>
|
||||
<javascript-module name="adempiere.local.storage" version="202011151100"/>
|
||||
<javascript-moudle name="html2canvas" version="1.0.0.rc7"/>
|
||||
<javascript-module name="org.idempiere.commons" version="202012030330"/>
|
||||
|
|
|
@ -40,14 +40,16 @@
|
|||
var me = this;
|
||||
this.ajaxOptions.error = function(jqxhr, textStatus, errorThrown) {
|
||||
if (me.trace)
|
||||
console.log("error: " + textStatus + " dtid: " + me.desktop.id + " errorThrown: " + errorThrown);
|
||||
console.log("error: " + textStatus + " dtid: " + me.desktop.id + " errorThrown: " + errorThrown + " status: " + jqxhr.status);
|
||||
if (textStatus != "timeout" && textStatus != "abort" && errorThrown != "SessionNotFound") {
|
||||
if (typeof console == "object") {
|
||||
console.error(textStatus);
|
||||
console.error(errorThrown);
|
||||
}
|
||||
console.error("error: " + textStatus + " errorThrown: " + errorThrown + " status: " + jqxhr.status);
|
||||
//stop immediately if server is not reachable
|
||||
if (jqxhr.status == 404 || jqxhr.status == 0) {
|
||||
me.failures = 3;
|
||||
} else {
|
||||
me.failures += 1;
|
||||
}
|
||||
}
|
||||
};
|
||||
this.ajaxOptions.success = function(data) {
|
||||
if (me.trace)
|
||||
|
@ -69,7 +71,7 @@
|
|||
};
|
||||
},
|
||||
_schedule: function() {
|
||||
if (this.failures < 20) {
|
||||
if (this.failures < 3) {
|
||||
this._req = null;
|
||||
setTimeout(this.proxy(this._send), this.delay);
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue