Embeddable data not persisted when using WriteBehind cache flush operation

Details

Description

When using an entity that includes an embeddable with the WriteBehind cache flush operation all the data associated with the entity is properly persisted in the database. However, none of the data associated with the embeddable is persisted. A testcase will be provided to demonstrate this failure.....

The problem that the embeddable fields are not persisted using WriteBehindCache is that WriteBehindCallback has its own BrokerImpl, which is different from the BrokerImpl in the embeddable's StateManagerImpl. As a result, the StateManagerImpl of the embeddable can not be fetched. The attached patch is to set a flag to indicate whether a particular BrokerImpl is from WriteBehindCallback.

Fay Wang
added a comment - 04/Dec/09 19:35 The problem that the embeddable fields are not persisted using WriteBehindCache is that WriteBehindCallback has its own BrokerImpl, which is different from the BrokerImpl in the embeddable's StateManagerImpl. As a result, the StateManagerImpl of the embeddable can not be fetched. The attached patch is to set a flag to indicate whether a particular BrokerImpl is from WriteBehindCallback.

Tim McConnell
added a comment - 14/Oct/09 04:01 See openjpa-persistence-jdbc\src\test\java\org\apache\openjpa\jdbc\writebehind\crud\TestEmbeddable.java and uncomment the testEntity01ManualFlush() method to see the failure....

Embeddable data not persisted when using WriteBehind cache flush operation

Description

When using an entity that includes an embeddable with the WriteBehind cache flush operation all the data associated with the entity is properly persisted in the database. However, none of the data associated with the embeddable is persisted. A testcase will be provided to demonstrate this failure.....