8 Replies Latest reply on Feb 26, 2009 3:32 AM by vaerssv

    Performance Cost of valid-connection-checker-class-name / ch

    spoulin

      I'm using JBoss 4.0.0 with Oracle 10g.

      I'm getting challenged by my DBA for suggesting the use of either valid-connection-checker-class-name or check-valid-connection-sql.

      With millions of connections daily they fear an impact on general perfomances.

      Does anyone ever benchmarked the overhead of this feature?

        • 1. Re: Performance Cost of valid-connection-checker-class-name
          vickyk

           

          "spoulin" wrote:
          Does anyone ever benchmarked the overhead of this feature?

          No we don't have but it would be interesting to see this with millions of hits .
          And don't have it if your DBA guarantees that DB will not be down ever .


          • 2. Re: Performance Cost of valid-connection-checker-class-name
            vaerssv

            hello, I've a little bit the same, so i'll not create a new post...
            our dba are challenging us because they have millions of validation check hits on their db.
            so i'm wondering if there is a way to limit the number of checks ? not removing them completely, but specifying that we want a maximum of one hit every 10 seconds for exemple, not just before every querry... ?
            many tanks

            • 3. Re: Performance Cost of valid-connection-checker-class-name
              peterj

              Did you write your own validation checker class? If so, you can try putting the timing in there. If you didn't write your own class, you will probably have to.

              • 4. Re: Performance Cost of valid-connection-checker-class-name
                vaerssv

                no we did'nt wrote our own class, we are just using the simple check-valid-connection-sql ...
                But i suppose your post means that it is not possible to limit the numbers of check with this simple check-valid-connection-sql?
                and so that I'll have to write my own connection checker class... ?

                • 5. Re: Performance Cost of valid-connection-checker-class-name
                  vickyk

                   

                  "vaerssv" wrote:

                  so i'm wondering if there is a way to limit the number of checks ? not removing them completely, but specifying that we want a maximum of one hit every 10 seconds for exemple, not just before every querry... ?
                  many tanks

                  What is the rational of doing such changes, can you explain this in detail?
                  Yes making the changes in custom implementation of ConnectionChecker will help here but I wanted you to understand clearly about the benefit that would you get by implementing it.


                  • 6. Re: Performance Cost of valid-connection-checker-class-name
                    vaerssv

                    in fact we use a simple "select 1 from dual", this causes few load, but the problem is that our dba's see millions of hits on the db, this generate some load that we wants to limit (by executing this query only every x time for exemple)...

                    i see in the doc:
                    check-valid-connection-sql : This is a SQL statement that should be run on a connection before it is returned from the pool to test its validity to test for stale pool connections. An example statement could be: select count(*) from x

                    maybe i don't understand exactly when the querry will be executed, but i suppose it is for every connection to the db... what i would like to have is to use the check-valid-connection not for every connection, but one every 10 seconds, for exemple, that will validate that the db is still reachable and all connection are considered as ok...

                    don't know if it makes sense?

                    • 7. Re: Performance Cost of valid-connection-checker-class-name
                      peterj

                       

                      so that I'll have to write my own connection checker class...


                      Yes. I would look at extending the existing class that handles the check-valid-connection-sql option.

                      • 8. Re: Performance Cost of valid-connection-checker-class-name
                        vaerssv

                        that's realy nice, many thanks in advance !