-
Type:
Regression Bug
-
Status: Closed
-
Resolution: Fixed
-
Affects Version/s: 6.2.X EE, 7.0.X EE, Master
-
Fix Version/s: 7.0.0 DXP FP23, 7.0.X EE, 7.0.4 CE GA5, 7.1.X, Master
-
Component/s: Performance > Caching Infrastructure
-
Branch Version/s:7.0.x
-
Backported to Branch:Committed
-
Git Pull Request:
We depend on Ehcache to support our cache API, and Ehcache can be configured to do replication to other jvm or to disk, which will serialize/deserialize keys and values.
NullModel is a placeholder for null model which can be stored into our cache. When we serialize it and deserialize it later, it should always return same object.
Reproduce steps:
Run unit test EntityCacheImplTest (This test is added in the fix of this issue)
Before fix, the test failed and error log like:
java.lang.AssertionError: expected same:<com.liferay.portal.kernel.service.persistence.impl.BasePersistenceImpl$NullModel@2ce68e68> was not:<com.liferay.portal.kernel.service.persistence.impl.BasePersistenceImpl$NullModel@77a4105>
After fix, the test passed.