scaffolding.custom-module.mjs.main-ingestion-legacy-upgrade.mjs Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of marklogic-data-hub Show documentation
Show all versions of marklogic-data-hub Show documentation
Library for Creating an Operational Data Hub on MarkLogic
import hubUtils from "/data-hub/5/impl/hub-utils.mjs";
function main(content, options) {
const legacyOptions = options.options;
const contentUri = content["uri"];
let contentValue = content["value"];
const contentContext = content["context"];
if(hubUtils.isJsonDocument(contentValue)) {
contentValue = contentValue.toObject();
contentValue = (contentValue && contentValue.content) ? contentValue.content : contentValue;
}
let result = {};
result["uri"] = contentUri;
result["value"] = require(legacyOptions["mainModuleUri"]).main(contentUri, contentValue, legacyOptions);
result["context"] = contentContext;
return result;
}
export default {
main
};
© 2015 - 2024 Weber Informatics LLC | Privacy Policy