add VPNInterface logic in VpnInterfaceManager
has a bug where if add VPN Interface fails, it keeps
retrying till it succeeds. There is no delay in retries.
IF there are any DS issues, this results in an infinite
loop which ties up a DJC thread and fills logs with same
msg repeatedly at a near instant rate.
Bug is in logic where onFailure() method adds the failed
interface back to retry. So while DJC does give up after
5 retries, since we've added it back to the queue
subsequent attempts start soon after.
This also fixes a copy-paste log msg which made it
difficult to troubleshoot where the error log
was repeating from.
Change-Id: I97c73dc879aaa4e1a4b3489e146d1a9337b62810
Signed-off-by: Vishal Thapar <vthapar@redhat.com>
}
private void processSavedInterface(UnprocessedVpnInterfaceData intefaceData, String vpnName) {
- if (!canHandleNewVpnInterface(intefaceData.identifier, intefaceData.vpnInterface, vpnName)) {
- LOG.error("add: VpnInstance {} for vpnInterface {} not ready, holding on ",
- vpnName, intefaceData.vpnInterface.getName());
- return;
- }
final VpnInterfaceKey key = intefaceData.identifier.firstKeyOf(VpnInterface.class);
final String interfaceName = key.getName();
InstanceIdentifier<VpnInterfaceOpDataEntry> vpnInterfaceOpIdentifier = VpnUtil