marklogic-community / grove-ml-gradle

Other
1 stars 2 forks source link

Removing the Schemas database config, per "Recommended Method to Run Grove with DHF" will cause mlDeploy to fail #11

Closed mattsmith-ml closed 4 years ago

mattsmith-ml commented 4 years ago

In the Grove and DHF documentation at https://marklogic-community.github.io/grove/guides/data-hub-framework/ one of the recommended steps for using Grove against a DHF environment is remove the configuration for all the databases except for your custom application's modules database so that they aren't created and you can just use the DHF Final database:

Delete content-database.json, schemas-database.json, and triggers-database.json from marklogic/ml-config/databases/.

This is fine for the content and triggers databases but there is a custom grove-ml-gradle task that runs when you run mlDeploy, setSchemasPermissions, that will fail as it always assumes that a schemas database has been created for your app (it's likely looking for appname-schemas or similar). I would recommend detecting if a schemas database config exists in ml-config and only running the task if it does.

At the moment, you can obviously work around this by only removing content-database.json and triggers-database.json. You will deploy an app-specific schemas database that will never get used but mlDeploy will complete.

grtjn commented 4 years ago

We decided to push for the other approach where you merge the gradle projects together, in favor of DHS compatibility. I expect we will merge the doc update soon, but until then it is outlined here https://github.com/marklogic-community/grove/pull/18

mariannemyers commented 4 years ago

Fixed with documentation update linked above.