HBASE-3408 AssignmentManager NullPointerException

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1055248 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael Stack 2011-01-05 00:01:56 +00:00
parent 46a56a74db
commit 8620d2c697
2 changed files with 5 additions and 3 deletions

View File

@ -812,6 +812,7 @@ Release 0.90.0 - Unreleased
HBASE-3383 [0.90RC1] bin/hbase script displays "no such file" warning on
target/cached_classpath.txt
HBASE-3344 Master aborts after RPC to server that was shutting down
HBASE-3408 AssignmentManager NullPointerException
IMPROVEMENTS

View File

@ -21,8 +21,8 @@ package org.apache.hadoop.hbase.master;
import java.io.DataInput;
import java.io.DataOutput;
import java.io.IOException;
import java.io.EOFException;
import java.io.IOException;
import java.net.ConnectException;
import java.util.ArrayList;
import java.util.HashMap;
@ -1005,8 +1005,9 @@ public class AssignmentManager extends ZooKeeperListener {
RegionPlan existingPlan = null;
synchronized (this.regionPlans) {
existingPlan = this.regionPlans.get(encodedName);
if (existingPlan == null || forceNewPlan ||
(existingPlan != null && existingPlan.getDestination().equals(serverToExclude))) {
if (forceNewPlan || existingPlan == null
|| existingPlan.getDestination() == null
|| existingPlan.getDestination().equals(serverToExclude)) {
newPlan = true;
this.regionPlans.put(encodedName, randomPlan);
}