07-22-2008 08:25 AM
I am trying to install application OTA. I have successfully installed for single COD by modifying JAD to point to the server URL. However in my application there are several COD files and I want them all to be installed once. So based on knowledge Base Article I added
for all COD files in single JAD. Since I am using signed code I updated size param with the new cod file size also.
When I point to this JAD file URL I get HTTP 500 error and Details shows it to be java.lang.NullPointerException.
Also I added dependency of all project into RIM-COD-Module-Dependencies, though I ve tried without changing it as well.
Here is my complete JAD file ..let me know if I have missed anything..
Manifest-Version: 1.0 RIM-COD-Module-Name: SosAlert RIM-COD-Module-Dependencies: net_rim_cldc,net_rim_locationapi,Objects,Applicati
onServices,net_rim_xml MIDlet-Jar-Size: 2071 MIDlet-1: ,, RIM-COD-Creation-Time: 1216305305 MIDlet-Jar-URL: SosAlert.jar RIM-COD-URL-1: http://serverip/temp/ExternalJarsLib.cod RIM-COD-Size-1: 33904 RIM-COD-URL-2: http://serverip/temp/Objects.cod RIM-COD-Size-2: 6840 RIM-COD-URL-3: http://serverip/temp/ApplicationServices.cod RIM-COD-Size-3: 4536 RIM-COD-URL: http://serverip/temp/SosAlert.cod RIM-COD-Size: 3716 MicroEdition-Configuration: CLDC-1.1 MIDlet-Version: 0.0 MIDlet-Name: SosAlert MIDlet-Vendor: <unknown> MicroEdition-Profile: MIDP-2.0 RIM-MIDlet-Flags-1: 0
Thanks in adavance.
Solved! Go to Solution.
07-22-2008 10:32 AM
You should not have to list your individial modules in the RIM-COD-Module-Dependencies section. Here are a couple questions that might help:
1. Are any of your cod files actually multiple cods (rename to the app.cod to app.zip and try to extract). If they are each extracted cod should be listed as separate RIM-COD-URL/Size-N in the jad.
2. Is your server setup with the correct mime types? The mime type for a jad should be text/vnd.sun.j2me.app-descriptor and the mime type for cod should be application/vnd.rim.cod
3. After you get the NullPointerException check your event log by going to the home screen and pressing Alt-LGLG. There may be an entry in bold that relates to the NullPointerException and has a stack trace. This may give us some insight as to why this is happening.
4. Try it on the simulator and see if the simulator's output has anything relevant.
Also let us know which jde you are building with and which OS/device model you are using when you get these errors.
07-22-2008 11:44 AM
Don't use the full HTTP path in the JAD, they're relative, so just put the names of the .cod files, i.e.:
MIDlet-Name: My Silly App
MIDlet-Description: Wish it would do something
MIDlet-Vendor: RIM Should Buy Us For Big Bucks, Inc.
That's a minimal JAD file for BlackBerry OTA that involves 3 separate modules.
Just make sure the JAD file and the COD files are all in the same folder and everything will work fine, all that's needed is the HTTP URL to the JAD file. Be sure also to list the COD files in reverse order of dependency, i.e. so the dependent ones are loaded first. And keep them each under 65536 bytes in size.
I'll be posting a longer description of OTA on my site soon.