mdsal.git
9 years agoMerge "Add exists method on DOMStoreReadTransaction and DOMDataReadTransaction"
Tom Pantelis [Wed, 13 Aug 2014 12:12:10 +0000 (12:12 +0000)]
Merge "Add exists method on DOMStoreReadTransaction and DOMDataReadTransaction"

9 years agoAdd exists method on DOMStoreReadTransaction and DOMDataReadTransaction
Moiz Raja [Sun, 10 Aug 2014 23:18:33 +0000 (16:18 -0700)]
Add exists method on DOMStoreReadTransaction and DOMDataReadTransaction

Introducing this API does not impact clients as it is mostly internal.

One reason for adding this API is because of ensureParentsByMerge used in a couple of places
which keeps checking if a parent node exists by reading a node to figure out if it exists. This is
fine for the InMemoryDataStore but it can be terrible in a distributed data store where the shard
which contains the data is remote. All sorts of overhead is associated with a remote read including
serialization which can actually be pretty expensive.

Change-Id: Ib5be5f6dc60be683d7a04c81dad08c56cd5681f4
Signed-off-by: Moiz Raja <moraja@cisco.com>
9 years agoMerge "Bug 1430: Off-load notifications from single commit thread"
Devin Avery [Mon, 11 Aug 2014 15:28:26 +0000 (15:28 +0000)]
Merge "Bug 1430: Off-load notifications from single commit thread"

9 years agoMerge "BUG-1511: add FIXME markers"
Ed Warnicke [Mon, 11 Aug 2014 13:01:37 +0000 (13:01 +0000)]
Merge "BUG-1511: add FIXME markers"

9 years agoBUG-1511: add FIXME markers
Robert Varga [Sat, 9 Aug 2014 10:38:17 +0000 (12:38 +0200)]
BUG-1511: add FIXME markers

Fixes a simple typo and drops marker FIXMEs for future implementation.

Change-Id: Ic4f67afd978f4bb43314d161afcfe1e56c831be6
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoMerge "BUG-1495: fail future when no local RPC is found"
Tony Tkacik [Fri, 8 Aug 2014 07:19:52 +0000 (07:19 +0000)]
Merge "BUG-1495: fail future when no local RPC is found"

9 years agoMerge "BUG-868: migrate ListenerRegistry"
Tony Tkacik [Thu, 7 Aug 2014 20:17:21 +0000 (20:17 +0000)]
Merge "BUG-868: migrate ListenerRegistry"

9 years agoMerge "BUG-1493: do not instantiate HashSet"
Tony Tkacik [Thu, 7 Aug 2014 19:57:53 +0000 (19:57 +0000)]
Merge "BUG-1493: do not instantiate HashSet"

9 years agoBUG-1495: fail future when no local RPC is found
Robert Varga [Thu, 7 Aug 2014 12:15:45 +0000 (14:15 +0200)]
BUG-1495: fail future when no local RPC is found

Instead of checking state, we return a failed future, which will have a
RpcImplementationUnavailableException as its cause. The current call
site is the remote broker, which is the provider of last resort and it
throws it when it has no foreign system available.

Change-Id: Ib9d8534ca75e60f1867a7c275ee653a70dbd7a00
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoBUG-1493: do not instantiate HashSet
Robert Varga [Wed, 6 Aug 2014 18:01:24 +0000 (20:01 +0200)]
BUG-1493: do not instantiate HashSet

This HashSet is used to track processed nodes -- but the parent node is
already giving us a method, which checks if it contains a particular
node ID. Let's use that instead of maintaining the set.

Based on traces, this should speed the datastore up by about 4.8%.

Change-Id: I09e1135f51c8967b9fe8c520a0e166918472de7d
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoBug 1430: Off-load notifications from single commit thread
tpantelis [Tue, 29 Jul 2014 10:42:14 +0000 (06:42 -0400)]
Bug 1430: Off-load notifications from single commit thread

Modified the InMemoryDOMDataStore to use the new
QueuedNotificationManager class added to yangtools common util for
DataChangeListener notifications.

Modified DOMDataCommitCoordinatorImpl's ListeningExecutorService to one
that off-loads ListenableFuture Runnable callbacks on a separate
executor.

Change-Id: I31f2fb002131c6d91b205d33255dd1bbc6433d9b
Signed-off-by: tpantelis <tpanteli@brocade.com>
9 years agoMerge "Bug 1386: Avoid commit deadlock"
Tony Tkacik [Wed, 6 Aug 2014 17:05:10 +0000 (17:05 +0000)]
Merge "Bug 1386: Avoid commit deadlock"

9 years agoMerge "Bug 1418 - onDataChange notification is not returning any data to the getCrea...
Tony Tkacik [Wed, 6 Aug 2014 09:25:10 +0000 (09:25 +0000)]
Merge "Bug 1418 - onDataChange notification is not returning any data to  the getCreatedData and getModifiedData function calls. Data change  notification does not seem to work."

9 years agoBug 1418 - onDataChange notification is not returning any data to
Jan Hajnar [Tue, 5 Aug 2014 10:25:44 +0000 (12:25 +0200)]
Bug 1418 - onDataChange notification is not returning any data to
the getCreatedData and getModifiedData function calls. Data change
notification does not seem to work.

* Changed normalized to binding data change event translation call to
include event listener path. This path is then used to decode leaf or
mixin only augmentation because it can't be injected through children.
* Added verification tests.

Change-Id: Ia9d936f17b30b94fe4878e343cff7babb8d29d0f
Signed-off-by: Jan Hajnar <jhajnar@cisco.com>
9 years agoBug 1386: Avoid commit deadlock
tpantelis [Mon, 14 Jul 2014 12:01:16 +0000 (08:01 -0400)]
Bug 1386: Avoid commit deadlock

Changed the executor in DOMDataCommitCoordinatorImpl to a new
class DeadlockDetectingListeningExecutorService added to yangtools util.
This detects deadlock if another blocking commit is done by a client
notified from the single commit thread.

Change-Id: Icdc2b835fd336a1bbc37953828126b57253929c0
Signed-off-by: tpantelis <tpanteli@brocade.com>
9 years agoBUG-868: migrate ListenerRegistry
Robert Varga [Tue, 5 Aug 2014 07:16:49 +0000 (09:16 +0200)]
BUG-868: migrate ListenerRegistry

yangtools.concepts.util is being migrated to yangtools.util, so adjust
users to lower the number of warnings.

Change-Id: I652f0131a59fdb2481d779c181861f7ed7674b03
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoMerge "Bug 1392: Change ReadTransaction#read to return CheckedFuture"
Tony Tkacik [Sun, 3 Aug 2014 18:17:46 +0000 (18:17 +0000)]
Merge "Bug 1392: Change ReadTransaction#read to return CheckedFuture"

9 years agoMerge "Bug 1333: Regression Test suite."
Ed Warnicke [Fri, 1 Aug 2014 10:25:31 +0000 (10:25 +0000)]
Merge "Bug 1333: Regression Test suite."

9 years agoMerge "Bug 1369: Use separate single threadpool for data operations on binding mountp...
Ed Warnicke [Fri, 1 Aug 2014 09:35:31 +0000 (09:35 +0000)]
Merge "Bug 1369: Use separate single threadpool for data operations on binding mountpoint."

9 years agoMerge "BUG-868: Migrate to SchemaContextListener"
Tony Tkacik [Fri, 1 Aug 2014 08:00:43 +0000 (08:00 +0000)]
Merge "BUG-868: Migrate to SchemaContextListener"

9 years agoBUG-868: Migrate to SchemaContextListener
Robert Varga [Sun, 9 Mar 2014 18:34:51 +0000 (19:34 +0100)]
BUG-868: Migrate to SchemaContextListener

SchemaServiceListener is deprecated, SchemaContextListener is its new
name. The class hierarchy allows for incremental migration.

Change-Id: I15d495d805eb7a08c3bcd3ab0cf8b5a8d2797db5
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoBUG-1228: Optimize AbstractForwardedDataBroker a bit
Robert Varga [Wed, 30 Jul 2014 18:42:00 +0000 (20:42 +0200)]
BUG-1228: Optimize AbstractForwardedDataBroker a bit

Profiling OFP with datastore backend has revealed that we spend about 9%
of CPU in AbstractForwardedDataBroker$1.compare(). This turns out to be
a comparator, which compares two YangInstanceIdentifiers by their path
length -- and to do that it iterates fully through both of them.

We perform three optimizations:
- make the comparator itself shareable, so we do not instantiate it
  (6000 during the profiling run)
- make the .sortedEntries() smart about empty maps
- teach the comparator to abort iteration as soon as the result is
  known

At the same time we import YangInstanceIdentifier, making the code a bit
more readable.

Change-Id: I38d3629ab33dac9e2e29b092e3a89d0821d09b07
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoBug 1392: Change ReadTransaction#read to return CheckedFuture
tpantelis [Mon, 14 Jul 2014 16:35:57 +0000 (12:35 -0400)]
Bug 1392: Change ReadTransaction#read to return CheckedFuture

Added a ReadFailedException that is used with the CheckedFuture.
Moved the RpcError list from TransactionCommitFailedException to a new base
OperationFailedException in yangtools and also derived ReadFailedException from
OperationFailedException.

Added a static MAPPER in ReadFailedException class using the new generalized base
ExceptionMapper class in yangtools. Also derived
TransactionCommitFailedExceptionMapper from ExceptionMapper.

Modified uses of Futures#makeChecked in the read Tx and write Tx submit
to use the new MappingCheckedFuture class in yangtools (see
https://git.opendaylight.org/gerrit/#/c/9240/ for details).

Change-Id: I5c4f717f0b8664b7d39c1e6f0366525f04e6634d
Signed-off-by: tpantelis <tpanteli@brocade.com>
9 years agoBUG-1092: adjust to YangInstanceIdentifier
Robert Varga [Tue, 29 Jul 2014 10:15:49 +0000 (12:15 +0200)]
BUG-1092: adjust to YangInstanceIdentifier

This is a compation to I1e30a0df93d8bfb891d047c58abcb117d4006c76,
adjusting the components to use the new name.

Change-Id: I615763240581e850f7752f82e44d752c8fceb169
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoMerge changes I1d768b2b,I9302e88a
Tony Tkacik [Tue, 29 Jul 2014 10:48:46 +0000 (10:48 +0000)]
Merge changes I1d768b2b,I9302e88a

* changes:
  Fix identity-ref serialization in netconf.
  BUG-1083 Netconf connector rework sal facade.

9 years agoMerge changes Ifd28301d,I38220acb,I9bad24df
Tony Tkacik [Tue, 29 Jul 2014 09:29:39 +0000 (09:29 +0000)]
Merge changes Ifd28301d,I38220acb,I9bad24df

* changes:
  WIP: Backwards compatible MountPointService
  Fix children element lookup in XmlElement
  Fix config attributes with same names for different modules.

9 years agoBUG-1083 Netconf connector rework sal facade.
Maros Marsalek [Tue, 22 Jul 2014 13:02:25 +0000 (15:02 +0200)]
BUG-1083 Netconf connector rework sal facade.

Change-Id: I9302e88ac3e831e2966e2baec9493a03e0a96be4
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
9 years agoWIP: Backwards compatible MountPointService
Maros Marsalek [Fri, 18 Jul 2014 12:29:39 +0000 (14:29 +0200)]
WIP: Backwards compatible MountPointService

Change-Id: Ifd28301ddd08d4edba93dba04a4d38c2ee13078a
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
9 years agoFix config attributes with same names for different modules.
Maros Marsalek [Thu, 24 Jul 2014 15:09:53 +0000 (17:09 +0200)]
Fix config attributes with same names for different modules.

Yang does not allow attributes in different cases to have the same name.
In yang modules for config, the configuration is located in cases and if 2 cases in same yang module contain child with same name, the transformation of data from CompositeNode to NormalizedNode

NOTE: This might break bgpcep and SP distribution, check.

Change-Id: I9bad24df9ac149da74b745ff648c72345e33deb1
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
9 years agoMerge "BUG-432: migrate users of Registration as appropriate"
Tony Tkacik [Mon, 28 Jul 2014 12:24:45 +0000 (12:24 +0000)]
Merge "BUG-432: migrate users of Registration as appropriate"

9 years agoMerge "RPC registrations should not throw"
Tony Tkacik [Mon, 28 Jul 2014 12:04:31 +0000 (12:04 +0000)]
Merge "RPC registrations should not throw"

9 years agoMerge "Deprecating unused get{Provider,Consumer} Functionality"
Tony Tkacik [Mon, 28 Jul 2014 09:01:25 +0000 (09:01 +0000)]
Merge "Deprecating unused get{Provider,Consumer} Functionality"

9 years agoMerge "Removed BundleContext from Broker.register{Consumer,Provider} (Part 2)"
Tony Tkacik [Mon, 28 Jul 2014 09:01:02 +0000 (09:01 +0000)]
Merge "Removed BundleContext from Broker.register{Consumer,Provider} (Part 2)"

9 years agoMerge "Removed BundleContext from Broker.register{Consumer,Provider}"
Tony Tkacik [Mon, 28 Jul 2014 09:00:21 +0000 (09:00 +0000)]
Merge "Removed BundleContext from Broker.register{Consumer,Provider}"

9 years agoMerge "Allow getChildNodes() to become a Collection"
Tony Tkacik [Mon, 28 Jul 2014 08:56:15 +0000 (08:56 +0000)]
Merge "Allow getChildNodes() to become a Collection"

9 years agoMerge "BUG-1381: do not use JavassistUtils.getLock()"
Tony Tkacik [Mon, 28 Jul 2014 08:53:03 +0000 (08:53 +0000)]
Merge "BUG-1381: do not use JavassistUtils.getLock()"

9 years agoBUG-432: migrate users of Registration as appropriate
Robert Varga [Sun, 27 Jul 2014 20:27:21 +0000 (22:27 +0200)]
BUG-432: migrate users of Registration as appropriate

This patch adjust all users to the non-generic nator of Registration,
plus migrates a few to ListenerRegistration.

Change-Id: I69c1c61890f866d24a4b50e685bddba32bac7815
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoRPC registrations should not throw
Robert Varga [Fri, 25 Jul 2014 12:39:27 +0000 (14:39 +0200)]
RPC registrations should not throw

Change-Id: I7f7f13ea7bdce3db5e833e3532c2e5db873daf74
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoAllow getChildNodes() to become a Collection
Robert Varga [Sat, 26 Jul 2014 04:06:52 +0000 (06:06 +0200)]
Allow getChildNodes() to become a Collection

Preparatory patch for yangtools change -- getChildNodes() will start
returning a Collection, not a Set.

Change-Id: Ie7255757e3f48465e3acd9e65764f1b79a3a9511
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoBUG-1381: do not use JavassistUtils.getLock()
Robert Varga [Fri, 25 Jul 2014 13:33:05 +0000 (15:33 +0200)]
BUG-1381: do not use JavassistUtils.getLock()

We have it now synchronized through the instance, so there's no need for
getLock().

Change-Id: I3e962f284132b376f77e9e2665b3fbb47f246514
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoDeprecating unused get{Provider,Consumer} Functionality
Ed Warnicke [Fri, 25 Jul 2014 12:21:31 +0000 (07:21 -0500)]
Deprecating unused get{Provider,Consumer} Functionality

Provider.getProviderFunctionality
Consumer.getConsumerFunctionality
interface ProviderFunctionality
interface ConsumerFunctionality

are unused.  They should go away, so this patch marks
them as deprecated.

Change-Id: Icfcbf9f4cfed0186c720eab26405894183b9009f
Signed-off-by: Ed Warnicke <eaw@cisco.com>
9 years agoRemoved BundleContext from Broker.register{Consumer,Provider} (Part 2)
Ed Warnicke [Fri, 25 Jul 2014 12:05:21 +0000 (07:05 -0500)]
Removed BundleContext from Broker.register{Consumer,Provider} (Part 2)

Moved the bodies of the methods around to make the deprecated
methods just call throughs to the new methods.

Removed extra argument from private method newSessionFor

Change-Id: I748662491e6670262ecfad4122bcc7a9f831107d
Signed-off-by: Ed Warnicke <eaw@cisco.com>
9 years agoRemoved BundleContext from Broker.register{Consumer,Provider}
Ed Warnicke [Fri, 25 Jul 2014 12:00:14 +0000 (07:00 -0500)]
Removed BundleContext from Broker.register{Consumer,Provider}

Don't freak out... the old methods are still there, just
deprecated.

Change-Id: I6f37af7d93948bbf0d3b23635c73803645028ec7
Signed-off-by: Ed Warnicke <eaw@cisco.com>
9 years agoMerge "BUG-1381: make users of JavassistUtils.getLock synchronized properly"
Tony Tkacik [Fri, 25 Jul 2014 11:17:52 +0000 (11:17 +0000)]
Merge "BUG-1381: make users of JavassistUtils.getLock synchronized properly"

9 years agoMerge "Override TransactionFactor method in DataBroker to return correct TransactionC...
Tony Tkacik [Fri, 25 Jul 2014 11:16:05 +0000 (11:16 +0000)]
Merge "Override TransactionFactor method in DataBroker to return correct TransactionChain."

9 years agoMake DOMMountPointService listenable
Maros Marsalek [Thu, 24 Jul 2014 11:43:09 +0000 (13:43 +0200)]
Make DOMMountPointService listenable

Change-Id: Ic44a4bf214f6f6a6d653627b6a62ab2f47bd9963
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
9 years agoMerge "Bug 1280: Added option to automaticly create parents"
Tom Pantelis [Thu, 24 Jul 2014 19:44:19 +0000 (19:44 +0000)]
Merge "Bug 1280: Added option to automaticly create parents"

9 years agoBUG-1381: make users of JavassistUtils.getLock synchronized properly
Robert Varga [Wed, 16 Jul 2014 21:07:27 +0000 (23:07 +0200)]
BUG-1381: make users of JavassistUtils.getLock synchronized properly

As a transition period, use both locking schemes. Once the initial
patches are in, we can then remove the use of getLock().

Change-Id: Ibf4c0ea9f420d81dfe74f7b0c5479f01b45a8d2d
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoOverride TransactionFactor method in DataBroker to return correct TransactionChain.
Maros Marsalek [Thu, 24 Jul 2014 09:30:11 +0000 (11:30 +0200)]
Override TransactionFactor method in DataBroker to return correct TransactionChain.

Change-Id: Ib86159c8faa8ddd729b9abc69ea7708fd4b086f3
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
9 years agoMerge "Bug 279, 1390: Used Guava Cache r for lazy-loading of RPC Routers"
Tom Pantelis [Wed, 23 Jul 2014 14:30:44 +0000 (14:30 +0000)]
Merge "Bug 279, 1390: Used Guava Cache r for lazy-loading of RPC Routers"

9 years agoMerge "NormalizedNode Mount APIs."
Tony Tkacik [Wed, 23 Jul 2014 05:41:39 +0000 (05:41 +0000)]
Merge "NormalizedNode Mount APIs."

9 years agoNormalizedNode Mount APIs.
Maros Marsalek [Fri, 18 Jul 2014 12:28:53 +0000 (14:28 +0200)]
NormalizedNode Mount APIs.

Change-Id: Iee3b7101642bde9aa1a38150ee2a62b84c3de1fb
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
9 years agoMerge "API Usability: Introduced type capture for Transaction Factory"
Devin Avery [Tue, 22 Jul 2014 13:43:37 +0000 (13:43 +0000)]
Merge "API Usability: Introduced type capture for Transaction Factory"

9 years agoMerge "Change put/merge methods to be type-safe in WriteTransaction"
Devin Avery [Mon, 21 Jul 2014 14:16:31 +0000 (14:16 +0000)]
Merge "Change put/merge methods to be type-safe in WriteTransaction"

9 years agoBug 1333: Regression Test suite.
Tony Tkacik [Thu, 10 Jul 2014 15:24:53 +0000 (17:24 +0200)]
Bug 1333: Regression Test suite.

Change-Id: Ib7e95b73bfb6a48f08b008427ac4d9d25dfb8355
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoChange put/merge methods to be type-safe in WriteTransaction
tpantelis [Sat, 12 Jul 2014 10:53:46 +0000 (06:53 -0400)]
Change put/merge methods to be type-safe in WriteTransaction

Removed declaration of put/merge methods from the common
AsyncWriteTransaction interface.

Defined put/merge methods in the derived Binding and DOM interfaces.
The Binding methods were made type-safe.

Javadoc usage/examples for the methods was put into the
AsyncWriteTransaction class docs and is linked to by the derived
interfaces.

This change is source-code compatible - no client code needs to change
(unless a client actually is incompatible path and data).

Change-Id: I779f6477f1c98e299c5d559043da612be97bfbe6
Signed-off-by: tpantelis <tpanteli@brocade.com>
9 years agoBug 1352: Added regression test to InMemory Data Store.
Tony Tkacik [Fri, 11 Jul 2014 09:33:51 +0000 (11:33 +0200)]
Bug 1352: Added regression test to InMemory Data Store.

Change-Id: Ia3a4e332c275d6dfdf9dafd2dfc433de15dbcb6f
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoMerge "Bug 1362: New AsyncWriteTransaction#submit method"
Tony Tkacik [Mon, 21 Jul 2014 09:11:50 +0000 (09:11 +0000)]
Merge "Bug 1362: New AsyncWriteTransaction#submit method"

9 years agoMerge "Removed unused private implementation class"
Devin Avery [Fri, 18 Jul 2014 12:01:36 +0000 (12:01 +0000)]
Merge "Removed unused private implementation class"

9 years agoMerge "Changed read to be type-safe in ReadTransaction"
Devin Avery [Fri, 18 Jul 2014 12:00:29 +0000 (12:00 +0000)]
Merge "Changed read to be type-safe in ReadTransaction"

9 years agoMerge "Improve RpcProviderRegistry loading"
Tony Tkacik [Fri, 18 Jul 2014 08:45:04 +0000 (08:45 +0000)]
Merge "Improve RpcProviderRegistry loading"

9 years agoMerge "Added SingleThreadedExecutors to data store instance."
Devin Avery [Thu, 17 Jul 2014 14:17:35 +0000 (14:17 +0000)]
Merge "Added SingleThreadedExecutors to data store instance."

9 years agoImprove RpcProviderRegistry loading
Robert Varga [Wed, 16 Jul 2014 20:22:42 +0000 (22:22 +0200)]
Improve RpcProviderRegistry loading

Profiling monitor usage at startup has shown that we spend about 19s of
CPU time over ~50 second bootup waiting in getRpcService(). Instead of a
home-grown cache, let's use a guava Loading cache, which allows us to
concurrently instantiate multiple rpc services at the same time.

Change-Id: Ieaaedd7da61cd0b03b05a44ee2a6285bc8eb46ac
Signed-off-by: Robert Varga <rovarga@cisco.com>
9 years agoMerge "Bug 1225: Fixed bug in registration of default RPC implementation."
Devin Avery [Wed, 16 Jul 2014 19:07:04 +0000 (19:07 +0000)]
Merge "Bug 1225: Fixed bug in registration of default RPC implementation."

9 years agoMerge "Deprecated Rpcs and RpcErrors helper classes"
Devin Avery [Wed, 16 Jul 2014 18:31:51 +0000 (18:31 +0000)]
Merge "Deprecated Rpcs and RpcErrors helper classes"

9 years agoMerge "Bug 1093: Extracted static inner classes from SchemaAwareRpcBroker."
Devin Avery [Wed, 16 Jul 2014 17:58:46 +0000 (17:58 +0000)]
Merge "Bug 1093: Extracted static inner classes from SchemaAwareRpcBroker."

9 years agoAdded SingleThreadedExecutors to data store instance.
Tony Tkacik [Wed, 16 Jul 2014 17:31:44 +0000 (19:31 +0200)]
Added SingleThreadedExecutors to data store instance.

Change-Id: I18900f4db121fe7728ecd3c0aae90cbd6e83fee2
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoRemoved unused private implementation class
Tony Tkacik [Wed, 16 Jul 2014 14:52:25 +0000 (16:52 +0200)]
Removed unused private implementation class

Change-Id: Ie17b82e8f057f8d0da40cd93229149125f668e71
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoBug 1093: Extracted static inner classes from SchemaAwareRpcBroker.
Tony Tkacik [Wed, 16 Jul 2014 10:58:21 +0000 (12:58 +0200)]
Bug 1093: Extracted static inner classes from SchemaAwareRpcBroker.

Change-Id: I68bc1d3e4a3b279877e5ece19bcc9e1bfcd0c3dc
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoAPI Usability: Introduced type capture for Transaction Factory
Tony Tkacik [Wed, 16 Jul 2014 12:22:52 +0000 (14:22 +0200)]
API Usability: Introduced type capture for Transaction Factory

Change-Id: If74733ce5464e294522abf79f9433849466a1f56
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoBug 1369: Use separate single threadpool for data operations on binding mountpoint.
Tony Tkacik [Wed, 16 Jul 2014 11:12:31 +0000 (13:12 +0200)]
Bug 1369: Use separate single threadpool for data operations on binding mountpoint.

Change-Id: I195188c1353df4696e8b16de699e5379b7bdc511
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoBug 1225: Fixed bug in registration of default RPC implementation.
Tony Tkacik [Tue, 15 Jul 2014 16:17:38 +0000 (18:17 +0200)]
Bug 1225: Fixed bug in registration of default RPC implementation.

Change-Id: I302bd0c9aa75e844864d0b7dd692c1d331a563ed
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoFixed class-cast when Netconf registered RPC implementations.
Tony Tkacik [Tue, 15 Jul 2014 16:43:02 +0000 (18:43 +0200)]
Fixed class-cast when Netconf registered RPC implementations.

Change-Id: I0803f7ec0d23bcf195c2fbac49e916c4f30110e1
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoMerge "Bug 1303: BindingIndependentConnector splitted."
Tony Tkacik [Tue, 15 Jul 2014 10:35:27 +0000 (10:35 +0000)]
Merge "Bug 1303: BindingIndependentConnector splitted."

9 years agoMerge "Bug 1125: Added regression test"
Tony Tkacik [Tue, 15 Jul 2014 08:56:21 +0000 (08:56 +0000)]
Merge "Bug 1125: Added regression test"

9 years agoBug 1280: Added option to automaticly create parents
Tony Tkacik [Wed, 23 Jul 2014 10:11:06 +0000 (12:11 +0200)]
Bug 1280: Added option to automaticly create parents

Introduced additional variation of put and merge
which allows user to specify if parents nodes
are to be created. Default behaviour is to not
create parent nodes, but users still have
explicit API for creating them if necessary.

Updated documentation accordingly and added note
that auto-create of parents may potentially
create garbage in data store.

Change-Id: Id4a88b015e05b4717e9c393ddf821c7f93e7e541
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoBug 279, 1390: Used Guava Cache r for lazy-loading of RPC Routers
Tony Tkacik [Tue, 22 Jul 2014 08:39:09 +0000 (10:39 +0200)]
Bug 279, 1390: Used Guava Cache r for lazy-loading of RPC Routers

Used Guava Cache for lazy-loading of RPC Routers, which
is thread safe. Guava Loading Cache was not suitable
since we needed to know when RPC was created outside
of Guava load() callback.

Introduced new internal exception type RpcIsNotRoutedException
which is thrown when service type is not routed.

Change-Id: I96b6ff68e300596aa837e21690f8cb92da12112c
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoBug 1125: Added regression test
Tony Tkacik [Mon, 14 Jul 2014 11:40:13 +0000 (13:40 +0200)]
Bug 1125: Added regression test

Change-Id: I455134dc95b8af4f4f0c79b11e55fd01b58731e4
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoBug 1362: New AsyncWriteTransaction#submit method
tpantelis [Fri, 11 Jul 2014 06:21:25 +0000 (02:21 -0400)]
Bug 1362: New AsyncWriteTransaction#submit method

- Added new AsyncWriteTransaction#submit and deprecated AsyncWriteTransaction#commit.

- Modified unit tests and current code (in the toaster) in the
  controller using commit.

Change-Id: I92317d01427bf442def8e7217ccb13313a0fd229
Signed-off-by: tpantelis <tpanteli@brocade.com>
9 years agoChanged read to be type-safe in ReadTransaction
Tony Tkacik [Mon, 7 Jul 2014 12:39:49 +0000 (14:39 +0200)]
Changed read to be type-safe in ReadTransaction

Removed declaration of read method from common
superinterface, which is now only marker interface
for read capabilities.

Defined read method in specialization of interface
for Binding and DOM interfaces, which makes
use of specific features of format.

This change is source-code compatible
and users of read method needs to update
their code appropriatelly as shown in
Toaster example.

Change-Id: I8c783fc5f276722a5a762eea7c769c3f54a31855
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoDeprecated Rpcs and RpcErrors helper classes
tpantelis [Thu, 10 Jul 2014 06:49:07 +0000 (02:49 -0400)]
Deprecated Rpcs and RpcErrors helper classes

With the new RpcResultBuilder class, we can deprecate the Rpcs and
RpcErrors classes.

Also migrate all uses of the deprecated classes to RpcResultBuilder in
the controller code.

Change-Id: I86408bba0ce19e70c7d7a41555e94052e54e93f8
Signed-off-by: tpantelis <tpanteli@brocade.com>
9 years agoBug 1303: BindingIndependentConnector splitted.
Lukas Sedlak [Thu, 10 Jul 2014 08:16:46 +0000 (10:16 +0200)]
Bug 1303: BindingIndependentConnector splitted.

Inner private classes in BindingIndependentConnector extracted into standalone package protected classes.
Fixed bug in BindingToDomTransaction class - domOpenedTransactions management.

Change-Id: I69173db2bf4e6746eac4fa67c57f65095f45c603
Signed-off-by: Lukas Sedlak <lsedlak@cisco.com>
9 years agoBug 1225: Added DataBroker and DataChangeListener test suite.
Tony Tkacik [Thu, 10 Jul 2014 15:24:07 +0000 (17:24 +0200)]
Bug 1225: Added DataBroker and DataChangeListener test suite.

Change-Id: I53a06845024936253f576e5095b3d00c15a47e99
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoBug 1284: Fixed serialization of Augment Instance Identifier
Tony Tkacik [Wed, 9 Jul 2014 15:42:59 +0000 (17:42 +0200)]
Bug 1284: Fixed serialization of Augment Instance Identifier

Instance Identifier pointing to Augmentation, which pointed
to augmentation with leafs only, was not properly
serialized to DOM Instance Identifier and this caused
subscription for parent node.

Instance Identifier Codec was updated to detect
this case and use different algorithm to serialize
last argument.

Change-Id: Ie47ec7a5ebc86e10a7e1b3ddbc8921bf089466b2
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoMerge "Bug 1223: Cleaned up BindingTestContext from unsupported components."
Ed Warnicke [Fri, 11 Jul 2014 09:35:26 +0000 (09:35 +0000)]
Merge "Bug 1223: Cleaned up BindingTestContext from unsupported components."

9 years agoMerge "Clarified the AsyncDataChangeEvent message - stated you must not block the...
Tony Tkacik [Fri, 11 Jul 2014 07:38:16 +0000 (07:38 +0000)]
Merge "Clarified the AsyncDataChangeEvent message - stated you must not block the thread."

9 years agoClarified the AsyncDataChangeEvent message - stated you must not block the thread.
Devin Avery [Thu, 10 Jul 2014 18:05:43 +0000 (14:05 -0400)]
Clarified the AsyncDataChangeEvent message - stated you must not block the thread.

Change-Id: I311b7c37f5848beb351d59fc830798d10302a3bb
Signed-off-by: Devin Avery <devin.avery@brocade.com>
9 years agoBug 1223: Cleaned up BindingTestContext from unsupported components.
Tony Tkacik [Wed, 9 Jul 2014 10:47:28 +0000 (12:47 +0200)]
Bug 1223: Cleaned up BindingTestContext from unsupported components.

Change-Id: I26123a2a9d56c85dcc329fda0727e7e3e664c829
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoMerge "Improve documentation of BindingAware{Provider,Consumer}"
Tony Tkacik [Wed, 9 Jul 2014 15:09:54 +0000 (15:09 +0000)]
Merge "Improve documentation of BindingAware{Provider,Consumer}"

9 years agoBug 1339: Added doublecheck for RPC registration
Lukas Sedlak [Wed, 9 Jul 2014 07:21:35 +0000 (09:21 +0200)]
Bug 1339: Added doublecheck for RPC registration

Change-Id: I786934b6cc690817688e60fd3d422293f37056be
Signed-off-by: Lukas Sedlak <lsedlak@cisco.com>
9 years agoMerge "Bug 1224, Bug 1221: Added Test case scenarios for Data Change Events."
Ed Warnicke [Tue, 8 Jul 2014 18:45:45 +0000 (18:45 +0000)]
Merge "Bug 1224, Bug 1221: Added Test case scenarios for Data Change Events."

9 years agoMerge "Bug 1328: Improved argument checks in generated RPC Router"
Ed Warnicke [Tue, 8 Jul 2014 16:51:05 +0000 (16:51 +0000)]
Merge "Bug 1328: Improved argument checks in generated RPC Router"

9 years agoBug 1328: Improved argument checks in generated RPC Router
Tony Tkacik [Tue, 8 Jul 2014 07:43:24 +0000 (09:43 +0200)]
Bug 1328: Improved argument checks in generated RPC Router

Change-Id: I5e4bd55a4a31b4b671b44163286c6b3ebe7707bf
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoBug 1224, Bug 1221: Added Test case scenarios for Data Change Events.
Tony Tkacik [Tue, 8 Jul 2014 15:29:26 +0000 (17:29 +0200)]
Bug 1224, Bug 1221: Added Test case scenarios for Data Change Events.

Added suite of test-cases which tests Data Change Events
and their contents for various combination of
  - initial state of data store
  - performed operation (e.g. write sibling, child, delete child)
  - various level of data change listener
    eg. (/top or /top/top-level-list/top-level-list[*])
  - various data change scope (BASE, ONE, SUBTREE)

Change-Id: Ic43ba3863e2954574ddec946f33512021839acfd
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoImprove documentation of BindingAware{Provider,Consumer}
Ed Warnicke [Tue, 24 Jun 2014 15:13:45 +0000 (10:13 -0500)]
Improve documentation of BindingAware{Provider,Consumer}

Change-Id: I39899f68f91a5c54099a404f00b944fa9cf3cec3
Signed-off-by: Ed Warnicke <eaw@cisco.com>
9 years agoMerge changes I6e8805e1,I4df698a0,I41e0e30d
Devin Avery [Tue, 8 Jul 2014 12:50:20 +0000 (12:50 +0000)]
Merge changes I6e8805e1,I4df698a0,I41e0e30d

* changes:
  Minor cleanup of test suites in MD-SAL
  Moved data test model to sal-test-model
  Bug 1280: Ensure list parent if written item is list item

9 years agoMerge "Bug 1283: Made return types of AsyncDataChangeEvent consistent"
Devin Avery [Tue, 8 Jul 2014 12:36:06 +0000 (12:36 +0000)]
Merge "Bug 1283: Made return types of AsyncDataChangeEvent consistent"

9 years agoMerge "Bug 1235: Documented Notification services of MD-SAL"
Tom Pantelis [Mon, 7 Jul 2014 17:42:47 +0000 (17:42 +0000)]
Merge "Bug 1235: Documented Notification services of MD-SAL"

9 years agoMinor cleanup of test suites in MD-SAL
Tony Tkacik [Mon, 7 Jul 2014 14:19:00 +0000 (16:19 +0200)]
Minor cleanup of test suites in MD-SAL

- Added SuppressWarning("deprecation") to test suites
  which test backwards compatibility with Hydrogen APIs
- Marked test which needs to be rewritten for new DataBroker API
- Removed superflous version for test dependencies

Change-Id: I6e8805e1895bc2171aa5c653d8d87fd8b5c9055b
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
9 years agoMerge "Bug 1316: Fixed loop in global RPC forwarding."
Tony Tkacik [Mon, 7 Jul 2014 15:02:18 +0000 (15:02 +0000)]
Merge "Bug 1316: Fixed loop in global RPC forwarding."