final MessageStore store = this.mocksControl.createMock(MessageStore.class);
EasyMock.expect(this.storeManager.getOrCreateMessageStore(this.topic, partition)).andReturn(store);
final BooleanCommand expectResp =
new BooleanCommand(HttpStatus.Success, msgId + " " + partition + " " + offset, opaque);
final AtomicBoolean invoked = new AtomicBoolean(false);
final PutCallback cb = new PutCallback() {
@Override
public void putComplete(final ResponseCommand resp) {
invoked.set(true);
if (!expectResp.equals(resp)) {
throw new RuntimeException();