Is your message sent with the persistent flag on the message set to true? A persistence store is only going to store the persistent messages, but the non-persistent ones are stored in memory and are lost on restart. On Nov 5, 2015 9:04 AM, "Hayate" <zero.sent...@gmail.com> wrote:
> I want save not consumed messages after amq or machine restart. Is this doc > actual for ActiveMQ 5.12.1 Release? I try use example from docs and get > error: > > > ERROR | Failed to load: class path resource [activemq.xml], reason: Line 86 > in XML document from class path resource [activemq.xml] is invalid; nested > exception is org.xml.sax.SAXParseException; lineNumber: 86; columnNumber: > 90; cvc-complex-type.2.4.a: Invalid content was found starting with element > 'kahaPersistenceAdapter'. One of > '{"http://activemq.apache.org/schema/core":jdbcPersistenceAdapter, > "http://activemq.apache.org/schema/core":journalPersistenceAdapter, > "http://activemq.apache.org/schema/core":kahaDB, > "http://activemq.apache.org/schema/core":levelDB, > "http://activemq.apache.org/schema/core":mKahaDB, > "http://activemq.apache.org/schema/core":memoryPersistenceAdapter, > "http://activemq.apache.org/schema/core":replicatedLevelDB, > WC[##other:"http://activemq.apache.org/schema/core"]}' is expected. > This error occurs with almost default config: > https://yadi.sk/d/e8tWyIzyk9piV > > > Well, i replace kahaPersistenceAdapter to kahaDB and restart. And get > error: > > > Attribute 'maxDataFileLength' is not allowed to appear in element 'kahaDB'. > I replace this attribute and ActiveMQ started. I send message to queue, > restard amq and my not consumed message gone. What i do wrong? > > > > -- > View this message in context: > http://activemq.2283324.n4.nabble.com/How-enable-ActiveMQ-persistence-tp4703696.html > Sent from the ActiveMQ - User mailing list archive at Nabble.com. >