Reputation: 181
I'm running WL 6.1 (6.1.0.01.20140310-1427) on a macbook air (latest OSX). I have a dojo hybrid application that I'm trying to connect to a remote WL server. When I generate an iOS app and I'm changing the address of the worklight server to a remote server. It does not change the address in the generated iOS code. The steps I follow are:
At this point they are still referencing my local server. If I edit them to point to the remote server, then my app works. Since these files are regenerated every time you do a build this is not a valid solution.
To verify it is nothing in my app, I created a default dojo hybrid application. Performed the steps I listed above. When I launched into xcode, the Root.plist and worklight.plist still have the default local server information.
So here is the funny thing. I also have a win7 system running the same level of WL developer plugin. I perform the same steps and the worklight.plist file is updated correctly on windows, just not in osx. The only other difference is the win7 version is running jre 1.7_21 where the osx is running 1.7_51. Both are in 64-bit mode.
Upvotes: 1
Views: 611
Reputation: 44516
I believe the real difference between your Mac and Windows machines is step 5, where you "launch into xcode". If by that you mean that you are actually doing Run As > Xcode project, then see below. This option is available only in Mac and not in Windows.
This is the expected behavior in Worklight 6.0.0.x and 6.1.0.x.
If after changing the server address to a remote server (rather than the local development server) and building, and then selecting Run As > Xcode project, this will overwrite the server settings back to the local development server.
Run As > Xcode project does 3 actions:
So if you want to use the app with the remote server settings, then after changing the settings and build the app, either:
For future releases of Worklight it is being considered to streamline the behavior so that no matter if you choose, local or remote server settings, Run As > Xcode project will always use the ones you've selected.
Upvotes: 3