public AmbryServer initializeServer(DataNodeId dataNodeId, Properties sslProperties, boolean enableHardDeletes,
      NotificationSystem notificationSystem, Time time, MockClusterAgentsFactory mockClusterAgentsFactory)
      throws InstantiationException {
    AmbryServer server;
    if (mockClusterAgentsFactory != null) {
      server =
          new AmbryServer(createInitProperties(dataNodeId, enableHardDeletes, sslProperties), mockClusterAgentsFactory,
              mockClusterSpectatorFactory, notificationSystem, time, null);
    } else {
      server = new AmbryServer(createInitProperties(dataNodeId, enableHardDeletes, sslProperties),
          this.mockClusterAgentsFactory, mockClusterSpectatorFactory, notificationSystem, time, null);
    }
    return server;
  }
Initialize {@link AmbryServer} node.
@param dataNodeId {@link DataNodeId} object of the server initialized.
@param sslProperties {@link Properties} object.
@param enableHardDeletes {@code enableHardDeletes} flag.
@param notificationSystem {@link NotificationSystem} object.
@param time {@link Time} object.
@param mockClusterAgentsFactory {@link MockClusterAgentsFactory} object. If null, use the member {@code mockClusterAgentsFactory}.
@return {@link AmbryServer} object.
ambry-test-utils/src/main/java/com/github/ambry/server/MockCluster.java