// mechanism. If assured replication is disabled, this returns
// immediately
prepareWaitForAckIfAssuredEnabled(msg);
try
{
msg.encode();
} catch (UnsupportedEncodingException e)
{
// will be caught at publish time.
}
pendingChanges.commitAndPushCommittedChanges(curChangeNumber, msg);