This week's book giveaway is in the Features new in Java 9 forum.
We're giving away four copies of Java 9 Revealed and have Kishori Sharan on-line!
See this thread for details.
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

Stateless Session Beans Create method question..  RSS feed

 
andy armstrong
Ranch Hand
Posts: 154
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the specs it states:
"A home interface defines one or more create(...) methods, one for each way to create a session
object. The arguments of the create methods are typically used to initialize the state of the created ses-sionobject."
I did not think create methods to pass in arguments were allowed for statless session beans.
What are create methods allowed for
sessionbeans?
stateful:
stateless:
 
Sanjay Raghavan
Ranch Hand
Posts: 148
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Entity Beans - Zero or more create methods. Sometimes it may be desirable to not allow EJB clients to insert rows
Stateful Session Beans - 1 or more create methods. These maintain conversational state, so you may want to initialize differently.
Stateless Session Beans - One no arg create method. No conversational state, so no initialization needed.
HTH.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!