https://github.com/marklogic-community/mlcp-util
Utility classes for MarkLogic Content Pump
https://github.com/marklogic-community/mlcp-util
content-pump java-library marklogic mlcp
Last synced: 5 months ago
JSON representation
Utility classes for MarkLogic Content Pump
- Host: GitHub
- URL: https://github.com/marklogic-community/mlcp-util
- Owner: marklogic-community
- License: other
- Created: 2016-03-17T23:35:59.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2022-08-10T19:51:47.000Z (almost 4 years ago)
- Last Synced: 2024-04-15T01:15:15.767Z (about 2 years ago)
- Topics: content-pump, java-library, marklogic, mlcp
- Language: Java
- Size: 89.8 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Archived repository
This repository has been archived. All classes have been migrated to the
[ml-javaclient-util subproject in the ml-gradle repository](https://github.com/marklogic/ml-gradle/tree/master/ml-javaclient-util).
The classes will be available in the upcoming ml-gradle 6.0.0 release.
This library provides a bean-like interface for mlcp. It doesn't depend on mlcp - it just collects arguments
and then returns them as a list, which you can then feed into mlcp.
Typical usage of this library looks like this:
MlcpBean bean = new MlcpBean();
bean.setHost("localhost");
// Set any other properties you want, and then build the array of args
String[] args = bean.buildArgs();
// Use mlcp OptionsFileUtil class to expand arguments, such as an options file
String[] expandedArgs = OptionsFileUtil.expandArguments(args);
// Optional - log the args before running mlcp, using whatever logging framework you wish
logger.info(bean.viewArgs(expandedArgs));
// Invoke mlcp
ContentPump.runCommand(expandedArgs);