[VOL-2744] on device reconnection do not reprovision eapol on existing subscriber

Change-Id: I0ce77082141b99bf8a2612d4dd3bc656fc5490c0
diff --git a/app/src/main/java/org/opencord/olt/impl/Olt.java b/app/src/main/java/org/opencord/olt/impl/Olt.java
index 8932f0d..8575255 100644
--- a/app/src/main/java/org/opencord/olt/impl/Olt.java
+++ b/app/src/main/java/org/opencord/olt/impl/Olt.java
@@ -306,7 +306,7 @@
 
             unprovisionVlans(deviceId, uplinkPort.number(), subscriberPortNo, uniTag);
 
-            // re-install eapol with default bandwidth profile
+            // remove eapol with default bandwidth profile
             oltFlowService.processEapolFilteringObjectives(deviceId, subscriberPortNo,
                                                            uniTag.getUpstreamBandwidthProfile(),
                                                            null, uniTag.getPonCTag(), false);
@@ -813,9 +813,14 @@
                     continue;
                 }
                 if (isUniPort(dev, p)) {
-                    log.info("Creating Eapol for the uni {}", p);
-                    oltFlowService.processEapolFilteringObjectives(dev.id(), p.number(), defaultBpId, null,
-                                                                   VlanId.vlanId(EAPOL_DEFAULT_VLAN), true);
+                    if (!programmedSubs.containsKey(new ConnectPoint(dev.id(), p.number()))) {
+                        log.info("Creating Eapol for the uni {}", p);
+                        oltFlowService.processEapolFilteringObjectives(dev.id(), p.number(), defaultBpId, null,
+                                                                       VlanId.vlanId(EAPOL_DEFAULT_VLAN), true);
+                    } else {
+                        log.debug("Subscriber Eapol for UNI port {} on device {} is already " +
+                                          "provisioned, not installing default", p.number(), dev.id());
+                    }
                 } else {
                     oltFlowService.processNniFilteringObjectives(dev.id(), p.number(), true);
                 }