[MINOR] Pass root exception to HoodieKeyGeneratorException for more information (#2354)
Co-authored-by: Xi Chen <chenxi07@qiyi.com>
This commit is contained in:
@@ -88,7 +88,7 @@ public class CustomAvroKeyGenerator extends BaseKeyGenerator {
|
|||||||
try {
|
try {
|
||||||
partitionPath.append(new TimestampBasedAvroKeyGenerator(config, partitionPathField).getPartitionPath(record));
|
partitionPath.append(new TimestampBasedAvroKeyGenerator(config, partitionPathField).getPartitionPath(record));
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
throw new HoodieKeyGeneratorException("Unable to initialise TimestampBasedKeyGenerator class");
|
throw new HoodieKeyGeneratorException("Unable to initialise TimestampBasedKeyGenerator class", e);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
|||||||
@@ -113,7 +113,7 @@ public class CustomKeyGenerator extends BuiltinKeyGenerator {
|
|||||||
partitionPath.append(new TimestampBasedKeyGenerator(config, partitionPathField).getPartitionPath(row.get()));
|
partitionPath.append(new TimestampBasedKeyGenerator(config, partitionPathField).getPartitionPath(row.get()));
|
||||||
}
|
}
|
||||||
} catch (IOException ioe) {
|
} catch (IOException ioe) {
|
||||||
throw new HoodieKeyGeneratorException("Unable to initialise TimestampBasedKeyGenerator class");
|
throw new HoodieKeyGeneratorException("Unable to initialise TimestampBasedKeyGenerator class", ioe);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
|||||||
Reference in New Issue
Block a user