1

在 MarkLogic 10.0-3 上,使用 ml-data-hub 插件 5.2.1,我想在基于mlAppName属性部署到各种环境(saliman.properties 插件 1.4.6)时,在流程的映射步骤中指定变量源和目标数据库,例如:

[...snip, snip...]
    "2" : {
          "name" : "myStep",
          "description" : "a step in my flow",
          "options" : {
            "additionalCollections" : [ ],
            "sourceQuery" : "cts.collectionQuery([\"targetCollection\"])",
            "mapping" : {
              "name" : "MyFlow-myStep",
              "version" : 0
            },
            "targetEntity" : "MyEntity",
            "sourceDatabase" : "%%mlAppName%%-STAGING",
            "collections" : [ "myStep", "MyEntity" ],
            "permissions" : "data-hub-operator,read,data-hub-operator,update",
            "validateEntity" : false,
            "sourceCollection" : "sourceCollection",
            "outputFormat" : "json",
            "targetDatabase" : "%%mlAppName%%-FINAL"
          },
          "customHook" : {
            "module" : "",
            "parameters" : { },
            "user" : "",
            "runBefore" : false
          },
          "retryLimit" : 0,
          "batchSize" : 100,
          "threadCount" : 4,
          "stepDefinitionName" : "entity-services-mapping",
          "stepDefinitionType" : "MAPPING"
        },
[...snip, snip...]

但是,不会发生令牌替换。这是不可能的,还是有更好的最佳实践方法来实现这一点?谢谢。

4

1 回答 1

2

不幸的是,它还不支持。您必须在加载文档后使用自定义 Gradle 任务来操作文档的内容。请在 DHF github 项目中创建一张票,尽管请求此功能,这是值得添加的。

于 2020-04-12T13:34:38.267 回答