0
votes

Migrated application from 6.2 to 7.0. Server MobileFirst version: 7.0.0.00.20150312-0731

The application itself works great. When push new wlapp to server, the device see's update is available. Proceed to install update and fails.

logCat

W/PluginManager(11315): THREAD WARNING: exec() call to WLDirectUpdatePlugin.start blocked the main thread for 20ms. Plugin should use CordovaInterface.getThreadPool(). W/HardwareRenderer(11315): Attempting to initialize hardware acceleration outside of the main thread, aborting W/PluginManager(11315): THREAD WARNING: exec() call to WLDirectUpdatePlugin.showProgressDialog blocked the main thread for 44ms. Plugin should use CordovaInterface.getThreadPool(). E/com.worklight.androidgap.directupdate.WLDirectUpdateDownloader( 9466): WLDirectUpdateDownloader.validateZipFileIntegrity in WLDirectUpdateDownloader.java:129 :: Invalid direct update zip file, original file might have been altered or replaced.

2
In LogCat does it say what type of file was downloaded? It should be "application/zip." - DoraC
Is this only happening in Android? - DoraC
@DoraC added more logs. I see this blocked thread warning. Would that cause this issue? - Zachary Loughridge

2 Answers

0
votes

7.0.0.00.20150312-0731 is an awfully old build of MFPF 7.0; many fixes, including to Direct Update took place since.

I suggest that you will update to latest available iFix from IBM Fix Central to confirm this issue still happens to you.

0
votes

This is an issue in which the content type of returned direct update zip is not "application/zip" as it should be.

Note that Worklight server returns "application/zip" content type for android direct update. We have a test fix right now where we just log the different content type and continue the direct update process since it can be correct zip and content type can be changed by firewall for example.

If you create a PMR, we can give you a test fix to test (just drop worklight-android.jar into Android project -> deploy onto device). Once we confirm that it works we can deliver it to production builds. When submitting the PMR please link them to this StackOverflow question to give full background of issue.