Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

EJB3.0 on Sun WebApp9.0 - dead end!

 
Kevin P Smith
Ranch Hand
Posts: 362
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys, wondering if you can help me as I'm a bit stuck with my EJB3.0 remote connection using Sun's Java WebApp9.0 Server.

Quick over-view:
I have a Client.war file which contains my Servlets and the Remote interfaces for teh EJB and other 'client' classes
I have a EJB.jar which contains the EJBs with their interfaces

I need to make a remote connection to the CreateNewUserAccountBean (Stateless) which connects to the Uploader (Entity) Bean
I have tried to post all the relivent parts of the code, but it's quite hard to make sure I have everything.

My code gets as far as the [InitialContext ic = new InitialContext(this.getEjbRemoteProps());] then bombs out claiming it can not find the Uploader class (under EJB.jar)

As I say, there is rather a lost here and it's not the easiest to look through, but kust wondering if there are any glaring erroes in the code.

All the code bits.........

THESE ARE IN THE CLIENT WAR
============================

CreateUserAccountServlet
------------------------



CreateUserAccountManager
-------------------------


RemoteEjbConnectionManager
--------------------------




THESE TWO ARE IN THE EJB3.0 JAR
===============================

CreateNewUserAccountBean
-------------------------


ICreateAccountRemote
======================



Uploader
--------



persistence.xml (under EJB.jar)
================================




SERVER.LOG OUTPUT
=================

[ August 26, 2008: Message edited by: Keith Seller ]
 
Jerwin Louise Uy
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you tried checking the EJB jar whether the class Uploader is properly loaded and recognized as an entity bean?
 
Kevin P Smith
Ranch Hand
Posts: 362
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just been looking at an old 'laliluna' I found hidden away on my machine, it looks lik ethe Entity bean needs to be referenced in the sun-ejb-jar.xml as well. So I think you could be right, I will investigate further.
 
Kevin P Smith
Ranch Hand
Posts: 362
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Still having no luck with this, I think I've narrowed it down to this line in the [RemoteEjbConnectionManager]

createAccRem = (ICreateAccountRemote) ic.lookup("createNewUserAccountEjb");
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic