You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2011/04/26 01:15:07 UTC
svn commit: r1096631 - in /hbase/branches/0.90: CHANGES.txt
src/main/java/org/apache/hadoop/hbase/master/HMaster.java
Author: stack
Date: Mon Apr 25 23:15:07 2011
New Revision: 1096631
URL: http://svn.apache.org/viewvc?rev=1096631&view=rev
Log:
HBASE-3729 Master can't exit when open port failed
Modified:
hbase/branches/0.90/CHANGES.txt
hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
Modified: hbase/branches/0.90/CHANGES.txt
URL: http://svn.apache.org/viewvc/hbase/branches/0.90/CHANGES.txt?rev=1096631&r1=1096630&r2=1096631&view=diff
==============================================================================
--- hbase/branches/0.90/CHANGES.txt (original)
+++ hbase/branches/0.90/CHANGES.txt Mon Apr 25 23:15:07 2011
@@ -33,6 +33,7 @@ Release 0.90.3 - Unreleased
HBASE-2470 Add Scan.setTimeRange() support in Shell (Harsh J Chouraria)
HBASE-3634 Fix JavaDoc for put(List<Put> puts) in HTableInterface
(Harsh J Chouraria)
+ HBASE-3749 Master can't exit when open port failed (gaojinchao)
IMPROVEMENT
HBASE-3717 deprecate HTable isTableEnabled() methods in favor of HBaseAdmin
Modified: hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/master/HMaster.java?rev=1096631&r1=1096630&r2=1096631&view=diff
==============================================================================
--- hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/master/HMaster.java (original)
+++ hbase/branches/0.90/src/main/java/org/apache/hadoop/hbase/master/HMaster.java Mon Apr 25 23:15:07 2011
@@ -515,50 +515,46 @@ implements HMasterInterface, HMasterRegi
* as OOMEs; it should be lightly loaded. See what HRegionServer does if
* need to install an unexpected exception handler.
*/
- private void startServiceThreads() {
- try {
- // Start the executor service pools
- this.executorService.startExecutorService(ExecutorType.MASTER_OPEN_REGION,
- conf.getInt("hbase.master.executor.openregion.threads", 5));
- this.executorService.startExecutorService(ExecutorType.MASTER_CLOSE_REGION,
- conf.getInt("hbase.master.executor.closeregion.threads", 5));
- this.executorService.startExecutorService(ExecutorType.MASTER_SERVER_OPERATIONS,
- conf.getInt("hbase.master.executor.serverops.threads", 3));
- this.executorService.startExecutorService(ExecutorType.MASTER_META_SERVER_OPERATIONS,
- conf.getInt("hbase.master.executor.serverops.threads", 5));
- // We depend on there being only one instance of this executor running
- // at a time. To do concurrency, would need fencing of enable/disable of
- // tables.
- this.executorService.startExecutorService(ExecutorType.MASTER_TABLE_OPERATIONS, 1);
-
- // Start log cleaner thread
- String n = Thread.currentThread().getName();
- this.logCleaner =
- new LogCleaner(conf.getInt("hbase.master.cleaner.interval", 60 * 1000),
- this, conf, getMasterFileSystem().getFileSystem(),
- getMasterFileSystem().getOldLogDir());
- Threads.setDaemonThreadRunning(logCleaner, n + ".oldLogCleaner");
-
- // Put up info server.
- int port = this.conf.getInt("hbase.master.info.port", 60010);
- if (port >= 0) {
- String a = this.conf.get("hbase.master.info.bindAddress", "0.0.0.0");
- this.infoServer = new InfoServer(MASTER, a, port, false);
- this.infoServer.setAttribute(MASTER, this);
- this.infoServer.start();
- }
- // Start allowing requests to happen.
- this.rpcServer.openServer();
- if (LOG.isDebugEnabled()) {
- LOG.debug("Started service threads");
- }
- } catch (IOException e) {
- if (e instanceof RemoteException) {
- e = ((RemoteException)e).unwrapRemoteException();
- }
- // Something happened during startup. Shut things down.
- abort("Failed startup", e);
+ private void startServiceThreads() throws IOException{
+
+ // Start the executor service pools
+ this.executorService.startExecutorService(ExecutorType.MASTER_OPEN_REGION,
+ conf.getInt("hbase.master.executor.openregion.threads", 5));
+ this.executorService.startExecutorService(ExecutorType.MASTER_CLOSE_REGION,
+ conf.getInt("hbase.master.executor.closeregion.threads", 5));
+ this.executorService.startExecutorService(ExecutorType.MASTER_SERVER_OPERATIONS,
+ conf.getInt("hbase.master.executor.serverops.threads", 3));
+ this.executorService.startExecutorService(ExecutorType.MASTER_META_SERVER_OPERATIONS,
+ conf.getInt("hbase.master.executor.serverops.threads", 5));
+
+ // We depend on there being only one instance of this executor running
+ // at a time. To do concurrency, would need fencing of enable/disable of
+ // tables.
+ this.executorService.startExecutorService(ExecutorType.MASTER_TABLE_OPERATIONS, 1);
+
+ // Start log cleaner thread
+ String n = Thread.currentThread().getName();
+ this.logCleaner =
+ new LogCleaner(conf.getInt("hbase.master.cleaner.interval", 60 * 1000),
+ this, conf, getMasterFileSystem().getFileSystem(),
+ getMasterFileSystem().getOldLogDir());
+ Threads.setDaemonThreadRunning(logCleaner, n + ".oldLogCleaner");
+
+ // Put up info server.
+ int port = this.conf.getInt("hbase.master.info.port", 60010);
+ if (port >= 0) {
+ String a = this.conf.get("hbase.master.info.bindAddress", "0.0.0.0");
+ this.infoServer = new InfoServer(MASTER, a, port, false);
+ this.infoServer.setAttribute(MASTER, this);
+ this.infoServer.start();
+ }
+
+ // Start allowing requests to happen.
+ this.rpcServer.openServer();
+ if (LOG.isDebugEnabled()) {
+ LOG.debug("Started service threads");
}
+
}
private void stopServiceThreads() {