• Post Reply Bookmark Topic Watch Topic
  • New Topic

How about Business methods in home interface ?  RSS feed

 
Valery Anciaux
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A new EJB 2.0 feature consists of writing business methods in the home interface that we can call without having to instanciate the EJB (kind of a static method)
Is it a good programming practice, and how about performances of this compared to using stateless session beans ?
Thanks,
Val�ry
 
Tim Holloway
Bartender
Posts: 18531
61
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Architecturally, that sounds like bolting a conventional JavaBean alongside an Enterprise JavaBean.
While it's undoubtedly less overhead, I'd approach it cautiously, since any methods you define there are going to lack the essential attributes that made it worth the trouble of using an EJB to begin with, and you may discover that as time goes by that some of those methods have to migrate OUT of the home interface and into the EJB proper.
But that's just speculation on my part.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!