Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 4.3.11, 5.2.3
    • Fix Version/s: 5.2.4, 5.1.4
    • Component/s: hibernate-core
    • Labels:
      None
    • Environment:
      Ubuntu Server 14.04 LTS, Percona Server 5.6
    • Last commented by a user?:
      true
    • Sprint:

      Description

      During startup phase, Hibernate relies on "SHOW FULL TABLES" to discover the schema.
      It executes the same command multiple times for the same table. As the execution time can vary between 100 and 200 ms on a loaded server, this can lead to very long startup times in the range of minutes. The duplication can be observed both in 4.3.11 and 5.2.3 however in the later one, it's more severe. Below is an example of number of queries observed for a complex schema with around 120 tables.
      Hibernate 4.3.11: 232 x SHOW FULL TABLES FROM
      Hibernate 5.2.3: 591 x SHOW FULL TABLES FROM
      In 5.2.3, the number of queries executed for same table varies. We have one table for which we see the same query 19 times!

      All the queries can be easily observed by enabling general log in Mysql. The issue might be related to HHH-11023 Closed

        Attachments

          Issue links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: