With the release of their new handsets and operating system,
Blackberry occupied lots of media space recently. This prompted me
to have a deeper look at their platform and to experiment a bit in
relation to ADF Mobile. You shouldn't read anything in this, by the way; my personal curiosity doesn't foreshadow Oracle's strategy.
The BlackBerry 10 OS, as you may know, is able to run most Android
applications through a runtime which supports about 70% of Android's
APIs. Just for the sake of it, I tried to repackage a very simple ADF
Mobile application and deploy it on the BlackBerry 10 simulator. Deployment
was successful, and I was even able to get past the splash screen.
It is only then that the application failed with an error message
stating « Network_ERR: XMLHttpRequest Exception 101 ». This application is self-contained and didn't call any web services, by
the way. The root cause of the error was obviously something else.
To be truthful, I expected the experiment to fail. The Android
toolkit provided by BlackBerry contains an executable that scans APKs (packaged Android applications) for
compatibility. When I ran it on my ADF Mobile APK, it flagged
various minor problems (since we are using various hardware
features) as well as a major issue: the presence of native
code. You can see the full output below:
Apk2Bar /Verifier version 1.5.1
Research In Motion Ltd ? 2012 All rights reserved.
[osname.apk]:(res/drawable-xhdpi/adfmf_icon.png) found an alternate icon with better size:impact=1
[osname.apk]:(AndroidManifest.xml) uses-feature: android.hardware.camera:required minimal Tablet OS version=2.1:impact=2
[osname.apk]:(AndroidManifest.xml) uses-feature: android.hardware.telephony:required minimal Tablet OS version=10.0.6:impact=2
[osname.apk]:(AndroidManifest.xml) uses-feature: android.hardware.camera.autofocus:required minimal Tablet OS version=10.0.9:impact=2
[osname.apk]:(AndroidManifest.xml) native-code: armeabi:impact=5
[osname.apk]:(com/phonegap/AudioHandler.java:275) uses method: android.media.AudioManager$setRouting:impact=1
[osname.apk]:(com/phonegap/AudioHandler.java:272) uses method: android.media.AudioManager$setRouting:impact=1
[osname.apk]:(com/phonegap/AudioPlayer.java:193) uses method: android.media.MediaPlayer$setAudioStreamType:impact=1
[osname.apk]:Summary: [5]=1; [4]=0; [3]=0; [2]=3; [1]=4;
Summary: [5]=1; [4]=0; [3]=0; [2]=3; [1]=4;
Impact Legend: [5]=Severe; [4]=High /context; [3]=Medium /context; [2]=Medium-low /context; [1]=Minor;
The offending native code is part of the JVM that we package with the application itself. Therefore, there is nothing we can do to circumvent the issue right now. Further releases of ADF Mobile could replace the current JVM, thus creating more favorable conditions for this to work.
I must say I was impressed by the developer tools provided by BlackBerry (formerly Research in Motion), especially the device simulator. Its boot time is an order of magnitude shorter than the Android Emulator's, and it was a joy to use.
Does your organization plans to get BlackBerry 10 devices? Is this new platform a more interesting target than Windows Phone? Let us know!