Should I use EJB3 as web-services?
More than a community and business event,
href='http://jazoon.com/en.html'>Jazoon'08 offers you a chance to
I have my own set of (Not
Is it a good design to expose EJB3 Session Facade as
on the Internet, href='http://java.sun.com/developer/EJTechTips/2006/tt0327.html#1'>EJB3
+ @WebService seem to be a fast and furious way to go straight to SOA
with few lines of code and a
good container. Despite the simplicity of annotations, I
started designing an Open
Source Classifieds system based on J2EE technologies and I have some
observations about that.
Instead of replicating here all discussions about web-services
design and its technology support, I prefer to bring you a few design
options and get your feedback live during Jazoon.
- Web Client -> JAXWS SOAP web-services -> Session Facade ->
Domain Model Facade -> @Entities
- Web Client -> @WebService Session Facade -> Domain Model
Facade -> @Entities
- Web Client -> @WebService Session Facade -> @Entities
Some considerations about the above design options:
- If I use annotations, I am assuming SOAP web-services, right?
And what about REST?
- If I do expose my Session Facade directly, how can I change
later my interface from SOAP web-service to something else ?
- What about validation and security? My business component
should care about data input validation and authorization and
- Load balance and orchestration. Can I use a web server (Tomcat?) to expose the service interface and a j2ee container to do the business? What about service collaboration? The session beans will have references one to each other?
Using a same class to expose services interface and realizing
business use cases seems a bit overlapped to me, but eventually I am
missing some point here. It is up to you, see you in ZÃ¼rich :)