@Override
protected RecordProducer createProducer(final String identifier) {
return new DefaultRecordProducer(this, identifier) {
@Override
protected AppendRecord createRecord() throws JournalException {
return new AppendRecord(TestJournal.this, identifier) {
@Override
public void writeString(String s) throws JournalException {
if (failRecordWrite) {
throw new JournalException("write failed");
} else {