OPENDJ-1441 (CR-4037) Persistent searches on external changelog do not return changes for new replicas and new domains
Fixed a problem introduced in r10918.
In getExistingOrNewDomainMap(DN) method, the MultimasterReplication.isECLEnabledDomain() method is called.
However, this method blocks forever at replication startup because MultimasterReplication state is equals to STARTING
and is only set to RUNNING in code that occurs after in the same thread.
Code sequence is :
1. SynchronizationProviderConfigManager calls MultimasterReplication.initializeSynchronizationProvider()
try to call MultimasterReplication.isECLEnabledDomain() but MultimasterReplication state is equals
to STARTING so it waits indefinitely on a state change
2. SynchronizationProviderConfigManager calls DirectoryServer.registerSynchronizationProvider(provider)
MultimasterReplication state is set to RUNNING
Add a check on registeredMultiDomainCursors to ensure that isECLEnabledDomain() is not called when
the replication server is starting (as no cursors can be created yet).