activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Posta (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AMQ-5284) InvalidClassException when migrating LevelDB store from 5.9.1 to 5.10.0
Date Mon, 20 Apr 2015 14:53:59 GMT

    [ https://issues.apache.org/jira/browse/AMQ-5284?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14502955#comment-14502955
] 

Christian Posta commented on AMQ-5284:
--------------------------------------

[~vhle01] not sure if there's a good way to make this backward compatible at this point...
might have to just drain existing queues in one version of the broker, and migrate to the
newer versions. Does something like that work for you?

> InvalidClassException when migrating LevelDB store from 5.9.1 to 5.10.0
> -----------------------------------------------------------------------
>
>                 Key: AMQ-5284
>                 URL: https://issues.apache.org/jira/browse/AMQ-5284
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: activemq-leveldb-store
>    Affects Versions: 5.10.0
>         Environment: CentOS 6.5 and Windows 7 x64
>            Reporter: Vu Le
>
> This is my first attempt to create an issue for ActiveMQ, so please bear with me...
> I first created an instance of ActiveMQ 5.9.1 configured with a LevelDB store. I started
the broker, then sent in 100,000 persistent test messages to a queue, then shut down the broker.

> I then upgraded to ActiveMQ 5.10.0. I started up the broker hoping to reuse the LevelDB
datastore, and I received the error below. 
> It looks like the serialized objects within the 5.9.1 are not compatible with the 5.10.0
objects. It occurs with other classes as well (not just the LongCounter class listed in the
error).
> {code}
> 2014-07-22 21:47:49,700 | INFO  | No IOExceptionHandler registered, ignoring IO exception
| org.apache.activemq.broker.BrokerService | LevelDB IOException handler.
> java.io.InvalidClassException: org.apache.activemq.leveldb.util.LongCounter; local class
incompatible: stream classdesc serialVersionUID = -2892799184011566766, local class serialVersionUID
= -1093574112128208819
>         at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:617 [:1.7.0_60]
>         at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1622)[:1.7.0_60]
>         at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1517)[:1.7.0_60]
>         at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1771)[:1.7.0_60]
>         at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1350)[:1.7.0_60]
>         at java.io.ObjectInputStream.readObject(ObjectInputStream.java:370)[:1.7.0_60]
>         at org.apache.activemq.leveldb.LevelDBClient$$anonfun$loadMap$1$1.apply(LevelDBClient.scala:924)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBClient$$anonfun$loadMap$1$1.apply(LevelDBClient.scala:919)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at scala.Option.foreach(Option.scala:245)[scala-library-2.11.0.jar:]
>         at org.apache.activemq.leveldb.LevelDBClient.loadMap$1(LevelDBClient.scala:919)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBClient.org$apache$activemq$leveldb$LevelDBClient$$loadCounters(LevelDBClient.scala:950)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBClient$$anonfun$replay_init$2.apply$mcV$sp(LevelDBClient.scala:684)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBClient$$anonfun$replay_init$2.apply(LevelDBClient.scala:657)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBClient$$anonfun$replay_init$2.apply(LevelDBClient.scala:657)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBClient.might_fail(LevelDBClient.scala:549)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBClient.replay_init(LevelDBClient.scala:657)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBClient.start(LevelDBClient.scala:558)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.DBManager.start(DBManager.scala:648)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.leveldb.LevelDBStore.doStart(LevelDBStore.scala:235)[activemq-leveldb-store-5.10.0.jar:5.10.0]
>         at org.apache.activemq.util.ServiceSupport.start(ServiceSupport.java:55)[activemq-client-5.10.0.jar:5.10.0]
>         at org.apache.activemq.broker.BrokerService.doStartPersistenceAdapter(BrokerService.java:640)[activemq-broker-5.10.0.jar:5.10.0]
>         at org.apache.activemq.broker.BrokerService.startPersistenceAdapter(BrokerService.java:629)[activemq-broker-5.10.0.jar:5.10.0]
>         at org.apache.activemq.broker.BrokerService.start(BrokerService.java:594)[activemq-broker-5.10.0.jar:5.10.0]
>         at org.apache.activemq.xbean.XBeanBrokerService.afterPropertiesSet(XBeanBrokerService.java:73)[activemq-spring-5.10.0.jar:5.10.0]
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[:1.7.0_60]
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)[:1.7.0_60]
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_60]
>         at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_60]
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1638)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1579)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1509)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:521)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:296)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:293)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:628)[spring-beans-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:932)[spring-context-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)[spring-context-3.2.8.RELEASE.jar:3.2.8.RELEASE]
>         at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64)[xbean-spring-3.16.jar:3.16]
>         at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52)[xbean-spring-3.16.jar:3.16]
>         at org.apache.activemq.xbean.XBeanBrokerFactory$1.<init>(XBeanBrokerFactory.java:104)[activemq-spring-5.10.0.jar:5.10.0]
>         at org.apache.activemq.xbean.XBeanBrokerFactory.createApplicationContext(XBeanBrokerFactory.java:104)[activemq-spring-5.10.0.jar:5.10.0]
>         at org.apache.activemq.xbean.XBeanBrokerFactory.createBroker(XBeanBrokerFactory.java:67)[activemq-spring-5.10.0.jar:5.10.0]
>         at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:71)[activemq-broker-5.10.0.jar:5.10.0]
>         at org.apache.activemq.broker.BrokerFactory.createBroker(BrokerFactory.java:54)[activemq-broker-5.10.0.jar:5.10.0]
>         at org.apache.activemq.console.command.StartCommand.runTask(StartCommand.java:87)[activemq-console-5.10.0.jar:5.10.0]
>         at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:57)[activemq-console-5.10.0.jar:5.10.0]
>         at org.apache.activemq.console.command.ShellCommand.runTask(ShellCommand.java:150)[activemq-console-5.10.0.jar:5.10.0]
>         at org.apache.activemq.console.command.AbstractCommand.execute(AbstractCommand.java:57)[activemq-console-5.10.0.jar:5.10.0]
>         at org.apache.activemq.console.command.ShellCommand.main(ShellCommand.java:104)[activemq-console-5.10.0.jar:5.10.0]
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[:1.7.0_60]
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)[:1.7.0_60]
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_60]
>         at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_60]
>         at org.apache.activemq.console.Main.runTaskClass(Main.java:262)[activemq.jar:5.10.0]
>         at org.apache.activemq.console.Main.main(Main.java:115)[activemq.jar:5.10.0]
> 2014-07-22 21:47:49,917 | INFO  | Stopped LevelDB[/home/user/data/leveldb] | org.apache.activemq.leveldb.LevelDBStore
| LevelDB IOException handler.
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message