wood burning stoves 2.0*
The moose likes Java Micro Edition and the fly likes J2ME and JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Mobile » Java Micro Edition
Bookmark "J2ME and JSP" Watch "J2ME and JSP" New topic
Author

J2ME and JSP

Preety Agarwal
Ranch Hand

Joined: Sep 28, 2000
Posts: 75
Hi all,
I got one doubt that assuming i already have a full fleged JSP
application with ORACLE as the back end. what are the issues involved AND need to be addressed if i just want to extend this application to cater for palm and mobile users via J2ME..
Mark Herschberg
Sheriff

Joined: Dec 04, 2000
Posts: 6037
The good news is that MIDP, and likely all CLDC profiles wil support HTTP (I forget if that'sexplicitly in the CLDC spec). This means you can view you JSP pages.
The bad news is that you probably have some serious modifcations to make to get your app to be viable on such a small device. Additionally, if you are doing anything which needs to be secure, it will likely be very slow. (The latter isn't always true, you can hand tune the byte code, but this is very difficult.)
--Mark
Preety Agarwal
Ranch Hand

Joined: Sep 28, 2000
Posts: 75
Thanks Mark
it gives me some idea...i need to inveastigate further on this area and under some of the terminolgoes ...i am a J2ME DUDE..he he he.....
Preety Agarwal
Anil Vupputuri
Ranch Hand

Joined: Oct 31, 2000
Posts: 527
In MIDP, if it supports HTTP, are there any web servers for these devices to withstand request and response


SCJP 1.5, SCEA, ICED (287,484,486)
Rohini Sulatycki
Greenhorn

Joined: Jun 07, 2001
Posts: 5
I would be interested in this as well.
Thanks,
Rohini
Mark Herschberg
Sheriff

Joined: Dec 04, 2000
Posts: 6037
Originally posted by Anil Vupputuri:
In MIDP, if it supports HTTP, are there any web servers for these devices to withstand request and response


I don't follow.
Because HTTP is a standard protocol, a J2ME client can make the HTTP to any server that supports it, which is quite a large number, e.g. every web server. Now the HTTP response form most of the servers will probably be far bigger than you'd like on a mobile device. Generally speaking, one would write extra servlets to handle HTTP requists from J2ME devices, servlet's which format the content for small screens. Does that answer your question?
--Mark
Anil Vupputuri
Ranch Hand

Joined: Oct 31, 2000
Posts: 527
Originally posted by Mark Herschberg:

Generally speaking, one would write extra servlets to handle HTTP requists from J2ME devices, servlet's which format the content for small screens. Does that answer your question?
--Mark

Okay. I wud like to know whether these small devices can understand HTTP requests & responses. To my ignorance, I believe that these devices understands only WAP but not HTTP, correct me if Iam wrong. Are there any API's which dealt with
writing servlets for these small devices.
Thx.
Anil
Nizan Horsefield
Ranch Hand

Joined: Jun 05, 2001
Posts: 42
Anil
You seem a little bit confused as to what J2ME can do and how it differs to WAP. This link should take you to a topic where I have tried to explain the differences in lay-mans terms and provided a link for each. http://www.javaranch.com/ubb/Forum41/HTML/000236.html
Hope this helps
Niz :-)


Nizan Horsefield<BR>Sys Eng Internet Services<BR>Citibank
Mark Herschberg
Sheriff

Joined: Dec 04, 2000
Posts: 6037
Originally posted by Anil Vupputuri:
Okay. I wud like to know whether these small devices can understand HTTP requests & responses. To my ignorance, I believe that these devices understands only WAP but not HTTP, correct me if Iam wrong. Are there any API's which dealt with
writing servlets for these small devices.

MIDP requires HTTP support. Most other profiles likely will, too, probably all of them. SO you can write a MIDlet which can send HTTP get and post requests to a server.
The server can be implemented anyway you want, as long as it supports HTTP; but if you're using Java, you'd use servlets. You would just use the standard servlet API, but simply make sure the content of the HTTP response generated by the servlet was appropriate for the device (wrt small screen and limited bandwidth).
WAP is simply a protocol put out by a standards group (IETF?). A particular hpone may or may not support it. The MIDP spec doesn't say anything about it. It's unlikely other J2ME profiles will acknowledge it either. In fact, I was at a talk earlier today in which the speaker hinted that the motivations for WAP were apparently not quite true, and so there is some movement to phase out the W* protocols.
--Mark
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: J2ME and JSP