mirror of https://github.com/apache/cloudstack.git
Fix logs mismatch between Network GC wait and interval (#10776)
Co-authored-by: nvazquez <nicovazquez90@gmail.com> Co-authored-by: dahn <daan@onecht.net> Co-authored-by: Wei Zhou <weizhou@apache.org>
This commit is contained in:
parent
6ba5e08221
commit
3ba5c2b610
|
|
@ -3559,8 +3559,9 @@ public class NetworkOrchestrator extends ManagerBase implements NetworkOrchestra
|
|||
final HashMap<Long, Long> stillFree = new HashMap<Long, Long>();
|
||||
|
||||
final List<Long> networkIds = _networksDao.findNetworksToGarbageCollect();
|
||||
final int netGcWait = NumbersUtil.parseInt(_configDao.getValue(NetworkGcWait.key()), 60);
|
||||
logger.info("NetworkGarbageCollector uses '{}' seconds for GC interval.", netGcWait);
|
||||
final int netGcWait = NetworkGcWait.value();
|
||||
final int netGcInterval = NetworkGcInterval.value();
|
||||
logger.info("NetworkGarbageCollector uses '{}' seconds for GC wait and '{}' seconds for GC interval.", netGcWait, netGcInterval);
|
||||
|
||||
for (final Long networkId : networkIds) {
|
||||
if (!_networkModel.isNetworkReadyForGc(networkId)) {
|
||||
|
|
@ -4882,9 +4883,9 @@ public class NetworkOrchestrator extends ManagerBase implements NetworkOrchestra
|
|||
}
|
||||
|
||||
public static final ConfigKey<Integer> NetworkGcWait = new ConfigKey<Integer>(Integer.class, "network.gc.wait", "Advanced", "600",
|
||||
"Time (in seconds) to wait before shutting down a network that's not in used", false, Scope.Global, null);
|
||||
"Time (in seconds) to wait before shutting down a network that's not in used", true, Scope.Global, null);
|
||||
public static final ConfigKey<Integer> NetworkGcInterval = new ConfigKey<Integer>(Integer.class, "network.gc.interval", "Advanced", "600",
|
||||
"Seconds to wait before checking for networks to shutdown", true, Scope.Global, null);
|
||||
"Seconds to wait before checking for networks to shutdown", false, Scope.Global, null);
|
||||
|
||||
@Override
|
||||
public ConfigKey<?>[] getConfigKeys() {
|
||||
|
|
|
|||
Loading…
Reference in New Issue