Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Caching EJB's - regarding  RSS feed

 
PN Kumar
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there any reason why remote interfaces of
"stateless" session EJB's should not be cached?
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can't think of any common reasons for not to.
However, if you need to cache the reference persistently, you'll have to use a Handle because the regular stub object is not guaranteed to be Serializable.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!