Administrator
- Administrator
- All Products
Include the following fields in the request:mftsaas/api/v1/mitasks
Field
| Type
| Required
| Description
|
---|---|---|---|
name
| String
| Yes
| Name of the task.
|
location
| String
| -
| Location of the project.
|
projectId
| String
| -
| ID number associated with the project.
|
projectName
| String
| -
| Name of the project.
|
description
| String
| -
| Description of the task.
|
sourceConnection
| String
| -
| Directory from where files are transferred.
|
sourceType
| String
| Yes
| Determines the type where files are transferred. Enter one of the following options:
|
includesubfolder
| String
| -
| Determines whether to include the files in sub-folders in the transfer. Set the value to
true to transfer files from all sub-folders under the defined source directory. Values are
true or
false .
|
checkDuplicate
| String
| -
| Determines whether to check for duplicate files. Values are
true or
false . Set the value to
true to check duplicate files and deny file transfer. If the value is set to
false all files are transferred.
|
filePickupOption
| String
| Yes
| Determines the file pickup method. Enter one of the following options:
|
allowConcurrency
| String
| -
| Determines whether to run multiple jobs concurrently. Set the value to
true to run multiple jobs concurrently, else set the value to
false .
Running concurrent jobs might cause unexpected results if the targets include duplicate files.
|
filePatternType
| String
| Yes
| This applies when filePickupOption is PATTERN.
File pattern type used to select files to transfer. Enter one of the following options:
|
filePattern
| String
| Yes
| Enter file pattern types, depending on the file pattern that you have selected.
|
filepickupByName
| String
| Yes
| This applies when filePickupOption is FILELIST. Enter one of the following options:
|
fileStability
| Boolean
| -
| Determines if the task verifies whether the file is stable before picking it up. Enter one of the following values.
Default is
false .
|
stabilityCheckInterval
| Int
| -
| Time in seconds that a
file ingestion and replication task waits to check the file stability.
You can specify a value in the stabilityCheckInterval field only if the fileStability option is set to
true .
The stability check interval ranges between 10 seconds to 300 seconds.
|
postPickupAction
| String
| -
| Determines what to do with source files after the transfer of files. The following options are available:
|
targetConnection
| String
| Yes
| Directory details to which files are transferred.
|
taskActions
| String
| -
| Actions to process files in the
file ingestion and replication task. If you add multiple actions,
file ingestion and replication processes files in a sequence.
|
actions
| File processing action.
Enter the following file processing actions:
| ||
action type
| Enter the action type depending on the action that you add.
To compress files use one of the following methods.
To decompress files use one of the following methods.
To encrypt files add PGP. Enter the key ID in the properties.
The
file ingestion and replication task uses the PGP method to encrypt files. Generate a key ring using the CLI. Enter the key ring in the
Key ID . For more information about the keyring CLIs, refer to key ring command reference in
Tasks .
To decrypt files, add PGP. Enter the key passphrase in the properties.
The
file ingestion and replication task uses the PGP method to encrypt files. Generate the key passphrase using the CLI. Enter the key passphrase in the
Key Passphrase . For more information about the keyring CLIs, refer to key ring command reference in
Tasks .
|
POST <serverURL>/public/core/v1/mitasks Content-Type: application/json Accept:application/json Content-Type:application/json IDS-SESSION-ID:{{IDS-SESSION-ID}} { "name": "Green Green v2", "location": { "projectId": "9JDNOBX9M31e2AD1dIUv6M", "projectName": "Default" }, "description": "", "sourceType": "CONNECTION", "sourceConnection": { "id": "", "name": "", "type": "local" }, "sourceParameters": { "filePattern": "*.txt", "filePatternType": "WILDCARD", "includeSubfolder": "false", "sourceDirectory": "C:\\Monitor", "checkDuplicate": "false", "fileStability": "true", "stabilityCheckInterval": "60", "postPickupAction": "KEEP" }, "targetConnection": { "id": "0100000B000000000002", "name": "ADLS", "type": "Azure Data Lake" }, "targetParameters": { "adlsTargetLocation": "/satyen/green" }, "agentGroupId": "01000025000000000002", "filePickupOption": "PATTERN", "logLevel": "NORMAL", "allowConcurrency": "true", taskActions":[ { "action": "Compression", "actionType": "Zip", "properties": {} } ] }
POST <serverURL>/public/core/v1/mitasks Content-Type: application/json Accept:application/json Content-Type:application/json IDS-SESSION-ID:{{IDS-SESSION-ID}} { "name": "FilePath_RestAPI1", "location": { "projectId": "0ggRhrI8ZziguyBxHBzuG0", "projectName": "Default" }, "description": "", "sourceType": "CONNECTION", "sourceConnection": { "id": "", "name": "", "type": "local" }, "targetConnection": { "id": "", "name": "", "type": "local" }, "sourceParameters": { "filePickupFilePath": "test.txt", "sourceDirectory": "/root/test", "checkDuplicate": "false", "fileStability": "true", "stabilityCheckInterval": "60", "postPickupAction": "KEEP", "filepickupByName": "FILEPATH", "batchSize": "5" }, "targetParameters": { "fileExistsAction": "OVERWRITE", "targetDirectory": "/root/testCheckStability" }, "agentGroupId": "01001D25000000000002", "logLevel": "NORMAL", "filePickupOption": "FILELIST", "allowConcurrency": "true" }
POST <serverURL>/public/core/v1/mitasks Content-Type: application/json Accept:application/json Content-Type:application/json IDS-SESSION-ID:{{IDS-SESSION-ID}} { "name": "DedupFilelist_RestAPI", "location": { "projectId": "0ggRhrI8ZziguyBxHBzuG0", "projectName": "Default" }, "description": "", "sourceType": "CONNECTION", "sourceConnection": { "id": "01001D0B0000000005PP", "name": "ADLSGen2", "type": "Azure Data Lake Gen2" }, "targetConnection": { "id": "01001D0B0000000005PU", "name": "AzureDW_Gen2", "type": "Azure DW" }, "sourceParameters": { "sourceDirectory": "/B2B/MI", "checkDuplicate": "true", "postPickupAction": "KEEP", "filepickupByName": "LISTOFFILES", "blockSize": "8388608", "filePickupFileList": "File1.txt,File2.txt", "batchSize": "5", "timeoutInterval": "60", "fileStability": "true", "stabilityCheckInterval": "60" }, "targetParameters": { "commandType": "auto", "targetTableName": "test1234", "isPushdown": "true", "ingestionMethod": "polybase", "targetSchemaName": "testing", "isTruncateTarget": "true" }, "agentGroupId": "01001D25000000000002", "logLevel": "NORMAL", "filePickupOption": "FILELIST", "allowConcurrency": "true" }
{ "id": "cEMWKpibm44bNf5aMjbJ4U", "name": "Green Green v2", "location": { "projectId": "9JDNOBX9M31e2AD1dIUv6M", "projectName": "Default" }, "description": "", "sourceType": "CONNECTION", "sourceConnection": { "id": "", "name": "", "type": "local" }, "sourceParameters": { "filePattern": "*.txt", "filePatternType": "WILDCARD", "includeSubfolder": "false", "sourceDirectory": "C:\\Monitor", "checkDuplicate": "false", "fileStability": "true", "stabilityCheckInterval": "60", "postPickupAction": "KEEP" }, "targetConnection": { "id": "0100000B000000000002", "name": "ADLS", "type": "Azure Data Lake" }, "targetParameters": { "adlsTargetLocation": "/satyen/green" }, "agentGroupId": "01000025000000000002", "createdTime": "2018-08-27T07:03:32Z", "updatedTime": "2018-08-29T12:14:58Z"" taskActions":[ { "action": "Compression", "actionType": "Zip", "properties": {} } ] } }