Uploaded image for project: 'Hibernate ORM'
  1. HHH-11634

ActionQueue#InsertActionSorter fails to generate right order

    Details

    • Bug Testcase Reminder (view):

      Bug reports should generally be accompanied by a test case!

    • Worked in:
    • Last commented by a user?:
      true
    • Sprint:

      Description

      After migration from 4.2.x to 5.2.9 batching susbsystem stops working we got

      08:46:59,871 ERROR [org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (default task-53) ERROR: duplicate key value violates unique constraint "pk_purchase_document"
       Details: Key (id_purchase_document)=(266985) already exists.
      

      Test case
      https://github.com/MirekSz/hibernate-HHH-11634
      In screenshots you can see what is wrong. In action queue there are 3 elements with the same id (hash = 5167) which generates after all inserting 3 times elements with the same id (with hibernate.order_inserts false it works)

      Config:
      hibernate.order_inserts true
      hibernate.jdbc.batch_size 10

      I also try SNAPSHOT VER after HHH-11585 Closed but the same error occurs

        Attachments

          Issue links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved: