Hyperfoil / Horreum

Benchmark results repository service
https://horreum.hyperfoil.io/
Apache License 2.0
34 stars 30 forks source link

Changes are not persisted due to `change_pkey` constraint violation #1852

Open johnaohara opened 3 days ago

johnaohara commented 3 days ago

Describe the bug

Changes are occasionally not persisted, caused by a PK constraint violation on insert

2024-06-27 12:45:02,146 a50236a963af quarkus-run.jar[7] WARN  [org.hib.eng.jdb.spi.SqlExceptionHelper] (executor-thread-12352) SQL Error: 0, SQLState: 23505
2024-06-27 12:45:02,147 a50236a963af quarkus-run.jar[7] ERROR [org.hib.eng.jdb.spi.SqlExceptionHelper] (executor-thread-12352) ERROR: duplicate key value violates unique constraint "change_pkey"
2024-06-27 12:45:02,148 a50236a963af quarkus-run.jar[7] WARN  [io.agr.pool] (executor-thread-12352) Datasource '<default>': JDBC resources leaked: 2 ResultSet(s) and 2 Statement(s)
2024-06-27 12:45:02,149 a50236a963af quarkus-run.jar[7] ERROR [io.hyp.too.hor.bus.TaskQueue] (executor-thread-12352) Error executing task in the queue for test 290: org.hibernate.exception.ConstraintViolationException: could not execute statement [ERROR: duplicate key value violates unique constraint "change_pkey"] [insert into change (confirmed,dataset_id,description,timestamp,variable_id,id) values (?,?,?,?,?,?)]
    at org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:97)
    at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:58)
    at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:108)
    at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:197)
    at org.hibernate.engine.jdbc.mutation.internal.AbstractMutationExecutor.performNonBatchedMutation(Abst
...
Caused by: org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint "change_pkey"