netconf.git
13 months agoBump versions to 6.0.0-SNAPSHOT 20/105520/2
Robert Varga [Wed, 19 Apr 2023 19:16:34 +0000 (21:16 +0200)]
Bump versions to 6.0.0-SNAPSHOT

This starts the next major development iteration.

Change-Id: I8f52ebdd1d7a90a4e3c445a52681530bd2d78c43
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoBump versions to 5.0.6-SNAPSHOT 19/105519/3
Robert Varga [Wed, 19 Apr 2023 19:15:57 +0000 (21:15 +0200)]
Bump versions to 5.0.6-SNAPSHOT

This starts the next development iteration.

Change-Id: Ib3c21cef2b3588b44fba33c3e7b242c46b32530b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoFix choice cases usage 88/104988/10
Yaroslav Lastivka [Thu, 23 Mar 2023 10:11:58 +0000 (12:11 +0200)]
Fix choice cases usage

Currently we are generating all cases from choice into payload used
as example in apidoc.
This is incorrect because we can use only one case at the time.
Implemented using first case (or default if specified) node in
apidoc example.

JIRA: NETCONF-983
Change-Id: Ifc32ee00e0de265b4f7e612adb5b8d3783b696a2
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
13 months agoAdd yanglib API for non-revision model 73/104473/14
Peter Suna [Mon, 20 Feb 2023 08:43:58 +0000 (09:43 +0100)]
Add yanglib API for non-revision model

The Yanglib API previously used a single API for both
models with revisions and those without. As a result,
it was necessary to append a '/' at the end of the URL request
for non-revision models.

This issue has now been resolved by introducing a separate API
specifically for non-revision models.

Added tests to validate the handling of both revision
and non-revision models.

Additionally, the existing Yanglib tests have been reworked to
use YANG models stored in resources.

JIRA: NETCONF-968
Change-Id: I3a22de90457bd1b2dbb77f3228bcce83a97ba4e1
Signed-off-by: Peter Suna <peter.suna@pantheon.tech>
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
13 months agoClean up NetconfDeviceTest 06/105206/3
Robert Varga [Tue, 4 Apr 2023 07:16:49 +0000 (09:16 +0200)]
Clean up NetconfDeviceTest

Use anyCollection() consistently to reduce the number of warnings.

Change-Id: I4ac1362640d6989e301d776b139c94c14b5e9c20
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoAdd transport-ssh 99/102299/51
Robert Varga [Wed, 7 Sep 2022 09:48:51 +0000 (11:48 +0200)]
Add transport-ssh

Add NETCONF transport implementation based on Apache SSHD.

Due to connection is managed by underlying TCP component
both sshd client and server implementations are not used
for connection but as factory managers. These are providing
associated session builders with factories configured
and serving ssh sessions.

sshd-netty components were used as reference on establishing
ssh sessions on top of existing communication channel.

JIRA: NETCONF-590
Change-Id: I21245b2f8b932da0a57fa386ee62b05dfcf8cc18
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
Signed-off-by: Ruslan Kashapov <ruslan.kashapov@pantheon.tech>
13 months agoRemove unused methods 75/105475/4
tobias.pobocik [Mon, 17 Apr 2023 10:28:33 +0000 (12:28 +0200)]
Remove unused methods

BaseYangSwaggerGenerator contains unused methods getSchemaService
and getPathVersion. Remove them to simplify our code.

JIRA: NETCONF-993
Change-Id: If1aa5f9e476a61e167849b67c1a56071dda6bb40
Signed-off-by: tobias.pobocik <tobias.pobocik@pantheon.tech>
13 months agoAdd OpenAPI 2 (swagger) authorization 81/105481/3
Ivan Hrasko [Tue, 18 Apr 2023 07:37:49 +0000 (09:37 +0200)]
Add OpenAPI 2 (swagger) authorization

After adding authorization feature into generated OpenAPI 3 docs
enhance OpenAPI 2 docs, too.

We can reuse SECURITY JSON node but the two specs diverge
in specifying which auth methods are used.

OpenAPI 2 uses global securityDefinitions object which we have
to create.

JIRA: NETCONF-990
Change-Id: I38df2414fa34fdf3297446428b31e8d113f1f636
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
13 months agoAdd OpenAPI 3 basic authorization 53/105253/8
Ivan Hrasko [Wed, 5 Apr 2023 13:11:33 +0000 (15:11 +0200)]
Add OpenAPI 3 basic authorization

Enhance JSON generated by ODL with basic authorization.
This way authorize button is shown on UI and user is allowed
to authorize all requests coming from swagger UI. It means
all requests when authorized contain basic auth header.

JIRA: NETCONF-990
Change-Id: If31d355b8a0211d871eda5b14ed6033bb0f1514c
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
13 months agoFix fields processing error for duplicate node names 92/105092/8
Sangwook Ha [Tue, 28 Mar 2023 07:05:55 +0000 (00:05 -0700)]
Fix fields processing error for duplicate node names

NetconfFieldsTranslator saves LinkedPathElement identified by the target
node identifier, hence does not allow keeping track of data nodes with
the same name failing to generate correct paths if such nodes are
included in the fields parameter.

Address the issue by replacing the list of sets to keep track of the
data nodes specified in the fields parameter with a tree of
LinkedPathElement objects keeping track of its parent path element.
This allows generation of all unique paths defined in the fields
parameter and also simplifies the processing.

But this change in the data structure is incompatible with
AbstractFieldsTranslator, and NetconfFieldsTranslator does not inherit
the abstract class.

JIRA: NETCONF-985
Change-Id: I762714f8a25231c1394d75b47e269167b37660f8
Signed-off-by: Sangwook Ha <sangwook.ha@verizon.com>
13 months agoRe-enable IETF links 60/105460/2
Robert Varga [Thu, 13 Apr 2023 16:34:53 +0000 (18:34 +0200)]
Re-enable IETF links

Do not exclude links to IETF anymore.

Change-Id: Ic7faeb69803c1ddd5feacd77d6382643efe772a4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoUpdate old links in user guide 94/105094/3
Sangwook Ha [Tue, 28 Mar 2023 20:51:32 +0000 (13:51 -0700)]
Update old links in user guide

There are several old links permanently redirected to new URLs in the
user guide. Update the links with new ones.

JIRA: NETCONF-986
Change-Id: Ib96f0c2918f1687822d42f4106a836e1a9245a8e
Signed-off-by: Sangwook Ha <sangwook.ha@verizon.com>
13 months agoRefactor and enable linkcheck except for IETF URLs 32/105432/5
guillaume.lambert [Thu, 13 Apr 2023 12:38:19 +0000 (14:38 +0200)]
Refactor and enable linkcheck except for IETF URLs

Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ic92f8995e4e388644c951113066cdfbb575fcda3

13 months agoBump automaton to 1.12-4 17/105417/2
Robert Varga [Wed, 12 Apr 2023 11:51:27 +0000 (13:51 +0200)]
Bump automaton to 1.12-4

There's no functional change.

Change-Id: Iace65d05ef4634feb12084b6397c425fc530a24c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoDisable linkcheck 24/105424/1
Robert Varga [Wed, 12 Apr 2023 15:02:00 +0000 (17:02 +0200)]
Disable linkcheck

Linkcheck is failing on rfc-editor, as noted in
https://jira.linuxfoundation.org/plugins/servlet/desk/portal/2/IT-25351,
disable it until that issue is fixed.

Change-Id: I30976060f43f5da6b3cc6c3ba0f0bc59f8388591
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoAdd transport-tls 00/102300/63
Robert Varga [Wed, 7 Sep 2022 09:48:51 +0000 (11:48 +0200)]
Add transport-tls

Add NETCONF transport implementation based on TCP+TLS.

JIRA: NETCONF-590
Change-Id: I5e0d6ddce30971dd5f2b0918600b9410aa439c08
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
Signed-off-by: Ruslan Kashapov <ruslan.kashapov@pantheon.tech>
13 months agoRemove empty XML lines 12/105112/9
zw1127 [Thu, 30 Mar 2023 09:19:55 +0000 (17:19 +0800)]
Remove empty XML lines

Java 9+ has changed the way indentation works, which means that unlike
Java 8, we are emitting empty lines, quite similar to what has been
reported in https://bugs.openjdk.org/browse/JDK-8262285.

Use an XSL style sheet to ensure we filter out empty Text nodes during
indenting transform opereations.

JIRA: NETCONF-988
Change-Id: Ia9e614d2c77766126923b9e1af82bb177dfb0c05
Signed-off-by: zw1127 <zw1016@gmail.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoImprove XmlUtil.toString() 18/105218/2
Robert Varga [Tue, 4 Apr 2023 12:19:18 +0000 (14:19 +0200)]
Improve XmlUtil.toString()

Simplify the try-catch block to cover the minimum required scope.

Change-Id: I61b0bf2d104ff7f272ac335207993d432c11c8ed
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoModernize XmlUtilTest 17/105217/2
Robert Varga [Tue, 4 Apr 2023 12:10:17 +0000 (14:10 +0200)]
Modernize XmlUtilTest

Use assertThrows() and text blocks to make it clearer as to what
we are doing.

Change-Id: I3ac89a14bc76d4427449aa9f24d820268b709d6e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoFix yang-library.json 79/105079/5
Robert Varga [Tue, 28 Mar 2023 08:53:33 +0000 (10:53 +0200)]
Fix yang-library.json

The JSON file should match the XML file, but the assertions are being
made on the XML content twice. Fix that typo and make sure JSON has the
correct content.

Change-Id: I74f260d062a8129c6446d3a509f093909da87075
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoUse assertEquals() instead of Hamcrest 78/105078/5
Robert Varga [Tue, 28 Mar 2023 08:45:47 +0000 (10:45 +0200)]
Use assertEquals() instead of Hamcrest

We have very simple assertions, there is no need to use Hamcrest here.

Change-Id: Ie3ca9a7688c1746bc7e572406475c25dee8d6dc1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoAdd (plain) PATCH method to OpenApi 60/104960/4
Yaroslav Lastivka [Thu, 16 Mar 2023 12:33:42 +0000 (14:33 +0200)]
Add (plain) PATCH method to OpenApi

ODL supports also plain PATCH method according to RFC.
PATCH method was added to apidocs.

JIRA: NETCONF-978
Change-Id: Ibaf22388585c4560e163bd5cda35c582135d7ad5
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
14 months agoActivate invalid block 77/105077/3
Robert Varga [Tue, 28 Mar 2023 08:39:33 +0000 (10:39 +0200)]
Activate invalid block

With the underlying improvement addressed we can enable the
commented-out block.

JIRA: NETCONF-381
Change-Id: I734214e0c3b26ab04f4cf2249b9eb582e055769a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoFix yang-library test root element 76/105076/2
Robert Varga [Tue, 28 Mar 2023 08:37:21 +0000 (10:37 +0200)]
Fix yang-library test root element

The 'modules' element is invalid, it should always be 'modules-state',
just as we have them in JSON. Fix the XML files.

Change-Id: Idd2955836f57528fbcf6863d20f6a1c0359a498f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoAcquire revision NodeList only once 75/105075/2
Robert Varga [Tue, 28 Mar 2023 08:29:14 +0000 (10:29 +0200)]
Acquire revision NodeList only once

There is absolutely no point in acquiring the node list twice, much less
executing getLength()'s internals multiple times.

Change-Id: Ibb98f05d067ce0c4b99df2f49968844dc82a0ac3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoFix LibraryModulesSchemas root 74/105074/2
Robert Varga [Tue, 28 Mar 2023 08:21:28 +0000 (10:21 +0200)]
Fix LibraryModulesSchemas root

Root element should refer to modules-state, as per the published module.

Change-Id: Iaa3d8ae6c765f836b2fe28e66501d8a28746b6e9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoUse Map.entry() 73/105073/2
Robert Varga [Tue, 28 Mar 2023 07:42:55 +0000 (09:42 +0200)]
Use Map.entry()

We guarantee non-null values, use a well-known Map.entry() method
instead of SimpleImmutableEntry.

Change-Id: I026080a01f8cb39d12fc912cca0be1ecfdb775b7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoModernize LibraryModulesSchemas 72/105072/2
Robert Varga [Tue, 28 Mar 2023 07:40:25 +0000 (09:40 +0200)]
Modernize LibraryModulesSchemas

Use Optional.orElseThrow() instead of Optional.get() to improve clarity.

Change-Id: Ia4f65c793c58601f90cf756a5c864a558d75d4b6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoUse an instanceof pattern 71/105071/2
Robert Varga [Tue, 28 Mar 2023 07:28:45 +0000 (09:28 +0200)]
Use an instanceof pattern

Combine check and cast into an instanceof pattern.

Change-Id: I1638b2f53e164fa6d73fd50ad0ff62ffcd6eed5a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoUse javax.ws.rs.core.MediaType 28/104928/5
tobias.pobocik [Thu, 16 Mar 2023 14:07:15 +0000 (15:07 +0100)]
Use javax.ws.rs.core.MediaType

sal-rest-docgen depends on JAX-RS, hence we can use its constants for
the (constant) 'produces' field.

JIRA: NETCONF-979
Change-Id: I0ed1793cedcf0653e1d5b5cf4f1f6267ce144a46
Signed-off-by: tobias.pobocik <tobias.pobocik@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoBump versions to 5.0.5-SNAPSHOT 44/105044/1
Robert Varga [Mon, 27 Mar 2023 16:51:53 +0000 (18:51 +0200)]
Bump versions to 5.0.5-SNAPSHOT

This starts the next development iteration.

Change-Id: Ic016c2aac96bf03d06734f671769273da3abbaed
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoChange alignments in methods declaration 14/104914/6
Yaroslav Lastivka [Thu, 16 Mar 2023 08:49:03 +0000 (10:49 +0200)]
Change alignments in methods declaration

Apply commonly accepted code style to some sal-rest-docgen classes
to make further development easier.

JIRA: NETCONF-981
Change-Id: Icbd59e052bf1be767bd114425397671f0adf7865
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
14 months agoUpdate testtool documentation 02/104402/11
Peter Suna [Wed, 15 Feb 2023 13:58:24 +0000 (14:58 +0100)]
Update testtool documentation

Update URL in testtool documentation to RFC8040.
Fix the auto-connect section to use the correct parameters,
as the 'scale-util' parameters do not work in the way
described in the documentation.

JIRA: NETCONF-947
Change-Id: I6f3a97073936fa35fe667aae6ab52d1101e0a9a3
Signed-off-by: Peter Suna <peter.suna@pantheon.tech>
14 months agoDisplay default values in help section of testtool 01/104401/5
Peter Suna [Wed, 15 Feb 2023 13:53:15 +0000 (14:53 +0100)]
Display default values in help section of testtool

Not all of the default values are described
in the 'Default Parameters' documentation section. Updating it
may not be maintainable. Therefore, describing the default values
in the help output could be helpful.

JIRA: NETCONF-947
Change-Id: I4333b6f66e9c9b1067cbe012d1122748c72e5261
Signed-off-by: Peter Suna <peter.suna@pantheon.tech>
14 months agoRemove default controller values in testtol 00/104400/5
Peter Suna [Wed, 15 Feb 2023 13:51:48 +0000 (14:51 +0100)]
Remove default controller values in testtol

The default values cannot be removed from
netconf-testtool, which means that it is not possible
to turn off the auto-connect functionality.

JIRA: NETCONF-947
Change-Id: Ic8bf0730717e312ca6d7daee3a984f5b6a14419f
Signed-off-by: Peter Suna <peter.suna@pantheon.tech>
14 months agoBump aaa to 0.17.7 32/105032/1
Robert Varga [Mon, 27 Mar 2023 09:43:16 +0000 (11:43 +0200)]
Bump aaa to 0.17.7

This picks up latest updates.

Change-Id: I838f0598dc955f769fc78ba154971aeb740ab407
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoFix schemas not shown for created devices 70/104970/2
OleksandrZharov [Mon, 20 Mar 2023 19:00:29 +0000 (20:00 +0100)]
Fix schemas not shown for created devices

Removed few lines from html template script that prevented
schemas from showing on web page.

JIRA: NETCONF-977
Change-Id: If739e6c331a45784bdd9bd00eb50b93a92a1bdb8
Signed-off-by: OleksandrZharov <Oleksandr.Zharov@pantheon.tech>
14 months agoAdd Change-event-notification-subscription-tutorial 05/104805/4
Yaroslav Lastivka [Thu, 9 Mar 2023 08:36:03 +0000 (10:36 +0200)]
Add Change-event-notification-subscription-tutorial

Change-event-notification-subscription-tutorial was moved from
Controller dev-guide to Netconf user-guide.
Old bierman-02 paths were fixed according to RFC 8040.
SSE was mentioned as a default mechanism to get notifications.
Provided steps on how to configure to use WebSockets.

JIRA: NETCONF-962
Change-Id: I3ba50494f8f0ea60d4ab1f4ed7de746df87a5ecb
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
14 months agoFix YangLib media types 00/104800/5
Ivan Hrasko [Wed, 8 Mar 2023 09:22:03 +0000 (10:22 +0100)]
Fix YangLib media types

Fix YangLib media types to return "application/yang" with default
fallback to "text/plain".

JIRA: NETCONF-972
Change-Id: Ibd7a6939342cfbe4b525442d8606e4c27d3e8b65
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
14 months agoRefactor YangLibProviderTest 85/104785/1
Ivan Hrasko [Tue, 7 Mar 2023 11:24:39 +0000 (12:24 +0100)]
Refactor YangLibProviderTest

Refactor mock usage: remove not needed doNothing constructs,
move mock setup to setUp method.

Split test cases for registering empty and non-YANG resources,
unregistering models with and without revision.

JIRA: NETCONF-968
Change-Id: I5195d794f2949c2343908281488d46d27bcf07bd
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
14 months agoUpdate NETCONF user guide 73/104373/17
Yaroslav Lastivka [Wed, 8 Feb 2023 17:46:34 +0000 (19:46 +0200)]
Update NETCONF user guide

User guide still contains references to removed bierman-02 paths:
`/restconf/config`, `/restconf/operational` and `restconf/operations`.

Fix them according to RFC 8040.

Make other small changes in order to make documentation up-to-date
with current state: update RFC-7895 link, update requests, default
ports and the netopeer2 usage.

JIRA: NETCONF-946
Change-Id: I94cd1fdf53ff3038a691f43f615d96645df7f023
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoBump versions to 5.0.4-SNAPSHOT 66/104666/1
Robert Varga [Wed, 1 Mar 2023 15:09:32 +0000 (16:09 +0100)]
Bump versions to 5.0.4-SNAPSHOT

This starts the next development iteration.

Change-Id: I67b99862d2dfd04fc8bea573b0ae6ac366a9ede6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoFix YANG patch request for augmented element 27/102227/47
OleksandrZharov [Fri, 26 Aug 2022 15:43:24 +0000 (17:43 +0200)]
Fix YANG patch request for augmented element

When writing JSON data using yangtool's NormalizedNodeStreamWriter
we have to check if the result is instance of Augmentation.

In that case we have to use its child as data. Similar process
is applied in JsonNormalizedNodeBodyReader.

JIRA: NETCONF-747
Change-Id: I2c1d1abcd3cbb483b414408c2c768bdc5731b8ce
Signed-off-by: OleksandrZharov <Oleksandr.Zharov@pantheon.tech>
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoRemove WebSocketSessionHandler.getRemoteEndpointAddress() 59/104659/1
Robert Varga [Wed, 1 Mar 2023 13:02:38 +0000 (14:02 +0100)]
Remove WebSocketSessionHandler.getRemoteEndpointAddress()

This method is not used anywhere, remove it.

Change-Id: I19efb7e687099a3f54b2623156df77d705575676
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoReduce verbosity of websocket timeout logging 58/104658/1
Robert Varga [Wed, 1 Mar 2023 12:55:56 +0000 (13:55 +0100)]
Reduce verbosity of websocket timeout logging

A websocket timing out is not a big thing, do not log a complete stack
trace when it occurs.

JIRA: NETCONF-970
Change-Id: I04ec6da1957ba13a27561dfbff9c06a10f011083
Signed-off-by: Ruslan Kashapov <ruslan.kashapov@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoFix web-socket timeout closure exceptions 23/104423/6
Ruslan Kashapov [Wed, 15 Feb 2023 13:58:40 +0000 (15:58 +0200)]
Fix web-socket timeout closure exceptions

As noted in WebSocketSessionHandler.onWebSocketClosed(), there is no
guarantee the session reports isOpen(). Performing the same check in
AbstractCommonSubscriber.removeSubscriber() (via isConnected()) can
therefore result in an ISE.

Fix this by removing the check.

JIRA: NETCONF-970
Change-Id: I6e437d9821e698e3faca121402a97b88ac486229
Signed-off-by: Ruslan Kashapov <ruslan.kashapov@pantheon.tech>
15 months agoSimplify WebSocketSessionHandler.isConnected() 57/104657/1
Robert Varga [Wed, 1 Mar 2023 12:45:15 +0000 (13:45 +0100)]
Simplify WebSocketSessionHandler.isConnected()

Use a simple expression instead of a if/else.

Change-Id: Ie1a2e26f1731c799fa6e9e1b027563702809eb7f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoEnforce idleTimeout/heartbeatInterval consistency 56/104656/1
Robert Varga [Wed, 1 Mar 2023 12:40:22 +0000 (13:40 +0100)]
Enforce idleTimeout/heartbeatInterval consistency

We should not allow a configuration where we time out before we send a
heartbeat. Enforce this invariant.

JIRA: NETCONF-970
Change-Id: Ic26319d7a3da4db9b28fa0aa2e39cdfe439fd786
Signed-off-by: Ruslan Kashapov <ruslan.kashapov@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoFix heartbeat/idle timer confusion 55/104655/1
Robert Varga [Wed, 1 Mar 2023 12:29:25 +0000 (13:29 +0100)]
Fix heartbeat/idle timer confusion

The two parameters are interchanged, make sure we pass the right thing
down.

JIRA: NETCONF-970
Change-Id: Ibd2a370f6fa0864026fee450383dd752d0821669
Signed-off-by: Ruslan Kashapov <ruslan.kashapov@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoReuse ObjectMapper instance 15/104615/5
Yaroslav Lastivka [Mon, 27 Feb 2023 09:01:55 +0000 (11:01 +0200)]
Reuse ObjectMapper instance

It's recommended to reuse ObjectMapper instances but in current codebase
we are recreating it.
ObjectMapper field was made static to prevent multiple object creation.

JIRA: NETCONF-938
Change-Id: If6ed5b5b1959b28d2330e3dc450afb3f20c15c29
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
15 months agoRemove misleading identifier check 78/104378/2
Ivan Hrasko [Mon, 13 Feb 2023 10:08:35 +0000 (11:08 +0100)]
Remove misleading identifier check

Check for presence of mount prefix in request for operation
is misleading. Its fully legal to ask for particular operation
on controller or device.

Remove this check which allows us to invoke requests for particular
operation on controller.

For now the request gives us all operations available on
controller/device and that will be fixed as part of NETCONF-928.

JIRA: NETCONF-929
Change-Id: Ia45ec624640b7b75416071f7675088c2bdab3091
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoFix restconf-nb websocket initialization failure on karaf 03/104403/5
Ruslan Kashapov [Wed, 15 Feb 2023 13:58:40 +0000 (15:58 +0200)]
Fix restconf-nb websocket initialization failure on karaf

Websocket servlet is initialized using indirect dependency on
server bundle (string class name in code, dynamic-import in
manifest). This dependency require to be set explicitly. Then
required bundle will be installed with odl-restconf-nb feature
and missing artifacts will be available for restcong-nb
class loader.

JIRA: NETCONF-953
Change-Id: I82e9133af1aeb98518f97a14a3574b82573f92dc
Signed-off-by: Ruslan Kashapov <ruslan.kashapov@pantheon.tech>
15 months agoBump upstreams 78/104578/2
Robert Varga [Fri, 24 Feb 2023 08:45:35 +0000 (09:45 +0100)]
Bump upstreams

Adopt:
- odparent-12.0.3
- infrautils-5.0.3
- yangtools-10.0.4
- mdsal-11.0.7
- controller-7.0.4
- aaa-0.17.6

Change-Id: I85f470ac0e8c44411de28f4fde7213a68018d354
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoCleanup of AbstractCommonSubscriber class 57/104557/3
Ivan Hrasko [Thu, 23 Feb 2023 13:55:31 +0000 (14:55 +0100)]
Cleanup of AbstractCommonSubscriber class

Fix method parameter javadoc and simplify logic operations.

Change-Id: I284b9e9027cc8af75c7968d7a73273681dc4d502
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoRemove Resource class 78/104478/5
Ivan Hrasko [Wed, 22 Feb 2023 13:04:27 +0000 (14:04 +0100)]
Remove Resource class

It was not used and not according to OAS v2 nor OAS v3.

JIRA: NETCONF-938
Change-Id: I315ef195749f8fc003df66778efde7747333d764
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoRemove ResourceList class 75/104475/4
Ivan Hrasko [Wed, 22 Feb 2023 12:46:06 +0000 (13:46 +0100)]
Remove ResourceList class

Remove ResourceList class and all its usages. The methods which were
using it were never called making class itself unused.

In addition, the class was not according to OAS v2 nor OAS v3.

JIRA: NETCONF-938
Change-Id: I9fba1a8425d44c0d8f14233669c4cbbcfc56ee33
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoFix feature install inside scale-util 20/104420/2
Peter Suna [Thu, 16 Feb 2023 07:34:21 +0000 (08:34 +0100)]
Fix feature install inside scale-util

The feature "odl-restconf-nb-rfc8040" has been deprecated
and is no longer available. It has been replaced by
the "odl-restconf-nb" feature.

Change-Id: I5dce4d65fa241ef9453f90b13703612d8e7b5747
Signed-off-by: Peter Suna <peter.suna@pantheon.tech>
15 months agoRemove BaseCallHomeTopology 87/104487/4
Yaroslav Lastivka [Wed, 22 Feb 2023 16:42:25 +0000 (18:42 +0200)]
Remove BaseCallHomeTopology

BaseCallHomeTopology has only one child class.
We can remove it and use CallHomeTopology directly.

When at place remove unused CallHomeTopology's constructor.

JIRA: NETCONF-969
Change-Id: Ic80140322161786a228a4735a38ee96e269a27cf
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoBump versions to 5.0.3-SNAPSHOT 94/104394/2
Robert Varga [Tue, 14 Feb 2023 20:33:46 +0000 (21:33 +0100)]
Bump versions to 5.0.3-SNAPSHOT

This starts the next development iteration.

Change-Id: I474a5629b2a1b9f5c3ae98b403a83359dcf28de8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoAdd doc Entry to read Netconf device events. 90/104290/7
gvrangan [Tue, 7 Feb 2023 05:22:01 +0000 (10:52 +0530)]
Add doc Entry to read Netconf device events.

This documentation suggests the procedure to use http client or browser
to read the Netconf device event notifications.

Change-Id: I6fd795f3fb8337f12620d298f0b036ba483404c9
Signed-off-by: gvrangan <gvrangan@gmail.com>
15 months agoUpdate documentation for YangLib feature 36/104236/11
Yaroslav Lastivka [Fri, 3 Feb 2023 08:43:12 +0000 (10:43 +0200)]
Update documentation for YangLib feature

Documentation was updated according to current model and default values.

JIRA: NETCONF-909
Change-Id: I514f3677b8ba6b02e6e146e47fdee09e5791a386
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
15 months agoFix odl-yanglib feature usage 87/104087/12
Yaroslav Lastivka [Thu, 19 Jan 2023 11:55:38 +0000 (13:55 +0200)]
Fix odl-yanglib feature usage

The problem is that Initialization stops working correctly and
expect non-empty YanglibConfig provided by blueprint.

Were set default cache-folder to cache/schema, binding-addr to
localhost and binding-port port 8181 by creating new config
file.

JIRA: NETCONF-909
Change-Id: I76455310d014a5ad87051cb0ac749f5ce9f010c1
Signed-off-by: Yaroslav Lastivka <yaroslav.lastivka@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoClean up mdsal-netconf-notification 44/104344/3
Robert Varga [Thu, 9 Feb 2023 15:11:57 +0000 (16:11 +0100)]
Clean up mdsal-netconf-notification

Remove impl.ops package and modernize classes a bit.

Change-Id: I4a5f549c2d05cefac544ce1a426815cbc2bc17d8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert mdsal-netconf-notification to OSGi DS 43/104343/5
Robert Varga [Thu, 9 Feb 2023 13:07:42 +0000 (14:07 +0100)]
Convert mdsal-netconf-notification to OSGi DS

The blueprint here is quite simple, even if a bit confusing. At the end
of the day we have only two components with services and a few plugins.

JIRA: NETCONF-963
Change-Id: I8d715d1db2ac66972c432e2b2808ad02cba7a463
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert sal-rest-docgen to OSGI DS 13/96713/14
Tomas Cere [Tue, 22 Jun 2021 10:35:57 +0000 (12:35 +0200)]
Convert sal-rest-docgen to OSGI DS

The generator is a few simple components. Rework their wiring to work
on top of OSGi DS.

JIRA: NETCONF-771
Change-Id: Iee36451c148c5fd414bda3c3ab43c7c8bac0b963
Signed-off-by: Tomas Cere <tomas.cere@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoEliminate blueprint from netconf-topology-impl 42/104342/4
Robert Varga [Thu, 9 Feb 2023 11:56:02 +0000 (12:56 +0100)]
Eliminate blueprint from netconf-topology-impl

The blueprint now is purely service injection, convert
NetconfTopologyImpl into a component instead.

JIRA: NETCONF-960
Change-Id: Id769b2d53cc75b0c5528aa6a0dd23d2b2a83cc85
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert NetconfSalKeystoreService into a component 41/104341/6
Robert Varga [Thu, 9 Feb 2023 11:20:59 +0000 (12:20 +0100)]
Convert NetconfSalKeystoreService into a component

This is a very simple component, activate it as part of
sal-netconf-connector rather than from topology blueprints.

Also remove the initial merge transaction, as it does not (and has not
for a long time) introduce any semantic state.

JIRA: NETCONF-960
Change-Id: Ibc182675bbd31eb970be6b2df0559fe5c852090e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoRemove org.opendaylight.netconf.topology.sb.keypair 39/104339/7
Robert Varga [Thu, 9 Feb 2023 10:06:54 +0000 (11:06 +0100)]
Remove org.opendaylight.netconf.topology.sb.keypair

This configuration holds the private key location and its pass phrase.
While we inject these values, they are not used anywhere.

JIRA: NETCONF-960
Change-Id: I0a5fd425a59137ac4d0dac5e2f2fd630c4f202bb
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert JaxRsNorthbound into a Component 38/104338/2
Robert Varga [Wed, 8 Feb 2023 23:18:52 +0000 (00:18 +0100)]
Convert JaxRsNorthbound into a Component

We have all we need to ditch blueprint, rehost Config Admin binding and
turn JaxRsNorthbound into a proper Component.

JIRA: NETCONF-959
Change-Id: Id2af0cc4925b34de01198cfcfd98bc63351399d3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoBump aaa to 0.17.5 37/104337/3
Robert Varga [Wed, 8 Feb 2023 22:38:41 +0000 (23:38 +0100)]
Bump aaa to 0.17.5

Pick up wiring changes implemented upstream. This unblocks removal
pretty much all the blueprints we have.

Change-Id: I090d89b6da40ffb774f1048361eea22c5d133da6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoTurn streams.Configuration into a record 36/104336/2
Robert Varga [Wed, 8 Feb 2023 22:51:52 +0000 (23:51 +0100)]
Turn streams.Configuration into a record

This is a pure data holder, convert it to a record. Also rename to
StreamsConfiguration to ensure naming conflicts do not occur.

JIRA: NETCONF-958
Change-Id: I01a203aeab692911799eb24ac4bcadcb029bf1f4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoRemove WebInitializer 27/104327/1
Robert Varga [Wed, 8 Feb 2023 19:36:20 +0000 (20:36 +0100)]
Remove WebInitializer

WebInitializer is a useless indirection, remove it and inline its logic
into JaxRsNorthbound.

JIRA: NETCONF-958
Change-Id: I8a51c128f4e17a36fb719f9c3209e0d7dde933a2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoRefactor restconf-nb blueprint 26/104326/2
Robert Varga [Wed, 8 Feb 2023 19:04:52 +0000 (20:04 +0100)]
Refactor restconf-nb blueprint

Blueprint here is really a large code fragment. Move it to a new class,
RestconfNorthbound, so that we purely inject dependencies/configuration.

JIRA: NETCONF-958
Change-Id: Ic7214393a599c136aa3876c111145182cc68db0b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoMove references to front 25/104325/2
Robert Varga [Wed, 8 Feb 2023 18:25:59 +0000 (19:25 +0100)]
Move references to front

References should be up first, as they are declaring dependencies.

Change-Id: Ie03d7889164943fbbf17f235401002a8ce370224
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoInline webSocketInitializer 24/104324/2
Robert Varga [Wed, 8 Feb 2023 18:22:04 +0000 (19:22 +0100)]
Inline webSocketInitializer

This bean is used only once, inline it in its sole caller.

Change-Id: I1f1ecb9c5747608c67a02b610f7f57064b76e2ac
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoInline restconfDataStreamServiceImpl 23/104323/2
Robert Varga [Wed, 8 Feb 2023 18:20:56 +0000 (19:20 +0100)]
Inline restconfDataStreamServiceImpl

This bean is used only once, inline it in its sole user.

Change-Id: Iba47a40a7f798b5b3acd443e855b701fb543e5b4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoInline restconfApplication 22/104322/2
Robert Varga [Wed, 8 Feb 2023 18:19:38 +0000 (19:19 +0100)]
Inline restconfApplication

This bean is used only once, inline it in its sole user.

Change-Id: I00f886cee80d4c6e6279fe6de0f97b35067078f8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoInline dataStreamApplication 21/104321/2
Robert Varga [Wed, 8 Feb 2023 18:17:55 +0000 (19:17 +0100)]
Inline dataStreamApplication

This bean is used only once, inline it in its sole user.

Change-Id: I1540d48e3479a8bc62d0600e7845ab19772672a6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoInline threadPoolFactory 20/104320/1
Robert Varga [Wed, 8 Feb 2023 18:15:44 +0000 (19:15 +0100)]
Inline threadPoolFactory

This bean is used only once, inline it in its sole user.

Change-Id: I366274dc2b040fb666994957ad468fadd988609b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert mdsal-netconf-tcp to OSGi DS 17/104317/2
Robert Varga [Wed, 8 Feb 2023 16:59:44 +0000 (17:59 +0100)]
Convert mdsal-netconf-tcp to OSGi DS

Create a disabled component instead using Declarative Services. This
enables it to be used without touching any code, just the SCR console.

JIRA: NETCONF-957
Change-Id: Id4fc561c3c8671de421b1410c3291390f87fbf56
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoMove unit tests to netconf.ssh package 15/104315/4
Robert Varga [Wed, 8 Feb 2023 16:44:34 +0000 (17:44 +0100)]
Move unit tests to netconf.ssh package

UTs should be co-located with the classes they are testing, clean that
up.

Change-Id: I59babf5ad47427a2bdb3e9145c2f0284d59a976c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert mdsal-netconf-ssh to OSGi DS 14/104314/2
Robert Varga [Wed, 8 Feb 2023 16:38:30 +0000 (17:38 +0100)]
Convert mdsal-netconf-ssh to OSGi DS

This is a rather simple blueprint, just convert the single component we
have here. Since Declarative Services shutdown dependents before
deactivating the reference, we can also squash the unbind() method.

JIRA: NETCONF-956
Change-Id: If3c5af7bd212583d0f37af085a33468a8d905802
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert mdsal-netconf-connector to OSGi DS 12/104312/4
Robert Varga [Wed, 8 Feb 2023 15:59:08 +0000 (16:59 +0100)]
Convert mdsal-netconf-connector to OSGi DS

This blueprint is extremely simple wiring, migrate it to Declarative
Services and also cleanup dependencies and code a bit.

JIRA: NETCONF-955
Change-Id: I54da9529206677f9d210d2db1cb7248a0ba0259b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert mdsal-netconf-monitoring to OSGi DS 06/104306/5
Robert Varga [Wed, 8 Feb 2023 13:04:16 +0000 (14:04 +0100)]
Convert mdsal-netconf-monitoring to OSGi DS

These are just two simple components, convert them to Declarative
Services.

JIRA: NETCONF-954
Change-Id: I3bf22d265feb8a1db086df396fb5ebaa26bbecdd
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert mdsal-netconf-impl to OSGi DS 05/104305/4
Robert Varga [Wed, 8 Feb 2023 12:37:52 +0000 (13:37 +0100)]
Convert mdsal-netconf-impl to OSGi DS

The blueprint here is just picking up config admin tuneables and wires
things together. This patch converts this wiring to OSGi DS.
Unfortunately the config admin bits are jumbled together, hence we use
factory components to split them up.

JIRA: NETCONF-951
Change-Id: Icdabc7b2e62cb77a6bf5659274955463be993f88
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoBump json-unit-assertj to 2.36.1 13/104313/4
Ivan Hrasko [Wed, 8 Feb 2023 16:03:21 +0000 (17:03 +0100)]
Bump json-unit-assertj to 2.36.1

Fix CVE-2022-42003 by bumping json-unit-assertj to 2.36.1
which uses fixed jackson-databind version 2.14.0.

Change-Id: I3ab3cb9e03393ea1d223616e0b013f7f10e6a74c
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoRemove duplicate authorization instantiation 08/104308/3
Robert Varga [Wed, 8 Feb 2023 13:42:21 +0000 (14:42 +0100)]
Remove duplicate authorization instantiation

We already have an authorization object, so it seems we should be
reusing it. This also fixes a potential leak as well.

JIRA: NETCONF-949
Change-Id: Id8c94b3f4deca9c62f3b02e1f0c9f3f36d5d23c9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoInline serverChannelInitializer 04/104304/3
Robert Varga [Wed, 8 Feb 2023 10:56:36 +0000 (11:56 +0100)]
Inline serverChannelInitializer

This bean is used only as an argument, inline it to make things clearer.

JIRA: NETCONF-951
Change-Id: Ie461efe86b7b80d087ad41770e8c75275db4b170
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoInline netconfServerSessionNegotiatorFactory 03/104303/3
Robert Varga [Wed, 8 Feb 2023 10:53:59 +0000 (11:53 +0100)]
Inline netconfServerSessionNegotiatorFactory

This bean is used only as an argument, inline it to make things clearer.

JIRA: NETCONF-951
Change-Id: If0430936c0ad85346ad26ee8903d2f3bfa73b870
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoSplit out NetconfMapperAggregator 99/104299/6
Robert Varga [Tue, 7 Feb 2023 18:47:51 +0000 (19:47 +0100)]
Split out NetconfMapperAggregator

Create a component to host the corresponding Blueprint element.
This starts the path to making the contract of
AggregatedNetconfOperationServiceFactory more explicit.

JIRA: NETCONF-951
Change-Id: Ic4f0164ac3423f39ca0d52a6200dcbbfa8f35f7f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoUse NetconfNodeUtils.DEFAULT_TOPOLOGY_IID 10/104310/1
Robert Varga [Wed, 8 Feb 2023 14:28:05 +0000 (15:28 +0100)]
Use NetconfNodeUtils.DEFAULT_TOPOLOGY_IID

We have an open-coded reference to "topology-netconf", squash it and use
the common centralized constant.

Change-Id: Id6399cd4534333b0cce16c0ebdae00c0ede2835b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoSimplify builder 09/104309/3
Robert Varga [Wed, 8 Feb 2023 13:59:07 +0000 (14:59 +0100)]
Simplify builder

We do not need the intermediate products, we can just pass them to a
fluent builder.

Change-Id: Id384d2fd54a454b89de7b43b12b23f1f135a767f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoUse a few more instanceof patterns 07/104307/1
Robert Varga [Wed, 8 Feb 2023 13:36:28 +0000 (14:36 +0100)]
Use a few more instanceof patterns

We can remove duplicate getter invocations, let's do that and also
eliminate the implied casts.

Change-Id: I582d64423b968b0c9e97b541feff80cfbaca7627
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoTurn SessionIdProvider into a component 98/104298/5
Robert Varga [Tue, 7 Feb 2023 18:11:04 +0000 (19:11 +0100)]
Turn SessionIdProvider into a component

SessionIdProvider is a service, make sure it is an interface with a
default provider, instantiated via OSGi DS. This make things a tad more
reasonable, as the provider will survive most reconfiguration.

JIRA: NETCONF-951
Change-Id: I18e95bca90ed886d13b4cc03e3a2f1b5169d7876
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoConvert netconf-config to OSGi DS 87/104287/16
Robert Varga [Mon, 6 Feb 2023 18:37:10 +0000 (19:37 +0100)]
Convert netconf-config to OSGi DS

Convert blueprint to explicit OSGi DS wiring, retaining the API and
behaviour of the wiring. This requires use of ComponentFactories to
deal with the fact the configuration is in a single configurationPid,
but really ends up being configuration of three inter-dependend classes.

JIRA: NETCONF-950
Change-Id: I19d506a336483bf0ea06a230ef5108a35d8845cc
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoRemove unused method createDeviceCommunicator 96/104296/5
Ivan Hrasko [Tue, 7 Feb 2023 14:04:37 +0000 (15:04 +0100)]
Remove unused method createDeviceCommunicator

Remove unused method AbstractNetconfTopology#createDeviceCommunicator.

Change-Id: I0042b1e3ce772dc9853f83080737e0250e50d070
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoAdd session-id to the operational datastore 90/91290/31
tobias.pobocik [Mon, 13 Jul 2020 08:46:42 +0000 (10:46 +0200)]
Add session-id to the operational datastore

Expose non-zero uint32 session-id provided by the device
in the HELLO-MESSAGE via operational datastore.

When device is disconnected null is used to indicate
a non-NETCONF entity session.

Session id can be used to retrieve session-specific info of the device.

JIRA: NETCONF-710
Change-Id: I1995e825cf32462232e164727a469a7b47d3acd0
Signed-off-by: Tibor Král <tibor.kral@pantheon.tech>
Signed-off-by: tobias.pobocik <tobias.pobocik@pantheon.tech>
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
Signed-off-by: Peter Suna <peter.suna@pantheon.tech>
15 months agoAdd fixme to NetconfNodeUtils 95/104295/3
Ivan Hrasko [Tue, 7 Feb 2023 13:41:00 +0000 (14:41 +0100)]
Add fixme to NetconfNodeUtils

NetconfNodeUtils#extractUserCapabilities method is creating
UserPreferences from NetconfSessionPreferences.

Here the purpose is unclear because NetconfSessionPreferences
are (re)created in NetconfDeviceCommunicator#onSessionUp.

Change-Id: I78ae38ffbd327b29dd29753b8b61d1e9c07bf55b
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoClarify NetconfSessionPreferences usage 94/104294/3
Ivan Hrasko [Tue, 7 Feb 2023 13:36:50 +0000 (14:36 +0100)]
Clarify NetconfSessionPreferences usage

Remove the only one usage of NetconfSessionPreferences method
fromStrings(collection) from production code and mark it
as visible for testing because now it is used only in tests.

Change-Id: Ib17ddafaed113e3f18588e1870b0d53bf26e1513
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
15 months agoHide CallHomeMountSessionManager 79/104279/6
Robert Varga [Mon, 6 Feb 2023 16:29:46 +0000 (17:29 +0100)]
Hide CallHomeMountSessionManager

This is an implementation detail not used anywhere, hide it and document
that it is non-final (as is CallHomeMountDispatcher) for testing
purposes.

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