Skip to content

feat: HBase resolvable endpoints #1159

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 25 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 17 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
0fbe36b
patches I
adwk67 Apr 10, 2025
b5f96d5
patches I
adwk67 Apr 10, 2025
303739e
wip: patch hbase to use listener endpoints
adwk67 Apr 23, 2025
8dc1c99
changed rendering
adwk67 Apr 23, 2025
bd17a9e
rework patch for UI
adwk67 May 15, 2025
4a5df3b
Merge branch 'main' into feat/hbase-resolvable-endpoints
nightkr May 30, 2025
2a2a5ac
Consistently override the advertised ports
nightkr May 31, 2025
9ef046c
add listener endpoint and info port to hbase-site.xml
adwk67 Jun 10, 2025
99fd166
patch and entrypoint refactoring
adwk67 Jun 13, 2025
9953042
hbase: use listener service for region mover
adwk67 Jun 16, 2025
9b02ec8
Merge branch 'main' into feat/hbase-resolvable-endpoints
adwk67 Jun 16, 2025
4b6b849
hbase: patch for 2.6.2 endpoints
adwk67 Jun 16, 2025
be89d58
Merge branch 'main' into feat/hbase-resolvable-endpoints
adwk67 Jun 16, 2025
ceba85b
removed dead variable
adwk67 Jun 16, 2025
f08e1c5
Update hbase/stackable/patches/2.6.1/0005-Allow-overriding-ipc-bind-p…
adwk67 Jun 24, 2025
d98ac32
Update hbase/stackable/patches/2.6.1/0005-Allow-overriding-ipc-bind-p…
adwk67 Jun 24, 2025
bd0b75e
review comments: added constants etc.
adwk67 Jun 25, 2025
a6a7e10
merge main and fix conflicts
adwk67 Jun 25, 2025
de0c6c7
set RPC_CLIENT_SPECIFY_HOST to true by default
adwk67 Jun 25, 2025
496444d
corrected constant descriptions
adwk67 Jun 25, 2025
3fa6301
updated 2.6.2 patch
adwk67 Jun 25, 2025
ee7ea2e
patch 2.6.1 to reverse bound/advertised properties
adwk67 Jun 26, 2025
7a4340e
property re-working for 2.6.2
adwk67 Jun 27, 2025
f3d3596
Merge branch 'main' into feat/hbase-resolvable-endpoints
adwk67 Jun 27, 2025
65aaae2
provide advertised port as a fallback, removed changes to test class
adwk67 Jun 27, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ All notable changes to this project will be documented in this file.
`check-permissions-ownership.sh` provided in stackable-base image ([#1029]).
- hbase: check for correct permissions and ownerships in /stackable folder via
`check-permissions-ownership.sh` provided in stackable-base image ([#1028]).
- hbase: provide patches to implement listener endpoints ([#1159]).
- hive: check for correct permissions and ownerships in /stackable folder via
`check-permissions-ownership.sh` provided in stackable-base image ([#1040]).
- spark-connect-client: A new image for Spark connect tests and demos ([#1034])
Expand Down Expand Up @@ -184,6 +185,7 @@ All notable changes to this project will be documented in this file.
[#1151]: https://github.com/stackabletech/docker-images/pull/1151
[#1152]: https://github.com/stackabletech/docker-images/pull/1152
[#1156]: https://github.com/stackabletech/docker-images/pull/1156
[#1159]: https://github.com/stackabletech/docker-images/pull/1159
[#1163]: https://github.com/stackabletech/docker-images/pull/1163
[#1165]: https://github.com/stackabletech/docker-images/pull/1165

Expand Down
25 changes: 19 additions & 6 deletions hbase/stackable/bin/hbase-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,17 @@ set -euo pipefail

# master, regionserver, rest
HBASE_ROLE_NAME="$1"
# k8s service name for this role+group combo
# <svc-name>.<namespace>.svc.cluster.local
HBASE_ROLE_SERVICE_NAME="$2"
# 16010 for master, 16020 for regionservers etc.
HBASE_ROLE_SERVICE_PORT="$3"
HBASE_ROLE_SERVICE_PORT="$2"
# master, regionserver, rest_http, rest_https
HBASE_PORT_NAME="$3"
# ui-http or ui-https
HBASE_UI_PORT_NAME="$4"

HBASE_ROLE_SERVICE_HOST="${HOSTNAME}.${HBASE_ROLE_SERVICE_NAME}"
# Needed for regionmover service and for hbase-site.xml (see below)
HBASE_SERVICE_HOST=$(cat /stackable/listener/default-address/address)

REGION_MOVER_OPTS="--regionserverhost ${HBASE_ROLE_SERVICE_HOST}:${HBASE_ROLE_SERVICE_PORT} --operation unload ${REGION_MOVER_OPTS}"
REGION_MOVER_OPTS="--regionserverhost ${HBASE_SERVICE_HOST}:${HBASE_ROLE_SERVICE_PORT} --operation unload ${REGION_MOVER_OPTS}"

prepare_signal_handlers() {
unset term_child_pid
Expand Down Expand Up @@ -64,6 +66,7 @@ cp /stackable/tmp/hdfs/core-site.xml /stackable/conf
cp /stackable/tmp/hbase/* /stackable/conf
cp /stackable/tmp/log_config/log4j* /stackable/conf

# Kerberos
if [ -f /stackable/kerberos/krb5.conf ]; then
KERBEROS_REALM=$(grep -oP 'default_realm = \K.*' /stackable/kerberos/krb5.conf)
export KERBEROS_REALM
Expand All @@ -72,6 +75,16 @@ if [ -f /stackable/kerberos/krb5.conf ]; then
sed -i -e s/\$\{env\.KERBEROS_REALM\}/"${KERBEROS_REALM}"/g /stackable/conf/hdfs-site.xml
fi

# Service endpoints
HBASE_SERVICE_PORT=$(cat /stackable/listener/default-address/ports/"${HBASE_PORT_NAME}")
HBASE_INFO_PORT=$(cat /stackable/listener/default-address/ports/"${HBASE_UI_PORT_NAME}")
HBASE_LISTENER_ENDPOINT="$HBASE_SERVICE_HOST:$HBASE_INFO_PORT"

sed -i -e s/\$\{HBASE_SERVICE_HOST\}/"${HBASE_SERVICE_HOST}"/g /stackable/conf/hbase-site.xml
sed -i -e s/\$\{HBASE_SERVICE_PORT\}/"${HBASE_SERVICE_PORT}"/g /stackable/conf/hbase-site.xml
sed -i -e s/\$\{HBASE_LISTENER_ENDPOINT\}/"${HBASE_LISTENER_ENDPOINT}"/g /stackable/conf/hbase-site.xml
sed -i -e s/\$\{HBASE_INFO_PORT\}/"${HBASE_INFO_PORT}"/g /stackable/conf/hbase-site.xml

rm -f "${STACKABLE_LOG_DIR}/_vector/shutdown"
prepare_signal_handlers
/stackable/containerdebug --output="${STACKABLE_LOG_DIR}/containerdebug-state.json" --loop &
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,296 @@
From 7014c24f4441278dd366c888fc0c05ce53fe9c06 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Natalie=20Klestrup=20R=C3=B6ijezon?= <nat@nullable.se>
Date: Fri, 30 May 2025 14:26:26 +0200
Subject: Allow overriding ipc bind port and use alternative port from listener

---
.../org/apache/hadoop/hbase/HConstants.java | 21 ++++++++++
.../apache/hadoop/hbase/master/HMaster.java | 20 +++++++--
.../hbase/regionserver/HRegionServer.java | 41 +++++++++++++++----
.../hbase/regionserver/RSRpcServices.java | 8 +++-
4 files changed, 76 insertions(+), 14 deletions(-)

diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java
index 3b2a58827f..1ba1feefcb 100644
--- a/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java
+++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java
@@ -197,6 +197,12 @@ public final class HConstants {
/** Parameter name for port master listens on. */
public static final String MASTER_PORT = "hbase.master.port";

+ /** Parameter name for master IPC address */
+ public static final String MASTER_IPC_ADDRESS = "hbase.master.ipc.address";
+
+ /** Parameter name for master IPC port */
+ public static final String MASTER_IPC_PORT = "hbase.master.ipc.port";
+
/** default port that the master listens on */
public static final int DEFAULT_MASTER_PORT = 16000;

@@ -206,6 +212,9 @@ public final class HConstants {
/** Configuration key for master web API port */
public static final String MASTER_INFO_PORT = "hbase.master.info.port";

+ /** Configuration key for bound master web API port */
+ public static final String MASTER_BOUND_INFO_PORT = "hbase.master.bound.info.port";
+
/** Configuration key for the list of master host:ports **/
public static final String MASTER_ADDRS_KEY = "hbase.masters";

@@ -316,6 +325,12 @@ public final class HConstants {
/** Parameter name for port region server listens on. */
public static final String REGIONSERVER_PORT = "hbase.regionserver.port";

+ /** Parameter name for master IPC address */
+ public static final String REGIONSERVER_IPC_ADDRESS = "hbase.regionserver.ipc.address";
+
+ /** Parameter name for master IPC port */
+ public static final String REGIONSERVER_IPC_PORT = "hbase.regionserver.ipc.port";
+
/** Default port region server listens on. */
public static final int DEFAULT_REGIONSERVER_PORT = 16020;

@@ -325,6 +340,9 @@ public final class HConstants {
/** A configuration key for regionserver info port */
public static final String REGIONSERVER_INFO_PORT = "hbase.regionserver.info.port";

+ /** A configuration key for bound regionserver hbase info port */
+ public static final String REGIONSERVER_BOUND_INFO_PORT = "hbase.regionserver.bound.info.port";
+
/** A flag that enables automatic selection of regionserver info port */
public static final String REGIONSERVER_INFO_PORT_AUTO = REGIONSERVER_INFO_PORT + ".auto";

@@ -1392,6 +1410,9 @@ public final class HConstants {
/** Configuration key for setting RPC codec class name */
public static final String RPC_CODEC_CONF_KEY = "hbase.client.rpc.codec";

+ /** Configuration key for setting that the RPC client should specify the host */
+ public static final String RPC_CLIENT_SPECIFY_HOST = "hbase.rpc.client.specify.host";
+
/** Configuration key for setting replication codec class name */
public static final String REPLICATION_CODEC_CONF_KEY = "hbase.replication.rpc.codec";

diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
index 3fe5abac27..2f323518da 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
@@ -20,6 +20,8 @@ package org.apache.hadoop.hbase.master;
import static org.apache.hadoop.hbase.HConstants.DEFAULT_HBASE_SPLIT_COORDINATED_BY_ZK;
import static org.apache.hadoop.hbase.HConstants.HBASE_MASTER_LOGCLEANER_PLUGINS;
import static org.apache.hadoop.hbase.HConstants.HBASE_SPLIT_WAL_COORDINATED_BY_ZK;
+import static org.apache.hadoop.hbase.HConstants.MASTER_BOUND_INFO_PORT;
+import static org.apache.hadoop.hbase.HConstants.MASTER_PORT;
import static org.apache.hadoop.hbase.master.cleaner.HFileCleaner.CUSTOM_POOL_SIZE;
import static org.apache.hadoop.hbase.util.DNS.MASTER_HOSTNAME_KEY;

@@ -559,6 +561,18 @@ public class HMaster extends HRegionServer implements MasterServices {
return conf.get(MASTER_HOSTNAME_KEY);
}

+ @Override
+ protected int getUseThisPortInstead(Configuration conf) {
+ int port = conf.getInt(MASTER_PORT, 0);
+ return port != 0 ? port : this.rpcServices.getSocketAddress().getPort();
+ }
+
+ @Override
+ protected int getUseThisInfoPortInstead(Configuration conf) {
+ int port = conf.getInt(MASTER_BOUND_INFO_PORT, 0);
+ return port != 0 ? port : this.infoServer != null ? this.infoServer.getPort() : -1;
+ }
+
private void registerConfigurationObservers() {
configurationManager.registerObserver(this.rpcServices);
configurationManager.registerObserver(this);
@@ -586,8 +600,8 @@ public class HMaster extends HRegionServer implements MasterServices {
registerConfigurationObservers();
Threads.setDaemonThreadRunning(new Thread(() -> TraceUtil.trace(() -> {
try {
- int infoPort = putUpJettyServer();
- startActiveMasterManager(infoPort);
+ putUpJettyServer();
+ startActiveMasterManager(useThisInfoPortInstead);
} catch (Throwable t) {
// Make sure we log the exception.
String error = "Failed to become Active Master";
@@ -2991,7 +3005,7 @@ public class HMaster extends HRegionServer implements MasterServices {
}
case MASTER_INFO_PORT: {
if (infoServer != null) {
- builder.setMasterInfoPort(infoServer.getPort());
+ builder.setMasterInfoPort(useThisInfoPortInstead);
}
break;
}
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
index 27bcef2f06..ff8b3b05f6 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
@@ -24,6 +24,9 @@ import static org.apache.hadoop.hbase.HConstants.DEFAULT_HBASE_SPLIT_WAL_MAX_SPL
import static org.apache.hadoop.hbase.HConstants.DEFAULT_SLOW_LOG_SYS_TABLE_CHORE_DURATION;
import static org.apache.hadoop.hbase.HConstants.HBASE_SPLIT_WAL_COORDINATED_BY_ZK;
import static org.apache.hadoop.hbase.HConstants.HBASE_SPLIT_WAL_MAX_SPLITTER;
+import static org.apache.hadoop.hbase.HConstants.REGIONSERVER_BOUND_INFO_PORT;
+import static org.apache.hadoop.hbase.HConstants.REGIONSERVER_PORT;
+import static org.apache.hadoop.hbase.HConstants.RPC_CLIENT_SPECIFY_HOST;
import static org.apache.hadoop.hbase.master.waleventtracker.WALEventTrackerTableCreator.WAL_EVENT_TRACKER_ENABLED_DEFAULT;
import static org.apache.hadoop.hbase.master.waleventtracker.WALEventTrackerTableCreator.WAL_EVENT_TRACKER_ENABLED_KEY;
import static org.apache.hadoop.hbase.namequeues.NamedQueueServiceChore.NAMED_QUEUE_CHORE_DURATION_DEFAULT;
@@ -505,6 +508,10 @@ public class HRegionServer extends Thread
*/
protected String useThisHostnameInstead;

+ protected int useThisPortInstead;
+
+ protected int useThisInfoPortInstead;
+
/**
* @deprecated since 2.4.0 and will be removed in 4.0.0. Use
* {@link HRegionServer#UNSAFE_RS_HOSTNAME_DISABLE_MASTER_REVERSEDNS_KEY} instead.
@@ -669,6 +676,8 @@ public class HRegionServer extends Thread
this.namedQueueRecorder = NamedQueueRecorder.getInstance(this.conf);
rpcServices = createRpcServices();
useThisHostnameInstead = getUseThisHostnameInstead(conf);
+ useThisPortInstead = getUseThisPortInstead(conf);
+ useThisInfoPortInstead = getUseThisInfoPortInstead(conf); //conf.getInt("hbase.info.port" , this.infoServer != null ? this.infoServer.getPort() : -1);

// if use-ip is enabled, we will use ip to expose Master/RS service for client,
// see HBASE-27304 for details.
@@ -678,7 +687,7 @@ public class HRegionServer extends Thread
useIp ? rpcServices.isa.getAddress().getHostAddress() : rpcServices.isa.getHostName();
String hostName =
StringUtils.isBlank(useThisHostnameInstead) ? isaHostName : useThisHostnameInstead;
- serverName = ServerName.valueOf(hostName, this.rpcServices.isa.getPort(), this.startcode);
+ serverName = ServerName.valueOf(hostName, useThisPortInstead, this.startcode);

rpcControllerFactory = RpcControllerFactory.instantiate(this.conf);
rpcRetryingCallerFactory = RpcRetryingCallerFactory.instantiate(this.conf,
@@ -715,7 +724,7 @@ public class HRegionServer extends Thread

// Some unit tests don't need a cluster, so no zookeeper at all
// Open connection to zookeeper and set primary watcher
- zooKeeper = new ZKWatcher(conf, getProcessName() + ":" + rpcServices.isa.getPort(), this,
+ zooKeeper = new ZKWatcher(conf, getProcessName() + ":" + useThisPortInstead, this,
canCreateBaseZNode());
// If no master in cluster, skip trying to track one or look for a cluster status.
if (!this.masterless) {
@@ -776,6 +785,16 @@ public class HRegionServer extends Thread
}
}

+ protected int getUseThisPortInstead(Configuration conf) {
+ int port = conf.getInt(REGIONSERVER_PORT, 0);
+ return port != 0 ? port : this.rpcServices.isa.getPort();
+ }
+
+ protected int getUseThisInfoPortInstead(Configuration conf) {
+ int port = conf.getInt(REGIONSERVER_BOUND_INFO_PORT, 0);
+ return port != 0 ? port : this.infoServer != null ? this.infoServer.getPort() : -1;
+ }
+
private void setupSignalHandlers() {
if (!SystemUtils.IS_OS_WINDOWS) {
HBasePlatformDependent.handle("HUP", (number, name) -> {
@@ -957,8 +976,7 @@ public class HRegionServer extends Thread
bootstrapNodeManager = new BootstrapNodeManager(clusterConnection, masterAddressTracker);
}
// Setup RPC client for master communication
- this.rpcClient = RpcClientFactory.createClient(conf, clusterId,
- new InetSocketAddress(this.rpcServices.isa.getAddress(), 0),
+ this.rpcClient = RpcClientFactory.createClient(conf, clusterId, getInetSocketAddress(this.conf),
clusterConnection.getConnectionMetrics(), Collections.emptyMap());
span.setStatus(StatusCode.OK);
} catch (Throwable t) {
@@ -972,6 +990,11 @@ public class HRegionServer extends Thread
}
}

+ private InetSocketAddress getInetSocketAddress(Configuration conf) {
+ return conf.getBoolean(RPC_CLIENT_SPECIFY_HOST, false) ?
+ new InetSocketAddress(this.rpcServices.isa.getAddress(), 0) : new InetSocketAddress(0);
+ }
+
/**
* Bring up connection to zk ensemble and then wait until a master for this cluster and then after
* that, wait until cluster 'up' flag has been set. This is the order in which master does things.
@@ -1533,6 +1556,7 @@ public class HRegionServer extends Thread
} else {
serverLoad.setInfoServerPort(-1);
}
+ serverLoad.setInfoServerPort(useThisInfoPortInstead);
MetricsUserAggregateSource userSource =
metricsRegionServer.getMetricsUserAggregate().getSource();
if (userSource != null) {
@@ -1688,7 +1712,7 @@ public class HRegionServer extends Thread
if (key.equals(HConstants.KEY_FOR_HOSTNAME_SEEN_BY_MASTER)) {
String hostnameFromMasterPOV = e.getValue();
this.serverName = ServerName.valueOf(hostnameFromMasterPOV,
- rpcServices.getSocketAddress().getPort(), this.startcode);
+ useThisPortInstead, this.startcode);
String expectedHostName = rpcServices.getSocketAddress().getHostName();
// if Master use-ip is enabled, RegionServer use-ip will be enabled by default even if it
// is set to disable. so we will use the ip of the RegionServer to compare with the
@@ -1814,7 +1838,7 @@ public class HRegionServer extends Thread

private void createMyEphemeralNode() throws KeeperException {
RegionServerInfo.Builder rsInfo = RegionServerInfo.newBuilder();
- rsInfo.setInfoPort(infoServer != null ? infoServer.getPort() : -1);
+ rsInfo.setInfoPort(infoServer != null ? useThisInfoPortInstead : -1);
rsInfo.setVersionInfo(ProtobufUtil.getVersionInfo());
byte[] data = ProtobufUtil.prependPBMagic(rsInfo.build().toByteArray());
ZKUtil.createEphemeralNodeAndWatch(this.zooKeeper, getMyEphemeralNodePath(), data);
@@ -2479,7 +2503,7 @@ public class HRegionServer extends Thread
LOG.info("Retry starting http info server with port: " + port);
}
}
- port = this.infoServer.getPort();
+ port = useThisInfoPortInstead;
conf.setInt(HConstants.REGIONSERVER_INFO_PORT, port);
int masterInfoPort =
conf.getInt(HConstants.MASTER_INFO_PORT, HConstants.DEFAULT_MASTER_INFOPORT);
@@ -3073,12 +3097,11 @@ public class HRegionServer extends Thread
LOG.info("reportForDuty to master=" + masterServerName + " with isa=" + rpcServices.isa
+ ", startcode=" + this.startcode);
long now = EnvironmentEdgeManager.currentTime();
- int port = rpcServices.isa.getPort();
RegionServerStartupRequest.Builder request = RegionServerStartupRequest.newBuilder();
if (!StringUtils.isBlank(useThisHostnameInstead)) {
request.setUseThisHostnameInstead(useThisHostnameInstead);
}
- request.setPort(port);
+ request.setPort(useThisPortInstead);
request.setServerStartCode(this.startcode);
request.setServerCurrentTime(now);
result = rss.regionServerStartup(null, request.build());
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java
index b77fcf338a..a86cd273ff 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java
@@ -280,6 +280,10 @@ import org.apache.hadoop.hbase.shaded.protobuf.generated.WALProtos.BulkLoadDescr
import org.apache.hadoop.hbase.shaded.protobuf.generated.WALProtos.CompactionDescriptor;
import org.apache.hadoop.hbase.shaded.protobuf.generated.WALProtos.FlushDescriptor;
import org.apache.hadoop.hbase.shaded.protobuf.generated.WALProtos.RegionEventDescriptor;
+import static org.apache.hadoop.hbase.HConstants.MASTER_IPC_ADDRESS;
+import static org.apache.hadoop.hbase.HConstants.MASTER_IPC_PORT;
+import static org.apache.hadoop.hbase.HConstants.REGIONSERVER_IPC_ADDRESS;
+import static org.apache.hadoop.hbase.HConstants.REGIONSERVER_IPC_PORT;

/**
* Implements the regionserver RPC services.
@@ -1270,14 +1274,14 @@ public class RSRpcServices implements HBaseRPCErrorHandler, AdminService.Blockin
int port = conf.getInt(HConstants.MASTER_PORT, HConstants.DEFAULT_MASTER_PORT);
// Creation of a HSA will force a resolve.
initialIsa = new InetSocketAddress(hostname, port);
- bindAddress = new InetSocketAddress(conf.get("hbase.master.ipc.address", hostname), port);
+ bindAddress = new InetSocketAddress(conf.get(MASTER_IPC_ADDRESS, hostname), conf.getInt(MASTER_IPC_PORT, port));
} else {
String hostname = DNS.getHostname(conf, DNS.ServerType.REGIONSERVER);
int port = conf.getInt(HConstants.REGIONSERVER_PORT, HConstants.DEFAULT_REGIONSERVER_PORT);
// Creation of a HSA will force a resolve.
initialIsa = new InetSocketAddress(hostname, port);
bindAddress =
- new InetSocketAddress(conf.get("hbase.regionserver.ipc.address", hostname), port);
+ new InetSocketAddress(conf.get(REGIONSERVER_IPC_ADDRESS, hostname), conf.getInt(REGIONSERVER_IPC_PORT, port));
}
if (initialIsa.getAddress() == null) {
throw new IllegalArgumentException("Failed resolve of " + initialIsa);
Loading