• Post Reply Bookmark Topic Watch Topic
  • New Topic

URGENT !!!!!!!!!! Q : JNI Call from VC++ to EJB Fails ?  RSS feed

 
Reshma Shanbhag
Ranch Hand
Posts: 208
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
we are making JNI call from VC++ application to a Java method, within which we are having a statement "Class.forName(myPackage.EjbHome)". This is where the JNI call fails. Instead of EjbHome Object if we use any other Java class it works fine.
It would be a great help if some could enlighten me as to why JNI call to load a EJBHome object fails. Is there any thing like JNI does not support EJB???
Any help regarding this would be really helpful to me
Thanks in advance
Reshma
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You cannot just load the EJBHome class and expect it to work -- EJB components require an EJB Container!
What you should do is:
- Set up an EJB Container running your EJB
- Locate the EJBHome from the container using JNDI
- Create an EJB reference with myEjbHome.create(...)
- Invoke methods on the EJB reference
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!