Ibm mobilefirst 在运行时更改服务器URL时,移动首次自动更新在iOS设备中失败

Ibm mobilefirst 在运行时更改服务器URL时,移动首次自动更新在iOS设备中失败,ibm-mobilefirst,mobilefirst-adapters,mobilefirst-server,mobilefirst-studio,mobilefirst-appcenter,Ibm Mobilefirst,Mobilefirst Adapters,Mobilefirst Server,Mobilefirst Studio,Mobilefirst Appcenter,我正在从事IBM MobileFirst Platform 7.1项目,在该项目中,我们有许多远程服务器,例如,Dev,Test等。要求是在运行时更改服务器,这样我们就不需要构建和分发多个应用程序 我跟着那位官员 下面是我用来在服务器更改后连接到服务器的代码 WL.Client.connect({onSuccess: function(){ WL.SimpleDialog.show( "Connection Success", "Successfu

我正在从事IBM MobileFirst Platform 7.1项目,在该项目中,我们有许多远程服务器,例如,Dev,Test等。要求是在运行时更改服务器,这样我们就不需要构建和分发多个应用程序

我跟着那位官员

下面是我用来在服务器更改后连接到服务器的代码

WL.Client.connect({onSuccess: function(){
        WL.SimpleDialog.show(
                "Connection Success", "Successfully connected to the server URL. Your app will reload once you press OK",  
                [{text: "OK", handler: function() {WL.Client.reloadApp();}}]
        );
    }, onFailure: function(error) {
        WL.SimpleDialog.show(
                "Connection Falied", error.status +" "+error.errorCode + " : " + error.errorMsg,  
                [{text: "Close", handler: function() {}}]
        );
    }});
它在Android中工作得非常好。但是,在iOS设备中,服务器会被更改并连接到新服务器。当自动更新运行以从更改的服务器获取新代码时,它会无限期地被卡住


任何帮助都将不胜感激。提前感谢。

这是否仅在您更改服务器url时才可用?如果在运行时不更改服务器URL,并直接连接到新服务器,它是否工作?@VivinK Yes。当我直接连接到新服务器而不在运行时更改它时,它确实可以工作。自动更新是指直接更新吗?是的。从移动第一服务器直接更新。