Peter Fuerholz (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=5e468be...
) *created* an issue
Hibernate ORM (
https://hibernate.atlassian.net/browse/HHH?atlOrigin=eyJpIjoiMWQ2YTg4ODVk...
) / Bug (
https://hibernate.atlassian.net/browse/HHH-13866?atlOrigin=eyJpIjoiMWQ2YT...
) HHH-13866 (
https://hibernate.atlassian.net/browse/HHH-13866?atlOrigin=eyJpIjoiMWQ2YT...
) OneToOne-association produces error on 5.4.0+ when using PostgreSQL (
https://hibernate.atlassian.net/browse/HHH-13866?atlOrigin=eyJpIjoiMWQ2YT...
)
Issue Type: Bug Affects Versions: 5.4.0 Assignee: Unassigned Components: hibernate-core
Created: 14/Feb/2020 04:16 AM Environment: Spring Boot application using PostgreSQL
Priority: Major Reporter: Peter Fuerholz (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=5e468be...
)
We have Spring Boot application using a OneToOne annotation and PostgreSQL.
Owning class:
```@Entity
@Table(name = "PAYMENT")
public class PaymentDO
{ @Id @GeneratedValue(strategy = GenerationType.IDENTITY) @Column(name =
"PAYMENT_ID", insertable = false, updatable = false, nullable = false) private
Long paymentId; @OneToOne(mappedBy = "payment", fetch = FetchType.LAZY, cascade
= CascadeType.ALL, orphanRemoval = true) private PaymentBatchJobDO paymentBatchJob; }
```
Owned class:
```@Entity
@Table(name = "PAYMENT_BATCH_JOB")
public class PaymentBatchJobDO
{ @Id @Column(name="PAYMENT_ID", updatable = false, nullable = false) private
Long paymentId; @OneToOne @PrimaryKeyJoinColumn(name = "PAYMENT_ID",
referencedColumnName = "PAYMENT_ID") private PaymentDO payment; }
```
Until Hibernate core 5.3.* that worked perfecty but with 5.4.* I get following error:
```2020-02-14 11:08:19.527 INFO 67291 — [ main] org.hibernate.dialect.Dialect : HHH000400:
Using dialect: org.hibernate.dialect.PostgreSQL95Dialect
2020-02-14 11:08:20.631 INFO 67291 — [ main] o.h.e.t.j.p.i.JtaPlatformInitiator :
HHH000490: Using JtaPlatform implementation:
[org.hibernate.engine.transaction.jta.platform.internal.NoJtaPlatform]
2020-02-14 11:08:20.636 INFO 67291 — [ main] j.LocalContainerEntityManagerFactoryBean :
Initialized JPA EntityManagerFactory for persistence unit 'default'
Payment onlyPaymentDO
{paymentId=1945, paymentBatchJob=null, amountTotal=12.00}
PaymentPaymentDO{paymentId=1945, paymentBatchJob=null, amountTotal=12.00}
2020-02-14 11:08:21.108 ERROR 67291 — [ main] org.hibernate.AssertionFailure : HHH000099:
an assertion failure occurred (this may indicate a bug in Hibernate, but is more likely
due to unsafe use of the session): org.hibernate.AssertionFailure: null identifier
org.hibernate.AssertionFailure: null identifier
at org.hibernate.engine.spi.EntityKey.<init>(EntityKey.java:51) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.internal.AbstractSharedSessionContract.generateEntityKey(AbstractSharedSessionContract.java:523)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.type.OneToOneType.isNull(OneToOneType.java:105) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.type.EntityType.resolve(EntityType.java:462) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.type.EntityType.resolve(EntityType.java:457) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.type.EntityType.replace(EntityType.java:358) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.type.AbstractType.replace(AbstractType.java:164) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.type.TypeHelper.replace(TypeHelper.java:204) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultMergeEventListener.copyValues(DefaultMergeEventListener.java:488)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultMergeEventListener.entityIsTransient(DefaultMergeEventListener.java:241)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultMergeEventListener.entityIsDetached(DefaultMergeEventListener.java:318)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultMergeEventListener.onMerge(DefaultMergeEventListener.java:172)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultMergeEventListener.onMerge(DefaultMergeEventListener.java:70)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:108)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.internal.SessionImpl.fireMerge(SessionImpl.java:776) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.internal.SessionImpl.merge(SessionImpl.java:763) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~
[na:na]
at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~ [na:na]
at
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~ [na:na]
at java.base/java.lang.reflect.Method.invoke(Method.java:566) ~ [na:na]
at
org.springframework.orm.jpa.SharedEntityManagerCreator$SharedEntityManagerInvocationHandler.invoke(SharedEntityManagerCreator.java:314)
~ [spring-orm-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at com.sun.proxy.$Proxy73.merge(Unknown Source) ~ [na:na]
at
org.springframework.data.jpa.repository.support.SimpleJpaRepository.save(SimpleJpaRepository.java:557)
~ [spring-data-jpa-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~
[na:na]
at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~ [na:na]
at
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~ [na:na]
at java.base/java.lang.reflect.Method.invoke(Method.java:566) ~ [na:na]
at
org.springframework.data.repository.core.support.RepositoryComposition$RepositoryFragments.invoke(RepositoryComposition.java:371)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.data.repository.core.support.RepositoryComposition.invoke(RepositoryComposition.java:204)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.data.repository.core.support.RepositoryFactorySupport$ImplementationMethodExecutionInterceptor.invoke(RepositoryFactorySupport.java:657)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.data.repository.core.support.RepositoryFactorySupport$QueryExecutorMethodInterceptor.doInvoke(RepositoryFactorySupport.java:621)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.data.repository.core.support.RepositoryFactorySupport$QueryExecutorMethodInterceptor.invoke(RepositoryFactorySupport.java:605)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.data.projection.DefaultMethodInvokingMethodInterceptor.invoke(DefaultMethodInvokingMethodInterceptor.java:80)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:353)
~ [spring-tx-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:99)
~ [spring-tx-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.invoke(PersistenceExceptionTranslationInterceptor.java:139)
~ [spring-tx-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.data.jpa.repository.support.CrudMethodMetadataPostProcessor$CrudMethodMetadataPopulatingMethodInterceptor.invoke(CrudMethodMetadataPostProcessor.java:178)
~ [spring-data-jpa-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:93)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212) ~
[spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at com.sun.proxy.$Proxy86.save(Unknown Source) ~ [na:na]
at
com.swisscom.billing.testhibernate.PaymentsTxService.addPaymentBatchJob(PaymentsTxService.java:53)
~ [main/:na]
at
com.swisscom.billing.testhibernate.PaymentsTxService$$FastClassBySpringCGLIB$$4919717e.invoke(<generated>)
~ [main/:na]
at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218) ~
[spring-core-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:769)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:747)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:353)
~ [spring-tx-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:99)
~ [spring-tx-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:747)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:689)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
com.swisscom.billing.testhibernate.PaymentsTxService$$EnhancerBySpringCGLIB$$604ba717.addPaymentBatchJob(<generated>)
~ [main/:na]
at com.swisscom.billing.testhibernate.StartupBean.onApplicationEvent(StartupBean.java:35)
~ [main/:na]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~
[na:na]
at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~ [na:na]
at
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~ [na:na]
at java.base/java.lang.reflect.Method.invoke(Method.java:566) ~ [na:na]
```
If I use a H2 database the error does not occur.
Configuration:
```spring.jpa.hibernate.use-new-id-generator-mappings=true
spring.jpa.hibernate.naming.physical-strategy=org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
spring.jpa.database-platform=org.hibernate.dialect.PostgreSQL95Dialect
```
There are different ways to implement a OneToOne relationship. If I change to the
(probably more typical):
Owned class:
``` @OneToOne
@MapsId
private PaymentDO payment;
```
I get following error:
```2020-02-14 11:25:41.048 WARN 74847 — [ main] o.h.engine.jdbc.spi.SqlExceptionHelper :
SQL Error: 0, SQLState: 42703
2020-02-14 11:25:41.048 ERROR 74847 — [ main] o.h.engine.jdbc.spi.SqlExceptionHelper :
ERROR: column paymentbat0_.payment_payment_id does not exist
Position: 8
2020-02-14 11:25:41.054 INFO 74847 — [ main] o.h.e.internal.DefaultLoadEventListener :
HHH000327: Error performing load command : org.hibernate.exception.SQLGrammarException:
could not extract ResultSet
org.hibernate.exception.SQLGrammarException: could not extract ResultSet
at
org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:103)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:99) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.extract(ResultSetReturnImpl.java:67)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.Loader.getResultSet(Loader.java:2287) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.Loader.executeQueryStatement(Loader.java:2045) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.Loader.executeQueryStatement(Loader.java:2007) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.Loader.doQuery(Loader.java:953) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:354) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:324) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.Loader.loadEntity(Loader.java:2401) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.entity.AbstractEntityLoader.load(AbstractEntityLoader.java:64) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.loader.entity.EntityLoader.loadByUniqueKey(EntityLoader.java:144) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.persister.entity.AbstractEntityPersister.loadByUniqueKey(AbstractEntityPersister.java:2384)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.type.EntityType.loadByUniqueKey(EntityType.java:745) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.type.EntityType.resolve(EntityType.java:467) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.engine.internal.TwoPhaseLoad.doInitializeEntity(TwoPhaseLoad.java:226) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.engine.internal.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java:160) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.loader.plan.exec.process.internal.AbstractRowReader.performTwoPhaseLoad(AbstractRowReader.java:255)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.loader.plan.exec.process.internal.AbstractRowReader.finishUp(AbstractRowReader.java:215)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.loader.plan.exec.process.internal.ResultSetProcessorImpl.extractResults(ResultSetProcessorImpl.java:141)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.loader.plan.exec.internal.AbstractLoadPlanBasedLoader.executeLoad(AbstractLoadPlanBasedLoader.java:105)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.loader.entity.plan.AbstractLoadPlanBasedEntityLoader.load(AbstractLoadPlanBasedEntityLoader.java:197)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.persister.entity.AbstractEntityPersister.load(AbstractEntityPersister.java:4350)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultLoadEventListener.loadFromDatasource(DefaultLoadEventListener.java:570)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultLoadEventListener.doLoad(DefaultLoadEventListener.java:538)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultLoadEventListener.load(DefaultLoadEventListener.java:208)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultLoadEventListener.proxyOrLoad(DefaultLoadEventListener.java:333)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultLoadEventListener.doOnLoad(DefaultLoadEventListener.java:108)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.internal.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:74)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:118)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.internal.SessionImpl.fireLoadNoChecks(SessionImpl.java:1182) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.internal.SessionImpl.fireLoad(SessionImpl.java:1171) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.internal.SessionImpl.access$2000(SessionImpl.java:198) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.internal.SessionImpl$IdentifierLoadAccessImpl.doLoad(SessionImpl.java:2809)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.internal.SessionImpl$IdentifierLoadAccessImpl.lambda$load$1(SessionImpl.java:2790)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at
org.hibernate.internal.SessionImpl$IdentifierLoadAccessImpl.perform(SessionImpl.java:2746)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.internal.SessionImpl$IdentifierLoadAccessImpl.load(SessionImpl.java:2790)
~ [hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.internal.SessionImpl.find(SessionImpl.java:3340) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at org.hibernate.internal.SessionImpl.find(SessionImpl.java:3312) ~
[hibernate-core-5.4.6.Final.jar:5.4.6.Final]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~
[na:na]
at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~ [na:na]
at
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~ [na:na]
at java.base/java.lang.reflect.Method.invoke(Method.java:566) ~ [na:na]
at
org.springframework.orm.jpa.SharedEntityManagerCreator$SharedEntityManagerInvocationHandler.invoke(SharedEntityManagerCreator.java:314)
~ [spring-orm-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at com.sun.proxy.$Proxy74.find(Unknown Source) ~ [na:na]
at
org.springframework.data.jpa.repository.support.SimpleJpaRepository.findById(SimpleJpaRepository.java:281)
~ [spring-data-jpa-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~
[na:na]
at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~ [na:na]
at
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~ [na:na]
at java.base/java.lang.reflect.Method.invoke(Method.java:566) ~ [na:na]
at
org.springframework.data.repository.core.support.RepositoryComposition$RepositoryFragments.invoke(RepositoryComposition.java:371)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.data.repository.core.support.RepositoryComposition.invoke(RepositoryComposition.java:204)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.data.repository.core.support.RepositoryFactorySupport$ImplementationMethodExecutionInterceptor.invoke(RepositoryFactorySupport.java:657)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.data.repository.core.support.RepositoryFactorySupport$QueryExecutorMethodInterceptor.doInvoke(RepositoryFactorySupport.java:621)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.data.repository.core.support.RepositoryFactorySupport$QueryExecutorMethodInterceptor.invoke(RepositoryFactorySupport.java:605)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.data.projection.DefaultMethodInvokingMethodInterceptor.invoke(DefaultMethodInvokingMethodInterceptor.java:80)
~ [spring-data-commons-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:353)
~ [spring-tx-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:99)
~ [spring-tx-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.invoke(PersistenceExceptionTranslationInterceptor.java:139)
~ [spring-tx-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.data.jpa.repository.support.CrudMethodMetadataPostProcessor$CrudMethodMetadataPopulatingMethodInterceptor.invoke(CrudMethodMetadataPostProcessor.java:178)
~ [spring-data-jpa-2.2.0.RELEASE.jar:2.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:93)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
~ [spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at
org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212) ~
[spring-aop-5.2.0.RELEASE.jar:5.2.0.RELEASE]
at com.sun.proxy.$Proxy83.findById(Unknown Source) ~ [na:na]
at com.swisscom.billing.testhibernate.StartupBean.onApplicationEvent(StartupBean.java:28)
~ [main/:na]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~
[na:na]
at
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~ [na:na]
at
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~ [na:na]
at java.base/java.lang.reflect.Method.invoke(Method.java:566) ~ [na:na]
```
--> paymentbat0_.payment_payment_id does not exist!
If I set `hibernate.id.disable_delayed_identity_inserts=true` the error does not change in
any way.
(
https://hibernate.atlassian.net/browse/HHH-13866#add-comment?atlOrigin=ey...
) Add Comment (
https://hibernate.atlassian.net/browse/HHH-13866#add-comment?atlOrigin=ey...
)
Get Jira notifications on your phone! Download the Jira Cloud app for Android (
https://play.google.com/store/apps/details?id=com.atlassian.android.jira....
) or iOS (
https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=Em...
) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100120- sha1:2415f4c )