3 Replies Latest reply on Jan 3, 2004 3:30 PM by Mark Reynolds

    Entity Beans / Performance

    Mark Reynolds Newbie


      I'm relatively new to JBoss and J2EE. I'm evaluating porting a Delphi/CORBA/Oracle application to JBoss. I've started by prototyping existing functionality but have run into some performance issues.

      I have a stateless session bean collaborating with three entity beans to provide a service. I'm using bean managed transactions and explicitly starting transactions from the stateless session bean. I'm using container managed persistence for the entity beans. The first step is to collect a set of financial transactions so I call a find method on the first entity local interface which returns a collection. For each item in the collection I make several calls to other entity beans. Everything works fine but performance is poor and gets dramatically worse as the size of the initial collection grows. With 50 instances returned in the initial step, I can process 4 instances per second. With 1,000 instances return, it takes 30 seconds to process each one.

      What is the best was to see what is going on in JBoss. I'm particularly interested in how often the database is being access and how often ejbs are being written to disk. From the simple logging I put in so far it seems like a lot of time is being spent simply accessing the instances in the collection returned from the initial find method.

      Here is some information about my environment.

      Athlon XP 2400, 1 Gig RAM
      Redhat Linux 9
      PostgreSQL 7.3.2
      Java 1.4.2
      JBoss 3.2.1