You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 27, 2023. It is now read-only.
You will need to first install MarkLogic if you haven't already. It is recommended to use a virtual machine or remote server to run MarkLogic to partition our resources (MarkLogic likes to use a lot of memory).
26
24
27
-
## What code baseline should I use?
28
-
We use a [fork-and-Branch Git workflow](http://blog.scottlowe.org/2015/01/27/using-fork-branch-git-workflow/). The dev branch contains the latest and greatest code, while master represents the latest published version. **Always branch from DEV**.
29
-
30
-
Review the [jobs/gradle.properties](https://github.com/sastafford/marklogic-spring-batch/blob/master/core/gradle.properties) file to make sure that your host, port, username, and password are correct for your environment. Do not check your local version of gradle.properties.
31
-
32
-
## Should I use an IDE?
25
+
# What code baseline should I use?
26
+
We use a [fork-and-Branch Git workflow](http://blog.scottlowe.org/2015/01/27/using-fork-branch-git-workflow/). The dev branch contains the latest and greatest code, while master represents the latest published version. **Always branch from DEV**. If you issue a pull request, make sure to compare against the DEV branch.
33
27
28
+
# Should I use an IDE?
34
29
Yes, it is recommended to use a Java friendly IDE to make one's life easier. Of course, you can use a simple text editor if that is your preference. The lead authors have a recent preference for [IntelliJ](https://www.jetbrains.com/idea/). We also use Gradle for our swiss army knife of building, testing, deploying, etc. One of the cool features of Gradle is the ability to create the project files for two popular IDE's, IntelliJ and Eclipse.
35
30
36
31
```
@@ -43,39 +38,47 @@ Yes, it is recommended to use a Java friendly IDE to make one's life easier. Of
43
38
44
39
The gradlew (or gradlew.bat on Windows) command is a Java program called the [Gradle Wrapper](https://docs.gradle.org/current/userguide/gradle_wrapper.html) which allows you to run a gradle command without installing Gradle on your machine. If you plan to contribute (or do any type of Java development) it would be worth while to go ahead and install Gradle on your dev machine.
45
40
46
-
## How do I verify things are set up correctly?
47
-
Once you have cloned the project locally execute the test cases. Gradle will handle downloading any dependencies that you need for this effort.
48
-
49
-
```
50
-
gradlew testAll
51
-
```
41
+
# What is the structure for the project?
52
42
53
-
It is our policy that the dev branch tests always are 100% passing. If all tests run to completion and 100% passing then you are ready to start coding.
43
+
*[core](https://github.com/sastafford/marklogic-spring-batch/tree/master/core) - contains enhancements and helper classes to the Spring Batch framework. This includes the following features
44
+
* A job repository that uses MarkLogic to persist job metadata
45
+
* Custom ItemReaders/Processors/Writers and tasklets that work with MarkLogic
46
+
* Configuration annotations for using MarkLogic and Spring Batch together
47
+
*[test](https://github.com/sastafford/marklogic-spring-batch/tree/master/test) - helper classes to assist in the testing of Spring Batch jobs written for MarkLogic.
48
+
*[examples](https://github.com/sastafford/marklogic-spring-batch/tree/master/examples) - A variety of recipes and examples to guide in the creation of your own MarkLogic batch processing jobs (i.e. migrating from a RDBMS)
54
49
55
-
# What should I work on?
50
+
# How do I set up my environment?
56
51
57
-
If you are new to the project the best way to contribute is to add a Job to the job library. Choose of the [job issues](https://github.com/sastafford/marklogic-spring-batch/labels/job) to get started on an assignment. If you have an example of a unique batch processing job then it would be a good idea to add it to the examples project.
52
+
## Deploy your MarkLogic test database
58
53
59
-
# What is the structure for the project?
54
+
Check the following properties file to see if there is any conflicts with your existing system.
60
55
61
-
There are three sub-projects for MarkLogic Spring Batch. Most contributions will be in the examples and jobs projects where the core work would be for those intimately familiar with the Spring Batch code baseline.
56
+
$PROJET_ROOT/core/gradle.properties
62
57
63
-
*[examples](https://github.com/sastafford/marklogic-spring-batch/tree/master/examples) are the recipes for creating your own batch processing jobs (i.e. migrating from a RDBMS). Developers should use these as templates and guidelines for writing their own MarkLogic batch processing jobs.
64
-
*[jobs](https://github.com/sastafford/marklogic-spring-batch/tree/master/jobs) are a library of common MarkLogic batch processing jobs to import, export, and transform.
65
-
*[core](https://github.com/sastafford/marklogic-spring-batch/tree/master/core) contains all enhancements on the Spring Batch framework. This includes the jobs utility, the MarkLogic Job Repository, and any custom ItemReaders/Processors/Writers and tasklets.
58
+
From the project root, run the following command. This will create a test database that is configured as a MarkLogic Job Repository.
66
59
67
-
# How do I test?
60
+
gradlew :core:mlDeploy
68
61
69
-
The quality of this project is based on the tests that exercise the code. Every issue worked should be accompanied by one or more tests that test the primary use case and several edge cases. Code that is submitted without any accompanied tests will not be accepted. Before submitting a pull request, run the test suite and confirm 100% test passing with the following gradle command.
62
+
Run the automated unit tests from the project root
70
63
71
64
```
72
-
./gradlew test
65
+
gradlew test
73
66
```
74
67
68
+
The policy is the dev branch tests are 100% passing. If all tests run to completion and 100% passing then you are ready to start commiting code.
69
+
70
+
# What should I work on?
71
+
72
+
If you are new to the project the best way to contribute is to add or improve an example to the directory of examlpes. Choose of the [job issues](https://github.com/sastafford/marklogic-spring-batch/labels/example) to get started on an assignment.
73
+
74
+
# How do I test?
75
+
76
+
The quality of this project is based on the tests that exercise the code. Every issue worked should be accompanied by one or more tests that test the primary use case and several edge cases. Code that is submitted without any accompanied tests will not be accepted. Before submitting a pull request, run the test suite and confirm 100% test passing with the following gradle command.
77
+
75
78
# How do I deploy the MarkLogic Spring Batch artifacts?
76
79
77
80
## MarkLogic Spring Batch Libraries
78
-
To deploy the marklogic-spring-batch core and jobs library to your local maven repository, first, increment the relevant version number in the gradle.properties file.
81
+
To deploy the marklogic-spring-batch core and test library to your local maven repository, first, increment the relevant version number in the gradle.properties file.
79
82
80
83
It is advised to first publish artifacts to the local maven repository and run local tests before publishing out to [bintray](https://bintray.com/)
81
84
@@ -89,15 +92,6 @@ Once you have verified your version then run the following command to publish to
89
92
gradle bintrayUpload
90
93
```
91
94
92
-
## MSB Command Line Utility
93
-
To deploy the MarkLogic Spring Batch command line program, execute the following gradle command
94
-
95
-
```
96
-
gradle distZip
97
-
```
98
-
99
-
This will create the distribution archive file under ./jobs/build/distribution/jobs.zip. This can then be uploaded to the distribution website.
100
-
101
95
# What is the best way to ask a question?
102
96
Open an issue and label it as a Question. Please don't use email. This is the best way to ask once and answer for all. If you are a MarkLogic employee, I recommend that you subscribe to the java-sig email newsgroup.
0 commit comments