Out of Memory when static Routes are configured with unresolved next hop
Root cause: This problem happens when there are staticRoutes configured but their
next hop IP are unresolved (ie. not responding to ARP Request).
StaticRouteImpl.java spawns a thread requesting hostTracker to discover the host,
this thread is waiting forever due to a bug in the thread (HostTrackerCallable)
that handles the discovery which never returns since the host is not responding.
Solution:
- Instead of creating threads dynamically, we create a threadpool of 2 and reuse
the threads.
- Fix the bug in HostTrackerCallable to sleep(2000) and returns.
Change-Id: Ic04d1dbaf17d5cd6672646050d71abb9885695e9
Signed-off-by: Chi-Vien Ly <chivly@cisco.com>