@@ -294,7 +294,7 @@ void startProbeScheduler() {
294294 }
295295
296296 /**
297- * Prode datanode by probe byte .
297+ * Prode datanode by probe type .
298298 */
299299 private void scheduleProbe (ProbeType type ) {
300300 LOG .debug ("Schedule probe datanode for probe type: {}." , type );
@@ -376,9 +376,8 @@ public DatanodeLocalInfo call() throws Exception {
376376 } catch (Exception e ) {
377377 LOG .error ("Probe failed, datanode: {}, type: {}." , datanodeInfo , type ,
378378 e );
379+ deadNodeDetector .probeCallBack (this , false );
379380 }
380-
381- deadNodeDetector .probeCallBack (this , false );
382381 }
383382 }
384383
@@ -402,7 +401,7 @@ private void probeCallBack(Probe probe, boolean success) {
402401 }
403402 } else {
404403 if (probe .getType () == ProbeType .CHECK_SUSPECT ) {
405- LOG .info ( "Add the node to dead node list: {}." ,
404+ LOG .warn ( "Probe failed, add suspect node to dead node list: {}." ,
406405 probe .getDatanodeInfo ());
407406 addToDead (probe .getDatanodeInfo ());
408407 }
@@ -415,11 +414,12 @@ private void probeCallBack(Probe probe, boolean success) {
415414 private void checkDeadNodes () {
416415 Set <DatanodeInfo > datanodeInfos = clearAndGetDetectedDeadNodes ();
417416 for (DatanodeInfo datanodeInfo : datanodeInfos ) {
418- LOG .debug ("Add dead node to check: {}." , datanodeInfo );
419417 if (!deadNodesProbeQueue .offer (datanodeInfo )) {
420418 LOG .debug ("Skip to add dead node {} to check " +
421419 "since the probe queue is full." , datanodeInfo );
422420 break ;
421+ } else {
422+ LOG .debug ("Add dead node to check: {}." , datanodeInfo );
423423 }
424424 }
425425 state = State .IDLE ;
@@ -475,6 +475,7 @@ public synchronized void addNodeToDetect(DFSInputStream dfsInputStream,
475475 datanodeInfos .add (datanodeInfo );
476476 }
477477
478+ LOG .debug ("Add datanode {} to suspectAndDeadNodes." , datanodeInfo );
478479 addSuspectNodeToDetect (datanodeInfo );
479480 }
480481
0 commit comments