[
https://issues.jboss.org/browse/ISPN-10935?page=com.atlassian.jira.plugin...
]
Ryan Emerson closed ISPN-10935.
-------------------------------
Assignee: Ryan Emerson
Resolution: Explained
[~mjoaquim12] Thank you for your question and reproducer. I have responded to your
question on StackOverFlow:
https://stackoverflow.com/questions/58815818/infinispan-10-0-1-final-no-m....
Lets continue the discussion there if required.
No marshaller registered for Java type java.util.UUID
-----------------------------------------------------
Key: ISPN-10935
URL:
https://issues.jboss.org/browse/ISPN-10935
Project: Infinispan
Issue Type: Bug
Affects Versions: 10.0.1.Final
Environment: Java version: openjdk version "13" 2019-09-17
Infinispan dependencies:
<dependency>
<groupId>org.infinispan</groupId>
<artifactId>infinispan-hibernate-cache-v53</artifactId>
<version>10.0.1.Final</version>
</dependency>
<dependency>
<groupId>org.infinispan</groupId>
<artifactId>infinispan-jcache</artifactId>
<version>10.0.1.Final</version>
</dependency>
Reporter: Joaquim Mascarenhas
Assignee: Ryan Emerson
Priority: Blocker
Attachments: SimpleCacheTest.java
Project is based on Wicket with hibernate and infinispan. Page render tests are failing
after I updated infinispan version to 10.0.1.Final.
Works if I change version to 9.4.16.Final.
Accessing cache using javax.cache fails:
*imports*
import javax.cache.Cache;
import javax.cache.CacheManager;
import javax.cache.Caching;
import javax.cache.configuration.MutableConfiguration;
import javax.cache.expiry.Duration;
import javax.cache.expiry.ModifiedExpiryPolicy;
import javax.cache.integration.CacheLoader;
import javax.cache.spi.CachingProvider;
*Initialize cache*
final CachingProvider cachingProvider = Caching.getCachingProvider();
final CacheManager cacheManager = cachingProvider.getCacheManager();
final MutableConfiguration<UUID,CachedImageInfoList> config = new
MutableConfiguration<>();
config.setTypes( UUID.class, CachedImageInfoList.class );
config.setStoreByValue( false );
config.setExpiryPolicyFactory( ModifiedExpiryPolicy.factoryOf( Duration.FIVE_MINUTES )
);
config.setReadThrough( true );
config.setCacheLoaderFactory( () -> new CacheLoader<>() { ... }
cache = cacheManager.createCache( SubdomainHeaderLogoImageTag.class.getName(), config );
*Fails when trying to retrieve*
cache.get( subdomainUnid );
Caused by: javax.cache.CacheException:
org.infinispan.persistence.spi.PersistenceException:
org.infinispan.commons.marshall.MarshallingException: No marshaller registered for Java
type java.util.UUID
at org.infinispan.jcache.Exceptions.launderException(Exceptions.java:70)
at org.infinispan.jcache.Exceptions.launderException(Exceptions.java:78)
at org.infinispan.jcache.embedded.JCache.get(JCache.java:191)
at
com.windcam.web.SubdomainHeaderLogoImageTag.getCachedImageInfo(SubdomainHeaderLogoImageTag.java:113)
at
com.windcam.web.SubdomainHeaderLogoImageTag.<init>(SubdomainHeaderLogoImageTag.java:71)
at
com.windcam.web.SubdomainHeaderLogoImageTag.<init>(SubdomainHeaderLogoImageTag.java:67)
at
com.windcam.web.SubdomainManagementListPage$1.populateItem(SubdomainManagementListPage.java:26)
at org.apache.wicket.markup.html.list.ListView.onPopulate(ListView.java:523)
at
org.apache.wicket.markup.repeater.AbstractRepeater.onBeforeRender(AbstractRepeater.java:124)
at org.apache.wicket.Component.beforeRender(Component.java:939)
at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1754)
... 99 more
Caused by: org.infinispan.persistence.spi.PersistenceException:
org.infinispan.commons.marshall.MarshallingException: No marshaller registered for Java
type java.util.UUID
at
org.infinispan.marshall.persistence.impl.MarshallableEntryImpl.marshall(MarshallableEntryImpl.java:211)
at
org.infinispan.marshall.persistence.impl.MarshallableEntryImpl.<init>(MarshallableEntryImpl.java:36)
at
org.infinispan.marshall.persistence.impl.MarshalledEntryFactoryImpl.create(MarshalledEntryFactoryImpl.java:64)
at
org.infinispan.jcache.embedded.JCacheLoaderAdapter.loadEntry(JCacheLoaderAdapter.java:51)
at
org.infinispan.persistence.manager.PersistenceManagerImpl.loadFromAllStoresSync(PersistenceManagerImpl.java:830)
at
org.infinispan.persistence.manager.PersistenceManagerImpl.lambda$loadFromAllStores$19(PersistenceManagerImpl.java:848)
at
org.infinispan.persistence.manager.PersistenceManagerImpl.lambda$supplyOnPersistenceExAndContinue$9(PersistenceManagerImpl.java:559)
at
java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1771)
at
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:830)
Caused by: org.infinispan.commons.marshall.MarshallingException: No marshaller
registered for Java type java.util.UUID
at
org.infinispan.marshall.persistence.impl.PersistenceMarshallerImpl.objectToBuffer(PersistenceMarshallerImpl.java:164)
at
org.infinispan.marshall.persistence.impl.PersistenceMarshallerImpl.objectToBuffer(PersistenceMarshallerImpl.java:132)
at
org.infinispan.marshall.persistence.impl.MarshallableEntryImpl.marshall(MarshallableEntryImpl.java:209)
... 10 more
--
This message was sent by Atlassian Jira
(v7.13.8#713008)