views:

169

answers:

2

How performant is the entity bean? Would it be too much to ask if I want 1000 objects per table (probably about 20 tables) across 5 processes where some processes might be changing the objects as often as 60 times a second?

Are there any resources out there on the limitations of the entity bean?

Thanks for any help!

A: 

Performance is not really limited by the entities, but the JPA provider's implementation and your database.

It's impossible to give performance estimation, because so many factors affect it:

  • JPA implementation
  • JPA settings (like caching and batch writing)
  • Server hardware
  • Network
  • Database type
  • Database settings
  • Application server vendor
  • Number of threads

etc.

This test could give you some indication on performance of different JPA providers:

http://terrazadearavaca.blogspot.com/2008/12/jpa-implementations-comparison.html

I have not tested the performance too much personally, but I measured one of my processes. It executes one query to each insert, and uses an Oracle database. It's running in one thread and is doing more than 250 inserts (+250 queries) per second. I would expect that using several threads the performance would be much better, but I have not so far had the need to try it.

tputkonen
A: 

Apart from the technical context, an important factor is you application's design. A lot of early EJB applications suffered from horrendous performance because they carelessly used remote methods for everything, i.e. setting 5 attributes on a single EJB resulted in 5 network roundtrips.

Michael Borgwardt