WIldfly 40.0.1.Final: Deployment of persistent unit fails with:
2026-06-29 14:58:17,840 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("deploy") failed - address: ([("deployment" => "dcm4chee-arc-ear-5.35.0-psql.ear")]) - Stage: (VERIFY) - failure description: {"WFLYCTL0080: Failed services" => {"jboss.persistenceunit.\"dcm4chee-arc-ear-5.35.0-psql.ear#dcm4chee-arc\"" => "jakarta.persistence.PersistenceException: Unable to build Hibernate SessionFactory [persistence unit: dcm4chee-arc]
Caused by: jakarta.persistence.PersistenceException: Unable to build Hibernate SessionFactory [persistence unit: dcm4chee-arc]
Caused by: org.hibernate.MappingException: The increment size of the [ian_task_pk_seq] sequence is set to [50] in the entity mapping but the mapped database sequence increment size is [1]"}}
Looks like the mapping file specified in the persistence.xml:
<persistence xmlns="http://xmlns.jcp.org/xml/ns/persistence" version="2.1">
<persistence-unit name="dcm4chee-arc">
<provider>org.hibernate.jpa.HibernatePersistenceProvider</provider>
<jta-data-source>java:/PacsDS</jta-data-source>
<mapping-file>META-INF/orm-sequence.xml</mapping-file>
<properties>
<property name="jakarta.persistence.database-product-name" value="PostgreSQL"/>
<property name="jakarta.persistence.database-major-version" value="10"/>
<property name="jakarta.persistence.database-minor-version" value="5"/>
<property name="hibernate.query.jpaql_strict_compliance" value="false"/>
</properties>
</persistence-unit>
</persistence> including:
<entity class="org.dcm4chee.arc.entity.IanTask">
<sequence-generator name="ian_task_pk_seq" sequence-name="ian_task_pk_seq" allocation-size="1"/>
<attributes>
<id name="pk">
<column name="pk"/>
<generated-value strategy="SEQUENCE" generator="ian_task_pk_seq"/>
</id>
</attributes>
</entity>
does not get applied, and therefore conflicts with the created DB sequence:
create sequence ian_task_pk_seq start with 1 increment by 1;