There are some crash recovery tests. Some are generic to persistent message stores, one is specific to the 'other' persistent message store implementation.
The test works by sending messages (without receiving), batched into transactions, and can be set up to stop after a certain number have been sent (which can be conveniently arranged to be mid-transaction, if you like). Then it waits for the user to press a key to continue, re-connects and recieves the message, and compares the sent to received. You should get back everything that was in a committed transaction. You can also CTRL-C or kill the broker mid-way through the sending (its done slowly by default to give you time to do this), in order to simulate a real crash. There is also an optional 'trigger' method that can be used to extend the test. This is used to trigger a hot-backup of the message store to test the backup/restore scenario. Tests can be found in the classes PingDurableClient and BackupTestClient (with hot-backup trigger). I think both have main methods you can call which are configured with some reasonable defaults. The Javadoc lists other parameters you can set (in addition to those listed in the parent PingPongProducer class). That should get you started anyway... Rupert On 18/05/07, Arnaud Simon <[EMAIL PROTECTED]> wrote:
So, it should be ok now. I have also written a JDBC store that somebody should check in for me. I would like to know where we stand regarding crash recovery tests? Have been writing any? Cheers Arnaud
