Affects Version/s: 5.3.1-fuse-01-00, 5.4.2-fuse-01-00
Fix Version/s: None
There is a message loss of persisted messages in latest ActiveMQ, using AMQ Persistent Store. The following test case for both 18.104.22.168-fuse and 5.4.2-fuse-01-00 exemplifies the problem. Here's the broker configuration:
Then, run the following script to populate the AMQ Store data logs. This script has been carefully thought out to leave a message in data-1, the first log file. Note that the script should be run in the ActiveMQ examples/ directory.
After running this script, you should see 3 data files in the AMQ Store journal directory.
Now, shutdown the broker, and delete the KR indices (activemq-data/kr-store/*).
On restart, the AsyncDataManager thread will go through the data files, and errantly determine that data-1 has no references. It moves data-1 to the archive directory. As a result, we see that the message we sent to queue 'Store1' is missing.
Only deleting the "state" folder in activemq-data/kr-store/ resolves this issue, however, the customer would like to see the use case work when deleting the entire kr-store file.