boolean isVpnInstanceUpdate = Boolean.FALSE;
final VpnInterfaceKey key = identifier.firstKeyOf(VpnInterface.class);
final String interfaceName = key.getName();
- List<String> oldVpnList = vpnUtil.getVpnListForVpnInterface(original);
+ List<String> oldVpnList = VpnUtil.getVpnListForVpnInterface(original);
List<String> oldVpnListCopy = new ArrayList<>();
oldVpnListCopy.addAll(oldVpnList);
- List<String> newVpnList = vpnUtil.getVpnListForVpnInterface(update);
+ List<String> newVpnList = VpnUtil.getVpnListForVpnInterface(update);
List<String> newVpnListCopy = new ArrayList<>();
newVpnListCopy.addAll(newVpnList);
return VpnConstants.IP_MONITOR_JOB_PREFIX_KEY + "-" + vpnName + "-" + ip;
}
- public List<String> getVpnListForVpnInterface(VpnInterface vpnInter) {
+ public static List<String> getVpnListForVpnInterface(VpnInterface vpnInter) {
return requireNonNullElse(vpnInter.getVpnInstanceNames(), Collections.<VpnInstanceNames>emptyList()).stream()
.map(VpnInstanceNames::getVpnName).collect(Collectors.toList());
}