my dog learned polymorphism*
The moose likes Web Services Certification (SCDJWS/OCEJWSD) and the fly likes Stateful EJB as WebService Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Certification » Web Services Certification (SCDJWS/OCEJWSD)
Bookmark "Stateful EJB as WebService" Watch "Stateful EJB as WebService" New topic
Author

Stateful EJB as WebService

Souvik Dasgupta
Ranch Hand

Joined: Sep 24, 2009
Posts: 77

I am new to EJB. Could anyone help me for below case:


SEI as below:



SIB as below:




But I am getting compilation error as:
If a class is part of ejb-jar and annotated @WebService, then it must designated as Singleton or Stateless session bean. Someone please explain.


Thanks and Regards, Souvik
SCJP, SCWCD, OCEJWSD
Frits Walraven
Creator of Enthuware JWS+ V6
Bartender

Joined: Apr 07, 2010
Posts: 1665
    
  25

A Stateful Session Bean cannot expose a WebService (only a Singleton Session Bean or Stateless Session Bean)
Souvik Dasgupta
Ranch Hand

Joined: Sep 24, 2009
Posts: 77


Got it.

Thanks Frits.
 
jQuery in Action, 2nd edition
 
subject: Stateful EJB as WebService