[ https://issues.apache.org/jira/browse/ARTEMIS-1637?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Justin Bertram updated ARTEMIS-1637: ------------------------------------ Affects Version/s: (was: 2.5.0) > artemis data exp does not work with JDBC store > ---------------------------------------------- > > Key: ARTEMIS-1637 > URL: https://issues.apache.org/jira/browse/ARTEMIS-1637 > Project: ActiveMQ Artemis > Issue Type: Bug > Components: Broker > Environment: apache-artemis-2.5.0-20180111.113938-84-bin > postgres (PostgreSQL) 10.1 > Reporter: Jiri Daněk > Priority: Major > > Prepare database > {noformat} > initdb . > pg_ctl -D . -l logfile start > createdb test > {noformat} > Configure broker (changes from defaul) > {noformat} > diff --git a/broker.xml b/broker.xml > index ea55343..ea5131b 100644 > --- a/broker.xml > +++ b/broker.xml > @@ -29,45 +29,16 @@ under the License. > > <persistence-enabled>true</persistence-enabled> > > - <!-- this could be ASYNCIO, MAPPED, NIO > - ASYNCIO: Linux Libaio > - MAPPED: mmap files > - NIO: Plain Java Files > - --> > - <journal-type>NIO</journal-type> > - > - <paging-directory>./data/paging</paging-directory> > - > - <bindings-directory>./data/bindings</bindings-directory> > - > - <journal-directory>./data/journal</journal-directory> > - > - > <large-messages-directory>./data/large-messages</large-messages-directory> > - > - <journal-datasync>true</journal-datasync> > - > - <journal-min-files>2</journal-min-files> > - > - <journal-pool-files>-1</journal-pool-files> > - > - <journal-file-size>10M</journal-file-size> > - > - <!-- > - This value was determined through a calculation. > - Your system could perform 0.35 writes per millisecond > - on the current journal configuration. > - That translates as a sync write every 2864000 nanoseconds. > - > - Note: If you specify 0 the system will perform writes directly to the > disk. > - We recommend this to be 0 if you are using journalType=MAPPED > and ournal-datasync=false. > - --> > - <journal-buffer-timeout>2864000</journal-buffer-timeout> > - > - > - <!-- > - When using ASYNCIO, this will determine the writing queue depth for > libaio. > - --> > - <journal-max-io>1</journal-max-io> > + <store> > + <database-store> > + > <jdbc-connection-url><![CDATA[jdbc:postgresql://localhost/test]]></jdbc-connection-url> > + <bindings-table-name>BINDINGS_TABLE</bindings-table-name> > + <message-table-name>MESSAGE_TABLE</message-table-name> > + <page-store-table-name>MESSAGE_T</page-store-table-name> > + > <large-message-table-name>LARGE_MESSAGES_TABLE</large-message-table-name> > + > <jdbc-driver-class-name>org.postgresql.Driver</jdbc-driver-class-name> > + </database-store> > + </store> > <!-- > You can verify the network health of a particular NIC by specifying > the <network-check-NIC> element. > <network-check-NIC>theNicName</network-check-NIC> > {noformat} > Start broker > {noformat} > $ bin/artemis run > [...] > {noformat} > Send messages > {noformat} > $ java -jar cli-qpid-jms/target/cli-qpid-jms-1.2.2-SNAPSHOT-LATEST.jar sender > -b localhost:5672 -a lalaQa --log-msgs dict > amqp://localhost:5672 > {'address': 'lalaQa', 'group-id': None, 'subject': None, 'user-id': None, > 'correlation-id': None, 'content-encoding': None, 'priority': 4, 'type': > None, 'ttl': 0, 'absolute-expiry-time': 0, 'content': None, 'redelivered': > False, 'reply-to-group-id': None, 'durable': True, 'delivery-time': > 1516831773986, 'group-sequence': '0', 'creation-time': 1516831773986, > 'content-type': None, 'id': 'ea29922d-109d-4ed7-a5ef-46c90f756b25:1:1:1-1', > 'reply-to': None, 'properties': {'JMSXDeliveryCount': 1}} > {noformat} > Stop the broker and attempt to export messages > {noformat} > $ bin/artemis data exp > 2018-01-24 23:10:18,045 WARN [org.apache.activemq.artemis.core.server] > AMQ222018: AIO was not located on this platform, it will fall back to using > pure Java NIO. If your platform is Linux, install LibAIO to enable the AIO > journal > 2018-01-24 23:10:18,129 INFO [org.apache.activemq.artemis.core.server] > AMQ221013: Using NIO Journal > <?xml version="1.0"?> > <activemq-journal> > <bindings> > </bindings> > <messages> > </messages> > </activemq-journal> > {noformat} > No messages are exported. > (Importing messages into a running broker which is backed by JDBC database > does work.) -- This message was sent by Atlassian JIRA (v7.6.3#76005)