More robust P4Runtime group handling
This patch solves the PENDING_UPDATE and PENDING_ADD_RETRY issue
observed on the ONS EU topology.
The P4Runtime action profile group handling has been re-implemented to
be robust against inconsistencies of the device mirror, which is now
periodically synchronized with the device state. Similarly, we implement
a routine in the P4RuntimeClient to cleanup unused action profile
members.
This patch includes also:
- Refactor PI handle classes to allow creating handles without the
entity instance
- Use list instead of collections in P4RuntimeClient methods, as order
of updates sent and/or entities received from the device is important
Change-Id: I2e7964ce90f43d66680131b47ab52aca32ab55d2
diff --git a/core/store/dist/src/test/java/org/onosproject/store/pi/impl/DistributedPiTranslationStoreTest.java b/core/store/dist/src/test/java/org/onosproject/store/pi/impl/DistributedPiTranslationStoreTest.java
index 2ba52a2..acfce12 100644
--- a/core/store/dist/src/test/java/org/onosproject/store/pi/impl/DistributedPiTranslationStoreTest.java
+++ b/core/store/dist/src/test/java/org/onosproject/store/pi/impl/DistributedPiTranslationStoreTest.java
@@ -45,7 +45,12 @@
};
private static final PiEntity PI_ENTITY = () -> PiEntityType.TABLE_ENTRY;
private static final PiHandle<PiEntity> PI_HANDLE =
- new PiHandle<PiEntity>(DeviceId.NONE, PI_ENTITY) {
+ new PiHandle<PiEntity>(DeviceId.NONE) {
+ @Override
+ public PiEntityType entityType() {
+ return PI_ENTITY.piEntityType();
+ }
+
@Override
public int hashCode() {
return HANDLE_HASH;