• Post Reply Bookmark Topic Watch Topic
  • New Topic

ejbActrivate(), ejbPassivate  RSS feed

 
Abhinaba Basu
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you please explain me this teo functions, or can you give me any link to any tutorials.
 
Mark Spritzler
ranger
Sheriff
Posts: 17309
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Simply put. Beans can be stored in a pool. And at certain points the container can decide, in order to save heap memory, to passivate a Bean. So it takes the information stored in the Bean and serializes it, and removes the Bean from memory. Then later when someone wants to use it and needs that state, then an object is created or taken from the pool, and the serialized information is then read in, this is called Activation. So those two methods are "hook" methods a way for you to write code when Activation has occured (After it was been deserialized) or when Passivation is about to occur (Before it is serialized)

Mark
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!