mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Jean-Noel Rouvignac
20.11.2014 7d7913228e6f52273f2fdada6822a380f95e0f8c
opendj-sdk/opendj-server/src/main/java/org/forgerock/opendj/server/setup/model/Model.java
@@ -143,14 +143,14 @@
     * Sets the type of this server as : replication activated and this is the first server in topology.
     */
    void setFirstInTopology() {
        this.setType(Type.FIRST_IN_TOPOLOGY);
        setType(Type.FIRST_IN_TOPOLOGY);
    }
    /**
     * Sets the type of this server as : replication activated and this is a server in an existing topology.
     */
    void setInExistingTopology() {
        this.setType(Type.IN_EXISTING_TOPOLOGY);
        setType(Type.IN_EXISTING_TOPOLOGY);
    }
    /**
@@ -368,16 +368,16 @@
     */
    void validate() throws ConfigException {
        if (isFirstInTopology() || isPartOfReplicationTopology()) {
            if (this.getReplicationConfiguration() == null) {
            if (getReplicationConfiguration() == null) {
                throw new ConfigException(LocalizableMessage.raw("No replication configuration found"));
            }
            if (isPartOfReplicationTopology()) {
                Reject.ifNull(this.getReplicationConfiguration().getAdministrator(),
                Reject.ifNull(getReplicationConfiguration().getAdministrator(),
                        "Administrator name should not be null");
                Reject.ifNull(this.getReplicationConfiguration().getPassword(), "Admin password should not be null");
                Reject.ifNull(this.getReplicationConfiguration().getGlobalAdministrator(),
                Reject.ifNull(getReplicationConfiguration().getPassword(), "Admin password should not be null");
                Reject.ifNull(getReplicationConfiguration().getGlobalAdministrator(),
                        "Global administrator should not be null");
                Reject.ifNull(this.getReplicationConfiguration().getGlobalAdministratorPassword(),
                Reject.ifNull(getReplicationConfiguration().getGlobalAdministratorPassword(),
                        "Global administrator should not be null");
                if (getReplicationConfiguration().getSuffixes() == null
                        || getReplicationConfiguration().getSuffixes().size() == 0) {