3

IBM Worklight 6.1.0 is now using Cordova v3.1. The upgrade process for Cordova configuration is automated.

My questions are:

  1. How the auto-upgrade is carried out in worklight?
  2. How do I know whether my Cordova library is updated?
  3. If the update is not carried automatically how to manually update it?
Cesar
  • 117
  • 1
  • 7
Kawinesh S K
  • 3,148
  • 1
  • 16
  • 29

1 Answers1

1

How the auto-upgrade is carried out in worklight?

After you install/upgrade to a new Worklight Studio version in Eclipse, if you have existing Worklight project already in the workspace then Worklight utilizes internal, custom-written, upgraders to check for the project version and will replace all old files (not just Cordova, but also other Worklight framework files) with new files.


How do I know whether my Cordova library is updated?

For the iPhone environment, for example, there is a version file: yourProject\apps\yourApp\iphone\native\CordovaLib\version

But not all environments have this file so IMO the easiest way would be to use the device.cordova API method:

  1. Put the following code snippet in your common\js\main.js > wlCommonInit() function.
  2. Build & deploy the project
  3. Preview the desired environment in Worklight Console or in a device or simulator/emulator, doesn't matter. You will see an alert with the used Cordova version:

    alert ("Used Cordova version is: " + device.cordova);
    


If the update is not carried automatically how to manually update it?

  • You cannot yet manually change the used Cordova version in a Worklight application. Again, the upgrade process of a Worklight project is more than just replacing the used Cordova version in the application

  • If that happens there will be errors involves. Lets tackle these if and when you'll encounter any issues...

Idan Adar
  • 44,156
  • 13
  • 50
  • 89
  • Actually I'm working with Worklight 6.1 (cordova 3.1) and I want to update my Cordova version without updating my Worklight version. Any how to achieve this ? also even with updating the Worklight version to 6.2 ( which is based on cordova 3.4) doesn't reply to the security issue on Android platform (http://cordova.apache.org/announcements/2014/08/04/android-351.html) . If I want to use Cordova 3.5.1 in my project , is there a workaround to do it ? – ghost rider3 Oct 02 '14 at 15:02
  • No need. All versions of Worklight have been updated with the security fixes for their respective Cordova versions; all that you need to do is download the latest iFix for your Worklight version from IBM Fix Central. – Idan Adar Oct 02 '14 at 15:04
  • You can't also update manually the cordova version for version 6.2, 6.3 and 7.0. – Cesar Jul 29 '15 at 14:22