Skip to content

Commit 943cbc0

Browse files
committed
HBASE-29686 Compatible issue of HFileOutputFormat2#configureRemoteCluster
1 parent a79100b commit 943cbc0

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/HFileOutputFormat2.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -777,7 +777,7 @@ public static void configureIncrementalLoadMap(Job job, TableDescriptor tableDes
777777
* @see #REMOTE_CLUSTER_ZOOKEEPER_CLIENT_PORT_CONF_KEY
778778
* @see #REMOTE_CLUSTER_ZOOKEEPER_ZNODE_PARENT_CONF_KEY
779779
*/
780-
public static void configureRemoteCluster(Job job, Configuration clusterConf) throws IOException {
780+
public static void configureRemoteCluster(Job job, Configuration clusterConf) {
781781
Configuration conf = job.getConfiguration();
782782

783783
if (!conf.getBoolean(LOCALITY_SENSITIVE_CONF_KEY, DEFAULT_LOCALITY_SENSITIVE)) {
@@ -794,7 +794,11 @@ public static void configureRemoteCluster(Job job, Configuration clusterConf) th
794794
conf.setInt(REMOTE_CLUSTER_ZOOKEEPER_CLIENT_PORT_CONF_KEY, clientPort);
795795
conf.set(REMOTE_CLUSTER_ZOOKEEPER_ZNODE_PARENT_CONF_KEY, parent);
796796

797-
TableMapReduceUtil.initCredentialsForCluster(job, clusterConf);
797+
try {
798+
TableMapReduceUtil.initCredentialsForCluster(job, clusterConf);
799+
} catch (IOException e) {
800+
throw new RuntimeException(e);
801+
}
798802

799803
LOG.info("ZK configs for remote cluster of bulkload is configured: " + quorum + ":" + clientPort
800804
+ "/" + parent);

0 commit comments

Comments
 (0)