Skip to content

Commit c5e0b8c

Browse files
author
Charles Greer
authored
Merge pull request #1370 from rahulvudutala/develop
DHFPROD-1126: 4.0.1 Example Project Changes
2 parents 5d690f3 + a0f9f86 commit c5e0b8c

File tree

60 files changed

+735
-688
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+735
-688
lines changed

examples/barebones/README.md

Lines changed: 44 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,44 @@
1-
# Barebones Example
2-
3-
This example shows you the zen of Data Hub Framework. Simply drop a `build.gradle` into a directory with these contents:
4-
5-
build.gradle:
6-
```groovy
7-
plugins {
8-
// this plugin lets you create properties files
9-
// for multiple environments... like dev, qa, prod
10-
id 'net.saliman.properties' version '1.4.6'
11-
12-
// this is the data hub framework gradle plugin
13-
// it includes ml-gradle. This plugin is what lets you
14-
// run DHF (Data Hub Framework) tasks from the
15-
// command line
16-
id 'com.marklogic.ml-data-hub' version '4.0.0'
17-
}
18-
```
19-
20-
Next, Initialize your DHF app:
21-
22-
```bash
23-
gradle hubInit
24-
```
25-
26-
Then Bootstrap your DHF app:
27-
28-
```bash
29-
gradle mlDeploy
30-
```
31-
32-
Then Deploy your custom modules:
33-
34-
```bash
35-
gradle mlLoadModules
36-
```
37-
38-
You can use scaffolding commands to configure flows.
39-
40-
```bash
41-
gradle hubCreateInputFlow
42-
gradle hubCreateHarmonizeFlow
43-
```
44-
For a complete list of gradle tasks, check here: [https://github.com/marklogic/marklogic-data-hub/wiki/Gradle-Tasks](https://github.com/marklogic/marklogic-data-hub/wiki/Gradle-Tasks)
1+
# Barebones Example
2+
3+
This example shows you the zen of Data Hub Framework. Simply drop a `build.gradle` into a directory with these contents:
4+
5+
build.gradle:
6+
```groovy
7+
plugins {
8+
// this plugin lets you create properties files
9+
// for multiple environments... like dev, qa, prod
10+
id 'net.saliman.properties' version '1.4.6'
11+
12+
// this is the data hub framework gradle plugin
13+
// it includes ml-gradle. This plugin is what lets you
14+
// run DHF (Data Hub Framework) tasks from the
15+
// command line
16+
id 'com.marklogic.ml-data-hub' version '4.0.1'
17+
}
18+
```
19+
20+
Next, Initialize your DHF app:
21+
22+
```bash
23+
gradle hubInit
24+
```
25+
26+
Then Bootstrap your DHF app:
27+
28+
```bash
29+
gradle mlDeploy
30+
```
31+
32+
Then Deploy your custom modules:
33+
34+
```bash
35+
gradle mlLoadModules
36+
```
37+
38+
You can use scaffolding commands to configure flows.
39+
40+
```bash
41+
gradle hubCreateInputFlow
42+
gradle hubCreateHarmonizeFlow
43+
```
44+
For a complete list of gradle tasks, check here: [https://marklogic.github.io/marklogic-data-hub/docs/gradle-tasks](https://marklogic.github.io/marklogic-data-hub/docs/gradle-tasks)

examples/barebones/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ plugins {
77
// it includes ml-gradle. This plugin is what lets you
88
// run DHF (Data Hub Framework) tasks from the
99
// command line
10-
id 'com.marklogic.ml-data-hub' version '4.0.0'
10+
id 'com.marklogic.ml-data-hub' version '4.0.1'
1111
}

examples/custom-tokens/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,4 +54,4 @@ gradle mlDeploy
5454
```
5555
Once the deployment is complete, then you can login to the admin console and see the new test database and test database application server that were created with the values that were specified from our properties file. Now that you've mastered utilizing custom tokens for your gradle deployment, you can continue on with your DHF app development.
5656

57-
For a complete list of gradle tasks, check here: [https://github.com/marklogic/marklogic-data-hub/wiki/Gradle-Tasks](https://github.com/marklogic/marklogic-data-hub/wiki/Gradle-Tasks)
57+
For a complete list of gradle tasks, check here: [https://marklogic.github.io/marklogic-data-hub/docs/gradle-tasks](https://marklogic.github.io/marklogic-data-hub/docs/gradle-tasks)

examples/custom-tokens/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ plugins {
77
// it includes ml-gradle. This plugin is what lets you
88
// run DHF (Data Hub Framework) tasks from the
99
// command line
10-
id 'com.marklogic.ml-data-hub' version '4.0.0'
10+
id 'com.marklogic.ml-data-hub' version '4.0.1'
1111
}
Lines changed: 132 additions & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -1,89 +1,132 @@
1-
# These settings are used by the Data Hub Framework when
2-
# communicating with MarkLogic.
3-
# The values in this file are meant as project-wide settings.
4-
# You can override these properties for a specific environment
5-
# by creating a gradle-{environment}.properties file.
6-
# For example, to create a properties file for your prod environment create a file
7-
# named gradle-prod.properties.
8-
#
9-
# ....
10-
mlHost=localhost
11-
12-
# Your MarkLogic Username and Password
13-
mlUsername=admin
14-
mlPassword=admin
15-
16-
# If specified, the manage username/password combo is used with the ML Management REST API for managing application
17-
# resources; this user must have the manage-admin and rest-admin roles.
18-
#
19-
# If these are not set, then mlUsername/mlPassword is used for managing application resources.
20-
# mlManageUsername=
21-
# mlManagePassword=
22-
23-
# If specified, the admin username/password combo is used with the ML Management REST API for creating users and roles. This
24-
# user must have the manage-admin or admin role. A good practice is to use your admin account here to create app-specific
25-
# users and roles, which can then be used as mlManageUsername/mlManagePassword and mlUsername/mlPassword.
26-
#
27-
# These properties are also used for connecting to the admin application on port 8001 - e.g. for initializing ML and for
28-
# waiting for ML to restart.
29-
#
30-
# If these properties are not set, then mlUsername/mlPassword will be used.
31-
# mlAdminUsername=
32-
# mlAdminPassword=
33-
34-
# If specified, these values can override where the DHF thinks
35-
# MarkLogic default ports are at. You would only use this if you
36-
# have changed the ports on which MarkLogic listens
37-
#
38-
# mlAppServicesPort=8000
39-
# mlAdminPort=8001
40-
# mlManagePort=8002
41-
42-
mlStagingAppserverName=data-hub-STAGING
43-
mlStagingPort=8010
44-
mlStagingDbName=data-hub-STAGING
45-
mlStagingForestsPerHost=4
46-
mlStagingAuth=digest
47-
48-
mlFinalAppserverName=data-hub-FINAL
49-
mlFinalPort=8011
50-
mlFinalDbName=data-hub-FINAL
51-
mlFinalForestsPerHost=4
52-
mlFinalAuth=digest
53-
54-
mlTraceAppserverName=data-hub-TRACING
55-
mlTracePort=8012
56-
mlTraceDbName=data-hub-TRACING
57-
mlTraceForestsPerHost=1
58-
mlTraceAuth=digest
59-
60-
mlJobAppserverName=data-hub-JOBS
61-
mlJobPort=8013
62-
mlJobDbName=data-hub-JOBS
63-
mlJobForestsPerHost=1
64-
mlJobAuth=digest
65-
66-
mlModulesDbName=data-hub-MODULES
67-
mlModulesForestsPerHost=1
68-
69-
mlStagingTriggersDbName=data-hub-TRIGGERS
70-
mlStagingTriggersForestsPerHost=1
71-
72-
mlStagingSchemasDbName=data-hub-SCHEMAS
73-
mlStagingSchemasForestsPerHost=1
74-
75-
# You can override this to specify an alternate folder for your
76-
# custom forest info. Defaults to user-config/forests/
77-
# mlCustomForestPath=forests
78-
79-
# The name of the Role to create for Hub Access
80-
mlHubUserRole=data-hub-role
81-
mlHubUserName=data-hub-user
82-
# this password is autogenerated for you via the 'gradle hubInit' task
83-
mlHubUserPassword=b$I7'3Ya|&;Ohw.ZzsDY
84-
85-
# Custom properties defined here
86-
TEST_DATABASE_NAME=custom-tokens-test-database
87-
TEST_SERVER_NAME=custom-tokens-test-database-server
88-
TEST_SERVER_PORT=8014
89-
TEST_TRACE_AUTH=digest
1+
# These settings are used by the Data Hub Framework when
2+
# communicating with MarkLogic.
3+
# The values in this file are meant as project-wide settings.
4+
# You can override these properties for a specific environment
5+
# by creating a gradle-{environment}.properties file.
6+
# For example, to create a properties file for your prod environment create a file
7+
# named gradle-prod.properties.
8+
#
9+
# ....
10+
mlDHFVersion=4.0.1
11+
mlHost=localhost
12+
13+
# If you are working with a load balancer please specify it here
14+
# mlIsHostLoadBalancer=false
15+
16+
# Your MarkLogic Username and Password
17+
mlUsername=
18+
mlPassword=
19+
20+
# If specified, the manage username/password combo is used with the ML Management REST API for managing application
21+
# resources; this user must have the manage-admin and rest-admin roles.
22+
#
23+
# If these are not set, then mlUsername/mlPassword is used for managing application resources.
24+
# mlManageUsername=
25+
# mlManagePassword=
26+
#
27+
# To change the Manage Port
28+
# mlManagePort=8002
29+
#
30+
# To use SSL on the Manage appserver (port 8002 by default)
31+
# mlManageScheme=https
32+
# mlManageSimpleSsl=true
33+
34+
# If specified, the admin username/password combo is used with the ML Management REST API for creating users and roles. This
35+
# user must have the manage-admin or admin role. A good practice is to use your admin account here to create app-specific
36+
# users and roles, which can then be used as mlManageUsername/mlManagePassword and mlUsername/mlPassword.
37+
#
38+
# These properties are also used for connecting to the admin application on port 8001 - e.g. for initializing ML and for
39+
# waiting for ML to restart.
40+
#
41+
# If these properties are not set, then mlUsername/mlPassword will be used.
42+
# mlAdminUsername=
43+
# mlAdminPassword=
44+
#
45+
# To change the Admin Port
46+
# mlAdminPort=8001
47+
#
48+
# To use SSL on the Admin appserver (port 8001 by default)
49+
# mlAdminScheme=https
50+
# mlAdminSimpleSsl=true
51+
52+
53+
# If specified, these values can override where the DHF thinks
54+
# MarkLogic default ports are at. You would only use this if you
55+
# have changed the ports on which MarkLogic listens
56+
#
57+
# mlAppServicesPort=8000
58+
#
59+
# To use SSL on the AppServices appserver (port 8000 by default)
60+
# mlAppServicesSimpleSsl=true
61+
62+
63+
mlStagingAppserverName=data-hub-STAGING
64+
mlStagingPort=8010
65+
mlStagingDbName=data-hub-STAGING
66+
mlStagingForestsPerHost=4
67+
mlStagingAuth=digest
68+
# To enable SSL for staging
69+
# mlStagingSimpleSsl=true
70+
71+
mlFinalAppserverName=data-hub-FINAL
72+
mlFinalPort=8011
73+
mlFinalDbName=data-hub-FINAL
74+
mlFinalForestsPerHost=4
75+
mlFinalAuth=digest
76+
# To enable SSL for final
77+
# mlFinalSimpleSsl=true
78+
79+
80+
mlJobAppserverName=data-hub-JOBS
81+
mlJobPort=8013
82+
mlJobDbName=data-hub-JOBS
83+
mlJobForestsPerHost=1
84+
mlJobAuth=digest
85+
# To enable SSL for jobs
86+
# mlJobSimpleSsl=true
87+
88+
mlModulesDbName=data-hub-MODULES
89+
mlModulesForestsPerHost=1
90+
91+
mlStagingTriggersDbName=data-hub-staging-TRIGGERS
92+
mlStagingTriggersForestsPerHost=1
93+
94+
mlStagingSchemasDbName=data-hub-staging-SCHEMAS
95+
mlStagingSchemasForestsPerHost=1
96+
97+
mlFinalTriggersDbName=data-hub-final-TRIGGERS
98+
mlFinalTriggersForestsPerHost=1
99+
100+
mlFinalSchemasDbName=data-hub-final-SCHEMAS
101+
mlFinalSchemasForestsPerHost=1
102+
103+
# You can override this to specify an alternate folder for your
104+
# custom forest info. Defaults to user-config/forests/
105+
# mlCustomForestPath=forests
106+
107+
# The name of the Role to create for Hub Access
108+
mlHubUserRole=data-hub-role
109+
mlHubUserName=data-hub-user
110+
# this password is autogenerated for you via the 'gradle hubInit' task
111+
mlHubUserPassword=_RK6_vC*eR9J&6<PEE6V
112+
113+
# The name of the role to create for hub deployment/development
114+
mlHubAdminRole=hub-admin-role
115+
mlHubAdminUserName=hub-admin-user
116+
mlHubAdminUserPassword=o@r*'.2HAt(3iAoXR/*v
117+
118+
# Deprecated property
119+
# If you are working with a load balancer please indicate so using
120+
# property "mlIsHostLoadBalancer"
121+
# When "mlIsHostLoadBalancer" is set to "true", the value specified for "mlHost" will be used as the load balancer.
122+
# You do not need to explicitly set the value of "mlLoadBalancerHosts" but if you do it must match the value of the property "mlHost"
123+
# mlLoadBalancerHosts=your-load-balancer-hostname
124+
125+
# Default module permissions which allow data-hub-role to execute flows
126+
mlModulePermissions=rest-reader,read,rest-writer,insert,rest-writer,update,rest-extension-user,execute,data-hub-role,read,data-hub-role,execute
127+
128+
# Custom properties defined here
129+
TEST_DATABASE_NAME=custom-tokens-test-database
130+
TEST_SERVER_NAME=custom-tokens-test-database-server
131+
TEST_SERVER_PORT=8014
132+
TEST_TRACE_AUTH=digest
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"database-name": "%%mlFinalModulesDbName%%",
2+
"database-name": "%%mlModulesDbName%%",
33
"collection-lexicon": true,
44
"uri-lexicon": true
55
}

examples/custom-tokens/src/main/ml-config/servers/final-server.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"root": "/",
55
"group-name": "%%GROUP%%",
66
"port": "%%mlFinalPort%%",
7-
"modules-database": "%%mlFinalModulesDbName%%",
7+
"modules-database": "%%mlModulesDbName%%",
88
"content-database": "%%mlFinalDbName%%",
99
"authentication": "%%mlFinalAuth%%",
1010
"default-error-format": "json",

examples/custom-tokens/user-config/databases/test-database.json

Lines changed: 0 additions & 4 deletions
This file was deleted.

examples/custom-tokens/user-config/servers/test-server.json

Lines changed: 0 additions & 15 deletions
This file was deleted.

examples/data-integration-tests/build.gradle

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ plugins {
1919

2020
// This gradle plugin extends the ml-gradle plugin with
2121
// commands that make the Data Hub Framework do its magic
22-
id 'com.marklogic.ml-data-hub' version '4.0.0'
22+
id 'com.marklogic.ml-data-hub' version '4.0.1'
2323

2424
id "org.jetbrains.kotlin.jvm" version "1.2.21"
2525
}
@@ -34,9 +34,9 @@ repositories {
3434
dependencies {
3535
// this allows you to write custom java code that depends
3636
// on the Data Hub Framework library
37-
compile 'com.marklogic:marklogic-data-hub:4.0.0'
38-
compile 'com.marklogic:marklogic-xcc:9.0.6'
39-
compile 'com.marklogic:marklogic-client-api:4.1.0'
37+
compile 'com.marklogic:marklogic-data-hub:4.0.1'
38+
compile 'com.marklogic:marklogic-xcc:9.0.7'
39+
compile 'com.marklogic:marklogic-client-api:4.1.1'
4040
// prototyping with kotlin tests
4141
compile 'io.github.microutils:kotlin-logging:1.4.6'
4242
compile "org.jetbrains.kotlin:kotlin-stdlib"

0 commit comments

Comments
 (0)