Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Blackberry working with Tomcat

 
Asheesh Nehra
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi experts, I am new to Blackberry and I am trying to call a very simple servlet from Tomcat. I am using Ecllipse with BlackBerry plug in but have also separate installs for Blackberry simulator and MDS-CS. My MDS is listening on port 8080 (at least that what they say it listens to by default), and my Tomcat is listening on port 8081. I have placed my simple servlet in WEB-APS directory on Tomcat server. When I try to access it from Internet Explorer by entering: http://localhost:8080/myDir/myServlet I get reply from my servlet as I expected. When i do request from blackberry application to that link then i got exception at HttpConnection.OpeninputStream . This piece of ccode is working for the MIDlet fine but when i run this in the blackberry application then throw exception at the HttpConnection.OpeninputStream.

please any body help me out
Thanks
 
Carol Hamer
author
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
To narrow down exactly where the problem is, I'd recommend the following tests:

1. Try accessing your servlet from a browser on the BlackBerry. If the servlet is accessible from IE on a computer but not from the BlackBerry's browser, then it's probably a network-level problem. (For example: the mobile operator may have restrictions on accessing non-standard ports via HTTP).
2. If you can access the servlet from your BlackBerry's browser, then try a test MIDlet -- with the same code -- but have it load another URL (one that you know should work like Google or JavaRanch). If you still get an exception, then the problem is the MIDlet code.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic