8 years agoMerge "BUG-2673: make IMDS implement DOMStoreTreeChangePublisher"
Tony Tkacik [Tue, 17 Mar 2015 11:30:27 +0000 (11:30 +0000)]
Merge "BUG-2673: make IMDS implement DOMStoreTreeChangePublisher"

8 years agoMerge "BUG-2673: Introduce AbstractDOMStoreTreeChangePublisher"
Tony Tkacik [Tue, 17 Mar 2015 11:28:27 +0000 (11:28 +0000)]
Merge "BUG-2673: Introduce AbstractDOMStoreTreeChangePublisher"

8 years agoMerge "BUG-2673: Create AbstractRegistrationTree and related classes"
Tony Tkacik [Tue, 17 Mar 2015 11:27:43 +0000 (11:27 +0000)]
Merge "BUG-2673: Create AbstractRegistrationTree and related classes"

8 years agoBUG-2673: make IMDS implement DOMStoreTreeChangePublisher 62/16662/2
Robert Varga [Mon, 16 Mar 2015 17:54:39 +0000 (18:54 +0100)]
BUG-2673: make IMDS implement DOMStoreTreeChangePublisher

This patch makes use of the AbstractDOMStoreTreeChangePublisher to do all
the registration wrangling and forwards all notifications towards a
dedicated publisher. Notifications are offloaded to the background
executor, just as normal DataChangeNotifications are. This initial
implementation does not close the registration listener race also
present in the data change notifications, as the notification manager
lacks the APIs to do that.

Change-Id: I36220b52a7a67df1f340b2b8bf32918de025920b
Signed-off-by: Robert Varga <>
8 years agoBUG-2673: Introduce AbstractDOMStoreTreeChangePublisher 49/16649/5
Robert Varga [Mon, 16 Mar 2015 12:21:24 +0000 (13:21 +0100)]
BUG-2673: Introduce AbstractDOMStoreTreeChangePublisher

This is a base class, reusable for various DOMStore implementations,
which want to implement the DOMStoreTreeChangePublisher interface.

Change-Id: I77f2488f3b99d9e9e34c97772df5a157c245f8c7
Signed-off-by: Robert Varga <>
8 years agoBUG-2673: Create AbstractRegistrationTree and related classes 32/16632/3
Robert Varga [Mon, 16 Mar 2015 09:41:44 +0000 (10:41 +0100)]
BUG-2673: Create AbstractRegistrationTree and related classes

This is a generalization of ListenerTree, useful for reusing the
infrastructure for multiple types of registrations.

Change-Id: I715b876d932d0a14ab9a479b1f1d39509a67e30b
Signed-off-by: Robert Varga <>
8 years agoBUG-2713 Extract capability implementations into util 34/16634/3
Maros Marsalek [Mon, 16 Mar 2015 12:22:03 +0000 (13:22 +0100)]
BUG-2713 Extract capability implementations into util

Identical implementations all over the place are now in 2 classes in

Change-Id: Ibc2aa78edb581654da1ac890d109d2f32cf94738
Signed-off-by: Maros Marsalek <>
8 years agoBUG-2839: remove dependencies on commons-io 25/16625/1
Robert Varga [Fri, 13 Mar 2015 12:11:50 +0000 (13:11 +0100)]
BUG-2839: remove dependencies on commons-io

Replaces uses of IOUtils methods with guava/JDK equivalents.

Change-Id: I16ece0feec2f4dc84c3be91ec675a0294cffcffb
Signed-off-by: Robert Varga <>
8 years agoMerge changes I8ad04406,I3ea2166c
Tony Tkacik [Sat, 14 Mar 2015 10:12:31 +0000 (10:12 +0000)]
Merge changes I8ad04406,I3ea2166c

* changes:
  BUG-2314 Fix (no-input)rpcs serialization in netconf connector
  Fix Already initialized exception from netconf-connector

8 years agoBUG-2314 Fix (no-input)rpcs serialization in netconf connector 85/16485/1
Maros Marsalek [Fri, 13 Mar 2015 14:12:55 +0000 (15:12 +0100)]
BUG-2314 Fix (no-input)rpcs serialization in netconf connector

Rpcs with no input were not wrapped in rpc element correctly

Change-Id: I8ad0440681e83dd3a04a8ba38f49b2d7c4976caa
Signed-off-by: Maros Marsalek <>
8 years agoFix Already initialized exception from netconf-connector 77/16477/1
Maros Marsalek [Fri, 13 Mar 2015 12:49:07 +0000 (13:49 +0100)]
Fix Already initialized exception from netconf-connector

Netconf-connector called initialization code and cleanup code (after capability
changed notification was received) in wrong order. This caused the cleanup

Change-Id: I3ea2166c912e2b6775bf9493a95102d66b5ae8a2
Signed-off-by: Maros Marsalek <>
8 years agoMerge "BUG-2596 Workaround for scheduled-threadpool module"
Tony Tkacik [Fri, 13 Mar 2015 12:28:31 +0000 (12:28 +0000)]
Merge "BUG-2596 Workaround for scheduled-threadpool module"

8 years agoMerge "Change in AbstractRaftBehavior#performSnapshotWithoutCapture"
Moiz Raja [Fri, 13 Mar 2015 11:50:50 +0000 (11:50 +0000)]
Merge "Change in AbstractRaftBehavior#performSnapshotWithoutCapture"

8 years agoBUG-2596 Workaround for scheduled-threadpool module 72/16472/1
Maros Marsalek [Fri, 13 Mar 2015 10:39:28 +0000 (11:39 +0100)]
BUG-2596 Workaround for scheduled-threadpool module

Register the scheduled-threadpool as all available service types in initial

Change-Id: If7929fbb9996f0ea8902d50e2c71875d343f229f
Signed-off-by: Maros Marsalek <>
8 years agoMerge "Refactor ShardTest"
Moiz Raja [Fri, 13 Mar 2015 10:31:26 +0000 (10:31 +0000)]
Merge "Refactor ShardTest"

8 years agoMerge "Reduce/enhance logging in AbstractLeader"
Moiz Raja [Fri, 13 Mar 2015 10:29:13 +0000 (10:29 +0000)]
Merge "Reduce/enhance logging in AbstractLeader"

8 years agoMerge "Purge in-memory log when install snapshot is done"
Moiz Raja [Fri, 13 Mar 2015 10:28:37 +0000 (10:28 +0000)]
Merge "Purge in-memory log when install snapshot is done"

8 years agoMerge "Use static Procedure callback for ApplyJournalEntries"
Moiz Raja [Fri, 13 Mar 2015 10:26:21 +0000 (10:26 +0000)]
Merge "Use static Procedure callback for ApplyJournalEntries"

8 years agoMerge "Changes in RaftActor#handleCaptureSnapshotReply"
Moiz Raja [Fri, 13 Mar 2015 10:26:02 +0000 (10:26 +0000)]
Merge "Changes in RaftActor#handleCaptureSnapshotReply"

8 years agoMerge "Change fields in ShardStats to non-volatile"
Moiz Raja [Fri, 13 Mar 2015 10:25:41 +0000 (10:25 +0000)]
Merge "Change fields in ShardStats to non-volatile"

8 years agoMerge "BUG-2314 Expose inventory mountpoint on proper path"
Tony Tkacik [Fri, 13 Mar 2015 09:23:39 +0000 (09:23 +0000)]
Merge "BUG-2314 Expose inventory mountpoint on proper path"

8 years agoBug 2845: Temporarily ignore RestPutOperationTest 09/16509/1
Tom Pantelis [Fri, 13 Mar 2015 03:49:03 +0000 (23:49 -0400)]
Bug 2845: Temporarily ignore RestPutOperationTest

RestPutOperationTest is frequently failing the verify builds so
setting to Ignore until the issue is fixed.

Change-Id: I134a6d73930cd104225a27880e87867026f35f03
Signed-off-by: Tom Pantelis <>
8 years agoBug 2834: Fix Restconf POST to wait for completion 92/16492/8
Ryan Goulding [Fri, 13 Mar 2015 15:15:32 +0000 (11:15 -0400)]
Bug 2834: Fix Restconf POST to wait for completion

This changeset introduces a blocking mechanism for Restconf POST to ensure that
the transaction completes before a response is returned, as is consistent with
Restconf PUT behavior.  checkedGet() is utilized to ensure write transaction

Change-Id: I74f68b883f6037ec62644a468d3cbb9370d8d25f
Signed-off-by: Ryan Goulding <>
8 years agoFix bug 2821 - restconf RPC parsing returns http status 500 22/16322/11
Vaclav Demcak [Wed, 11 Mar 2015 13:13:22 +0000 (14:13 +0100)]
Fix bug 2821 - restconf RPC parsing returns http status 500

Note: RpcDefinition is a direct child of SchemaNode and we are not able to
use it as DataSchemaNode or SchemaContext. In next RpcDefinition hasn't any
child except Input & Output ContainerNodes. So we are using RpcDefinition
for SchemaNode as a marker in InstanceIdentfierContext.

* json input read @Provider has to change RpcDefinition SchemaNode
to Input ContainerSchemaNode for a correct parsing RPC input data from stream

* no-payload Rpc - Rpc Call could be without payload, but jersey always does
to parse empty stream to NormalizedNode so we add check for stream.available
before start parsing input NormalizedNode from stream and return NNContext
with null data. All checks for data exist have to be implemented for every
method with NormalizedNodeContext.

* fix RpcOutput NormalzidNodeContext in RestconfImpl - we expect to have
RpcDefinition as reultNodeSchema and data are payloaded inside as Output obj.

* fix NormalizedNodeJsonBodyWriter and NormalizedNodeXmlBodyWriter for RpcDefinition
- RpcDefinition has no child elements so RpcDefinition.output has to be a root
DataSchemaNode for json parser

* add JsonBodyReader/Writer test suite
* add Xml rpc Writer parser test suite

Change-Id: I31273bee937f57fa1551a33fcc4d6c81b984afb6
Signed-off-by: Vaclav Demcak <>
8 years agoAdd missing union type builder 04/16404/2
Robert Varga [Thu, 12 Mar 2015 16:48:45 +0000 (17:48 +0100)]
Add missing union type builder

This type was missing and should not be generated over and over again.

Change-Id: Ife3e97c2c639e29ca2115429b53e6dec62440db7
Signed-off-by: Robert Varga <>
8 years agoBUG-2314 Expose inventory mountpoint on proper path 98/16398/1
Maros Marsalek [Thu, 12 Mar 2015 15:38:53 +0000 (16:38 +0100)]
BUG-2314 Expose inventory mountpoint on proper path

The path is updated according to the Normalized nodes API

Change-Id: Ibeb8b98016d0056a703eb97f6e31c6a5507a21ea
Signed-off-by: Maros Marsalek <>
8 years agoMerge "BUG-2343 Report sideloaded models for nc correctly"
Tony Tkacik [Thu, 12 Mar 2015 11:58:32 +0000 (11:58 +0000)]
Merge "BUG-2343 Report sideloaded models for nc correctly"

8 years agoMerge "BUG-2314 Allow rpcs with no input in netconf connector"
Tony Tkacik [Thu, 12 Mar 2015 11:57:36 +0000 (11:57 +0000)]
Merge "BUG-2314 Allow rpcs with no input in netconf connector"

8 years agoMerge "Quick fix nullable RPC input"
Tony Tkacik [Thu, 12 Mar 2015 11:04:09 +0000 (11:04 +0000)]
Merge "Quick fix nullable RPC input"

8 years agoBUG-2314 Allow rpcs with no input in netconf connector 32/16332/3
Maros Marsalek [Wed, 11 Mar 2015 15:30:47 +0000 (16:30 +0100)]
BUG-2314 Allow rpcs with no input in netconf connector

Change-Id: I81b05c98032c8bda7b34608c33ddcb5a0888ba67
Signed-off-by: Maros Marsalek <>
8 years agoBUG-2343 Report sideloaded models for nc correctly 80/16380/2
Maros Marsalek [Thu, 12 Mar 2015 09:57:00 +0000 (10:57 +0100)]
BUG-2343 Report sideloaded models for nc correctly

The sideloading of models behaved as a merge operation but was reported as
replace. Report the resulting models as a merge.

Change-Id: Id44d077e72ae0ce5f202c5178d5c7e5b825d6deb
Signed-off-by: Maros Marsalek <>
8 years agoChange fields in ShardStats to non-volatile 86/16386/3
Tom Pantelis [Sun, 8 Mar 2015 12:16:07 +0000 (08:16 -0400)]
Change fields in ShardStats to non-volatile

Most if the fields in ShardStats are volatile or AtomicLong counters.
While volatile guarantees immediate thread visibility, we can live with
eventual consistency to avoid the overhead of volatile writes on the
fast path as reads via JMX will be infrequent.

All of the counters except 1 are updated by Shard so concurrent updates
won't occur. failedReadTransactionsCount is updated by ShardTransaction
so we need to keep that as AtomicLong as it will be updated concurrently.
But it's a failure counter so will be updated infrequently.

Change-Id: I6a0f748bd595379243e0ea31d84f6c8d0989003a
Signed-off-by: Tom Pantelis <>
8 years agoMerge "Add sal-akka-raft test-jar dependency to sal-distributed-store pom"
Moiz Raja [Thu, 12 Mar 2015 01:33:51 +0000 (01:33 +0000)]
Merge "Add sal-akka-raft test-jar dependency to sal-distributed-store pom"

8 years agoUse static Procedure callback for ApplyJournalEntries 70/16370/2
Tom Pantelis [Thu, 12 Mar 2015 00:12:42 +0000 (20:12 -0400)]
Use static Procedure callback for ApplyJournalEntries

Optimization in RaftActor to reuse a static Procedure callback instance
when persisting ApplyJournalEntries.

Change-Id: Id4b799b847191f9d7b31aca54d9926638407410e
Signed-off-by: Tom Pantelis <>
8 years agoChanges in RaftActor#handleCaptureSnapshotReply 68/16368/3
Tom Pantelis [Wed, 11 Mar 2015 23:30:59 +0000 (19:30 -0400)]
Changes in RaftActor#handleCaptureSnapshotReply

captureSnapshot.getReplicatedToAllIndex() is usually -1 (in fact I
haven't yet been able to come with a test scenario where it isn't) and
we shouldn't reset the behavior's replicatedToAllIndex history when
we snapshot due to memory threshold exceeded. This prevents log trimming
when a lagging follower is caught up via install snapshot. Eventually
log trimming would catch up on subsequent replicates but I don't see a
reason why we should reset it to -1.

Also made a couple other logging changes.

Change-Id: I6b9eafc84455a88c3bc1fc91608fe257c03b4093
Signed-off-by: Tom Pantelis <>
8 years agoChange in AbstractRaftBehavior#performSnapshotWithoutCapture 69/16369/1
Tom Pantelis [Thu, 12 Mar 2015 00:00:06 +0000 (20:00 -0400)]
Change in AbstractRaftBehavior#performSnapshotWithoutCapture

If tempMin isn't present in the log and tempMin is grater
than the current replicatedToAllIndex, then update replicatedToAllIndex
to tempMin. Details are in the code comments.

Change-Id: I373d5c4b7ce9fd2504f2a4fa996b49a6d9ffe5b6
Signed-off-by: Tom Pantelis <>
8 years agoReduce/enhance logging in AbstractLeader 66/16366/1
Tom Pantelis [Wed, 11 Mar 2015 22:31:25 +0000 (18:31 -0400)]
Reduce/enhance logging in AbstractLeader

If you turn on debug logging for Shard, the "Checking sendAppendEntries
for follower..." message is logged by sendUpdatesToFollower on every
AppendEntriesReply heartbeat even when no data was sent to the follower.
This bombards the karaf.log. To avoid this, we need this only logged if
something changed for the follower. So, I changed the FollwerLogInformation
setMatchIndex and setNextIndex methods to return a boolean if changed
which handleAppendEntriesReply checks to see if either were updated. If
neither changed, it passes true to sendUpdatesToFollower for isHeartbeat
so the message isn't logged.

I also made a few other minor logging changes.

Change-Id: Ib1f2109092b3656c3cc3dfdd2cd7b4641a3f890b
Signed-off-by: Tom Pantelis <>
8 years agoPurge in-memory log when install snapshot is done 64/16364/1
Tom Pantelis [Wed, 11 Mar 2015 22:11:33 +0000 (18:11 -0400)]
Purge in-memory log when install snapshot is done

In AbstractLeader#handleInstallSnapshotReply, after the last snapshot
chunk has been sent and acknowledged by the follower and, since install
snapshot *should* only happen for a lagging follower, the follower
is most likely caught up at this point so we can be greedy and try
to trim the log and advance replicatedToAllIndex.

Change-Id: Id22dfbcb6e459e3d3f6801d1c6c850bdd42989fa
Signed-off-by: Tom Pantelis <>
8 years agoAdd sal-akka-raft test-jar dependency to sal-distributed-store pom 55/16355/1
Tom Pantelis [Wed, 11 Mar 2015 21:11:22 +0000 (17:11 -0400)]
Add sal-akka-raft test-jar dependency to sal-distributed-store pom

So we can use the test utilities in sal-akka-raft.

Change-Id: Ibb28522ed49c61c53d3b3296b38c898c7ea5129b
Signed-off-by: Tom Pantelis <>
8 years agoMerge "Fixed testool performance bottleneck due to testtool using NetconfMonitoring...
Tony Tkacik [Wed, 11 Mar 2015 19:28:01 +0000 (19:28 +0000)]
Merge "Fixed testool performance bottleneck due to testtool using NetconfMonitoring from ODL. Added a dummy NetconfMonitoring implementation for testtool."

8 years agoMerge "Changed NetconfDeviceDatastoreAdapter and NetconfDeviceTopologyAdapter to...
Tony Tkacik [Wed, 11 Mar 2015 19:27:46 +0000 (19:27 +0000)]
Merge "Changed NetconfDeviceDatastoreAdapter and NetconfDeviceTopologyAdapter to use TransactionChains instead of Transactions to prevent race condition between init and update when a device is created."

8 years agoMerge "Remove duplicate dependency declarations"
Tony Tkacik [Wed, 11 Mar 2015 19:27:13 +0000 (19:27 +0000)]
Merge "Remove duplicate dependency declarations"

8 years agoMerge "Fixed failing tests due to different attribute handling in mdsal netconf north...
Tony Tkacik [Wed, 11 Mar 2015 19:27:07 +0000 (19:27 +0000)]
Merge "Fixed failing tests due to different attribute handling in mdsal netconf northbound."

8 years agoMerge "Make logger final"
Tony Tkacik [Wed, 11 Mar 2015 19:25:45 +0000 (19:25 +0000)]
Merge "Make logger final"

8 years agoMerge changes Ic1abe2f7,I9b4bc3ad,If347c979
Tony Tkacik [Wed, 11 Mar 2015 19:25:10 +0000 (19:25 +0000)]
Merge changes Ic1abe2f7,I9b4bc3ad,If347c979

* changes:
  Remove empty javadocs and make strings constant
  Remove unused logger
  Use an ImmutableMap

8 years agoMake logger final 15/16315/2
Robert Varga [Wed, 11 Mar 2015 10:18:33 +0000 (11:18 +0100)]
Make logger final

The logger should be marked as final and also be called LOG, not

Change-Id: I75f675eec1ee54d659d93aef3e39204a1f7cc920
Signed-off-by: Robert Varga <>
8 years agoRemove empty javadocs and make strings constant 14/16314/2
Robert Varga [Wed, 11 Mar 2015 10:17:50 +0000 (11:17 +0100)]
Remove empty javadocs and make strings constant

Cleans up malformed an empty javadocs and also make string constants
really constant.

Change-Id: Ic1abe2f7c2cb6e6327fde7095742fc0a96ca2e02
Signed-off-by: Robert Varga <>
8 years agoRemove unused logger 13/16313/2
Robert Varga [Wed, 11 Mar 2015 10:16:47 +0000 (11:16 +0100)]
Remove unused logger

Removes the logger, which is not used anyway. Fixes an eclipse warning.

Change-Id: I9b4bc3ad88107b2b2ba0cd999b89e3105b2b3b65
Signed-off-by: Robert Varga <>
8 years agoUse an ImmutableMap 12/16312/2
Robert Varga [Wed, 11 Mar 2015 10:10:03 +0000 (11:10 +0100)]
Use an ImmutableMap

ImmutableMap has better lookup characteristics, so use that instead of
wrapping a regular hashmap.

Change-Id: If347c9790640f9802f438d5fa225978a56186805
Signed-off-by: Robert Varga <>
8 years agoQuick fix nullable RPC input 30/16330/3
Vaclav Demcak [Wed, 11 Mar 2015 15:06:10 +0000 (16:06 +0100)]
Quick fix nullable RPC input

* DOMRpcService is declaring a method invokeRpc like
invokeRpc(@Nonnull SchemaPath type, @Nullable NormalizedNode<?, ?> input)

* add check to null for input in BindingRpcImplementationAdapter and
BindingDOMRpcImplementationAdapter because they are trying to deserialze
input automaticly withou any null check before. It produces next exception
for nopayload rpc:


Change-Id: I3970564b9645473eee6c01ab1ea632f323de959a
Signed-off-by: Vaclav Demcak <>
8 years agoRemove duplicate dependency 16/16316/2
Robert Varga [Wed, 11 Mar 2015 11:00:30 +0000 (12:00 +0100)]
Remove duplicate dependency

Fixes a maven warning about duplicate artifacts.

Change-Id: Iccd64ce946ddfbff5b158780d9b29fca7c142521
Signed-off-by: Robert Varga <>
8 years agoMerge "Migrate to using odlparent:features-test"
Tony Tkacik [Wed, 11 Mar 2015 16:18:35 +0000 (16:18 +0000)]
Merge "Migrate to using odlparent:features-test"

8 years agoDisable unstable netconf-notifications tests 27/16327/1
Maros Marsalek [Wed, 11 Mar 2015 14:30:58 +0000 (15:30 +0100)]
Disable unstable netconf-notifications tests

Comment out unreliable lassertions for XML payload comparison.
Proper fix needs to be provided.

Change-Id: I6e32eefb0ccf95e616dd9c236338593f49ff0af3
Signed-off-by: Maros Marsalek <>
8 years agoMerge "Use default SchemaCtx for base netconf ops(if not available)"
Tony Tkacik [Wed, 11 Mar 2015 12:28:39 +0000 (12:28 +0000)]
Merge "Use default SchemaCtx for base netconf ops(if not available)"

8 years agoUse default SchemaCtx for base netconf ops(if not available) 10/16310/1
Maros Marsalek [Wed, 11 Mar 2015 10:34:27 +0000 (11:34 +0100)]
Use default SchemaCtx for base netconf ops(if not available)

If remote device does not expose yang model for base netconf operations, use a
default, pre built schema context for these operations e.g. Lock, unlock

Change-Id: I33e89adaa9a151cc236586e75264a907bf45a5df
Signed-off-by: Maros Marsalek <>
8 years agoBUG-1513: migrate users to ChoiceSchemaNode 08/16308/1
Robert Varga [Wed, 11 Mar 2015 09:59:11 +0000 (10:59 +0100)]
BUG-1513: migrate users to ChoiceSchemaNode

This migrates all users to the new interface name, cleaning them up as
the data.api and model.api name clash is resolved.

Change-Id: Ibdc317d5ff86c6a895cccdacf6dfea1fb005d9b6
Signed-off-by: Robert Varga <>
8 years agoRemove duplicate dependency declarations 43/16243/2
Robert Varga [Tue, 10 Mar 2015 08:52:48 +0000 (09:52 +0100)]
Remove duplicate dependency declarations

These are declared twice, producing a maven warning. Remove duplicities.

Change-Id: Ica73b9220c5815e45591cd1d4a7600b432adee5d
Signed-off-by: Robert Varga <>
8 years agoMigrate to using odlparent:features-test 29/16229/2
Robert Varga [Tue, 10 Mar 2015 07:47:40 +0000 (08:47 +0100)]
Migrate to using odlparent:features-test

yangtools features-test is going away, migrate away from it.

Change-Id: Idcf27275fd57868ee1e56656854365ac2dcab907
Signed-off-by: Robert Varga <>
8 years agoMerge "Bug 2412: Expose Mountpoints on proper path"
Tony Tkacik [Wed, 11 Mar 2015 06:13:38 +0000 (06:13 +0000)]
Merge "Bug 2412: Expose Mountpoints on proper path"

8 years agoMerge "BUG 2805 - Fixed Restconf RPC calls and POST to create data"
Tony Tkacik [Wed, 11 Mar 2015 06:13:12 +0000 (06:13 +0000)]
Merge "BUG 2805 - Fixed Restconf RPC calls and POST to create data"

8 years agoMerge "Bug 2364: Migrated Binding MD-SAL to not use composites nodes"
Tony Tkacik [Wed, 11 Mar 2015 06:12:48 +0000 (06:12 +0000)]
Merge "Bug 2364: Migrated Binding MD-SAL to not use composites nodes"

8 years agoBug 2412: Expose Mountpoints on proper path 79/16279/2
Maros Marsalek [Tue, 10 Mar 2015 16:14:08 +0000 (17:14 +0100)]
Bug 2412: Expose Mountpoints on proper path

Lists such as topology, node were not doubled
in the YANG Instance Identifier used as a key for mountpoints,
which prevented Binding compontents from accessing

This patch fixes also bug in restconf, which was
also producing incorrect instance identifiers.

Change-Id: I3122163d00d4c23fcccc4bbffdf3d0113744c98d
Signed-off-by: Maros Marsalek <>
8 years agoMerge "Add netconf-ssh as dependency to features-mdsal"
Ed Warnicke [Tue, 10 Mar 2015 21:40:34 +0000 (21:40 +0000)]
Merge "Add netconf-ssh as dependency to features-mdsal"

8 years agoBUG 2805 - Fixed Restconf RPC calls and POST to create data 36/16136/8
Maros Marsalek [Tue, 10 Mar 2015 10:19:33 +0000 (11:19 +0100)]
BUG 2805 - Fixed Restconf RPC calls and POST to create data

RPCs now works again with JSON and XML
POST works with data store.

AbstractIdentifierAwareJaxRsProvider and its derivates,
provides InstanceIdentifierContext as was parsed from
RESTCONF URI, along with parsed NormalizedNode.

If operation is create, then parsed NormalizedNode
is used along with InstanceIdentifier context to compute
full InstanceIdentifier for data to be created
and works with these data.

This actually simplified flow in codecs.

Change-Id: I5b12965f35d946087cc57f19a28425b27eb27755
Signed-off-by: Vaclav Demcak <>
Signed-off-by: Maros Marsalek <>
8 years agoModify ChainedTransactionProxy to override sending of FindPrimaryShard 59/16159/3
Tom Pantelis [Sun, 8 Mar 2015 02:16:37 +0000 (21:16 -0500)]
Modify ChainedTransactionProxy to override sending of FindPrimaryShard

Previously, ChainedTransactionProxy overrode the sendCreateTransaction
method from TransactionProxy to intercept the sending of the
CreateTransaction message in order to asynchronously wait for the
transaction's ready Futures to complete before sending the message.

To facilitate write-only transaction optimizations which will not create
a separate transaction actor, we need to intercept the FindPrimaryShard
message instead. Thus a new overridden method,
sendFindPrimaryShardAsync, was added the same as sendCreateTransaction
except it sends the FindPrimaryShard message..

Change-Id: I5d0a3de0b9530a538e2425147fad8ace823763f3
Signed-off-by: Tom Pantelis <>
8 years agoMerge "Refactor LegacyTransactionConntextImpl"
Moiz Raja [Tue, 10 Mar 2015 18:27:15 +0000 (18:27 +0000)]
Merge "Refactor LegacyTransactionConntextImpl"

8 years agoMerge "Handle FollowerInitialSyncStatus message in Shard/ShardManager"
Tom Pantelis [Tue, 10 Mar 2015 16:58:08 +0000 (16:58 +0000)]
Merge "Handle FollowerInitialSyncStatus message in Shard/ShardManager"

8 years agoBug 2364: Migrated Binding MD-SAL to not use composites nodes 61/16261/4
Tony Tkacik [Sun, 8 Mar 2015 15:30:27 +0000 (16:30 +0100)]
Bug 2364: Migrated Binding MD-SAL to not use composites nodes

Bidning MD-SAL is fully migrated to be adapter on top
of NormalizedNode MD-SAL. This migration once all legacy
classes are removed will provide easier-to-read more
maintanable code of Binding MD-SAL.

Change-Id: I1df6cda4bd6035ac5e01e1285f8aab4201dcc86d
Signed-off-by: Tony Tkacik <>
8 years agoFixed failing tests due to different attribute handling in mdsal netconf northbound. 72/16272/1
Tomas Cere [Tue, 10 Mar 2015 14:49:38 +0000 (15:49 +0100)]
Fixed failing tests due to different attribute handling in mdsal netconf northbound.

Change-Id: I4f3723b9094f953307982ee25019e3736c9d24de
Signed-off-by: Tomas Cere <>
8 years agoAdd netconf-ssh as dependency to features-mdsal 66/16266/1
Thanh Ha [Tue, 10 Mar 2015 14:49:54 +0000 (10:49 -0400)]
Add netconf-ssh as dependency to features-mdsal

This should fix our issue with autorelease-lithium build failing due to
missing netconf-ssh which happens occassionally.

Change-Id: I655290e1110203195934bfac1adf47d6d08f60db
Signed-off-by: Thanh Ha <>
8 years agoFix netconf operation serialization in nc 57/16257/3
Maros Marsalek [Tue, 10 Mar 2015 12:29:27 +0000 (13:29 +0100)]
Fix netconf operation serialization in nc

For delete operation, the netconf operation attribute was not added to the
normalizedNode structure.

Change-Id: Idbe65ff3a6eee6fa24d96c68f8ce59da03f4c91d
Signed-off-by: Maros Marsalek <>
8 years agoAdd SchemaContext to NormalizedNode parser in NETCONF 24/16024/9
Maros Marsalek [Wed, 4 Mar 2015 14:43:23 +0000 (15:43 +0100)]
Add SchemaContext to NormalizedNode parser in NETCONF

Change-Id: Id674dc60eba84cb5cb37b6f170654ae7333f91b6
Signed-off-by: Maros Marsalek <>
8 years agoMigrate users of AnyXml node to DOMSource 37/16137/9
Maros Marsalek [Fri, 6 Mar 2015 13:37:57 +0000 (14:37 +0100)]
Migrate users of AnyXml node to DOMSource

AnyXml node used to wrap Node<?> but now wraps a DOMSource

Change-Id: If4f5845e5a0611d5fe38951dd6afe73d0a6f95bc
Signed-off-by: Maros Marsalek <>
8 years agoFixed testool performance bottleneck due to testtool using NetconfMonitoring from... 87/16187/4
Tomas Cere [Mon, 9 Mar 2015 09:23:56 +0000 (10:23 +0100)]
Fixed testool performance bottleneck due to testtool using NetconfMonitoring from ODL.
Added a dummy NetconfMonitoring implementation for testtool.

Change-Id: I4d2eaf955ccac78de135749bd8c2bda3e3d6f35b
Signed-off-by: Tomas Cere <>
8 years agoMerge "Bug 2260: Reduce overhead of unused TransactionProxy instances"
Tom Pantelis [Mon, 9 Mar 2015 23:57:47 +0000 (23:57 +0000)]
Merge "Bug 2260: Reduce overhead of unused TransactionProxy instances"

8 years agoMerge "Performance optimizations for simple transactions"
Tom Pantelis [Mon, 9 Mar 2015 23:51:39 +0000 (23:51 +0000)]
Merge "Performance optimizations for simple transactions"

8 years agoBug 2260: Reduce overhead of unused TransactionProxy instances 59/15859/7
Tom Pantelis [Sun, 1 Mar 2015 02:21:10 +0000 (21:21 -0500)]
Bug 2260: Reduce overhead of unused TransactionProxy instances

Moved constructon of the operationLimiter and operationCompleter to the
throtteOperation method lazily. Added a volatile initialized boolean for
the lazy check and to "piggy-back" synchronize the updates to
operationLimiter and operationCompleter as well.

In TransactionProxy#ready, if no operations were performed then the
txFutureCallbackMap will be empty so returned a static
NoOpDOMStoreThreePhaseCommitCohort in that case.

The only remaining overhead in the constructor is the
TransactionIdentifier instance. The Builder seemed extraneous here so I
removed it to reduce the overhead from 2 object allocations to 1.

Change-Id: I083d4176c880055938bbf1f21c00da3859d66af6
Signed-off-by: Tom Pantelis <>
8 years agoHandle FollowerInitialSyncStatus message in Shard/ShardManager 95/15995/6
Moiz Raja [Tue, 3 Mar 2015 23:49:48 +0000 (15:49 -0800)]
Handle FollowerInitialSyncStatus message in Shard/ShardManager

Both Shard and ShardManager updated the status in their respective
MBeans so that the status can be queried from there

Change-Id: I9e9fd6c93ad6a1b4d260f6ecd9a7fd1d63f70a12
Signed-off-by: Moiz Raja <>
8 years agoBug 2412: Fixed reading of JSON using new codecs. 09/16209/2
Tony Tkacik [Mon, 9 Mar 2015 16:44:52 +0000 (17:44 +0100)]
Bug 2412: Fixed reading of JSON using new codecs.

Change-Id: I6676fc2f323d0d9152657dcc9b2cdb5f593110e5
Signed-off-by: Tony Tkacik <>
8 years agoPerformance optimizations for simple transactions 55/15955/3
Moiz Raja [Tue, 3 Mar 2015 00:32:31 +0000 (16:32 -0800)]
Performance optimizations for simple transactions

- Cache the ActorSelection for the primary shard in ActorContext
- Use isInstance to check for type of message instead of equals in ActorContext
  ShardManager and Shard
- Change the order in which we check for transaction type to create in Shard
- Create ShardTransactionIdentifier using the ShardTransactionIdentifier
  constructor instead of the Builder

These optimizations are aimed at making simple transactions faster in the dsBenchMark. This
set of optimizations reduced the amount of time that test takes from 20s to 18s on my Mac.

Change-Id: I1a4328d90839ef80041ae4f3bb7dccd45ac7fb97
Signed-off-by: Moiz Raja <>
8 years agoChanged NetconfDeviceDatastoreAdapter and NetconfDeviceTopologyAdapter to use Transac... 88/16188/4
Tomas Cere [Mon, 9 Mar 2015 12:26:40 +0000 (13:26 +0100)]
Changed NetconfDeviceDatastoreAdapter and NetconfDeviceTopologyAdapter to use TransactionChains
instead of Transactions to prevent race condition between init and update when a device is created.

Change-Id: I8b7f507dd66d3bf95e15858c456f8905c9bbf4b9
Signed-off-by: Tomas Cere <>
8 years agoQuickfix: Remove deprecated providers from Restconf Application 28/16028/9
Vaclav Demcak [Fri, 6 Mar 2015 13:36:50 +0000 (14:36 +0100)]
Quickfix: Remove deprecated providers from Restconf Application

Jersey 1.17 has problem with multiple Entity providers,
which consumes same content-type and produces different
Entity class. In wiring phase it does not report any problems,
but in runtime it may select incorrect one, which
will result in IllegalArgumentException, which is not

So in order to unblock most of functionality, legacy
providers are disabled.

This will fix data-store access, but without
subsequent patches RPCs are not usable.

Change-Id: I860e162232d887d13629504421076495a50a075b
Signed-off-by: Vaclav Demcak <>
8 years agoBUG 2412 - restconf @POST invokeRpc for notification subscription 48/15948/13
Vaclav Demcak [Mon, 9 Mar 2015 13:32:32 +0000 (14:32 +0100)]
BUG 2412 - restconf @POST invokeRpc for notification subscription

* modified notification subscription to work on new api
* added conversion to normalized instance identifier in notification
subscription path
* removed mixin nodes from data change event path
* modified returned paths to skip augmentation identifiers in change
event path
* modified returned location header entry on get stream to use "ws"

Change-Id: If7f5e92eedbebe0daeb149a38d429a1dcb47c1c9
Signed-off-by: Vaclav Demcak <>
8 years agoBUG 2412 - restconf @POST invokeRpc with nopayload method 23/15923/7
Vaclav Demcak [Mon, 2 Mar 2015 14:31:15 +0000 (15:31 +0100)]
BUG 2412 - restconf @POST invokeRpc with nopayload method

* migration to new faster Infrastructure API and Codecs for method
@POST invokeRpc(String,String,UriInfo) on @Path {/operations/identifier}

New faster Infrastructure API works with NormizedNodeContext and
we are replacing rpc call method from RestconfService
to use NormalizedNodeContext

* add DOMRpcService -> DOMRpcRouter as rpcRoutingTable holder (it needs to change
in future commit, because we have SchemaContextListener in ControllerContext
and we can have own RpcRoutingTable management there

* fix tests (InvokeRpcMethodTest)
* ignore tests - which are not able to fix now
* remove old codecs from integration test suites to be sure of using corrct codecs

Change-Id: I44119bf0337a1f714991a0e003dabab2da482d23
Signed-off-by: Vaclav Demcak <>
8 years agoBUG 2412 - restconf @POST invokeRpc with payload method 22/15922/6
Vaclav Demcak [Mon, 2 Mar 2015 14:30:33 +0000 (15:30 +0100)]
BUG 2412 - restconf @POST invokeRpc with payload method

* migration to new faster Infrastructure API and Codecs for method
@POST invokeRpc(String, NormalizedNodeContext,UriInfo)
on @Path {/operations/identifier}

New faster Infrastructure API works with NormizedNodeContext and
we are replacing invokeRpc method from RestconfService
to use NormalizedNodeContext

* add DOMRpcService -> DOMRpcRouter as rpcRoutingTable holder (it
needs to change in future commit, because we have SchemaContextListener
in ControllerContext and we can have own RpcRoutingTable management there
Known issues:
We are ignoring Notification for invokeRpc method for yet.
It has to be fixed asap.

* fix tests (InvokeRpcMethodTest) - prepareDomPayload method create
serious rpc input obj.
* ignore tests - which are not able to fix now

Change-Id: I2e71f4d536a739a8e439ce6320b7e32569d1b0e0
Signed-off-by: Vaclav Demcak <>
8 years agoMerge changes I4ec69712,I8348002a,I7e6abbf1,Idc2294da
Tony Tkacik [Sun, 8 Mar 2015 22:17:16 +0000 (22:17 +0000)]
Merge changes I4ec69712,I8348002a,I7e6abbf1,Idc2294da

* changes:
  BUG 2412 - restconf @POST createConfigurationData(payload) method migration
  BUG 2412 - restconf @POST createConfigurationData method migration
  BUG 1269 - fill HTTP POST response location attribute
  BUG 2412 - restconf @PUT updateConfigurationData method migration

8 years agoBUG-2314 Migrate netconf-connector to NormalizedNode 83/15783/9
Maros Marsalek [Tue, 24 Feb 2015 12:17:00 +0000 (13:17 +0100)]
BUG-2314 Migrate netconf-connector to NormalizedNode

CompositeNodes are wiped out from sal-netconf-connector.

The inital operations performed on a remote netconf device
(e.g. Schema download) is performed using a special schema
context that contains base netconf, netconf monitoring
and netconf notification schemas.

With this schema context, it is possible to also use
normalized nodes.

YangInstanceIdentifier -> NormalizedNode filter structure
is handled by a class named InstanceIdToFilter that was
extracted from deprecated DataNormalizer.

Change-Id: Ibcc399c3ef9413aa4f96dba5b4bb2611db7123a8
Signed-off-by: Maros Marsalek <>
8 years agoRefactor ShardTest 62/16162/4
Tom Pantelis [Sat, 7 Mar 2015 04:25:57 +0000 (23:25 -0500)]
Refactor ShardTest

Refactored the helium compatibility tests in ShardTest into a new
PreLithiumShardTest class to keep them separate. This will make it
easier to remove the Helium test code when it's no longer needed.
Since it needs the same setup as ShardTest and some of the utility
methods, I moved all the setup and utility methods to an
AbstractShardTest to avoid duplication. This also makes ShardTest
smaller and easier to follow.

I also moved the ShardTransactionHeliumBackwardsCompatibilityTest to
the compat package.

Change-Id: Ie46441adbd0be4c4a655f5db640519705a6ced29
Signed-off-by: Tom Pantelis <>
8 years agoBug 2578 - Added Binding Adapters for new Notification Broker 17/15417/13
Jan Hajnar [Tue, 17 Feb 2015 15:47:54 +0000 (16:47 +0100)]
Bug 2578 - Added Binding Adapters for new Notification Broker

Implement and integrate Binding to DOM Notification adapters

* implemented forwarded notification broker
* added simple test for forwarded notification broker
* added configuration of new modules and services to md-sal config

Change-Id: I259c971f0dc61bc1b00cbaad2956c3d8b37ff780
Signed-off-by: Jan Hajnar <>
8 years agoBUG 2412 - restconf @POST createConfigurationData(payload) method migration 55/15355/12
Vaclav Demcak [Mon, 16 Feb 2015 01:08:09 +0000 (02:08 +0100)]
BUG 2412 - restconf @POST createConfigurationData(payload) method migration

* migration to new faster Infrastructure API and Codecs for method
@POST createConfigurationData(NormalizedNodeContext) on @Path {/config}

New faster Infrastructure API works with NormizedNodeContext and
we are replacing createConfigurationData(NormalizedNodeContext) from
RestconfService to use NormalizedNodeContext.

* add fix or comment tests - problem with RestconfDocumentedExceptionMapper
- it has to be fixed in future commit in this chain

Change-Id: I4ec69712535c322ba8bb8ba8be7943589c10d69b
Signed-off-by: Vaclav Demcak <>
8 years agoBUG 2412 - restconf @POST createConfigurationData method migration 54/15354/13
Vaclav Demcak [Mon, 2 Mar 2015 14:18:03 +0000 (15:18 +0100)]
BUG 2412 - restconf @POST createConfigurationData method migration

* migration to new faster Infrastructure API and Codecs for method
@POST createConfigurationData(String,NormalizedNodeContext,UriInfo)
on @Path {/config/identifier}

New faster Infrastructure API works with NormizedNodeContext and
we are replacing createConfigurationData method from RestconfService
to use NormalizedNodeContext.

* add additional functionality to find a correct child DataSchemaNode
for @POST input payload in XmlNormalizedNodeBodyReader

* add fix or comment tests - problem with RestconfDocumentedExceptionMapper
      - it has to be fixed in future commit in this chain

Change-Id: I8348002aaa817bc4816a0d132f5811fa84eda389
Signed-off-by: Vaclav Demcak <>
8 years agoBUG 1269 - fill HTTP POST response location attribute 74/11274/16
Vaclav Demcak [Mon, 2 Mar 2015 14:16:10 +0000 (15:16 +0100)]
BUG 1269 - fill HTTP POST response location attribute

HTTP POST response atribute LOCATION is now filled with URI to top level
data which were inserted via POST HTTP operation.

RestCodec call was added. Not all codecs have String as output of serialize method
(InstanceIdentifier, Identityref). Currently serialize output is
transformed to string via toString method.

Change-Id: I7e6abbf100b2458907a1afd3b0dd96a6c54d5652
Signed-off-by: Vaclav Demcak <>
8 years agoBUG 2412 - restconf @PUT updateConfigurationData method migration 53/15353/12
Vaclav Demcak [Wed, 11 Feb 2015 14:41:59 +0000 (15:41 +0100)]
BUG 2412 - restconf @PUT updateConfigurationData method migration

* migration to new faster Infrastructure API and Codecs for method
@PUT updateConfigurationData(String, NormalizedNodeContext)
on @Path {/config/identifier}

New faster Infrastructure API works with NormizedNodeContext and
we are replacing updateConfigurationData method from RestconfService
to use NormalizedNodeContext.

* add fix or comment tests - problem with RestconfDocumentedExceptionMapper
  - it has to be fixed in future commit in this chain

Change-Id: Idc2294daed170c9e7dd5a5a0464a961759b34992
Signed-off-by: Vaclav Demcak <>
8 years agoMerge "Remove Neutron dependencies"
Tony Tkacik [Sun, 8 Mar 2015 15:37:14 +0000 (15:37 +0000)]
Merge "Remove Neutron dependencies"

8 years agoMerge "BUG 2412 - restconf RestconfDocumentedExceptionMapper class migration"
Tony Tkacik [Sun, 8 Mar 2015 15:14:37 +0000 (15:14 +0000)]
Merge "BUG 2412 - restconf RestconfDocumentedExceptionMapper class migration"

8 years agoMerge changes If17aefba,I36d0f5ec
Tony Tkacik [Sun, 8 Mar 2015 15:13:27 +0000 (15:13 +0000)]
Merge changes If17aefba,I36d0f5ec

* changes:
  BUG 2412 - restconf getOperations method migration
  BUG 2412 - restconf mountpoint getOperations method migration

8 years agoMerge topic 'cleanup/composite-node'
Tony Tkacik [Sun, 8 Mar 2015 15:12:48 +0000 (15:12 +0000)]
Merge topic 'cleanup/composite-node'

* changes:
  BUG 2412 - restconf @GET getAvailableStreams(uri) method migration
  Add SchemaContext to NormalizedNode parser in RESTCONF

8 years agoBUG 2412 - restconf getOperations method migration 19/15819/6
Vaclav Demcak [Wed, 25 Feb 2015 00:47:50 +0000 (01:47 +0100)]
BUG 2412 - restconf getOperations method migration

* migration to new faster Infrastructure API and Codecs for method
@GET getOperations(UriInfo) on @Path {/operations}

New faster Infrastructure API works with NormizedNodeContext and
we are replacing first method getModule(URI) from RestconfService
to use NormalizedNodeContext.
BUT we are not able follow specification for migration in this case
because, we have to change restconf-netconf yang schema before.

Change-Id: If17aefbaa139ee7f1064b25a8592da76d71c4bc4
Signed-off-by: Vaclav Demcak <>
8 years agoMerge "Fixed build-failure because of undeclared transtive dependency."
Tony Tkacik [Sun, 8 Mar 2015 14:15:02 +0000 (14:15 +0000)]
Merge "Fixed build-failure because of undeclared transtive dependency."

8 years agoBUG 2412 - restconf @GET getAvailableStreams(uri) method migration 74/14974/12
Vaclav Demcak [Wed, 11 Feb 2015 12:04:49 +0000 (13:04 +0100)]
BUG 2412 - restconf @GET getAvailableStreams(uri) method migration

* migration to new faster Infrastructure API and Codecs for method
@GET getAvailableStreams(UriInfo) on @Path {/streams}

New faster Infrastructure API works with NormizedNodeContext and
we are replacing getAvaliableStreams(UriInfo) method from RestconfService
to use NormalizedNodeContext.

* fix test suiteRestGetOperationTest

Change-Id: Ibe07c2afa72177a259ed7bb23a47e95369d0c145
Signed-off-by: Vaclav Demcak <>