[infinispan-issues] [JBoss JIRA] (ISPN-1653) CacheLoader with BdbjeCacheStore throws NotSerializableException: org.infinispan.marshall.MarshalledValue

Galder Zamarreño (Commented) (JIRA) jira-events at lists.jboss.org
Thu Jan 5 05:26:13 EST 2012


    [ https://issues.jboss.org/browse/ISPN-1653?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12653999#comment-12653999 ] 

Galder Zamarreño commented on ISPN-1653:
----------------------------------------

Re: storeAsBinary

Weird, the only reason a MarshalledValue would be used is if storeAsBinary or lazyDeserialization is somehow enabled. Some debugging on your side might explain how that's used even if you turn it off.

Re: Multiple CacheManagers

Two cache managers can share the same JGroups channel, that's what JGroupsChannelLookup (http://docs.jboss.org/infinispan/5.1/apidocs/org/infinispan/remoting/transport/jgroups/JGroupsChannelLookup.html) is there for, to be able to provide the JGroups channel externally. The best example implementation of this is located in AS7 (https://github.com/jbossas/jboss-as/blob/master/clustering/infinispan/src/main/java/org/jboss/as/clustering/infinispan/ChannelProvider.java), but you can probably mimmic what it does by looking at JGroupsTransport does to create and connect a JGroups channel (https://github.com/galderz/infinispan/blob/master/core/src/main/java/org/infinispan/remoting/transport/jgroups/JGroupsTransport.java). There's a lot of boilter plate code but essentially it loads an XML file and connects.

We have a JIRA around to provide an example of this (ISPN-313), but doing this is not very common and if you need to do it, we can suggest you use AS7 which makes it easy to have multiple cache managers since it takes care of all the JGroups transport stuff for you.

If you end up building that JGroups channel lookup class, share it with us so that we can include it in the source code for future reference.
                
> CacheLoader with BdbjeCacheStore throws NotSerializableException: org.infinispan.marshall.MarshalledValue
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: ISPN-1653
>                 URL: https://issues.jboss.org/browse/ISPN-1653
>             Project: Infinispan
>          Issue Type: Bug
>          Components: Loaders and Stores
>    Affects Versions: 5.1.0.CR2
>         Environment: Jetty 7.5.4, JDK 1.6.0
>            Reporter: Hüdaverdi Cakir
>            Assignee: Galder Zamarreño
>              Labels: Bdbje, Berkeley, Lucene
>             Fix For: 5.1.0.CR3
>
>         Attachments: infinispan-config.xml, infinispan.log
>
>
> Trying to setup a persistent CacheLoader for distributed Lucene index. Using Berkeley DB as backend.
> During startup following exception is thrown:
> Caused by: java.io.NotSerializableException: org.infinispan.marshall.MarshalledValue
> 	at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1164) ~[na:1.6.0_29]
> 	at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:330) ~[na:1.6.0_29]
> 	at com.sleepycat.bind.serial.SerialBinding.objectToEntry(SerialBinding.java:179) ~[je-5.0.34.jar:5.0.34]
> 	at com.sleepycat.collections.DataView.useKey(DataView.java:502) ~[je-5.0.34.jar:5.0.34]
> 	at com.sleepycat.collections.DataCursor.getSearchKey(DataCursor.java:551) ~[je-5.0.34.jar:5.0.34]
> 	at com.sleepycat.collections.StoredContainer.getValue(StoredContainer.java:301) ~[je-5.0.34.jar:5.0.34]
> 	at com.sleepycat.collections.StoredMap.get(StoredMap.java:240) ~[je-5.0.34.jar:5.0.34]
> 	at org.infinispan.loaders.bdbje.BdbjeCacheStore.load(BdbjeCacheStore.java:405) ~[infinispan-cachestore-bdbje.jar:5.1.0.CR2]
> 	... 118 common frames omitted
> Also tried with replicated mode, fetchPersistentState=false, preload=false... no success.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       



More information about the infinispan-issues mailing list