1 / 5

EJB State Diagrams

EJB State Diagrams. Simple Lifecycle of Session Bean. Client EJBHome EJBObject Container Context Instance Data Store. create(…). new. new. new. setSessionContext(ctxt). ejbCreate(…). ejbPassivate(). read state from instance. write state to data store. read state from data store.

zenda
Download Presentation

EJB State Diagrams

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. EJB State Diagrams

  2. Simple Lifecycle of Session Bean Client EJBHome EJBObject Container Context Instance Data Store create(…) new new new setSessionContext(ctxt) ejbCreate(…) ejbPassivate() read state from instance write state to data store read state from data store write state to instance ejbActivate()

  3. EJB Transaction Sequence Client EJBHome EJBObject Synchron Instance Trans Svc Database javax.jts.UserTransaction.begin() business method register_synchronization(synch) afterBegin() access database regis_res() business method javax.jts.UserTransaction.commit() beforeCompletion() beforeCompletion() write updates to database commit() afterCompletion(s) afterCompletion(s)

  4. Creating an Entity Object Client EJBHome EJBObject Synchron Instance Trans Svc Database javax.jts.UserTransaction.begin() create(args) ejbCreate(args) Bean Managed create record in database regis_res() ejbCreate(args) Container Managed create record in database regis_res() new ejbPostCreate(args) register_synchronization(synch) business method business method

  5. Synchronizing with Data Client EJBHome EJBObject Container Instance Trans Svc Database business method business method ejbStore() write data to database Bean Managed ejbPassivate() ejbStore() extract fields Container Managed write data to database ejbPassivate() business method ejbActivate() ejbLoad() Bean Managed read data from database read data from database Container Managed write data to fields ejbLoad() business method

More Related