genius.git
6 years agoRunning Genius CSIT in a dev environment 90/67290/6
Faseela K [Thu, 18 Jan 2018 15:56:57 +0000 (21:26 +0530)]
Running Genius CSIT in a dev environment

Document on how to run genius csit in a dev
environment

Change-Id: Iccc0468023f5a5ee1452d4d1712c741c464713bc
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoadding portuuid to be retrieved as part of port statistics 49/66849/16
Viji J [Wed, 3 Jan 2018 05:26:53 +0000 (10:56 +0530)]
adding portuuid to be retrieved as part of port statistics

Port statistics Listener gives nodeconnectorid.
To retrieve portuuid, portname is required.
Through "InterfaceInventoryStateListener" nodeconnectorId-portname map
is built.
Listener class is added upon
"odl-interface-meta/interface-child-info/interface-parent-entry" through
which interfaceparentname-interfacechildentry map is built.

Using these two maps, portuuid is retreived in port statistics.

Change-Id: I83ad72ce0ff21980b323f28aeb2cc177a4034eab
Signed-off-by: Viji J <viji.j@ericsson.com>
Signed-off-by: VijiJ <viji.j@ericsson.com>
Signed-off-by: Viji J <viji.j@ericsson.com>
6 years agoRemove older s-n-d implementation. 19/66519/4
Faseela K [Fri, 15 Dec 2017 17:48:53 +0000 (23:18 +0530)]
Remove older s-n-d implementation.

Now that genius has moved to infrautils based
diagstatus, let us remove the older status-and-diagnostics
code which was remaining in IFM and ITM in bits and pieces.

Change-Id: I322c020021e60efe28c1b35415660e0b26b90fee
Signed-off-by: Faseela K <k.faseela@gmail.com>
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoadded read method to ResourceBatchingManager 04/67004/10
K.V Suneelu Verma [Wed, 10 Jan 2018 06:10:31 +0000 (11:40 +0530)]
added read method to ResourceBatchingManager

Reads the identifier of given resource type
If the identifier is going to be deleted , returns Optional.absent()
If the identifier is going to be added , returns the to be added DataObject
else goes to the datastore and reads it.

Change-Id: Ie3e5903d22463d5914068bb693c54f4b93594d02
Signed-off-by: K.V Suneelu Verma <k.v.suneelu.verma@ericsson.com>
6 years agoAdd link to ITM scale spec to index 66/67566/1
Vishal Thapar [Thu, 25 Jan 2018 04:55:27 +0000 (10:25 +0530)]
Add link to ITM scale spec to index

Change-Id: I45aa103dce848e745874711f630af22efcd151bd
Signed-off-by: Vishal Thapar <vishal.thapar@ericsson.com>
6 years agoSpec for ITM Scale Improvements 09/65809/9
Hema Gopalakrishnan [Tue, 21 Nov 2017 17:29:02 +0000 (22:59 +0530)]
Spec for ITM Scale Improvements

Addressed review comments

Change-Id: I9b4a85853e90bbbdeba25093d149067cf41f5b98
Signed-off-by: Hema Gopalakrishnan <hema.gopalkrishnan@ericsson.com>
6 years agoMinor changes found by static analyzer 69/67469/1
David Suarez [Tue, 23 Jan 2018 10:35:29 +0000 (11:35 +0100)]
Minor changes found by static analyzer

Change-Id: I56d29266629e56488d8f3ef9f5824fe277718182
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoACL: Defining new ACL tables 57/65157/8
Somashekar Byrappa [Mon, 6 Nov 2017 10:11:08 +0000 (15:41 +0530)]
ACL: Defining new ACL tables

+ Defining new ACL tables as per the spec "Support for protocols that are not
supported by conntrack".
+ Includes metadata changes for ACL.

Change-Id: I95df598428f6351e2abb0b173a4318253c9e20bc
Signed-off-by: Somashekar Byrappa <somashekar.b@altencalsoftlabs.com>
6 years agoLoading balancing port statistics collections 74/66974/7
Viji J [Tue, 9 Jan 2018 13:13:04 +0000 (18:43 +0530)]
Loading balancing port statistics collections

Currently in clustered controller nodes, stats query for
switches is happening on the master node due to DTCL
listener attachment, so the statistics RPC invocation
involves both local RPC and remote RPC calls. This creates
overhead in a scaled environment.

Fix is been provided to have CDTCL and applying EOS to find
the switches connected locally to the controller node.
Now, each controller node collects statisticsof its own
connected switches.Thus, avoiding remote RPC calls.
Additionally, added 10s of delay between each rpc call
of the switches stats query.
Also increased initial delay to be 5minutes to the overall
statistics collection.

Change-Id: I50b502992bb8182eab406342f467ef56b6ef7798
Signed-off-by: Viji J <viji.j@ericsson.com>
Signed-off-by: VijiJ <viji.j@ericsson.com>
6 years agoTemplate for TestPlans 81/65081/10
Vishal Thapar [Fri, 3 Nov 2017 10:09:45 +0000 (15:39 +0530)]
Template for TestPlans

Also adds initial draft of interface-manager test plan

Change-Id: I5f327ba95d4254231b8489d0392a53ebaac2b3c1
Signed-off-by: Vishal Thapar <vishal.thapar@ericsson.com>
6 years agoAdjust for odlparent 3 / yangtools 2 68/66468/5
Stephen Kitt [Thu, 14 Dec 2017 16:30:19 +0000 (17:30 +0100)]
Adjust for odlparent 3 / yangtools 2

Change-Id: I737d07fa781c7bdbc1fe069a6684f87cb459bafa
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoFix IdManagerTest bug 87/66387/5
Michael Vorburger [Tue, 12 Dec 2017 13:50:15 +0000 (14:50 +0100)]
Fix IdManagerTest bug

a failing assert in a background thread in an ExecutorService is useless
and will do nothing; assert can only be used inside the main test
thread.  Also the ExecutorService must be logging its thread deaths.
also this is a prime example of where we really should use
LogCaptureRule to let any logged errors fails the test.

This will NOT fix GENIUS-105, just show the real root cause better.  But
now if you uncomment the RunUntilFailureClassRule & RunUntilFailureRule,
then you will hit the problem what occurred in GENIUS-105 during the
build locally, sooner or later (just let it run a few minutes).

Change-Id: Idb1b6b36c9628d39ba7875bec5c19fb426bad061
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoMigration of arputil counters to use infrautils.metrics 54/66054/9
Viji J [Wed, 29 Nov 2017 08:54:39 +0000 (14:24 +0530)]
Migration of arputil counters to use infrautils.metrics

instead of infrautils.counters

Code changes are done to use infrautils.metrics api and
cleaned up infrautils.counters dependency.

Change-Id: I73bf730d0f0e2f96fa4a84ab471e18f33305360c
Signed-off-by: Viji J <viji.j@ericsson.com>
Signed-off-by: VijiJ <viji.j@ericsson.com>
6 years agoMake upgrading flag settable from a config file 66/66566/4
Josh [Mon, 18 Dec 2017 16:26:30 +0000 (18:26 +0200)]
Make upgrading flag settable from a config file

File is called genius-mdsalutil-config.xml and looks like:
<config xmlns="urn:opendaylight:params:xml:ns:yang:mdsalutil">
  <upgradeInProgress>true</upgradeInProgress>
</config>

ALSO, fix that bundle is not reloaded when config changes on the fly.

Change-Id: I89e25cefd03cbaea1f7f59701d4265d93b526899
Signed-off-by: Josh <jhershbe@redhat.com>
6 years agoEOS Openflow entitytype changes 41/66641/7
VijiJ [Wed, 20 Dec 2017 09:30:41 +0000 (15:00 +0530)]
EOS Openflow entitytype changes

1) EOS on openflow switches entity type got changed to "org.opendaylight.mdsal.ServiceEntityType"
2) Fix null pointer exception - putIfAbsent returns null when the first value is added.
   computeIfAbsent is replaced.
3) revisit of logs.

Change-Id: I13452abaaf382ac5ff9bda4bb1d1c7ad7278c5ec
Signed-off-by: VijiJ <viji.j@ericsson.com>
Signed-off-by: Viji J <viji.j@ericsson.com>
Signed-off-by: VijiJ <viji.j@ericsson.com>
Signed-off-by: Viji J <viji.j@ericsson.com>
6 years agoDataObjectCache CacheProvider requireNonNull 19/67019/1
Michael Vorburger [Wed, 10 Jan 2018 16:26:02 +0000 (17:26 +0100)]
DataObjectCache CacheProvider requireNonNull

just to avoid people who may start using this rather sooner than later
thinking "oh that's not [yet!] used, so I can just pass null" and then
breaking things when we (soon) do use it - better safe than sorry.

Change-Id: I08f1c99b9f7449b4fdd97d9fbdc4e524971bb28f
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoMinor: DataObjectCache final ListenerRegistration 18/67018/1
Michael Vorburger [Wed, 10 Jan 2018 16:21:34 +0000 (17:21 +0100)]
Minor: DataObjectCache final ListenerRegistration

Change-Id: I02179e863f03371d9bc1837843f451433151b797
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoMigrate listeners in id-manager-impl module to use new listeners fw 27/66127/4
David Suarez [Thu, 30 Nov 2017 23:36:39 +0000 (00:36 +0100)]
Migrate listeners in id-manager-impl module to use new listeners fw

Change-Id: I12a6e1537163ee7178ad79f5cfc3f72d9dd9dda3
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years ago@Ignore testMultithreadedIdAllocationForSameKeyFromReleasedIds 40/66940/2
Michael Vorburger [Mon, 8 Jan 2018 15:12:07 +0000 (16:12 +0100)]
@Ignore testMultithreadedIdAllocationForSameKeyFromReleasedIds

just like the previous
testMultithreadedIdAllocationForSameKeyFromAvailableIds

because it is unstable and seems to fail autorelease, at least sometimes
(perhaps when the build servers are heavily loaded?); as seen e.g. in
https://lists.opendaylight.org/pipermail/genius-dev/2017-December/002197.html

Change-Id: I67e7a6ab97467961a55af86ef959f09f2609d8b5
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoBug 8998 - ping to TOR vm fails post vm migration 66/66866/2
eaksahu [Thu, 4 Jan 2018 09:08:18 +0000 (14:38 +0530)]
Bug 8998 - ping to TOR vm fails post vm migration

fix npe in  accessing cache

Change-Id: Idf8d9b91a6aa007f85d3fc8185870eedce5b6768
Signed-off-by: eaksahu <a.k.sahu@ericsson.com>
6 years agoAdd DataObjectCache 03/66403/11
Tom Pantelis [Wed, 13 Dec 2017 00:06:33 +0000 (19:06 -0500)]
Add DataObjectCache

This is intended as a non-static replacement for DataStoreCache.

Change-Id: I1331c46326424d79df78fdd5431475eed8746338
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoDataTreeEventCallbackRegistrar for data tree instance call backs 94/65894/11
Michael Vorburger [Fri, 24 Nov 2017 14:58:53 +0000 (15:58 +0100)]
DataTreeEventCallbackRegistrar for data tree instance call backs

Phase 1 is this first interface service API & simple implementation.

Phase 2 will be an optimized implementation (post usage).

Change-Id: I37d0b787874b00646d9e7ea93f3a91664a69db4a
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoKaraf CLI to print BFD Cache 63/66863/4
Nidhi Adhvaryu [Thu, 4 Jan 2018 05:30:11 +0000 (11:00 +0530)]
Karaf CLI to print BFD Cache

Change-Id: I73b5f43613b20d0291b4ef4ae5a352cb736f1d74
Signed-off-by: Nidhi Adhvaryu <nidhi.adhvaryu@ericsson.com>
6 years agomdsalutil: introduce new service index for VPNv6 60/66560/2
Philippe Guibert [Mon, 18 Dec 2017 12:09:33 +0000 (12:09 +0000)]
mdsalutil: introduce new service index for VPNv6

In the case of two router setup configuration bound to the same port,
where IPv4 and IPv6 traffic is redirected to different router, one needs
a new service index that sticks to IPv6 Service. The changes here
include that new service

Change-Id: I4432277fe7361fdd98c193873031e67cff3f8a28
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
6 years agoAdjust to odlparent 3 Checkstyle settings 67/66467/4
Stephen Kitt [Thu, 14 Dec 2017 16:08:50 +0000 (17:08 +0100)]
Adjust to odlparent 3 Checkstyle settings

Change-Id: I2a63188743ccddc74b4d87615efbb9fdf9cd9554
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years ago@Ignore testMultithreadedIdAllocationForSameKeyFromAvailableIds 86/66386/2
Michael Vorburger [Tue, 12 Dec 2017 13:28:32 +0000 (14:28 +0100)]
@Ignore testMultithreadedIdAllocationForSameKeyFromAvailableIds

in IdManagerTest, for occassional build issue GENIUS-105

Change-Id: I0b296aa9ac9289f2937bd50545479800522fc120
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoAdd K8S port pattern 14/66314/3
Faseela K [Thu, 7 Dec 2017 16:54:23 +0000 (22:24 +0530)]
Add K8S port pattern

K8S ports should be treated in the same way as Nova or Tunnel
Ports by Genius. Currently Genius prefixes dpnId to interface-name
if a portname does not match with a set of known port patterns.

Change-Id: Iba3a843583742fe5d29ffe9dcffc6d3dade316ee
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoRemoved @Deprecated Guava checkedGet in SingleTransactionDataBroker 13/66113/4
Michael Vorburger [Thu, 30 Nov 2017 21:30:34 +0000 (22:30 +0100)]
Removed @Deprecated Guava checkedGet in SingleTransactionDataBroker

by replacing it with ListenableFutures.checkedGet from infrautils

Change-Id: If0e117df659d9312f8345445f785efb49ba532b2
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoInterfaceManagerService API without RpcResult 04/65004/8
Michael Vorburger [Wed, 1 Nov 2017 22:15:34 +0000 (23:15 +0100)]
InterfaceManagerService API without RpcResult

FutureRpcResults lets us easily and clearly make RPC implementations
be simple delegating wrappers to methods just returning a Future<Output>
witout the intermediary RpcResult that I find is often more worked
around than really used.

These non-RPC service implementation classes can then be registered as
regular local OSGi Services, and direct used locally.

Change-Id: Iaa9b0bfc0b4517190b72b42fa4f81ed2ef06ab0e
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoAdded a new API addL2GwInterface to handle adding TOR NodeId as external 39/66239/4
Yugandhar Reddy Kaku [Tue, 5 Dec 2017 12:24:38 +0000 (17:54 +0530)]
Added a new API addL2GwInterface to handle adding TOR NodeId as external
destination endpoint

Change-Id: I929757008e451e285b4a029523c120256628d30c
Signed-off-by: Yugandhar Reddy Kaku <yugandhar.reddy.kaku@ericsson.com>
6 years agoId manager: use transaction manager 26/64726/6
Stephen Kitt [Wed, 25 Oct 2017 16:04:49 +0000 (18:04 +0200)]
Id manager: use transaction manager

Use the transaction manager to manager all write transactions as far
as possible. A couple of uses are still left because they manipulate
state outside the transaction scope.

Change-Id: Iad5a8d03f40e2a5488ecd0d52fe96f5df4cb35bb
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoUse odl-daexim instead of odl-daexim-all 63/66163/2
Faseela K [Fri, 1 Dec 2017 19:13:50 +0000 (00:43 +0530)]
Use odl-daexim instead of odl-daexim-all

Change-Id: I1375a70e4cfc96cae346e18abb571b8f5bcba720
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoRetryingManagedNewTransactionRunnerImpl made private (incl. JavaDoc) 70/66170/3
Michael Vorburger [Fri, 1 Dec 2017 23:23:37 +0000 (00:23 +0100)]
RetryingManagedNewTransactionRunnerImpl made private (incl. JavaDoc)

because upon starting to explain the retrying
ManagedNewTransactionRunner to people I realized that the 3 impls are
really my implementation detail; as a user what's important is the pure
close guaranteeing VS the retrying one.

Change-Id: I5613a9a50e61f7d5385f8840725ec283424481a8
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoUpgrade Race Condition: tap ports not getting table=0 flows 50/66050/2
Josh [Wed, 29 Nov 2017 08:30:39 +0000 (10:30 +0200)]
Upgrade Race Condition: tap ports not getting table=0 flows

On occasion VM ports do not get table 0 and 220 flows. The immediate
cause of this is there is no interface state added for the neutron port
(name=the uuid) just for the "physical" port (name=tapXYZ). This happens
because of the following race condition:

TerminationPointStateListener triggers the creation of the child
interface for the external ids it receives from ovsdb. Before it does,
it retrieves an entry in InterfacemgrProvider#nodeIidToBridgeMap in order
to retrieve the node's dpid.  However, the entry in
InterfacemgrProvider#nodeIidToBridgeMap is created from
InterfaceTopologyStateListener and does not necessarily happen in time.
In fact I have seen cases where InterfaceTopologyStateListener is invoked
between two events to TerminationPointStateListener and the first port
will not get flows but the second will.

This fix simply reads from md-sal if the bridge is not present in the
cache yet. This works because the bridge and termination point
augmentations for the node are actually written to md-sal in the same
transaction, the bug has to do with the order of notifications. Note
that in regular application flow the bridge will show up WAY before
the termination points.

Change-Id: I7d6abeaeaec500316da6c282def9a6e75fc63cf2
Signed-off-by: Josh <jhershbe@redhat.com>
6 years agoadd maxRetries to RetryingManagedNewTransactionRunner 72/66072/3
Michael Vorburger [Wed, 29 Nov 2017 18:41:31 +0000 (19:41 +0100)]
add maxRetries to RetryingManagedNewTransactionRunner

as well as the SingleTransactionDataBroker

Change-Id: I5ae21465bc8152bacdd3a9d4cbb068789c27af29
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoUse @OsgiService annotation instead of XML 48/66148/3
David Suarez [Fri, 1 Dec 2017 11:39:33 +0000 (12:39 +0100)]
Use @OsgiService annotation instead of XML

Following the DI best practices [1], the dataBroker <reference> entry
in lockmanager.xml resource file is replaced by its corresponding
annotation. Tests are changed accordingly.

[1] https://wiki.opendaylight.org/view/BestPractices/DI_Guidelines

Change-Id: I5b4d0ee3e10043f7065b4c08e7f7d2a0f51d2566
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoClean up 23/65923/3
David Suárez [Mon, 27 Nov 2017 07:41:57 +0000 (08:41 +0100)]
Clean up

- Remove deprecated
- Declare some fields as final
- Remove some redundancies

Signed-off-by: David Suárez <david.suarez.fuentes@gmail.com>
Change-Id: I03c0dc552768ae13e1f0a350e3802ac9e52446f5

6 years agoMigrate InterfaceStateListener listener to use the new Listeners FW 20/64620/5
David Suarez [Fri, 24 Nov 2017 12:06:32 +0000 (13:06 +0100)]
Migrate InterfaceStateListener listener to use the new Listeners FW

The change uses the synchronous version of the DCTL since it is already
using the JobCoordinator to offload work to other thread(s).

Change-Id: Ie0110370a5cb6fa3a0e3199c5fbd4c5401eac0bd
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoSingleTransactionDataBroker with RetryingManagedNewTransactionRunner 12/65812/5
Michael Vorburger [Tue, 21 Nov 2017 18:34:25 +0000 (19:34 +0100)]
SingleTransactionDataBroker with RetryingManagedNewTransactionRunner

built-in retries transparently handle OptimisticLockFailedException

This probably will squash a number of bugs from
https://jira.opendaylight.org/browse/NETVIRT-994?jql=text%20~%20"OptimisticLockFailedException"%20and%20status%20%3D%20Open
in one go.

Change-Id: I7a3762d9563935f66975f0e6e000609f39b05733
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoRemove DataStoreJobCoordinator 64/66064/3
Tom Pantelis [Wed, 29 Nov 2017 16:11:27 +0000 (11:11 -0500)]
Remove DataStoreJobCoordinator

Change-Id: I742fa9fa240b57cc231f97ccbbd4b0eb8dfa8a76
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoRemove CheckedConsumer from genius and use infrautils' 66/65566/3
Michael Vorburger [Wed, 15 Nov 2017 18:15:18 +0000 (19:15 +0100)]
Remove CheckedConsumer from genius and use infrautils'

The one from infrautils has better exception declaration, via generics.

Change-Id: Ie06824f7cb117d9f5069ebedd99f10dc261fb2cf
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoLockManager unlock() with RetryingManagedNewTransactionRunner 33/65233/5
Michael Vorburger [Mon, 6 Nov 2017 23:47:41 +0000 (00:47 +0100)]
LockManager unlock() with RetryingManagedNewTransactionRunner

lock() and tryLock() should ideally also be switched to
(Retrying)ManagedNewTransactionRunner and FutureRpcResults, but that's a
little trickier, because of the return true/false in readWriteLock().

This is a partial counter proposal to
https://git.opendaylight.org/gerrit/#/c/61526/ related to
https://jira.opendaylight.org/browse/GENIUS-86.  It's not a complete
counter proposal; the changes other than the retry on unlock should
still be considered.

Change-Id: Ie6588a0314828a3d1e88c741b7f8d511afb29e12
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoDrop obsolete Maven site configuration 36/65936/1
Stephen Kitt [Mon, 27 Nov 2017 17:12:33 +0000 (18:12 +0100)]
Drop obsolete Maven site configuration

See
https://lists.opendaylight.org/pipermail/odlparent-dev/2017-November/001492.html

Change-Id: I5f6e6bb6d5e45e3404793f98c098bbf44f8a2661
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoCheckstyle errors while building on windows due to windows delimiters 65/61265/4
Faseela K [Mon, 7 Aug 2017 10:48:09 +0000 (16:18 +0530)]
Checkstyle errors while building on windows due to windows delimiters

Change-Id: Ib826eca8aff9d82e69b61fa5df0d2047cd0907d4
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoUpgrading flag for full sync upgrades 99/65299/10
Josh [Wed, 8 Nov 2017 08:17:25 +0000 (10:17 +0200)]
Upgrading flag for full sync upgrades

This commit introduces a small utility that tracks whether or not
an upgrade is in progress. The purpose of this state is so that
code paths required during upgrade need not be entered during
regular application flow. The upgrade in progress state is toggled
via REST (or config xml). I tested it like this:

> curl -v -u admin:admin -X PUT -d @put-data -H \
"Content-Type: application/json" \
http://127.0.0.1:8181/restconf/config/genius-mdsalutil:config

...where the contents of the put-data file are:
{
"config": {
        "upgradeInProgress": false
         }
}

The REST call to retrieve the status is:

> curl -u admin:admin http://127.0.0.1:8181/restconf/config/genius-mdsalutil:config

Change-Id: I96d4255645b8650ee97154ff58c1afc52d1ac9f0
Signed-off-by: Josh <jhershbe@redhat.com>
6 years agoNicer (shorter) how to addErrorLogging in AlivenessProtocolHandlerLLDP 84/65384/3
Michael Vorburger [Thu, 9 Nov 2017 18:14:27 +0000 (19:14 +0100)]
Nicer (shorter) how to addErrorLogging in AlivenessProtocolHandlerLLDP

improves If342b11591f1dfe6e58fdca29b400531455669fd

using I6be0a0677659d9748e86995c8a4874e99e2c6493

Change-Id: I9b8de70bd1d3f226801c68946f1e4ceaaca8bb3a
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoRemove un-used fields, services and DEFAULT_CALLBACK in 3 ITM Workers 33/65633/4
Michael Vorburger [Thu, 16 Nov 2017 19:26:12 +0000 (20:26 +0100)]
Remove un-used fields, services and DEFAULT_CALLBACK in 3 ITM Workers

Change-Id: Icb1cedc35c98cd91e0ca22500c3a1c1cc41677f6
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoFix possible transaction leak in ItmInternalTunnelDeleteWorker 41/65641/4
Michael Vorburger [Thu, 16 Nov 2017 20:25:41 +0000 (21:25 +0100)]
Fix possible transaction leak in ItmInternalTunnelDeleteWorker

Change-Id: I0e079346c12002a55eb043b72c2f2e2c3b81f7c4
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoFix bad transaction leak in ItmInternalTunnelAddWorker 38/65638/4
Michael Vorburger [Thu, 16 Nov 2017 20:08:05 +0000 (21:08 +0100)]
Fix bad transaction leak in ItmInternalTunnelAddWorker

see https://jira.opendaylight.org/browse/NETVIRT-985

  523x transactions opened here, which are not closed:
    org.opendaylight.genius.itm.confighelpers.ItmInternalTunnelAddWorker.buildAllTunnels

Change-Id: I9c32010b64688b9cb441a2ea637e9519ba803c80
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoGENIUS-86 : LockManager fixes 26/61526/17
Kency Kurian [Fri, 11 Aug 2017 05:47:21 +0000 (11:17 +0530)]
GENIUS-86 : LockManager fixes

Root cause:

There were few AskTimeOut exception that was observed, which means the
data got eventually written to the DS. But because of the exception the
lock was being tried again to be acquired. Later, because of the first
write attempt that got succesful we were getting logs saying that the lock is
already present. This could be avoided by checking if the lock that is
already present in the DS is that of the same request.

Fix:

- For each request we can maintain an id so that if at all a timeOut
exception occurs, but eventually the write succeeds, we can identify
which request got successful by checking the owner field.
- While trying for lock, if lock is already present check for owner and
if it is the same owner then return from lock.

Change-Id: Ia2757981e92dbd48f3057c841f6ed6d710ba5bd2
Signed-off-by: Kency Kurian <kency.kurian@ericsson.com>
6 years agoFix FindBugs violations and enable enforcement in interfacemanager-api 46/65646/4
Tom Pantelis [Fri, 17 Nov 2017 00:38:45 +0000 (19:38 -0500)]
Fix FindBugs violations and enable enforcement in interfacemanager-api

Change-Id: I244fae322dce5042c72b942f0c814331e92a5d1e
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoFix FindBugs violations and enable enforcement in mdsalutil-impl 45/65645/4
Tom Pantelis [Thu, 16 Nov 2017 23:42:58 +0000 (18:42 -0500)]
Fix FindBugs violations and enable enforcement in mdsalutil-impl

Also converted FlowBatchingUtils from static to a singleton.

Change-Id: I22f9e5eb82ac3022bd8a5a754f84338ee7bab4a3
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoEnforce findbugs 18/65518/4
David Suarez [Tue, 14 Nov 2017 23:48:01 +0000 (00:48 +0100)]
Enforce findbugs

Change-Id: I4c5d2832b248e51bb4cb648875e3bc3205354f81
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoFix too long service binding INFO logs 39/65739/1
Faseela K [Mon, 20 Nov 2017 16:35:07 +0000 (22:05 +0530)]
Fix too long service binding INFO logs

Change-Id: I93860de36c332a1a8fcca0d06e5073fb2baac439
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoEnable FindBugs enforcement in alivenessmonitor-impl 44/65644/3
Tom Pantelis [Thu, 16 Nov 2017 23:00:29 +0000 (18:00 -0500)]
Enable FindBugs enforcement in alivenessmonitor-impl

No violations found!

Change-Id: I41b94f0b0c7a3d9bb7e239c45733448db80ac2f4
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoItmInternalTunnel[Add|Delete]Worker with DataBroker as field instead arg 34/65634/3
Michael Vorburger [Thu, 16 Nov 2017 19:49:13 +0000 (20:49 +0100)]
ItmInternalTunnel[Add|Delete]Worker with DataBroker as field instead arg

Change-Id: Iedb80eb07a9b7be9a377d3e904512a5ae343c1c7
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoFix FindBugs violations and enable enforcement in lockmanager-impl 43/65643/2
Tom Pantelis [Thu, 16 Nov 2017 22:49:12 +0000 (17:49 -0500)]
Fix FindBugs violations and enable enforcement in lockmanager-impl

Change-Id: I7b84acae64c5fae452903e9797c707732261b12f
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoShut down the resource batcher before cleaning up 74/65674/2
Stephen Kitt [Fri, 17 Nov 2017 15:31:22 +0000 (16:31 +0100)]
Shut down the resource batcher before cleaning up

Currently, every time the batcher runs, it retrieves the information
it needs from a map. When we unregister a resource, we remove that
information before stopping the scheduled thread; this can result in
errors being logged because the thread fires between the removal and
the scheduler shutdown.

This patch switches the order, stopping the scheduler before cleaning
up the map.

Change-Id: I9a95cbf90b0b45c9d2ffe2731700d8e4416f9c54
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoFix FindBugs violations and enable enforcement in idmanager-impl 42/65642/2
Tom Pantelis [Thu, 16 Nov 2017 22:25:54 +0000 (17:25 -0500)]
Fix FindBugs violations and enable enforcement in idmanager-impl

See in-line comments

Change-Id: I0a204876084ed15dca98c9022f8940869b3750f8
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoMigrate itm-impl module to use the infrautils JobCoordinator 79/65579/3
David Suarez [Wed, 15 Nov 2017 20:31:40 +0000 (21:31 +0100)]
Migrate itm-impl module to use the infrautils JobCoordinator

For this migration some refactoring and cleaning was needed.

Change-Id: Icf8748b8dafe338937bea4478e11a5c9d6c72435
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoDiagstatus integration for datastore service 62/65362/7
Nidhi Adhvaryu [Wed, 15 Nov 2017 12:56:47 +0000 (18:26 +0530)]
Diagstatus integration for datastore service

Change-Id: I915e13debbd3c423f978871232901cd0c7b2fa6b
Signed-off-by: Nidhi Adhvaryu <nidhi.adhvaryu@ericsson.com>
6 years agoEnforce findbugs 93/65493/5
David Suarez [Mon, 13 Nov 2017 23:10:46 +0000 (00:10 +0100)]
Enforce findbugs

Change-Id: Iaf15f28ed9c666086060612ed5dfac61974d4bf0
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoFutureRpcResults fromBuilder() without String rpcMethodName argument 47/65547/2
Michael Vorburger [Wed, 15 Nov 2017 13:38:55 +0000 (14:38 +0100)]
FutureRpcResults fromBuilder() without String rpcMethodName argument

Change-Id: I9f1ad85d237d081cf0c52aa5731740111584b658
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoEnforce findbugs 19/65519/2
David Suarez [Tue, 14 Nov 2017 23:52:31 +0000 (00:52 +0100)]
Enforce findbugs

Change-Id: Iff89f5de97c8d679bf1d3d57115783ea0d305b80
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoMigrate OvsdbNodeListener listener to use the new listeners framework 25/64625/4
David Suarez [Mon, 23 Oct 2017 22:19:55 +0000 (00:19 +0200)]
Migrate OvsdbNodeListener listener to use the new listeners framework

Change-Id: Ib4bd20052a1aaae51e247f1fef0b5279523c5f50
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoEnforce findbugs 12/65412/2
David Suarez [Fri, 10 Nov 2017 17:06:46 +0000 (18:06 +0100)]
Enforce findbugs

Change-Id: I41ecc7822885efe248b577532f895e3c7daf8f37
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoEnforce findbugs 19/65419/2
David Suarez [Fri, 10 Nov 2017 20:51:16 +0000 (21:51 +0100)]
Enforce findbugs

Change-Id: Ic95e3230ac75deda3aca32f6a4469ff62a15c047
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoAsyncDataTreeChangeListenerBase Thread with name of subclass 85/65285/3
Michael Vorburger [Tue, 7 Nov 2017 21:24:28 +0000 (22:24 +0100)]
AsyncDataTreeChangeListenerBase Thread with name of subclass

AsyncClusteredDataTreeChangeListenerBase the same

Change-Id: Id98ba50ce5e0571595d84efb6a6c0674ecec144c
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoAdapt DJC delegate to consumer RollbackCallable 38/64938/2
Stephen Kitt [Tue, 31 Oct 2017 09:54:54 +0000 (10:54 +0100)]
Adapt DJC delegate to consumer RollbackCallable

This adapts the DJC delegate to infrautils to the changes made in
https://git.opendaylight.org/gerrit/63983 to switch to a consuming
RollbackCallable.

Change-Id: Ic2b79a9f2eb2390a391f6589c80a31bcb962fc0b
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoJavaDoc for deprecated and new datastoreutils.listeners 21/65321/3
Michael Vorburger [Wed, 8 Nov 2017 15:55:30 +0000 (16:55 +0100)]
JavaDoc for deprecated and new datastoreutils.listeners

Change-Id: Ifbd018f42bc8501929bb072c0f4172ee903345c6
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoRename class LockManager to LockManagerServiceImpl and move package 91/65291/3
Michael Vorburger [Tue, 7 Nov 2017 23:51:12 +0000 (00:51 +0100)]
Rename class LockManager to LockManagerServiceImpl and move package

Change-Id: I5fd1197718aaeda5662cc331957edc301db97029
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoFix FindBugs violations and enable enforcement in interfacemanager-impl 26/64926/7
Tom Pantelis [Tue, 31 Oct 2017 05:18:07 +0000 (01:18 -0400)]
Fix FindBugs violations and enable enforcement in interfacemanager-impl

See in-line comments.

Change-Id: I92e383a5f3a8d466a4bd8ade0c2485b883cb98ba
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoEnforce findbugs 18/65418/5
David Suarez [Fri, 10 Nov 2017 18:53:24 +0000 (19:53 +0100)]
Enforce findbugs

Change-Id: I38f169cb53790414488b5f67123b581c6397f07b
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoImprove listener notification 61/65461/1
David Suarez [Sun, 12 Nov 2017 19:26:03 +0000 (20:26 +0100)]
Improve listener notification

Minor improvements:

- Introduce local variables to avoid calling getters
- All parameters of update() method annotated as @Nonnull

Change-Id: Iddbba4dd6cdef6ff697c1756a27ba859c3060968
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoTransform asynchronous listener into synchronous 23/64623/4
David Suarez [Mon, 23 Oct 2017 21:14:43 +0000 (23:14 +0200)]
Transform asynchronous listener into synchronous

This listener can be synchronous since it is already
offloading the workload through the JobCoordinator.

Change-Id: Ic9fcbca3d5665202c58d01345d47d5a3ea258457
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoDrop Karaf shell specifiers 16/65316/2
Stephen Kitt [Wed, 8 Nov 2017 14:58:13 +0000 (15:58 +0100)]
Drop Karaf shell specifiers

We no longer need to support Karaf 3, and the karaf.shell
"[3.0.0,4.1)" declarations prevent us from upgrading to Karaf 4.1
(which is coming with odlparent 3).

Change-Id: If39706d860e67dabd33ce4fc84d046075eac9a33
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoFix compiler and FindBugs warnings in mdsalutil-api 86/64986/6
Tom Pantelis [Wed, 1 Nov 2017 04:40:29 +0000 (00:40 -0400)]
Fix compiler and FindBugs warnings in mdsalutil-api

Change-Id: Ieea0fda8a6a3685619b64f28d54cf697abdf8ac5
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoFix broken build from FindBugs RV_RETURN_VALUE_IGNORED violation in RPC 79/65379/1
Michael Vorburger [Thu, 9 Nov 2017 16:49:05 +0000 (17:49 +0100)]
Fix broken build from FindBugs RV_RETURN_VALUE_IGNORED violation in RPC

Impact of https://jira.opendaylight.org/browse/MDSAL-294

Change-Id: If342b11591f1dfe6e58fdca29b400531455669fd
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoLog cleanup in InterfaceStateListener 37/65237/3
Faseela K [Tue, 7 Nov 2017 01:00:43 +0000 (06:30 +0530)]
Log cleanup in InterfaceStateListener

Change-Id: I0d14a46b8d0b997f350ebd3702806cb6bb442e1e
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoRemove usage of runOnlyInOwnerNode for InterfaceConfigListener 46/65146/4
Faseela K [Sat, 4 Nov 2017 17:36:48 +0000 (23:06 +0530)]
Remove usage of runOnlyInOwnerNode for InterfaceConfigListener

runOnlyInLeaderNode queues a DJC job to check for entity owner,
that too with a constant string. If too many interfaces are getting
configured at the same time, this will potentially slow down DJC.

Change-Id: Iee98b8d503369100e446abe158594f3bb2cc18c1
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoStub syncInstallGroup in TestIMdsalApiManager 42/65242/1
Faseela K [Tue, 7 Nov 2017 01:36:55 +0000 (07:06 +0530)]
Stub syncInstallGroup in TestIMdsalApiManager

To resolve random Elan junit failures

Caused by:
org.opendaylight.yangtools.testutils.mockito.UnstubbedMethodException:
syncInstallGroup(java.math.BigInteger dpId,
org.opendaylight.yang.gen.v1.
urn.opendaylight.group.types.rev131018.groups.Group group, long
delayTime) is not implemented in testIMdsalApiManager

Change-Id: Ie07faff86db7b4c8642d36a97c0a023e3327e794
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoRemove unnecessary log in FlowBasedServicesInterfaceStateListener 86/65186/3
Faseela K [Mon, 6 Nov 2017 17:02:18 +0000 (22:32 +0530)]
Remove unnecessary log in FlowBasedServicesInterfaceStateListener

Change-Id: I2474d000ef6921024221ae0a090f912b1f7799f5
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoFix ResourceBatchingManager NPE seen in ElanServiceTest 80/65180/1
Michael Vorburger [Mon, 6 Nov 2017 16:41:26 +0000 (17:41 +0100)]
Fix ResourceBatchingManager NPE seen in ElanServiceTest

to avoid this problem which occasionally fails ElanServiceTest:

org.opendaylight.genius.datastoreutils.testutils.infra.AutoCloseableRuntimeException:
Failed to close() class
org.opendaylight.genius.interfacemanager.renderer.ovs.utilities.BatchingUtils
(...)
Caused by: java.lang.NullPointerException
10:59:34  at
org.opendaylight.genius.utils.batching.ResourceBatchingManager.deregisterBatchableResource(ResourceBatchingManager.java:215)

Change-Id: I68d6fc5ec03e6f59e111e66659f0f0e1187511ca
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoDiagStatus integration for IFM and ITM 01/62901/23
Faseela K [Thu, 21 Sep 2017 14:13:57 +0000 (19:43 +0530)]
DiagStatus integration for IFM and ITM

Adding the implementation for registering the
service and reporting the initial status for
interface-manager and ITM.

Change-Id: I9f49f122af6708c5f8d476275d7b8aae9c0ea4af
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoInterfacemgrProvider ListenableFutures.addErrorLogging() 44/64844/6
Michael Vorburger [Sat, 28 Oct 2017 01:26:51 +0000 (03:26 +0200)]
InterfacemgrProvider ListenableFutures.addErrorLogging()

This is better than the TODO, but worse than a real full async solution.

Change-Id: I4bed4112162416801e5f6b898edc91fc0e91c03c
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoRefactor BatchingUtils/SouthboundUtils to non-static singletons 19/64919/3
Tom Pantelis [Tue, 31 Oct 2017 02:17:17 +0000 (22:17 -0400)]
Refactor BatchingUtils/SouthboundUtils to non-static singletons

Change-Id: Ic670cc9e7c1951c610b91f5f2afaf303962e1574
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoRefactor InterfaceMetaUtils to non-static 06/64906/3
Tom Pantelis [Mon, 30 Oct 2017 21:18:06 +0000 (17:18 -0400)]
Refactor InterfaceMetaUtils to non-static

Change-Id: I362505797dc12bc4281b86ad747b52448cc7d505
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoFollow-up to https://git.opendaylight.org/gerrit/#/c/64492/ 92/64892/3
Tom Pantelis [Mon, 30 Oct 2017 19:47:06 +0000 (15:47 -0400)]
Follow-up to https://git.opendaylight.org/gerrit/#/c/64492/

Addresses Michael's comments. The *Helper classes are now
singletons and inject all dependent services. In addition,
AlivenessMonitorUtils was made a singleton as well to be
consistent.

Since OvsInterfaceTopologyStateRemoveHelper has only one user
and its lone method is not large, I removed the class and
in-lined the code in InterfaceTopologyStateListener rather than
making it a singleton.

Change-Id: I450f5ad115f6c7b9926c06081ead5447f15ad496
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoGENIUS-95: clarify the NONE documentation 39/65039/3
Stephen Kitt [Thu, 2 Nov 2017 10:13:25 +0000 (11:13 +0100)]
GENIUS-95: clarify the NONE documentation

The onFailure warning only applies when NONE is used for failure
logging.

Change-Id: I7e0cbafefebce5eb4b8a1a9d7f3525a9b684713c
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoFutureRpcResults: prevent duplicate builder calls 79/65079/3
Stephen Kitt [Fri, 3 Nov 2017 08:51:45 +0000 (09:51 +0100)]
FutureRpcResults: prevent duplicate builder calls

This patch makes FutureRpcResultBuilder prevent callers from using
onSuccess(), onFailure() and withRpcErrorMessage() twice.

Change-Id: I947e1ecdc52690b65edbe77c4e878ba81f95440d
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoRemove Serializable from instructions, actions, MatchInfo 08/65008/3
Michael Vorburger [Wed, 1 Nov 2017 23:27:40 +0000 (00:27 +0100)]
Remove Serializable from instructions, actions, MatchInfo

Change-Id: I42377198b2441ff2ec7a358964a1db8dfe0f618d
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoFix warnings/cleanup in alivenessmonitor 84/64984/2
Tom Pantelis [Wed, 1 Nov 2017 01:23:10 +0000 (21:23 -0400)]
Fix warnings/cleanup in alivenessmonitor

Change-Id: I508ef8a4c54fbc2af4ae3af56755af73bf192dae
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoIdManager RPCs switched to using FutureRpcResults 50/64450/10
Michael Vorburger [Wed, 18 Oct 2017 12:52:15 +0000 (14:52 +0200)]
IdManager RPCs switched to using FutureRpcResults

This change preserves the logging of idmanager failures exactly as-is.

This first change does intentionally not yet change idmanager's behavior
and should have no impacts to users; it just simplifies the code.  (But
this means that it sort of "abuses" the FutureRpcResults, because it
does not implement real async operations returning real futures, but is
forced to be synchronous.  The idea is to raise a separate follow-up
change after this has gone in, which will make all operations async; and
there defer the sync get to the callers (or not) - after checking that
all of them really do @CheckReturnValue.)

FutureRpcResults now also logs every RPC entry point.  This is at at
level TRACE by default, but can be customized; just like success and
failure log levels can.

FutureRpcResults is also extended with a syntactic sugar short-cut
directly accepting the YANG Builder for Output often found in such RPCs.

Change-Id: If8def50e4d2e9381af045a3af725ba90e3ff7725
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoFix netvirt CSIT failure 49/65049/1
Faseela K [Thu, 2 Nov 2017 14:43:00 +0000 (20:13 +0530)]
Fix netvirt CSIT failure

Due to accidental removal of Interface Config Listener registration

Change-Id: Id43a28342f879f07a834fcf93041732064f85bda
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoGENIUS-95: Fix interfacemanager RPC error log 99/64999/4
Michael Vorburger [Wed, 1 Nov 2017 17:42:57 +0000 (18:42 +0100)]
GENIUS-95: Fix interfacemanager RPC error log

see https://jira.opendaylight.org/browse/GENIUS-95 for more background

Change-Id: Icf35e0ebbf29895e6017f109e6a5a55f5bbe4a53
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoRemove ClusteringUtils and EntityOwnerUtils 29/64829/2
Tom Pantelis [Fri, 27 Oct 2017 21:02:39 +0000 (17:02 -0400)]
Remove ClusteringUtils and EntityOwnerUtils

All users have been migrated to EntityOwnershipUtils so these
classes can be removed to eliminate the last references to the
controller EOS APIs.

Change-Id: I84ea8bdd780f8ca4f505a5dfb09b962797d4269b
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoFix the listeners registration process 54/64954/4
David Suarez [Tue, 31 Oct 2017 15:36:19 +0000 (16:36 +0100)]
Fix the listeners registration process

It is a bad practice to pass the 'this' out of a constructor, specially
in multi-threading environments, since the object is not yet fully
constructed. To fix that, we have added a register() method that will be
invoked by BluePrint just after the constructor; both the register() and
close() methods need to be declared as 'public' and not 'final',
otherwise BluePrint will not be able to call them.

The shutdown() method has been removed in favour of a simple close().

Change-Id: I7f63f8041b583fa266f49cebe9ad8aab672bae1f
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoRefactor InterfaceManagerCommonUtils to non-static 44/64544/9
Tom Pantelis [Thu, 19 Oct 2017 20:35:56 +0000 (16:35 -0400)]
Refactor InterfaceManagerCommonUtils to non-static

Change-Id: I17fe65b53cb887056a1be58c8cb715885057cd2d
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoCleanup in idmanager-impl 34/64834/4
Tom Pantelis [Fri, 27 Oct 2017 22:46:59 +0000 (18:46 -0400)]
Cleanup in idmanager-impl

- Change public Map fields, allocatedIdMap and releaseIdLatchMap, in
IdUtils to private and added methods to access them.

- In ReleasedIdHolder, delayedEntries is expected to be thread-safe and
is initialized to a CopyOnWriteArrayList however it can be set externally
via setDelayedEntries with no knowledge if the passed List is thread-safe.
It turns out the 3 callers do pass in a CopyOnWriteArrayList however it
shouldn't rely on callers doing the right thing so I changed it to create
a new CopyOnWriteArrayList from the past List to guarantee it. This also
ensures delayedEntries is never null.

Change-Id: I792012ecb218609fb40e1f9efb78dc9d077d2d05
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
6 years agoRemove deploy-site.xml 99/64899/2
Thanh Ha [Mon, 30 Oct 2017 21:05:16 +0000 (17:05 -0400)]
Remove deploy-site.xml

With the javadoc jobs now available to generate javadoc it is time to
remove the maven-sites and related files.

Change-Id: I7761c1efaf216cacf87d909f9a38ec2b265fda66
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>