Update: I wrote: > You don't get JDBC persistence unless ActiveMQ is explicitly > configured for that. I guess an "xbean:" URI is needed for > that, but I haven't tried this myself.
OK, now I have tried. It turns out that using an "xbean:" URI for BrokerXmlConfig requires adding Spring libraries to OpenEJB in order to work. But there is a third alternative, the "properties:" URI. Unfortunately the ActiveMQ documentation is hard to penetrate, I had to find javadocs and do some trial and error in order to figure out which properties are (or might be) available. Here is the configuration I ended up with. First, openejb.xml: BrokerXmlConfig properties:file:/opt/openejb/conf/activemq.properties I tried using ${openejb.base} in the file path, but that didn't work. Don't know if that is a bug or a candidate for a feature request :-) Then I created the file activemq.properties: useJmx = false persistent = true dataDirectory = /opt/openejb/data/activemq transportConnectorURIs = tcp://localhost:61616 Yet again, ${openejb.base} doesn't work, or rather it results in a directory with the literal name "${openejb.base}" being created in the currently connected directory when openejb is started. I would assume that string interpolation in this file most likely needs code changes in the ActiveMQ source. The persistent JMS storage will be a KahaDB database under the "dataDirectory". I have verified that it actually does persist and retransmit messages that were sent before a restart and consumed afterwards. This works for me. I don't know how to achieve JDBC persistence. -- Bjorn Danielsson Cuspy Code AB