masterChangeListener = new MasterChangeListener();
learner.addListener(masterChangeListener);
learner.start();
try {
/* Notify the listener about the current master. */
final ReplicationGroup repGroup = repGroupAdmin.getGroup();
final RepGroupImpl group = RepInternal.getRepGroupImpl(repGroup);
/*
* In the absence of a network failure, the query should result in
* a call to the notify method of MonitorChanegListener.