Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

J2ME client to J2EE EJB

 
Mikkel Arentoft
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All
We are working on a J2EE EJB application server project where we want to connect a PDA running J2ME.
We have been experimenting with accessing the EJB's from the PDA without any success.
So I was wondering if anyone had any experience accessing an EJB from a J2ME application.
 
a sanjuan
Ranch Hand
Posts: 164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how exactly, are you trying to "access" the ejb from the pda? wouldn't accessing the j2me app via servlets be more efficient? i've had no problems accessing serverside webapps from a palm when my palm is connected to the internet.
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes Servlets are the way to go. You will have a buffer between your EJBs and the PDA. that way you can take whatever you get from the EJB and make it such that the transfer to the PDa is the smallest it can be, thereby speeding your application.
Servlets can access EJBs very nicely, that is why in their web.xml files they have tags for EJB's.
When I say Servlets I also am including JSP in there.
Unfortunately, it looks like you can't use RMI to access classes outside the PDA, that is why you can't access EJBs directly.
Mark
 
Mikkel Arentoft
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the replies. I was investigating my options and it is clearly the best way to write a set of high level business functions in a servlet and use that.
But please explain the point about RMI? I have used RMI on a PDA to access classes on a desktop computer without any problems. Why can't it be extended to access EJB's?
Mikkel
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My exposure is to MIDLets on MIDP, so on higher more robust PDAs, it could be possible that RMI is available. I have not seen those APIs.
If anyone knows if RMI is available to MIDP let me know too.
Mark
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic