netconf.git
3 years agoAdd diffie-hellman-group14-sha1 to the list of default key exchange algorithms 71/95471/1 stable/magnesium
Oleksii Mozghovyi [Wed, 10 Mar 2021 10:47:55 +0000 (12:47 +0200)]
Add diffie-hellman-group14-sha1 to the list of default key exchange algorithms

The list of key exchange algorithms enabled by default has been changed
with a Mina SSHD uplift to the version of 2.6.0, leaving some of the
SHA1 algorithms disabled by default. Some the devices might still use
this algorithm, so this change brings back the
'diffie-hellman-group14-sha1' algorithm to the list.

JIRA: NETCONF-765
Change-Id: Iea58448981e19f1632799d05dbda8784415ebf1f
Signed-off-by: Oleksii Mozghovyi <oleksii.mozghovyi@pantheon.tech>
(cherry picked from commit 79c50af55997e216a7c70e13a53a88d94b2b62c7)

3 years agoUpgrade sshd to 2.6.0 59/95259/4
Iaroslav [Tue, 2 Feb 2021 14:31:46 +0000 (16:31 +0200)]
Upgrade sshd to 2.6.0

Upgrade sshd to version 2.6.0

JIRA: NETCONF-752
Change-Id: Iaf6fd1ab232458aeb58636590bc84d3d8d2036f6
Signed-off-by: Iaroslav <iaroslav.kholiavko@pantheon.tech>
(cherry picked from commit 96eb5a33f9406e0c5d34fdab6358e9bb0c3797df)

3 years agoBump versions by x.y.(z+1) 99/94199/1
jenkins-releng [Fri, 11 Dec 2020 08:52:52 +0000 (08:52 +0000)]
Bump versions by x.y.(z+1)

Signed-off-by: jenkins-releng <jenkins-releng@opendaylight.org>
Change-Id: I364d7b1a2b6d13b5a2f2143e2e219548c3522f15

3 years agoBump upstream versions 98/93798/2
Robert Varga [Thu, 12 Nov 2020 11:43:27 +0000 (12:43 +0100)]
Bump upstream versions

Pick up:
- odlparent-6.0.12
- yangtools-4.0.14
- mdsal-5.0.16

Change-Id: Id8bd2126d14edcc81e473e30334894d8fa00aaf5
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoCorrect operations input/output media types 22/93522/1
Robert Varga [Tue, 3 Nov 2020 13:45:09 +0000 (14:45 +0100)]
Correct operations input/output media types

We do not produce/consume raw yang-data, add the missing XML
qualifier.

JIRA: NETCONF-741
Change-Id: I2978527125c80ae142af1f0b307c3b99adbe3ba9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit f679d21f00818505ec5b5299c4ffce7dea9263f4)

3 years agofix example string generation for types with isBasicLatin pattern 66/93566/1
Cmarada, Michal [Tue, 27 Oct 2020 13:30:10 +0000 (14:30 +0100)]
fix example string generation for types with isBasicLatin pattern

Generex generator fails to create example if pattern contains
{isBasicLatin} condition. The issue is fixed by replacing original
condition by range of allowed basic latin characters (0x00 - 0x7F).

JIRA: NETCONF-737
Signed-off-by: Cmarada, Michal <michal.cmarada@pantheon.tech>
Change-Id: I7bc5bf3621a40804122acd4604cfe8c132ffff24

3 years agoTest SchemaExportContentYangBodyWriter 94/93394/2
Jakub Toth [Thu, 13 Apr 2017 12:44:20 +0000 (14:44 +0200)]
Test SchemaExportContentYangBodyWriter

Change-Id: Ib40451621d5f20731186003ab88f4054e98546e7
Signed-off-by: Jakub Toth <jatoth@cisco.com>
(cherry picked from commit 0ce9ec3dcc59f1cef3c896b8e2573f711aa25a39)

3 years agoAdd workaround for SSH connection issue related to SSHD-1028 15/93115/1
Tibor Král [Mon, 26 Oct 2020 03:03:02 +0000 (04:03 +0100)]
Add workaround for SSH connection issue related to SSHD-1028

Provide custom version of Nio2Session which overrides the
bugged method.

JIRA: NETCONF-736
Change-Id: I0ef091680a9bdbe6bcab889335bb5ff48e91b703
Signed-off-by: Tibor Král <tibor.kral@pantheon.tech>
(cherry picked from commit 28925cdfe32f72ebcd034c9c7c9c107f176ca452)

3 years agoSquash registrations 41/93041/1
Robert Varga [Wed, 14 Oct 2020 09:42:07 +0000 (11:42 +0200)]
Squash registrations

Use a minimally-sized List instead of default allocation.

Change-Id: I58ce1082a96d546d66ce4ca59df14c20b2bc9d2a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoAdd SchemaSourceRegistration list to NetconfConnectorDTO 39/93039/2
Robert Varga [Wed, 14 Oct 2020 06:41:41 +0000 (08:41 +0200)]
Add SchemaSourceRegistration list to NetconfConnectorDTO

When a NetconfDevice is initialized, we keep track of it via
NetconfConnectorDTO. As a device actually can have some YANG Library
source attached to it, we are registering them as well, but we are
failing to unregister them.

Keep the registration list in the DTO and route close requests
towards it -- allowing us to also remove the registrations.

JIRA: NETCONF-675
Change-Id: Id1d5fb2ff23aad766273e22d5f6f6639300fb3a5
Signed-off-by: PeterSuna <peter.suna@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoIf there is only one revision is present, return it. 77/92277/1
Vladyslav Marchenko [Tue, 25 Aug 2020 07:32:29 +0000 (10:32 +0300)]
If there is only one revision is present, return it.

JIRA: NETCONF-720
Signed-off-by: Vladyslav Marchenko <vladyslav.marchenko@pantheon.tech>
Change-Id: I9103ef41af9bda1681baddf853fb3f739c20b620
(cherry picked from commit 839046e2c74e05f363ba5aa6809c7eb03b60869e)

3 years agoRevert "Revert "Upgrade mina-sshd to 2.4.0"" 15/92315/1
Robert Varga [Wed, 26 Aug 2020 18:30:07 +0000 (20:30 +0200)]
Revert "Revert "Upgrade mina-sshd to 2.4.0""

This reverts commit f25f45ff27c8a7c7df780df609ec33f6662ea61e,
re-bumping to 2.5.1.

JIRA: NETCONF-716
Change-Id: I520d807c50a8107c0189745cf56e0fbc75871230
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 6cc04f8a72d33b24d78aeeaa65eb8fae8217c608)

3 years agoUse YangConstants.RFC6020_YIN_MEDIA_TYPE 01/92301/1
Robert Varga [Tue, 7 Jul 2020 18:05:01 +0000 (20:05 +0200)]
Use YangConstants.RFC6020_YIN_MEDIA_TYPE

application/yin+xml media type is an RFC6020 definition, and hence
its common definition lives in YangConstants. Use it for there
instead of brewing our own.

Change-Id: I6d9f9fd123ffa6db41994d55400bd8c640c6a1f4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit fe99fcac52d3bd524f8046e0ea151b7704f3d90e)

3 years agoUse YangConstants.RFC6020_YANG_MEDIA_TYPE 00/92300/1
Robert Varga [Tue, 7 Jul 2020 17:58:34 +0000 (19:58 +0200)]
Use YangConstants.RFC6020_YANG_MEDIA_TYPE

application/yang media type is an RFC6020 definition, and hence its
common definition lives in YangConstants. Use it from there instead
of brewing our own.

Change-Id: I75d2c2849e8d4e98760445148f1afc9b1f0acb6d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit e8ac0cf7f89d9f746da699de1d3f0d1eff1241dc)

3 years agoEnable server heartbeats 96/92296/1
Robert Varga [Fri, 31 Jul 2020 08:38:30 +0000 (10:38 +0200)]
Enable server heartbeats

When we configure the server to have any timeout, make sure we give
initiate a heartbeat at least three times before timing out. Also, if
we do not specify the idle timer, we need to disable NIO2 read timeout.

JIRA: NETCONF-716
Change-Id: I2c6ed07b5d3b29f6524b0ed99067895c4dfdc020
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit d512058bc228950fab6ede804c0b533588367dcf)

3 years agoDisable NIO read timeout by default 95/92295/1
Robert Varga [Tue, 4 Aug 2020 16:57:21 +0000 (18:57 +0200)]
Disable NIO read timeout by default

Rework which timeouts are disabled, as we are hitting timeout
after 615 seconds.

JIRA: NETCONF-716
Change-Id: I98ef51b4346c2aee0c9c87d58035bc08ef2c77d1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 84c3a3198ad33135dbc982dfb048ee5906d79ece)

3 years agoRevert "Upgrade mina-sshd to 2.4.0" 82/91882/2
Jamo Luhrsen [Tue, 4 Aug 2020 22:54:11 +0000 (15:54 -0700)]
Revert "Upgrade mina-sshd to 2.4.0"

This reverts commit 560e49a0c5d879e763eb82f737db92bc78a276d3
as well as c2e07b76734c34a2fe88262530b4ac4a387b8ee7, as these
are suspected to cause a regression.

JIRA: NETCONF-716
Change-Id: Ie73f3a7b0b4f41e690b368035f212938916b40dd
Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
(cherry picked from commit f25f45ff27c8a7c7df780df609ec33f6662ea61e)

3 years agoRevert "Expand rsa-ssh2 signatures" 90/92290/1
Jamo Luhrsen [Tue, 4 Aug 2020 22:06:18 +0000 (15:06 -0700)]
Revert "Expand rsa-ssh2 signatures"

This reverts commit 3453c508f27c64feb7220c84160a34df732b9738.

Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Change-Id: Ib3d442178877c82c760a625ff5acaa546ba797d4
(cherry picked from commit 19af114f06221cf94c5ef2c6d96b02ea67a05fc6)

3 years agoExtra superfluous edit-config RPC sent 04/92104/1
Jamo Luhrsen [Wed, 12 Aug 2020 22:54:35 +0000 (15:54 -0700)]
Extra superfluous edit-config RPC sent

Extra superfluous edit-config RPC sent just prior to correct edit-config
RPC for top-level lists POST & PUT to certain top-level lists in a
mounted device's model returns a 500 error via Restconf, although in
some cases (device-dependent) the config appears to have committed.

This problem first appeared in Boron-SR3, and continues in Carbon SR-1.

JIRA: NETCONF-482

Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Change-Id: I718bda377245d884864e160f2566e7c3d8e62e47
(cherry picked from commit 371f6acfd6cf89319ecbffeb0259e2ce13d32405)

3 years agoAdd import for netconf-node-optional 35/91735/2
Nikhil Soni [Fri, 3 Jul 2020 07:35:54 +0000 (13:05 +0530)]
Add import for netconf-node-optional

This was missed in the initial work to add the
optional schema first added here:
  https://git.opendaylight.org/gerrit/c/netconf/+/82521

Because of that, adding any of the optional configs
(e.g., datastore-lock) to the body of the create device
RPC was failing. importing it in netconf-node-topology
fixes that.

JIRA: NETCONF-670
Change-Id: I5fc72d9714e0fb4f1dfd26f161d2eb3dcfe8862a
Signed-off-by: Nikhil Soni <nsoni@luminanetworks.com>
(cherry picked from commit 9ed4befdde4f9c88705ddd1ec70c5b5b5ec19a25)

3 years agoBump versions by x.y.(z+1) 98/91998/1
jenkins-releng [Mon, 10 Aug 2020 07:29:35 +0000 (07:29 +0000)]
Bump versions by x.y.(z+1)

Signed-off-by: jenkins-releng <jenkins-releng@opendaylight.org>
Change-Id: Ie4053f76fc90f1a16024125c383602b5eac379fc

3 years agoReturn Location in resp header for notif subscrip 05/91805/2
Jamo Luhrsen [Fri, 31 Jul 2020 19:24:22 +0000 (12:24 -0700)]
Return Location in resp header for notif subscrip

For rfc8040 responses we are not getting the Location
returned in the response header. This addresses that.

Pulling this work from master commit in work for NETCONF-312
This patch https://git.opendaylight.org/gerrit/c/netconf/+/90371

JIRA: NETCONF-676

Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Change-Id: Ia84da3b9cf0789328af72607c8f739ff81c331a4

3 years agoSynchronize stop and reschedule keepalive methods 21/91721/2
Anna Bencurova [Tue, 28 Jul 2020 12:19:45 +0000 (14:19 +0200)]
Synchronize stop and reschedule keepalive methods

Synchronize to avoid stucked scheduled keepalive task. This is not
a perfect solution, but should work for now.

JIRA: NETCONF-715
Change-Id: I130507f3e6472c8b15eb027e40ab41c972f075ec
Signed-off-by: Anna Bencurova <Anna.Bencurova@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoBump odlparent/yangtools/mdsal to 6.0.11/4.0.13/5.0.14 55/91555/1
Robert Varga [Wed, 22 Jul 2020 21:27:46 +0000 (23:27 +0200)]
Bump odlparent/yangtools/mdsal to 6.0.11/4.0.13/5.0.14

Pick up latest updates from upstream.

Change-Id: I8145730aaec3fa94a8647ed0e719909520424089
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoAdd support for nested notifications to NetconfMessageTransformer 92/90692/5
Anna Bencurova [Thu, 25 Jun 2020 12:16:02 +0000 (14:16 +0200)]
Add support for nested notifications to NetconfMessageTransformer

RFC7950 nested notifications are becoming the norm, yet we cannot
seem to grasp them. This patch adds preliminary support for decoding
them and shuffling them towards whoever may be consuming them.

JIRA: NETCONF-704
Change-Id: I63bebf87de93611f7c887f8b077e59000876aa84
Signed-off-by: Anna Bencurova <Anna.Bencurova@pantheon.tech>
3 years agoBump odlparent/yangtools/mdsal to 6.0.10/4.0.12/5.0.13 84/91384/1
Robert Varga [Fri, 17 Jul 2020 15:23:51 +0000 (17:23 +0200)]
Bump odlparent/yangtools/mdsal to 6.0.10/4.0.12/5.0.13

Pick up latest updates from upstream.

Change-Id: If2bf45eae7c2db8c26edeb3b63a4114166d35bd0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoFix missing stream leaf value 73/91373/1
Nikhil Soni [Thu, 18 Jun 2020 16:31:36 +0000 (22:01 +0530)]
Fix missing stream leaf value

If any subscription is present, attempting to build the tree will be
rejected, as the leaf will not have a set value.

JIRA: NETCONF-700
Change-Id: I6d448ceb42605b268408c91844c5b08b0c8929eb
Signed-off-by: Nikhil Soni <nsoni@luminanetworks.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoFix Nested YANG 1.1 Action invocation 67/91067/1
ajay_dp001 [Sun, 12 Jul 2020 07:21:17 +0000 (12:51 +0530)]
Fix Nested YANG 1.1 Action invocation

Invocation of action fails if the action is defined as an augmentation.
As it turns out the logic can be very much simplified by just cutting
the last item from YangInstanceIdentifier, as that points to the parent
(and hence context) of the action.

JIRA: NETCONF-696
Signed-off-by: ajay_dp001 <ajay.deep.singh@est.tech>
Change-Id: I1d5cd6f65ae4d040d36de5f24f6d76fe5076991f

3 years agoFix OperationsCreator javadoc 87/91087/1
Robert Varga [Fri, 10 Jul 2020 10:46:02 +0000 (12:46 +0200)]
Fix OperationsCreator javadoc

checkstyle is a bit more touchy, fix it up.

Change-Id: I39ad689d10ba508f2284cbc6cdf9c915ab5796c9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoBump odlparent/yangtools/mdsal 83/91083/2
Robert Varga [Fri, 10 Jul 2020 05:00:31 +0000 (07:00 +0200)]
Bump odlparent/yangtools/mdsal

This adopts the following versions:
- odlparent-6.0.9
- yangtools-4.0.11
- mdsal-5.0.12

Change-Id: I28f0fafe62c6111bac3411ec36a12a746ec67535
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoExpand rsa-ssh2 signatures 57/91057/1
Robert Varga [Wed, 8 Jul 2020 07:01:58 +0000 (09:01 +0200)]
Expand rsa-ssh2 signatures

With mina-sshd 2.5.0 we can also support openssh.com versions,
update the list to match.

Change-Id: I4440329912e928ba035e3f7ee9f73ef0f7cc9257
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 8ebdad28dfd63d6a226e2a7b8a907dc2e703321c)

3 years agoBump mina-sshd to 2.5.1 55/91055/1
Robert Varga [Tue, 7 Jul 2020 16:46:41 +0000 (18:46 +0200)]
Bump mina-sshd to 2.5.1

https://github.com/apache/mina-sshd/blob/master/docs/changes/2.5.0.md
https://github.com/apache/mina-sshd/blob/master/docs/changes/2.5.1.md

Change-Id: I95b25909fad428a3ba61472cedc7d98c3ebe1532
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit c2e07b76734c34a2fe88262530b4ac4a387b8ee7)

3 years agoAdd rsa-sha2 signatures to default client 49/90749/1
Robert Varga [Tue, 7 Jul 2020 21:38:03 +0000 (23:38 +0200)]
Add rsa-sha2 signatures to default client

Netopeer2 can be configured to only allow rsa-sha2 signatures, in
which case we fail to connect to it. Add these to the list of
supported signatures by default.

Change-Id: I00a961e23c06c99dfca0043dd2129fc1438d0b94
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 66c5129a69f4697e7f42b6b4342dc2f30206814f)

3 years agoBind operation prefix to correct namespace 47/90747/1
Robert Varga [Thu, 17 Jan 2019 12:05:32 +0000 (13:05 +0100)]
Bind operation prefix to correct namespace

During NetconfUtil.writeNormalizedNode() we failed
to set a prefix for the netconf operation leading to a warning.
Make sure we set the correct NamespaceContext and fallback
to setPrefix() in case the underlying DOM writer does not
support setNamespaceContext().

JIRA: NETCONF-603
Change-Id: Icff5e045c4e901bb53990177d448a1ea43952c62
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
Signed-off-by: Tomas Cere <tomas.cere@pantheon.tech>
(cherry picked from commit 197acb99bed8c585e26091eafb761481533718a0)

3 years agoReport HTTP status 409 on DATA_MISSING error 59/89559/7
Lukas Baca [Mon, 4 May 2020 09:47:23 +0000 (11:47 +0200)]
Report HTTP status 409 on DATA_MISSING error

Change the HTTP status reported on DATA_MISSING conditions to 409,
to match RESTCONF specification. Previous behavior of using 404
can be selected globally via a system property.

JIRA: NETCONF-682
Change-Id: Ibb10b7f9b8d49cd85edaf4fee8986a14cc9f3506
Signed-off-by: Lukas Baca <lbaca@luminanetworks.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
3 years agoRevert "Fix nested YANG 1.1 Action invocation" 84/90484/2
Jamo Luhrsen [Mon, 22 Jun 2020 17:59:23 +0000 (17:59 +0000)]
Revert "Fix nested YANG 1.1 Action invocation"

This reverts commit 126f12f7a2f64d88060f6d55e3c738e5d891deed.

Reason for revert: checking if this caused the regression reported in NETCONF-702

Change-Id: I6f65c587f5e9d04e67dcdcaeda12688d206524b5
Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
3 years agoCatch exception when transformer fails to parse 71/90271/2
Jamo Luhrsen [Thu, 4 Jun 2020 00:17:26 +0000 (17:17 -0700)]
Catch exception when transformer fails to parse

There is a deadlock if a transformer fails to parse a reply
and uses that to invoke the rpc. The future gets stuck and
never completes. This catches the case of a bad toRpcResult
from the transformer and marks the future with a
DefaultDOMRpcException

JIRA: NETCONF-695
Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Change-Id: Ied3e0ac4b08e128c41f54e01df91543e4d3fc3a4

3 years agoFix nested YANG 1.1 Action invocation 61/90261/1
ajay_dp001 [Wed, 3 Jun 2020 04:27:28 +0000 (09:57 +0530)]
Fix nested YANG 1.1 Action invocation

Invocation of action fails if the action is defined as an augmentation.
As it turns out the logic can be very much simplified by just cutting
the last item from YangInstanceIdentifier, as that points to the parent
(and hence context) of the action.

JIRA: NETCONF-696
Change-Id: I7b03b2b1ebdd7bffbfab5291552c430700ff2850
Signed-off-by: ajay_dp001 <ajay.deep.singh@est.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoClean up some log messages and descriptions 89/89989/2
Jamo Luhrsen [Wed, 27 May 2020 17:21:22 +0000 (10:21 -0700)]
Clean up some log messages and descriptions

Just some minor changes for readability when digging through
log files. yang desrciption was changed to match log message
as they were duplicates of each other.

Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Change-Id: I51a6deee824ef95b3c7721c2e555f247d95de781
(cherry picked from commit 49fcac580c1d866bb76a87abc7e0a4f53c25c032)

3 years agoHandle multiple rpc-error in the same rpc-reply 56/90256/1
Jamo Luhrsen [Thu, 14 May 2020 21:12:58 +0000 (14:12 -0700)]
Handle multiple rpc-error in the same rpc-reply

When multiple rpc-error is seen in a reply it was not being
caught as an error and eventually falling through the cracks
to show up as an IllegalArgumentException.

This also adds a hack/workaround for passing back all the
error messages found from each of the multiple rpc-error(s)

Also, instead of this case not being recognized as an
rpc-error, it was causing the request to wait until
the device request timeout to expire at which point it's
noted as a full RPC failure and the device is disconnected
and reconnected. Now it is recognized as an error and the
response is handled as soon as it's received and there is
no connection flap.

JIRA: NETCONF-666
Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Change-Id: I71829e04d7642cfd4d1c54596f1fc7670db0d292
(cherry picked from commit 8b2fc27e338bdd9cea9674204c1ec3d40a0c68c4)

3 years agoUse censor attribute for CLI commands 85/89985/1
Venkatrangan Govindarajan [Wed, 27 May 2020 20:57:58 +0000 (02:27 +0530)]
Use censor attribute for CLI commands

This patch will help avoid usernames/passwords for device
access to be saved in karafhistory

JIRA: NETCONF-694
Change-Id: If2ac255b0ec9bbc32e3aec7d0247497cc927a3e1
Signed-off-by: Venkatrangan Govindarajan <vgovindarajan@luminanetworks.com>
(cherry picked from commit 1c201f8a99753109f18a47053c16c2d9b756ac37)

3 years agoNETCONF-685 : Correctly propagate 'pageNum' query parameter 53/89753/2
Richard Kosegi [Wed, 13 May 2020 13:58:01 +0000 (15:58 +0200)]
NETCONF-685 : Correctly propagate 'pageNum' query parameter

There is slight difference between html code used for
bierman vs. 8040 apidocs explorer. However they both trigger same
code path on server side. 8040 is not sending 'pageNum' query
parameter that server-side code is expecting, which leads to NPE.

Change-Id: I7948276390ecf76927a9720ee20ffc1b3c36a109
Signed-off-by: Richard Kosegi <richard.kosegi@gmail.com>
3 years agoCorrect POST Location with lists 29/89929/2
wsx25289 [Sun, 26 Apr 2020 07:17:28 +0000 (03:17 -0400)]
Correct POST Location with lists

When a document is POSTed to a map, we end up returning the wrong
location. Update location with the first entry in the map to produce
the correct result.

JIRA: NETCONF-676
Change-Id: I0a8ab5a8147b98847a1fbb1b66cc7bb7b7722872
Signed-off-by: Wsx25289 <10200860@zte.com.cn>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit d2e6a73b08ae4a3d6a7975895404ca3de07d2ee2)

3 years agoClean up PostDataTransactionUtil 85/89885/2
Robert Varga [Fri, 22 May 2020 09:23:28 +0000 (11:23 +0200)]
Clean up PostDataTransactionUtil

These methods are horrible in their if/else use. Clean them up a bit
so as to make clearer what is going on.

Change-Id: I8b6a619c3c9af548af42985a79fdf7d9c99a9fa0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoAllow SshClient to be customized via NetconfClientConfiguration 83/89883/2
Tibor Král [Wed, 20 May 2020 13:16:40 +0000 (15:16 +0200)]
Allow SshClient to be customized via NetconfClientConfiguration

There are a number of options we want to have configurable on
a per-client (rather than per-dispatcher) basis. These options
are related to how SSH operates and hence we do not want to
duplicate them but rather allow an explicit pre-built client
instance to be passed down.

JIRA: NETCONF-641
Change-Id: I4c39a8ec909edae0ca15e5af4efd7ca690d64fbf
Signed-off-by: Tibor Král <tibor.kral@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
3 years agoGet notification streams error. 53/89553/2
wsx25289 [Fri, 3 Apr 2020 09:14:58 +0000 (05:14 -0400)]
Get notification streams error.

Get streams should have correct response.

JIRA: NETCONF-663

Change-Id: I5cd5342653795b5531ca66cf6d839f9568c59474
Signed-off-by: Wsx25289 <10200860@zte.com.cn>
3 years agoNETCONF southbound requires notifications.yang model to be present on the device 08/89908/1
vladyslav.marchenko [Mon, 23 Mar 2020 15:05:23 +0000 (17:05 +0200)]
NETCONF southbound requires notifications.yang model to be present on the device

There is no standardized YANG model for NETCONF notifications simply
because RFC5277 predates YANG and has not been updated. The presence
of the notification capability is enough for notifications to work –
the SchemaContext assembly code supplies the model internally based
on the capability.

JIRA: NETCONF-338
Signed-off-by: vladyslav.marchenko <Vladyslav.Marchenko@pantheon.tech>
Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Change-Id: Iaec5eab02f8d43f752d90a3fd0ecbc0a57e9e75f

3 years agoAdjust window on read 28/89828/1
Robert Varga [Thu, 14 May 2020 21:09:03 +0000 (23:09 +0200)]
Adjust window on read

As a side-effect of us bypassing the read function, we no longer
update the window occupancy, which leads to the other side stopping
sending data. Make sure we adjust the window after passing the data
down the pipeline.

JIRA: NETCONF-686
Change-Id: I66c4873d901f7b88aabd97a1c599be64397b16c7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 65f621ffc65f5905bd94692927ca8e4fede5efff)

3 years agoRe-integrate ssh client 27/89827/1
Robert Varga [Fri, 27 Sep 2019 11:19:22 +0000 (13:19 +0200)]
Re-integrate ssh client

This re-wraps SshClient in a different way, allowing us to shuffle
information directly into netty.

JIRA: NETCONF-674
Change-Id: Iba0abf81fda90b45403b507c7a00ec9fad48c5a1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
Signed-off-by: Tibor Král <tibor.kral@pantheon.tech>
Signed-off-by: Vladyslav Marchenko <vladyslav.marchenko@pantheon.tech>
(cherry picked from commit 7461000dc0c8263ae58f3f95e1e3081daf9f69fa)

3 years agoUpgrade mina-sshd to 2.4.0 26/89826/1
Robert Varga [Mon, 27 Apr 2020 18:45:25 +0000 (20:45 +0200)]
Upgrade mina-sshd to 2.4.0

https://github.com/apache/mina-sshd/blob/master/docs/changes/2.4.0.md

Change-Id: I26a5cdc8eb699c16c86352156b55ffa331762c5e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 2697d67c6b0eac8bfb4a459ba1036cd872ac53c2)

3 years agoShade mina-sshd 25/89825/1
Robert Varga [Mon, 27 Apr 2020 12:25:30 +0000 (14:25 +0200)]
Shade mina-sshd

Karaf is using a down-reved version of sshd, which unfortunately
has interplay with us providing a newer version. Shade apache-sshd
so that we can ship whatever version we want without worries about
overlap.

JIRA: NETCONF-677
Change-Id: I0b509b6482f2af207bc07328a9cdb720ebbf506f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit c1999af65772cfa7d9a6789926c496c31637772f)

3 years agoEliminate CallHomeSessionContext.nettyChannel 24/89824/1
Robert Varga [Wed, 29 Apr 2020 17:54:00 +0000 (19:54 +0200)]
Eliminate CallHomeSessionContext.nettyChannel

Holding a temporary field only for it to be picked up by a callback
does not make sense. Eliminate it and allocate it much later in the
game.

Change-Id: I34b7dbc7244ef1627797c19d5b0d1c046ea46be3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 50e7111dd182ce505d2a01041ff0b1493d440437)

3 years agoDo not require NetconfSessionImpl 27/89427/2
Robert Varga [Wed, 29 Apr 2020 12:14:18 +0000 (14:14 +0200)]
Do not require NetconfSessionImpl

Drop the instanceOf checks down to simple null checks, so that
we are not tied to a particular implementation.

JIRA: NETCONF-674
Change-Id: I3b9d123d6034a96e6b2d09d68d3cf5bae117cc78
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit d6d0678d47378b5f7ed1316d34ebd240991f5756)

3 years agoBump versions by x.y.(z+1) 91/89791/1
jenkins-releng [Fri, 15 May 2020 01:38:43 +0000 (01:38 +0000)]
Bump versions by x.y.(z+1)

Signed-off-by: jenkins-releng <jenkins-releng@opendaylight.org>
Change-Id: I65d403467fe16b3882338fda01d88be85da72f23

4 years agoEliminate useless allocation 88/89288/2
Robert Varga [Sat, 25 Apr 2020 14:03:33 +0000 (16:03 +0200)]
Eliminate useless allocation

For some reason we are going through an indirection instead of
getting the modules directly. Fix that.

Change-Id: Id49d5db3501dae6cb5368599f4f8c7855115a962
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 433817a40cd93b408afca7dea4e99ba701fbc8c9)

4 years agoAdd sources to shaded-exificient 51/89451/1
Robert Varga [Mon, 27 Apr 2020 13:34:55 +0000 (15:34 +0200)]
Add sources to shaded-exificient

Our shaded-exificient does not contain a source attachment, fix
that.

Change-Id: I5743c31266817dbaa71e46af30e5ab24c11b232d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 8cdfad793c63f870c44c7db717529cf59dbd5b21)

4 years agoExclude xmlpull's MANIFEST.MF 50/89450/1
Robert Varga [Mon, 27 Apr 2020 13:30:12 +0000 (15:30 +0200)]
Exclude xmlpull's MANIFEST.MF

We do not need this manifest, just ditch it to suppress a warning.

Change-Id: I6837ca40e91db65b22b2b6358d8bb86022b4d2fb
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit c44df3a82e196ede1c7ae41ff76b076fe2a0bef4)

4 years agoRemove unneeded sshd dependency 49/89449/1
Robert Varga [Mon, 27 Apr 2020 13:39:39 +0000 (15:39 +0200)]
Remove unneeded sshd dependency

odl-netconf-util does not need sshd, move it to netconf-netty-util,
where it really belongs.

Change-Id: I254daf9608820af5965724a2eb1873343303b54c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 41c3552923a49955573921411b93c77d447c51c8)

4 years agoAdd eddsa dependency to netconf-testtool 90/89290/2
Robert Varga [Sun, 26 Apr 2020 14:51:36 +0000 (16:51 +0200)]
Add eddsa dependency to netconf-testtool

This enables it to process ed25519 keys, which is useful.
Also remove superfluous xmlunit version specification.

Change-Id: Ib8803c2684e14840269fbec9f71b89b0d4b460a8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove unneeded blueprint-core dependency 85/89385/1
Robert Varga [Sat, 25 Apr 2020 19:11:17 +0000 (21:11 +0200)]
Remove unneeded blueprint-core dependency

Not sure why this was ever needed, remote it.

Change-Id: Ife5c4ccd5e1bb64a3717e7aa838a83a9d3395c0f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit b3290906d9a61c317e7b239aca0634a991a056dd)

4 years agoMove eddsa dependency 84/89384/1
Robert Varga [Sat, 25 Apr 2020 19:02:07 +0000 (21:02 +0200)]
Move eddsa dependency

We actually do not need to have it in netconf-netty-util, it
is enough to have it as a test dependency near SSHTest.

Change-Id: Id4b56883ff155c102874e751a8cefb9b5c72325f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 66d50efd0d2e18a00c08f53f5549ce66224a4f61)

4 years agoPull eddsa into netconf-netty-util 80/89280/2
Robert Varga [Wed, 22 Apr 2020 23:15:03 +0000 (01:15 +0200)]
Pull eddsa into netconf-netty-util

Pulling in this dependency allows SSHTest to pass with ed25519
keys being configured.

Change-Id: I1084e207503ab5e6f4ed50405fecabb96a018841
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit a3a133c313057124c2e5f26cde5cd7af8402fca0)

4 years agoBump odlparent/yangtools/mdsal 96/89196/3
Robert Varga [Tue, 21 Apr 2020 10:39:36 +0000 (12:39 +0200)]
Bump odlparent/yangtools/mdsal

This adopts the following versions:
- odlparent-6.0.6
- yangtools-4.0.8
- mdsal-5.0.10

Change-Id: I1ccad57f35148b2dd8c53b15c2f6efb5a7e59ed0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd plain PATCH capability to RFC8040 server 65/89165/2
Allan Clarke [Mon, 2 Mar 2020 20:29:11 +0000 (14:29 -0600)]
Add plain PATCH capability to RFC8040 server

Rename constant PATCH to YANG_PATCH - there are now two patch types
Add unit tests for PlainPatchDataTransactionUtil
Update unit tests for RestconfDataService

JIRA: NETCONF-657
Change-Id: I0356e7d4947f89ed603d71e722d845e709ea4e03
Signed-off-by: Allan Clarke <aclarke@pobox.com>
Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit fe6e7e380f5948e2582d97df5cb2498c59353869)

4 years agoReuse SchemaContext.NAME for base NETCONF data qname 14/89214/1
Robert Varga [Tue, 21 Apr 2020 08:46:50 +0000 (10:46 +0200)]
Reuse SchemaContext.NAME for base NETCONF data qname

This QName is a well-known constant available from SchemaContext,
do not use scattered definition.

Change-Id: I68b88d216e35b2583828a73a5d4a2ebe2f092893
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 9851b35a4a68631cdd72f3e96ac6a02ab399da83)

4 years agoAdd a dedicated AuthenticationFailedException 63/89163/1
Robert Varga [Sun, 19 Apr 2020 11:18:47 +0000 (13:18 +0200)]
Add a dedicated AuthenticationFailedException

When we have a failure to authenticate, we want the client to be
able to discern this state.

Add a dedicated exception and report it instead of straight
exception from SSH (which may be anything) or a generic ISE.

JIRA: NETCONF-665
Change-Id: I1f113d5aaff6bf4482d9725adaa06b5d2479304c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 027c3087a288cc7291cdfe265711dfaaa907bf9b)

4 years agoFix defensive subscriber removal 84/89184/1
wsx25289 [Thu, 9 Apr 2020 07:29:44 +0000 (03:29 -0400)]
Fix defensive subscriber removal

Attempting to modify the collection while iterating over it
results in ConcurrentModificationException. Use an explicit
iterator and Iterator.remove() to prevent it.

JIRA: NETCONF-664
Change-Id: I6206dfdd896307f83420cfb3201d1125adbf9a07
Signed-off-by: Wsx25289 <10200860@zte.com.cn>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFiles should not be executable 61/89161/1
Robert Varga [Sun, 19 Apr 2020 13:32:33 +0000 (15:32 +0200)]
Files should not be executable

We do not want these to be executable, drop those permissions.

Change-Id: I1ba2d56cc195dce85809ea48a5d231ddcd3b351a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 240d3fac65776cb33025b1350baa9cb83d869452)

4 years agoDo not consider query depth in initial namespace 36/88936/3
wsx25289 [Mon, 3 Feb 2020 10:57:49 +0000 (05:57 -0500)]
Do not consider query depth in initial namespace

Initial namespace is independent of the maximum depth requested
by the user. This is a mixup with path depth introduced in the
previous fix for NETCONF-497.

Change-Id: I90fdcc60b2be0891082333490d77d681ecc4fc4a
Signed-off-by: Wsx25289 <10200860@zte.com.cn>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix default value check 23/88923/2
Magic_J [Mon, 9 Apr 2018 06:17:44 +0000 (14:17 +0800)]
Fix default value check

TypeDefinition.getDefaultValue() is returning an optional, which
results in it always being non-null. Fix the check for nullness
and make sure we use the correct value.

Change-Id: Id5aba6cd215d4e19f8b583a81e5599daa9bbe12d
Signed-off-by: Magic_J <panda.magic.j@gmail.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove references to sal-common-impl 34/88934/1
Robert Varga [Mon, 6 Apr 2020 11:25:15 +0000 (13:25 +0200)]
Remove references to sal-common-impl

We do not need anything from sal-common-impl, remove references
to it.

Change-Id: If99a707c8d3be10d3a491aff1d1564f14727926a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit dd39734d10f26749ec82835432b1dab3e37f7c3f)

4 years agoMigrate Compendium reference 88/88788/1
Robert Varga [Mon, 6 Apr 2020 10:29:30 +0000 (12:29 +0200)]
Migrate Compendium reference

We are using OSGi R6, migrate the artifact reference.

Change-Id: I1b669bdc5eaa2c235945acf29db2b27e2ed1d62b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 77ba494432b41b3ab84cd8778d0a8157b6efa7b6)

4 years agoBring doc building up to python3 07/88307/1
Jamo Luhrsen [Wed, 26 Feb 2020 00:52:08 +0000 (16:52 -0800)]
Bring doc building up to python3

looks like readthedocs builds have been failing for a while
because python2 can't find some version of sphinx that is
now required by lfdocs-conf. Maybe an older version of
sphinx would still work, but it's time to catch up to
python3 anyway.

integration/test just added this same .readthedocs.yml
file which finally got it's rtd build to work after
having unknowingly been failing for a month:

https://git.opendaylight.org/gerrit/c/integration/test/+/88064
https://readthedocs.org/projects/odl-integrationtest/builds/?page=1

and netconf has been in the same boat:
https://readthedocs.org/projects/odl-netconf/builds/?page=1

Signed-off-by: Jamo Luhrsen <jluhrsen@gmail.com>
Change-Id: I63c01d8d9805ee492ebeb4d1b65723ab8a2d59b9
(cherry picked from commit bca11c23ab24a7119a3972e4629f46e9e0565abd)

4 years agoBump versions by x.y.(z+1) 23/88523/1
jenkins-releng [Thu, 19 Mar 2020 11:59:38 +0000 (11:59 +0000)]
Bump versions by x.y.(z+1)

Signed-off-by: jenkins-releng <jenkins-releng@opendaylight.org>
Change-Id: I04e296a37cfb014e10904281eb203062ff96647f

4 years agoNETCONF-125 connection timeout and between timeout are fixed 95/88295/1
Sarguna Dharani [Mon, 10 Feb 2020 11:55:44 +0000 (17:25 +0530)]
NETCONF-125 connection timeout and between timeout are fixed

Signed-off-by: Sarguna Dharani <sarguna.dharani@verizon.com>
Change-Id: I56275dfa10dcfd4ed1a30fbb6c34169e301269db
(cherry picked from commit fe5d5bcfdc2dff7c6fe83e1c6b7dbb69d386f06c)

4 years agoReject multiple sessions with the same host key 54/88254/1
Manoj Chokka [Mon, 10 Feb 2020 18:15:34 +0000 (23:45 +0530)]
Reject multiple sessions with the same host key

SSH host key is supposed to be unique among devices. If there is an
attempt to establish a session with the same key, terminate the new
session.

Since that rules out the possibility of multiple remotes for a key,
refactor the code to use a ConcurrentMap instead of a Multimap --
removing the need for any locking.

As we really want to use CallHomeProtocolSessionContext in logging,
make it implement a toString() method and clean it up a bit.

JIRA: NETCONF-653
Change-Id: I2d78b9aa34ee4b16d0c6d2ed2ac172942c575851
Signed-off-by: Manoj Chokka <manoj.chokka@verizon.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 547c1ddb9d8794c4cd40b16a88a28e337dfb7730)

4 years agoAdd option to provide custom SshClient for netconf-client 69/87969/2
Tibor Král [Mon, 24 Feb 2020 15:28:11 +0000 (16:28 +0100)]
Add option to provide custom SshClient for netconf-client

When creating netconf-client the DEFAULT SshClient is
used on the background by the AsyncSshHandler. This adds
the option to provide custom SshClient to be used instead.

JIRA: NETCONF-641
Change-Id: I99b1c2e882353732a2e55d0523ee6adbd1ca8cc0
Signed-off-by: Tibor Král <tibor.kral@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 995f11a17da91d69a4c6650016ff4b6afafc1259)

4 years agoDo not attempt to parse empty RPC/action reply 71/87971/1
Sanjana B [Mon, 10 Feb 2020 11:26:59 +0000 (16:56 +0530)]
Do not attempt to parse empty RPC/action reply

An RPC or action can legally result in an empty reply,
even if it has some optional content in its schema.

Detect </ok> reply and do not attempt to parse it as
YANG data.

JIRA: NETCONF-568
JIRA: NETCONF-644
Change-Id: I1f0b5c349f418824b9b0b3e1f01f16824b1b8df4
Signed-off-by: Anna Bencurova <Anna.Bencurova@pantheon.tech>
Signed-off-by: Sanjana B <sanjana.b@verizon.com>
Signed-off-by: Tibor Král <tibor.kral@pantheon.tech>
(cherry picked from commit df25a540e0985695d3d0f93c68a977a4de729329)

4 years agoUpdate .gitreview to stable/magnesium 88/87888/1
jenkins-releng [Tue, 18 Feb 2020 22:05:26 +0000 (22:05 +0000)]
Update .gitreview to stable/magnesium

Signed-off-by: jenkins-releng <jenkins-releng@opendaylight.org>
Change-Id: I80f8f5334ad0348b7e5d5d9fc67f8cc2bfb83ed4

4 years agoDrop the use of google truth/@LogRule 57/87057/2
Robert Varga [Mon, 20 Jan 2020 19:00:16 +0000 (20:00 +0100)]
Drop the use of google truth/@LogRule

Simple JUnit is sufficient here, no need to depend on Truth
nor infrautils-testutils here.

Change-Id: I306799d4adc1f98fe7ffe8477c25fb231d9bd0a4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump to odlparent-6.0.4/yangtools-4.0.6/mdsal-5.0.9 96/86996/3
Robert Varga [Thu, 16 Jan 2020 21:10:01 +0000 (22:10 +0100)]
Bump to odlparent-6.0.4/yangtools-4.0.6/mdsal-5.0.9

Pick up latest fixes and upgrades.

Change-Id: Id639868a847ec16da35040cf2cd45ba83860d99b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd namespace to action request XML 10/86810/2
Anna Bencurova [Wed, 8 Jan 2020 14:33:05 +0000 (15:33 +0100)]
Add namespace to action request XML

JIRA: NETCONF-652
Change-Id: I7a7b52d6db821f82995432c3f75ba24fe8e86067
Signed-off-by: Anna Bencurova <Anna.Bencurova@pantheon.tech>
4 years agoPropagate MountPointContext to NetconfRpcStructureTransformer 15/86515/3
Robert Varga [Thu, 19 Dec 2019 18:04:36 +0000 (19:04 +0100)]
Propagate MountPointContext to NetconfRpcStructureTransformer

We need to be aware of schema mounts, so that we can properly handle
them. This patch attempts to push down MountPointContext to all the
interested places.

Change-Id: Ic1c3a29bf69ee5838cd5f8434a0bcfdc767642b7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd ietf-netconf-acm model 17/86517/3
Robert Varga [Fri, 20 Dec 2019 09:09:07 +0000 (10:09 +0100)]
Add ietf-netconf-acm model

This model is needed with some netconf devices, make sure we
package it.

Change-Id: Ia11367acf9fd670bb76ccb616dab1332b163cfbb
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove websocket-server override 84/86484/1
Robert Varga [Wed, 18 Dec 2019 14:35:20 +0000 (15:35 +0100)]
Remove websocket-server override

odlparent-6.0.3 is providing this declaration, remote it.

Change-Id: Id90d9b07031263d966a17e00e03f7d71b501044c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove jsr173-ri from dependencies 83/86483/1
Robert Varga [Wed, 18 Dec 2019 14:36:17 +0000 (15:36 +0100)]
Remove jsr173-ri from dependencies

JSR173 is part of JRE, hence there is no point to inherit this
dependency. It also helps to have our releases consumable from
Central (which does not carry the .jar).

Change-Id: Iba78f955c8da0b9f0f49ebfa7893094ce8f6931c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove ARIES-1923 workaround 38/86438/1
Robert Varga [Mon, 16 Dec 2019 21:03:55 +0000 (22:03 +0100)]
Remove ARIES-1923 workaround

We now have proper monkey-patch in place and can therefore remove
this workaround.

Change-Id: Ibdccb625f951c1dcd248fbb86176a8474842fd5e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump odlparent/yangtools/mdsal to 6.0.3/4.0.3/5.0.6 68/86368/2
Robert Varga [Thu, 12 Dec 2019 07:01:49 +0000 (08:01 +0100)]
Bump odlparent/yangtools/mdsal to 6.0.3/4.0.3/5.0.6

Pick up the latest upgrades and fixes.

Change-Id: If80c79f631d97b602b908f633f92d8aca4e90cda
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump to odlparent-6.0.1/yangtools-4.0.2/mdsal-5.0.4 18/85618/1
Robert Varga [Wed, 6 Nov 2019 14:09:37 +0000 (15:09 +0100)]
Bump to odlparent-6.0.1/yangtools-4.0.2/mdsal-5.0.4

This picks up latest upgrades and fixes.

Change-Id: I8db358b0af81394a561071d98bffea168dda47cc
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoCorrectly close NormalizedNodeStreamWriters 73/85573/1
Robert Varga [Tue, 5 Nov 2019 06:50:48 +0000 (07:50 +0100)]
Correctly close NormalizedNodeStreamWriters

This code ends up not not closing the stream writer correctly,
which means some state may end up being unfinished. Fix that up.

Change-Id: Icad45cd12d30e44dabe4f86e73a6790bd5137154
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoProperly close stream writer 48/85548/1
Robert Varga [Sun, 20 Oct 2019 09:23:48 +0000 (11:23 +0200)]
Properly close stream writer

Failing to close the streamwriter means it will not output its
trailer in all cases. Fix that.

Change-Id: I218cea9ff61fbc7c33ccab75638dda9a4f20b391
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit bfe9193b90281e42de549fe93e7f690ee72c8dea)

4 years agoUpdating Action Rest Endpoints on Swagger UI 01/85501/2
ajay_dp001 [Sat, 2 Nov 2019 02:25:45 +0000 (02:25 +0000)]
Updating Action Rest Endpoints on Swagger UI

NETCONF-647

Signed-off-by: ajay_dp001 <ajay.deep.singh@est.tech>
Change-Id: I790d81a833bdcb611459b3418fbf66be2388e050

4 years agoFix config/oper reconciliation for leaf-lists 14/85114/6
wsx25289 [Tue, 15 Oct 2019 08:01:30 +0000 (04:01 -0400)]
Fix config/oper reconciliation for leaf-lists

When config and operational datastore both have same data, then if
we get data which has a leaf-list node by rests/data, it will fail,
because there is no code to process leaf-list.

Change-Id: I4724447158bf0a1a12e87145dcb361e8196b1170
Signed-off-by: Wsx25289 <10200860@zte.com.cn>
4 years agoDo not use toString() in looging messages 06/85406/1
Robert Varga [Mon, 28 Oct 2019 12:45:05 +0000 (13:45 +0100)]
Do not use toString() in looging messages

This eliminates unnecessary toString() calls, as logging implementation
will call it when necessary.

Change-Id: Ic3b45b9ae34c29951ed6eea94cae39c423b6ec26
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove remaining use of compat DTO methods 96/85396/1
Robert Varga [Fri, 25 Oct 2019 13:25:51 +0000 (15:25 +0200)]
Remove remaining use of compat DTO methods

This fixes up the final three offenders.

Change-Id: I834fe08bae984d0e5798f5b30d68f7ed1d89f0cf
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMigrate to use java.util.Optional 95/85395/1
Robert Varga [Fri, 25 Oct 2019 13:21:56 +0000 (15:21 +0200)]
Migrate to use java.util.Optional

Modernizer is pointing out this use of Guava, migrate it. Also clean
up builder use in this class.

Change-Id: I2a20e21fa1e767f594d0f20e9eebe6dce4e7996e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMigrate setters 32/84932/7
Robert Varga [Mon, 7 Oct 2019 05:59:21 +0000 (07:59 +0200)]
Migrate setters

This migrate Binding DTO setter usage to use Uint types, fixing
deprecation warnings.

Change-Id: I6eb6224ccaca1444c686eec52b36afa625939557
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdjust for AAA ditching WebClient 90/84790/20
Robert Varga [Fri, 27 Sep 2019 15:15:19 +0000 (17:15 +0200)]
Adjust for AAA ditching WebClient

This adjust for the fact AAA is using Java 11 HttpClient.

Change-Id: Ie0afd4db88828fa76581b830e74819344d19b916
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove superfluous checkstyle/spotbugs configuration 82/85282/1
Robert Varga [Mon, 21 Oct 2019 04:12:43 +0000 (06:12 +0200)]
Remove superfluous checkstyle/spotbugs configuration

odlparent is already configuring these, remove the declarations.

Change-Id: I309cd92b5096f6ec2c2d025f0ba735412dc94720
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAcquire RFC8528 mount point map 90/85090/1
Robert Varga [Thu, 26 Sep 2019 15:58:35 +0000 (17:58 +0200)]
Acquire RFC8528 mount point map

This adds the logic to create a mountpoint map, without supporting
inline schemas and recursion.

Change-Id: I2a9306fd9e021f1b13b9bbac96cfe83e35c5285f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>