Interface MasterDataInstanceImportBuilder

  • All Known Implementing Classes:
    MasterDataInstanceImportBuilderImpl

    public interface MasterDataInstanceImportBuilder
    An Import Builder which allows importing master data instances in bulk from master data documents.

    The documents being imported should have the following format:

    Single tenant:

    
         {
             "dataObjectDefinitionKey": "country",
             "tenantId": "acme",
             "masterData": [
               {...},
               ...
             ]
         }
     

    Multi tenants:

    
         {
             "dataObjectDefinitionKey": "country",
             "tenantIds": [ "acme", "megacorp" ],
             "masterData": [
               {...},
               ...
             ]
         }
     

    If the data object definition key or id are provided then the document can also have the following format:

    
         [
           {...},
           ...
         ]
     
    Author:
    Filip Hrisafov
    • Method Detail

      • tenantId

        MasterDataInstanceImportBuilder tenantId​(String tenantId)
        The tenantId that should be used when deploying the master data resource documents. If set then the tenantId from the document would be ignored.
        Parameters:
        tenantId - the id of the tenant to which to deploy
      • dataObjectDefinitionKey

        MasterDataInstanceImportBuilder dataObjectDefinitionKey​(String dataObjectDefinitionKey)
        The data object definition key that should be used when deploying the master data resource documents. If set then the dataObjectDefinitionKey from the document would be ignored.
        Parameters:
        dataObjectDefinitionKey - the key of the data object that should be used for deployment
      • dataObjectDefinitionId

        MasterDataInstanceImportBuilder dataObjectDefinitionId​(String dataObjectDefinitionId)
        The data object definition id that should be used when deploying the master data resource documents. If set then the dataObjectDefinitionKey from the document would be ignored.
        Parameters:
        dataObjectDefinitionId - the id of the data object that should be used for deployment
      • overwrite

        MasterDataInstanceImportBuilder overwrite()
        Before importing master data instances from the document. Delete all of them that matched the definition id / key in the matching tenant. This should be used with care. If set then the overwrite flag from the document would be ignored.