Discussions

EJB programming & troubleshooting: Confusion - Mastering Enterprise JavaBeans 3rd Edition

  1. Confusion - Mastering Enterprise JavaBeans 3rd Edition (2 messages)

    Stateful and Stateless session bean comparison table provided on page number, 89, Table 4.1

    It status following things

    Stateful - passivate -> Unused because there is no conversational state !!!!

    Stateless - passivate -> Release any resources your bean may be holding !!!!!

    This seems goofy,

    Any thoughts on this part....

    Threaded Messages (2)

  2. This is definitely not goofy...[ Go to top ]

    Well,
           passivate is a call back when ur bean is persisted for the want of resources (bit blobed).

           in case of a stateless session bean its a one time request and resovle so all the resources that you use are in the context of the interface method that u are executing.

           where as in case of a stateful sesson bean you might be using resources that you might "contain" in your bean like JDBC connection, these need to be freed when ur bean is in a passive state thats why the call back method passivate

    there is nothing goofy about it
  3. I think its jus typo..[ Go to top ]

    yeah..ur right..i guess its a typo...since the whole comparison should be Stateful and then Stateless..because u cant have more than one ejbCreate in stateless and stuff like that..good catch buddy..