YARN-9639. DecommissioningNodesWatcher cause memory leak. Contributed by Bilwa S T.
(cherry picked from commit be80334cdf
)
This commit is contained in:
parent
e7fce2104f
commit
a2f4e4698b
|
@ -207,6 +207,11 @@ public class DecommissioningNodesWatcher {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void stop() {
|
||||||
|
pollTimer.cancel();
|
||||||
|
pollTimer = null;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Status about a specific decommissioning node.
|
* Status about a specific decommissioning node.
|
||||||
*
|
*
|
||||||
|
|
|
@ -263,6 +263,7 @@ public class ResourceTrackerService extends AbstractService implements
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void serviceStop() throws Exception {
|
protected void serviceStop() throws Exception {
|
||||||
|
decommissioningWatcher.stop();
|
||||||
if (this.server != null) {
|
if (this.server != null) {
|
||||||
this.server.stop();
|
this.server.stop();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue