View Single Post
  #1 (permalink)  
Old 06-24-2009, 10:44 AM
hdawg's Avatar
hdawg hdawg is offline
Proprietor
 
Join Date: Nov 2008
Posts: 2,257
Blog Entries: 147
Default KB17084 - Wireless application deployment over WAP

KB17084 - Wireless application deployment over WAP


Environment

  • BlackBerry® Enterprise Server
  • BlackBerry smartphones



Overview

This document is intended for wireless operators or wireless portal providers who want to deploy applications wirelessly to BlackBerry smartphones.
BlackBerry® Device Software 3.6 and later allows BlackBerry smartphone users to download third-party Java® applications wirelessly using the BlackBerry® Browser. BlackBerry smartphone users can manage, run, and delete these applications using BlackBerry® Desktop Manager. The BlackBerry smartphone supports Java applications, called MIDlets, that use the Mobile Information Device Profile (MIDP) application programming interfaces (APIs), as well as Java applications that use BlackBerry APIs.
This implementation follows the functional requirements that are specified in Over The Air User Initiated Provisioning Recommended Practice for the Mobile Information Device Profile: Version 1.0, which is published by Sun Microsystems®.
Supported file types

The following two files are required for an application to be downloaded wirelessly to the device:
  • A JAD file is an application descriptor that provides information about the application and the location of COD files.
  • A COD file is a compiled and packaged application code (BlackBerry specific format).
The BlackBerry Browser uses the JAD file to discover applications for download. This required JAD file provides a URL to the COD files for the application. Application COD files cannot be downloaded directly if a JAD file is unavailable.
The BlackBerry smartphone does not support JAR files. Therefore, the JAR files for MIDP applications (MIDlets) are converted into the BlackBerry COD file format using the BlackBerry® Java® Development Environment (BlackBerry JDE). To download the BlackBerry JDE, visit the BlackBerry Developer® Zone.
Third-party Java applications written using the BlackBerry JDE are packaged into COD files.
Note: The provisioning server and web server set the Multipurpose Internet Mail Extensions (MIME) type for JAD files to text/vnd.sun.j2me.app-descriptor. The web server sets the MIME type for COD files to application/vnd.rim.cod.
Application descriptor file

Additional JAD file parameters (identified by a RIM-COD prefix) are required to support COD files. These parameters are added automatically when you build applications using the BlackBerry JDE or when you convert JAR files using the BlackBerry Converter.
Parameter Description
RIM-COD-URL
URL to the location of the COD file for the application
RIM-COD-Size
Size of the COD file in bytes
RIM-COD-Module-Name
Name of the application
RIM-COD-Module-Dependencies
Software modules that exist on the device to install this application
RIM-COD-Creation-Time
Time when the COD file was created


The following is an example of a JAD file for a third-party Java application:
Manifest-Version: 1.0
RIM-COD-Module-Name: Expense_Reporter
RIM-COD-Module-Dependencies: net_rim_os,net_rim_cldc
RIM-COD-Creation-Time: 1051886195
MIDlet-Jar-URL: unknown
RIM-COD-URL: expense_reporter.cod
RIM-COD-Size: 15112
MicroEdition-Configuration: CLDC-1.0
MIDlet-Version: 0.0
MIDlet-Name: unnamed
MIDlet-Vendor: anonymous
MicroEdition-Profile: MIDP-1.0
Note: You can create a dual-purpose JAD file to support the downloading of MIDlets on both BlackBerry smartphones and third-party devices. Create a JAD file that contains both RIM-COD-URL and RIM-COD-Size entries and MIDlet-Jar-URL and MIDlet-Jar-Size. On BlackBerry smartphones, the COD files are downloaded; on other devices, the JAR files are downloaded.
You can specify multiple COD files in a single JAD file by appending a number to the RIM-COD-URL and RIM-COD-Size headers as follows:
RIM-COD-URL-1: expense_reporter.cod
RIM-COD-Size-1: 19292
RIM-COD-URL-2: expense_lib.cod
RIM-COD-Size-2: 12291
When the application is downloaded on the BlackBerry smartphone, the multiple COD files are not displayed. The size of the application is displayed as the sum of the COD file sizes.
Application discovery

To locate application to download, use the Wireless Application Protocol (WAP) browser on the BlackBerry smartphone.
  1. In the WAP browser, the user views a link to a JAD file.
  2. The user selects the link to start the installation process.
  3. The WAP browser downloads the JAD file, which the application loader tool uses to start the application installation.
As specified in the OTA Recommended Practice, the web server sets the MIME type of the JAD file to text/vnd.sun.j2me.app-descriptor.
Application installation
As specified in the OTA Recommended Practice, the BlackBerry smartphone supports UTF-8 as the default character set for JAD files.
  1. Using the information in the selected JAD file, the WAP Browser displays a dialog box with information about the application such as name, version, vendor, and size (To see an example click on Figure 1).
  2. To cancel the installation process, click Cancel; to continue the installation process, click Download.
  3. Using the URL specified in the JAD file, the BlackBerry smartphone downloads the application COD file using HTTP. If the server or proxy includes a Set-Cookie header in the response, the WAP browser stores the cookie values.
  4. If the server or proxy responds to the request for the application with a 401 (Unauthorized) or 407 (Proxy Authentication Required) response, a dialog box appears. Type a username and password. The BlackBerry smartphone resends the request with the user-supplied credentials.
  5. The application loader tool verifies there is enough space on the BlackBerry smartphone to install the application; if there is insufficient space, the installation stops.
  6. The application loader tool displays a message to the user when the installation is complete. Note: The BlackBerry smartphone does not support the MIDlet-Install-Notify attribute in the JAD file and does not send an installation status report to indicate the success or failure of the application installation.
  7. On the BlackBerry smartphone Home screen, click the icon to start the application.
Application update

The Application Manager on the BlackBerry smartphone does not distinguish between an application update and a new installation. If you install an application that already exists on the BlackBerry smartphone, you are not notified. The existing application is removed and replaced by the new application.
Application removal

To delete third-party applications from the BlackBerry smartphone:
  1. In Options, click Applications or Advanced Options > Applications to view a list of third-party applications that are installed on the BlackBerry smartphone.
  2. To view information about an application, select it, and click Properties or View Properties.
  3. To delete an application, select it and click Delete. You are prompted to confirm the deletion.
Note: The BlackBerry smartphone does not support the MIDlet-Delete-Confirm attribute in the JAD file and the value of this attribute is not included in the confirmation prompt.
WAP gateway configuration

In a WAP environment, BlackBerry smartphone users download applications using the WAP Browser on the BlackBerry smartphone, which uses the WAP protocol stack to communicate with the WAP gateway.
To support wireless application download for BlackBerry smartphones, WAP gateways must meet the following requirements:
  • Support MIME types for JAD and COD files ( text/vnd.sun.j2me.app-descriptor and application/vnd.rim.cod)
  • Follow the rules for HTTP proxies (RFC 2616) for the JAD and COD MIME types
  • Support HTTP authentication (server responses 401 and 407)
  • Pass any set-cookie headers to the BlackBerry smartphone
Attached Images
 
__________________
http://blog.port3101.org/hdawg/
Reply With Quote
Sponsored Links