in src/main/java/com/google/cloud/solutions/autotokenize/dlp/DlpIdentify.java [166:184]
public void inspectTable(
@Element KV<ShardedKey<String>, Table> dlpTableForIdentify, ProcessContext processContext) {
var columnName = dlpTableForIdentify.getKey().getKey();
var dlpTable = dlpTableForIdentify.getValue();
try {
dlpBatchInspect
.identifyInfoTypes(KV.of(dlpTable, ImmutableMap.of(columnName, columnName)))
.forEach(processContext::output);
} catch (RuntimeException exception) {
logger.atSevere().withCause(exception).log(
"Error processing batch: key: %s, bytes: %s, elementCount: %s",
columnName, dlpTable.getSerializedSize(), dlpTable.getRowsCount());
if (errorTag() != null) {
processContext.output(errorTag(), dlpTableForIdentify);
}
}
}