1 Reply Latest reply on Mar 5, 2011 2:29 PM by mp911de

    performance tuning in a JBOSS/ MySQL cluster environment

    joepareti

      Apology for asking silly questions but I am rather new to the topic. I need to gather advices on how to guide the development of a new application based on those components, and I need to be aware of potential bottlenecks, I have discussed the matter with the development team following the guidlines of RH/JBOSS best practises. Some architectural features are:

      • MYSQL cluster make s use of pacemaker, replication, monitoring agents
      • performance so far on mysql cluster includes more than 1 million rows / sec (R) and 80k rows/sec (W)
      • MYSQL runs in SLES 11 with HA extensions; 2 virtual cpu's, 4 GB RAM
      • JBOSS EAP 5.0 runs on 4 vcpu's and 12 GB RAM/ RHEL 5.5, but with no JBOSS cluster
      • web services are provided by Enterprise web services
      • The GC in JVM is multi-threaded enabled, i.e. 4 threads
      • The Mysql optimizations call for 100% in-memory DB with current workloads
      • Other params enforce transaction security against data corruption
      • The VM's run on a complex of 9 servers, each with quad core Nehalem; storage is connected over 4 Gb FC ports (2 per server)
      • Performance is perceived by the customer as "user's time waiting at the GUI"
        • 1. performance tuning in a JBOSS/ MySQL cluster environment
          mp911de

          Hi Joseph,

          with no Information about what your App needs to do, I can only give you things on your way, you probably know:

          • Make use of EJB3 with Hibernate or JPA including some Caching (Infinispan works nice)
          • Load as few data as possible, as much as needed. No more.
          • Load even fewer data from your database
          • Design you code to perform only the things, you really need. Don't make the code smarter as it should be.
          • Let the Database make as much work as possible (i.e. use one Statement using Joins instead of a lot of small Database Queries)
          • Make sure, you have Indices on the right Columns (Data Model Design)
          • Keep your Web-Sessions as small as possible
          • Use rather a own Business Locking over Optimistic Locking (i.e. Last-Changed-Flag or Version Column in your Data-Model). Optimistic Locking adds lots of CPU overhead and additional (if used) Cache-Handling
          • Try avoiding Session-Replication in case when you would like to make a JBoss cluster
          • If you would use a Web-App, favor Ajax-Requests over Page-Reload - it makes feel a faster application
          • Cache time-consuming stuff (i.e. if you use drools, avoid compiling rules on each execution)
          • Favor in-memory Objects over persistent Objects, where possible (i.e. when you just want to track a Progress of an Process use some Stateful EJB or a Managed Bean instead of writing a row in your Database for each Step)

           

          Beside this, your Hardware-Config sounds neat!

           

          If you have any specific Questions, just post 'em.

           

          Best regards,

          Mark