Skip to content

Commit

Permalink
Added other database example back
Browse files Browse the repository at this point in the history
  • Loading branch information
rjrudin committed Aug 3, 2016
1 parent 7fb6761 commit 3cd7636
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions examples/sample-project/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,22 @@ ext {
//mlAppDeployer.commands.add(new com.marklogic.appdeployer.command.cpf.DeployDefaultPipelinesCommand())
}

/*
* ml-gradle does not blindly process every file in the ml-config/databases directory. It checks for specific files
* for a content database, a schemas database, and a triggers database. There are specific commands for each file, and
* each command provides a number of options for configuring the forests for a database. So to create another database,
* you'll need the block below.
*
* This will be improved in ml-gradle 2.3.1. Supports exists for this in ml-app-deployer already via the
* DeployOtherDatabasesCommand, it's just not part of mlDeploy yet.
*/
ext {
def otherDbCommand = new com.marklogic.appdeployer.command.databases.DeployDatabaseCommand("other-database.json")
mlAppDeployer.commands.add(otherDbCommand)
mlDatabaseCommands.add(otherDbCommand)
}


/*
* Example of a custom command, which in this case performs a merge on a database. The benefit of doing this in a
* command (as opposed to a task) is that a command can be included in the mlDeploy and mlUndeploy tasks by adding it to
Expand Down

0 comments on commit 3cd7636

Please sign in to comment.