• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to inject sessionbean local reference in webservice(soap)

 
blv krishna
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,

i have a web service which has to expose the session bean which is in same project. for that i need to call that session bean in the web service. i was tried with

but it is not working . please help me to resolve.

regards
Guru...
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34974
379
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What kind of class is the web service class? You can only inject EJBs in other EJBs or servlets. For a standalone class, you need to do a JNDI lookup the "old fashioned" way.
 
blv krishna
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jeanne Boyarsky wrote:What kind of class is the web service class? You can only inject EJBs in other EJBs or servlets. For a standalone class, you need to do a JNDI lookup the "old fashioned" way.


hi,

the web service is stateless session bean!!!

i have another problem that is , in my application i have a generic local/remote interface the all the beans has to implement the same interfaces . i am getting the following error.



sample code



regards
Guru...
 
Jaikiran Pai
Marshal
Pie
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have another problem that is , in my application i have a generic local/remote interface the all the beans has to implement ...


That's been answered in your other thread here http://www.coderanch.com/t/470650/EJB-Other-Java-EE-Technologies/java/implementing-same-interface-by-more
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic