Discussions

Performance and scalability: When I use EntityBeans....

  1. When I use EntityBeans.... (3 messages)

    I am a bignner for J2EE.I want to know when I can omit Entitybeans for performance problems and directly access DB from sessionbeans?

    Threaded Messages (3)

  2. When I use EntityBeans....[ Go to top ]

    There is no concrete rule for when Entity Beans are appropriate. Whether or not using them will improve performance depends on the way you develop your EBs, the way your app server supports them, and the way the EB clients access them (i.e, how many remote calls are made).
    I think for any reasonable answer to this question you should read an EJB tutorial.
    Note that EJB2.0 greatly improves the performance level of some EBs. Watch out of EJB2.0 books, some are coming out.

    Gal
  3. When I use EntityBeans....[ Go to top ]

    General Rule is ...

    If you want to only read data from DB, then you could directly call SQL from you session Bean.

    You must go thru Entity Bean if you manipulate the data to DB. It means both read and write or write.

    Thanks
    Alagan
  4. When I use EntityBeans....[ Go to top ]

    I use entity beans only under the following scenario

    - Data is read only or read mostly
    and / or
    - The bean models coarse grained complex business object spanning multiple tables in the database

    I also use all the optimizations provided by the App Server vendor to reduce database access

    Pranab