Extends the FlowRuleService and its api by adding in-order processing
capabilities. This is achieved by introducing stripe key as way to
indicate how to process the flowrules. Key is an object which is used
to select a specific executor. Operations having the same key is guaranteed
that will be processed by the same executor.
Change-Id: I5ab4d42e8a2b8cb869f3dc2305dbc5084d31f08b
(cherry picked from commit 07af21d9e116414b74152dc812cc980ca2c4c0a5)
If the store is already in sync re-issueing a batch
request is dangerous (race with conflictual writes)
and wrong. In this case, if the device is still reporting
the flow, it is enough to send a flow removal directly.
Instead, if the flow is expired it is important to update
the store accordingly and then issue a flow removal as
consequence of the batch request.
Change-Id: I11a595e0a91f0efdc1cac3bf1d589a5108f1ae06
With the persistence mastership in place the stats are no longer
discarded because of the lack of a master. This change introduces
further checks based on the availability. Additionally, it purges
the pending groups map which was leaking memory.
Change-Id: I6b0d127bf9a247d7981871f02847f6e2f4074182
For some devices like p4rt devices which are first registered
and then updated does not make sense to check the reachability
asap: connection is established concurently to the mastership
checks and the channel might not be ready.
Change-Id: I5a31e09cf382df388a473af338eb72fb9a187fa8
The probe task is not performed in atomic way and between the
initial mastership check and the actual probe the execution
can be blocked many times and the mastership can change. Recheck
the mastership after pipeline probe returns.
We are seeing an issue when a network partition occurs: watchdog
is stuck for 60s before returning and will mark the device offline.
However, in the meanwhile the mastership has been passed to another
instance which is already connected and has already marked the device
online. An harmless side effect of this change is that when we return
from the pipeline config we might be no longer the master and this
will delay in the worst case the markonline of the device for 15s
(next reconcile interval)
Additionally, this patch simplifies the Manager by removing the
executor lock and by using only one worker per device. This change
prevents also the exhaustion of all workers than can easily happen
if there is a network partition that prevents the probe to return
immediately.
Change-Id: I3429cd0598c95589e50f35139f6087f83ceb60f2
This patch is the part 1 and contains the following:
- Make the GDP greedy by reasserting immediately the role
Change-Id: I7259d4ace4a3e58ae2d97b6e53a393c41d5c0df9
(cherry picked from commit d510b7db8aeafbb52b00982dacb1f1079b0cc4b2)
Design doc can be found here:
https://docs.google.com/document/d/1UStD1hGCy5YQlFmaWfclq6uYROtMY56jWxUBwfUEsRM
Additionally, introduce few more changes in the DeviceManager:
- Always reassert the role if the instance has a valid role
- Test reachability through isReachable and probeReachability
Change-Id: I35183c04b65a98bc0332ed256be8333b53d6b68f
(cherry picked from commit b2f636bffd2783266826503755ba5f42dfdb2b75)
Introduce a new API for PiInterpreter to map logical port number to a long
port number and deprecate the old one.
The reason we need to translate logical port number to a long type is that
the mapped number will become negative when translating port number to
an unsigned integer with MSB (e.g., 0xFFFFFFFD) and the low level driver
or translator is expecting to get a positive number.
Change-Id: I751e69461b0cf97280f12fd98ca2b15b83cbe84f
Mastership changes can happen during the processing of the flow rules stats,
If there is no master while we are executing handleExistingFlow we will get
null when we try to retrieve the stored flow rule. This is wrongly handled
with the removal of the flow rule from the store which will cause lost
of connectivity. This patch basically removes the flow rule only when we are
sure of what we are doing, when we are not the code verifies if there are
proper conditions to continue the processing (check if there was a mastership
change).
Additionally, this patch improves the logging of the ECFlowRuleStore
Change-Id: I7b79e7ab3d8ccfa6edca6ba4ad5de93ada082265
- All ports that has a subnet configured in netcfg will be used for probing
- A port may not exist on the device even if it's configured in interfces
- A port will never be added to the edge port list if it is never enabled
If a port meets both conditions above, it will fail the isEdgePort check and produce repeating warning messages.
This patch explicitly avoid probing on non-existent or disabled ports
Change-Id: I5cc5f32d4b2ff9fc00729e0adddbede29fb49ca0
(cherry picked from commit a618d74a7596633d666679f709a853d374fe2cb9)
With this fix the ONOS cluster will start a new term if the mastership is not
acknowledged by the device after 10 seconds.
Change-Id: Id0927181e4ba37ed1af52dd9843d4c2563469025
Added backwards compatible flag to GET /intents/ to return full intent JSON.
Added GET /intents/application/{appId} to return application specifc intents.
Extended IntentService to include getIntentsByAppId(appId).
Removed hard-coded intent codec lookup in IntentWebResource.
Change-Id: I38e7b1dbd7669e654afe723f6ec3a4eb7a9af6fb
java.lang.NullPointerException: null
at org.onosproject.net.host.impl.HostManager$InternalHostProviderService.hostVanished(HostManager.java:573) ~[?:?]
at org.onosproject.provider.netcfghost.NetworkConfigHostProvider.removeHost(NetworkConfigHostProvider.java:189) ~[?:?]
at org.onosproject.provider.netcfghost.NetworkConfigHostProvider$InternalNetworkConfigListener.event(NetworkConfigHostProvider.java:274) ~[?:?]
at org.onosproject.provider.netcfghost.NetworkConfigHostProvider$InternalNetworkConfigListener.event(NetworkConfigHostProvider.java:222) ~[?:?]
at org.onosproject.event.ListenerRegistry.process(ListenerRegistry.java:66) [!/:?]
at org.onosproject.event.impl.CoreEventDispatcher$DispatchLoop.process(CoreEventDispatcher.java:198) [!/:?]
at org.onosproject.event.impl.CoreEventDispatcher$DispatchLoop.run(CoreEventDispatcher.java:180) [!/:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
at java.lang.Thread.run(Thread.java:834) [?:?]
Change-Id: If6e3978798d5fb11b3f5b1344b551b9f3cd3e51d
(cherry picked from commit 3a615560678cb83fa41f393fa59c346cdae659e2)
Changes in the GDP are done to make sure the default availability is always
updated through the two step process defined in the provider and to prevent
the disconnection of the devices when an instance rejoins the cluster
Finally, the patch improves logging inside the GossipDeviceStore and improve
the stability of PiPipeconfWatchdogManager by getting rid of the timer and
timer task and by executing the event listeners inside an executor.
Change-Id: Ibc6ce711e15e86bde05dbf3b1c37d2a93516fae3
There is no guarantee that the HostProbingProvider is already
registered before setDelegate is called. This patch prevents
npe caused by events delivered before the provider is ready
Change-Id: I8612a3b156e342752d1ade9ee1d7d786ad53cc9e
(cherry picked from commit e84b2e8081ea40ff06eaa1b119c6e22cfcf9459d)
- Code clean up (unused code, unuseful comments)
- Remove deprecated internal APIs
- Prevent the ejection of the meter pollers
- Prevent the ejection of the mf pollers
- Fix unproper filter of device events
- Fix delete on store which updated existing meters with dummy value
- Fix NPE in TofinoMeterProgrammable caused by default config
- Update unit tests
Change-Id: Ib2767e3ab3cf146693e61b7e1890419c9743d521
(cherry picked from commit a770879a950d1cc985db1a659da701551700e886)
If a component property as a multiline comment the app activation
will throw an exception and no property for that component would be initialized.
This patch address that in two ways:
- Make sure that if we cannot parse a line from cfgdef the other properties are enabled and logs a warn.
- Changes the onos-maven-plugin so that it removes new lines when generating the .cfgdef file
Bumping version as plugin is already published from onos-2.5 branch
Change-Id: I550c23624118782fe6d79c9abbaf75ae59ea0eab
- Improve ONOS cli enabling CRUD of p4rt trtcm
- Improve ONOS rest enabling CRUD of p4rt trtcm
- Improve MeterService with scope defined reads and integrate in cli/rest
- Add support along the stack for BYTE_PER_SEC unit
- Add support along the stack for COMMITTED and PEAK bands
- Fix several bugs in ONOS cli/rest interfaces
- Improve REST codecs
- Fix NPE in MeterDriverProvider
- Improve PiMeterTransalation by enforcing trtcm config
- Implement explicit translation of the bands
- Fix ONOS reconciliation by removing from the mirror the wrong configs
- Remove unnecessary checks in MeterEntryCodec
- Update unit tests
It will follow a 2nd patch to complete SDFAB-527
Change-Id: I855235b17f60cb1d39f5b9a042c1015105a8a269
- Introduce a boolean to control the meter service modes
- User defined mode does not provide any coordination to the apps
- Only one mode can be active at time
- In addition some sanity checks are peformed by the meter service
- Update existing unit tests and add new ones to test the new behaviors
- Initial clean up of the meters subsystems
Change-Id: I61500b794f27e94abd11637c84bce0dbb2e073f3
This is achieved by translating SIMPLE next objective into
INDIRECT groups. By default SELECT groups are always used
which has as side effect the creation of action profile groups
with the maxGroupSize derived from the action profile model.
Instead, PiGroupTranslator sets always to 1 the maxGroupSize
of action profile groups derived from a INDIRECT groups which
allows us to achieve a better scale for target devices pre-allocating
memory according to the maxGroupSize.
Change-Id: I7079a99ca9a7474eafae7f258da06770453b05f9
To support truncate by P4Runtime clone/mirror session, we need to pass the
truncate size/length from ONOS northbound to the southbound.
As discussed in the SDFabric syncup, we decide to pass this information via
the instruction in group bucket so applications or pipeliners can simply
reuse current APIs.
Change-Id: I15cc822b7c8008b6b9f8b02f3f399769ae396ef0
(cherry picked from commit 9f94a13bf5695996708eedc17166b5b09308147f)
Offload listeners processing to external executors to prevent
the listener ejection due to time consuming processing
In future, we may want to extend the same fix to the
HostManager and NetworkConfigHostProvider
Additionally, avoid the propagation of the exceptions in GroupDriverProvider
which leads to the cancellation of the peridioc poll task
Change-Id: I8ea4ec9fda1ccc48bbd3855fd443ee8760cbbb60