You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you move data from source to destination store, Azure Data Factory copy activity provides data consistency verification to ensure the data is not only successfully copied from source to destination store, but also verified to be consistent between source and destination store. Once inconsistent data have been found during the data movement, you can either abort the copy activity or continue to copy the rest by enabling fault tolerance setting to skip inconsistent data. You can get the skipped object names by enabling session log setting in copy activity.
22
24
23
25
> [!IMPORTANT]
24
-
> This feature is currently in preview due to the limitations below:
25
-
> 1. Data consistency verification is available only for binary files copy between file-based stores with 'PreserveHierarchy' behavior in copy activity.
26
-
> 2. When you get the skipped inconsistent file names by enabling session log setting in copy activity, the completeness of log file can not be 100% guaranteed if copy activity failed.
27
-
> 3. The session log contains inconsistent files names only, where the successfully copied files are not logged.
26
+
> This feature is currently in preview with the known limitations we are actively working on:
27
+
> 1. Data consistency verification is available only for binary files copy between file-based stores with 'PreserveHierarchy' behavior in copy activity. For copying tabular data, data consistency verification is not available in copy activity yet.
28
+
> 2. When you enable session log setting in copy activity to see the inconsistent file list to be skipped, the completeness of log file can not be 100% guaranteed if copy activity failed.
29
+
> 3. The session log contains inconsistent files names only, where the successfully copied files are not logged so far.
28
30
29
31
## Supported data stores
30
32
@@ -48,7 +50,7 @@ When you move data from source to destination store, Azure Data Factory copy act
48
50
49
51
50
52
## Configuration
51
-
The following example provides a JSON definition to enable data consistency in Copy Activity:
53
+
The following example provides a JSON definition to enable data consistency verification in Copy Activity:
52
54
53
55
```json
54
56
"typeProperties": {
@@ -81,21 +83,22 @@ The following example provides a JSON definition to enable data consistency in C
validateDataConsistency | If you set true for this property, copy activity will check file size, lastModifiedDate, and MD5 checksum for each object copied from source to destination store to ensure the data consistency between source and target. Be aware the copy performance will be impacted by enabling this option. | True<br/>False (default) | No
85
-
dataInconsistency | It is one of the key-value pairs for skipErrorFile property to determine if you want to skip the inconsistent data.<br/> -True: you want to copy the rest by skipping inconsistent data.<br/> - False: you want to abort the copy activity once inconsistent data found.<br/>Be aware this property is only valid when you set validateDataConsistency as True. | True<br/>False (default) | No
86
-
logStorageSettings | A group of properties that can be specified when you want to enable session log to show skipped object names. | | No
87
-
linkedServiceName | The linked service of [Azure Blob Storage](connector-azure-blob-storage.md#linked-service-properties) or [Azure Data Lake Storage Gen2](connector-azure-data-lake-storage.md#linked-service-properties) to store the session log. | The names of an `AzureBlobStorage` or `AzureBlobFS` types linked service, which refers to the instance that you want to use to store the log file. | No
86
+
validateDataConsistency | If you set true for this property, copy activity will check file size, lastModifiedDate, and MD5 checksum for each object copied from source to destination store to ensure the data consistency between source and destination store. Be aware the copy performance will be affected by enabling this option. | True<br/>False (default) | No
87
+
dataInconsistency | One of the key-value pairs within skipErrorFile property bag to determine if you want to skip the inconsistent data.<br/> -True: you want to copy the rest by skipping inconsistent data.<br/> - False: you want to abort the copy activity once inconsistent data found.<br/>Be aware this property is only valid when you set validateDataConsistency as True. | True<br/>False (default) | No
88
+
logStorageSettings | A group of properties that can be specified to enable session log to show skipped object names. | | No
89
+
linkedServiceName | The linked service of [Azure Blob Storage](connector-azure-blob-storage.md#linked-service-properties) or [Azure Data Lake Storage Gen2](connector-azure-data-lake-storage.md#linked-service-properties) to store the session log files. | The names of an `AzureBlobStorage` or `AzureBlobFS` types linked service, which refers to the instance that you want to use to store the log file. | No
88
90
path | The path of the log file. | Specify the path that you want to store the log file. If you do not provide a path, the service creates a container for you. | No
89
91
90
92
>[!NOTE]
91
93
>- Data consistency is not supported in staging copy scenario.
92
-
>- When copying binary files to Azure Blob Storage or Azure Data Lake Storage Gen2, copy activity does both file size and MD5 checksum verification to ensure the data consistency between source and destination stores. For copying binary files to other storage stores, copy activity does file size verification to ensure the data consistency between source and destination store.
94
+
>- When copying binary files from any storage store to Azure Blob Storage or Azure Data Lake Storage Gen2, copy activity does file size and MD5 checksum verification to ensure the data consistency between source and destination stores.
95
+
>- When copying binary files from any storage store to other storage stores except Azure Blob Storage or Azure Data Lake Storage Gen2, copy activity does file size verification to ensure the data consistency between source and destination store.
93
96
94
97
95
-
## Monitor data consistency verification
98
+
## Monitoring
96
99
97
-
### Activity output
98
-
After the copy activity run completes, you can get the result of data consistency verification from the output of each copy activity run:
100
+
### Output from copy activity
101
+
After the copy activity run completely, you can see the result of data consistency verification from the output of each copy activity run:
99
102
100
103
```json
101
104
"output": {
@@ -114,37 +117,38 @@ After the copy activity run completes, you can get the result of data consistenc
114
117
}
115
118
116
119
```
120
+
You can see the details of data consistency verification from "dataConsistencyVerification property".
117
121
118
-
Value for**VerificationResult**:
122
+
Value of**VerificationResult**:
119
123
-**Verified**: Your copied data has been verified to be consistent between source and destination store.
120
-
-**NotVerified**: Your copied data has not been verified to be consistent because you have not enabled the validateDataConsistency setting.
121
-
-**Unsupported**: Your copied data has not been verified to be consistent because data consistency verification is not supported for this copy pairs.
124
+
-**NotVerified**: Your copied data has not been verified to be consistent because you have not enabled the validateDataConsistency in copy activity.
125
+
-**Unsupported**: Your copied data has not been verified to be consistent because data consistency verification is not supported for this copy pair.
122
126
123
-
Value for**InconsistentData**:
124
-
-**Found**: ADF copy activity has found Inconsistent data.
125
-
-**Skipped**: ADF copy activity has found and skipped Inconsistent data.
126
-
-**None**: ADF copy activity has not found any inconsistent data because either you disabled validateDataConsistency setting or your data has been verified to be consistent between source and destination store.
127
+
Value of**InconsistentData**:
128
+
-**Found**: ADF copy activity has found inconsistent data.
129
+
-**Skipped**: ADF copy activity has found and skipped inconsistent data.
130
+
-**None**: ADF copy activity has not found any inconsistent data because either you disabled validateDataConsistency in copy activity or your data has been verified to be consistent between source and destination store.
127
131
128
-
### Activity session log
132
+
### Session log from copy activity
129
133
130
-
If you configure to log the inconsistent file, you can find the log file at this path: `https://[your-blob-account].blob.core.windows.net/[path-if-configured]/copyactivity-logs/[copy-activity-name]/[copy-activity-run-id]/[auto-generated-GUID].csv`. The log files can only be the csv files.
134
+
If you configure to log the inconsistent file, you can find the log file at this path: `https://[your-blob-account].blob.core.windows.net/[path-if-configured]/copyactivity-logs/[copy-activity-name]/[copy-activity-run-id]/[auto-generated-GUID].csv`. The log files will be the csv files.
131
135
132
-
The schema of the log file is as following:
136
+
The schema of a log file is as following:
133
137
134
138
Column | Description
135
139
-------- | -----------
136
-
Timestamp | The timestamp when ADF skips the inconsistent data
137
-
Level | The level of log information for this item. It will be in 'Warning' level if this item shows the skipped file names.
138
-
OperationName | The type of ADF copy activity operation against data. It will be 'FileSkip' to specify that particular file has been skipped
139
-
OperationItem | The skipped file names from the source data store
140
-
Message | More information to illustrate what kinds of the inconsistency being skipped
140
+
Timestamp | The timestamp when ADF skips the inconsistent data.
141
+
Level | The log level for this item. It can be the 'Warning' for file skipping operational log.
142
+
OperationName | ADF copy activity operational behavior on each object. It can be 'FileSkip' or 'TabularRowSkip' to specify the file or row to be skipped.
143
+
OperationItem | The object names to be skipped.
144
+
Message | More information to illustrate why files being skipped.
2020-02-26 06:22:56.3190846, Warning, FileSkip, "sample1.csv", "File is skipped after read 548000000 bytes: ErrorCode=DataConsistencySourceDataChanged,'Type=Microsoft.DataTransfer.Common.Shared.HybridDeliveryException,Message=Source file 'sample1.csv' is changed by other clients during the copy activity run.,Source=,'."
146
150
```
147
-
From the sample log, you can see sample1.csv has been skipped due to it is inconsistent between source and destination store. You can also get more details that the reason why sample1.csv becomes inconsistent is because it was changed by other clients during the copy activity run.
151
+
From the log file above, you can see sample1.csv has been skipped because it failed to be verified to be consistent between source and destination store. You can get more details about why sample1.csv becomes inconsistent is because it was under changing by other applications when ADF copy activity is copying at the same time.
0 commit comments