Skip to content
This repository was archived by the owner on Sep 16, 2024. It is now read-only.

Commit aae24f3

Browse files
committed
#377 Deprecating support for creating forests on one host automatically
This is better achieved explicitly via mlDatabasesWithForestsOnOneHost
1 parent b0cb6f8 commit aae24f3

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

src/main/java/com/marklogic/appdeployer/DefaultAppConfigFactory.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -839,6 +839,14 @@ protected ConfigDir buildConfigDir(String path) {
839839
return new ConfigDir(baseDir);
840840
}
841841

842+
/**
843+
* This was added in 3.11.0 to mirror the functionality of the now-deprecated DeployTriggersDatabaseCommand and
844+
* DeploySchemasDatabaseCommand classes. But the mlDatabasesWithForestsOnOneHost property is the better way of
845+
* handling this so that it's explicitly configured, rather than happening magically via setting mlAppName.
846+
*
847+
* @param appConfig
848+
*/
849+
@Deprecated
842850
protected void setDefaultsForDatabasesWithForestsOnOneHost(AppConfig appConfig) {
843851
Set<String> set = appConfig.getDatabasesWithForestsOnOneHost();
844852
if (set == null || set.isEmpty()) {

src/test/java/com/marklogic/appdeployer/DefaultAppConfigFactoryTest.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -552,6 +552,10 @@ public void mlUsernameAndPassword() {
552552
assertNull("SSL hostname verifier should be null by default", config.getRestSslHostnameVerifier());
553553
}
554554

555+
/**
556+
* See notes on the method that's deprecated, should be removed in ml-app-deployer 4.0.
557+
*/
558+
@Deprecated
555559
@Test
556560
public void schemasAndTriggerDatabaseNamesShouldBeInSetOfDatabasesWithForestsOnOneHost() {
557561
sut = new DefaultAppConfigFactory(new SimplePropertySource("mlAppName", "example"));

0 commit comments

Comments
 (0)