05-31-2011 03:26 AM
I'm trying to make a servlet that is going to deliver an application to a blackberry phone. My problem is that after i send the JAD file I cannot download the cod file. The bb browser gives me some Invalid COD error (not found).
My JAD file contains a referrence to a COD like this: RIM-COD-URL: xxxx.cod.
After the phone downloads the JAD and i hit download, I don't receive any requests in my servlet for the COD file.
Is it not using http protocol to download the COD ? or is it not using the same relative path to get CODs as it does for the JAD.
My url looks like this: "http:IP:8080/bbServlet" , bbServlet denotes my servlet.
When i access it with the phone i receive the JAD file, and i can detect this on the server side.
If I hit download on the phone , it gives me the error.
Isn't it suppose to make a request for the COD file like this:
I hope someone knows.
PS:I cannot make my application files public on the server.
Solved! Go to Solution.
05-31-2011 04:42 AM
"I don't receive any requests in my servlet for the COD file."
I think the download processing expects to download the file directly itself and so will issue an http request for the specific files identified in the jad. I think you will to intercept these to provide the cod file from your Servlet.
In your case where the base URL is
I suspect the downloads will be directed to
It might be that by manipulating the jad you can do something different, look at the jad file itself, specifically the RIM URL lines and that will give you ideas.
05-31-2011 06:39 AM
I managed to make it work. The problem was the BES that my company owns, i think. Imediately after the JAD request was made there was another request made by the phone but this time the User-Agent header was different: MDS_18.104.22.168; and it requested the first .cod file.
I sent all the cod files to each request that followed and it all worked.
The thing is I sent the 1st cod to the MDS request and also to the BlackBerry request and i wonder if i send the cod file twice.
Do you have any ideea why there was a request with the user-agent MDS ? And it is for ?