transportpce.git
2 years agoMerge changes I27d64e31,I9d7bba90
Guillaume Lambert [Fri, 29 Oct 2021 12:23:18 +0000 (12:23 +0000)]
Merge changes I27d64e31,I9d7bba90

* changes:
  Run autopep8 tox profile
  Remove unused imports detected by pylint

2 years agoMerge "Bump upstream dependencies to P-SR1"
Guillaume Lambert [Fri, 29 Oct 2021 12:21:13 +0000 (12:21 +0000)]
Merge "Bump upstream dependencies to P-SR1"

2 years agoBump upstream dependencies to P-SR1 62/98162/2
Gilles Thouenon [Wed, 27 Oct 2021 10:01:57 +0000 (12:01 +0200)]
Bump upstream dependencies to P-SR1

odlparent => 9.0.8
mdsal => 8.0.7
netconf => 2.0.7

JIRA: TRNSPRTPCE-565
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: I426325d16e3e1f55b634728b686e348266a349f5

2 years agoRun autopep8 tox profile 03/98203/3
guillaume.lambert [Thu, 28 Oct 2021 08:50:05 +0000 (10:50 +0200)]
Run autopep8 tox profile

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

2 years agoExtend tapi feature documentation 02/97902/12
errea [Fri, 15 Oct 2021 12:25:39 +0000 (14:25 +0200)]
Extend tapi feature documentation

- Add description of the tapi extension into the developer
guide and update tapi-topology figure
- Add comments on the Topology Management - Service Handler
interface

JIRA: TRNSPRTPCE-469
Change-Id: I229e34d64bb3548eda51f89c2f1caef3550b3251
Signed-off-by: errea <errea@eurecom.fr>
2 years agoRemove unused imports detected by pylint 02/98202/1
guillaume.lambert [Thu, 28 Oct 2021 07:52:14 +0000 (09:52 +0200)]
Remove unused imports detected by pylint

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

2 years agoRemove upstream dependencies version overriding 02/98002/3
Gilles Thouenon [Wed, 20 Oct 2021 14:29:53 +0000 (16:29 +0200)]
Remove upstream dependencies version overriding

Remove some dependency versions that were overriding versions managed in
odlparent.

JIRA: TRNSPRTPCE-555
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: I7e9e43edb2ca25be2594026316ef65b41fe15ffc

2 years agoMerge "Refactor Karaf builds for tests and tox.ini"
Guillaume Lambert [Thu, 28 Oct 2021 07:07:44 +0000 (07:07 +0000)]
Merge "Refactor Karaf builds for tests and tox.ini"

2 years agoMerge "Fix remaining PortMapping sonar issues"
Guillaume Lambert [Thu, 28 Oct 2021 07:06:58 +0000 (07:06 +0000)]
Merge "Fix remaining PortMapping sonar issues"

2 years agoRefactor Karaf builds for tests and tox.ini 19/98119/7
guillaume.lambert [Mon, 25 Oct 2021 10:15:02 +0000 (12:15 +0200)]
Refactor Karaf builds for tests and tox.ini

- use dedicated env files for Karaf listening ports settings
- create tox profiles to (re)build Karaf folders dedicated to tests
- adapt tests launcher and build scripts accordingly

This should avoid weird race conditions that can happen when performing
several tests locally.

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Icfa0e09e65ed054155002b9e4b07370ca1ad0aaf

2 years agoUpdate PTL info 26/98026/2
guillaume.lambert [Thu, 21 Oct 2021 09:26:06 +0000 (11:26 +0200)]
Update PTL info

Gilles Thouenon has been approved as the new PTL of TransportPCE.

https: //wiki.opendaylight.org/display/ODL/2021+PTL+election

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

2 years agoFix remaining PortMapping sonar issues 72/97972/1
guillaume.lambert [Tue, 19 Oct 2021 07:54:36 +0000 (09:54 +0200)]
Fix remaining PortMapping sonar issues

This refactoring intends to fix remaining sonar issues about
cyclomatic complexity and commented code in PortMapping classes.
To this purpose, it introduces a few intermediate functions.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I7e24dc8ae4841658370a07d73017a9ca49766536

2 years agoMerge changes Ic48b0970,Id372a645
Guillaume Lambert [Mon, 18 Oct 2021 09:35:37 +0000 (09:35 +0000)]
Merge changes Ic48b0970,Id372a645

* changes:
  Add a feature to start swagger
  Remove OpenROADM ospf YANG model rev 2020-05-29

2 years agoMerge changes I05cce46d,Ia329ea5f,I933c58d1
Guillaume Lambert [Fri, 15 Oct 2021 19:34:05 +0000 (19:34 +0000)]
Merge changes I05cce46d,Ia329ea5f,I933c58d1

* changes:
  Fix some small issues pointed by Sonar
  PortMapping Refactoring step 5
  PortMapping Refactoring step 4

2 years agoMerge "Improve container support in tox.ini"
Guillaume Lambert [Thu, 14 Oct 2021 18:13:25 +0000 (18:13 +0000)]
Merge "Improve container support in tox.ini"

2 years agoImprove container support in tox.ini 84/97384/5
guillaume.lambert [Fri, 3 Sep 2021 08:23:34 +0000 (10:23 +0200)]
Improve container support in tox.ini

- modify tox.ini to use dedicated scripts that can detect a local podman
  installation and use it instead of docker.
- replace nbiotifications docker-compose YAML file by a standalone
  container directly runnable with docker or podman.

Podman.io is a rootless and serverless alternative to Docker.io.
It avoids using sudo in many cases, what is a good thing.
It is now prefered to Docker.io by many linux distributions.

https://podman.io/
https://access.redhat.com/solutions/3696691
https://thesynack.com/posts/docker-compose-podman/
https://martinheinz.dev/blog/35

JIRA: TRNSPRTPCE-527
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I593568b2e17bebe784eff7b3413d0d5b829f2ade

2 years agoFix: Disconnection of netconf node 82/97882/5
Gilles Thouenon [Wed, 13 Oct 2021 13:49:29 +0000 (15:49 +0200)]
Fix: Disconnection of netconf node

- Add protection to check that a node exists in TransportPCE datastores
before removing it. Appeared when the node connection remained in a
transient state, and that the node had not been created in PortMapping
and the different topologies.
- Add a new isNodeExist method in PortMapping to test presence or not of
a node in the datastore.

JIRA: TRNSPRTPCE-547
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: I93744ea941c909c6a18e7ccc879801f83103efba

2 years agoFix some small issues pointed by Sonar 73/97873/1
guillaume.lambert [Tue, 12 Oct 2021 19:59:53 +0000 (21:59 +0200)]
Fix some small issues pointed by Sonar

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

2 years agoPortMapping Refactoring step 5 67/97867/3
guillaume.lambert [Mon, 11 Oct 2021 12:51:13 +0000 (14:51 +0200)]
PortMapping Refactoring step 5

This refactoring intends to optimize some parts of the code
and to fix sonar issues about cyclomatic complexity.
To this purpose, it introduces a few intermediate functions.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ia329ea5ff3f5662ab701aadaf9cf31d9f744693a

2 years agoPortMapping Refactoring step 4 60/97860/3
guillaume.lambert [Sun, 10 Oct 2021 21:03:43 +0000 (23:03 +0200)]
PortMapping Refactoring step 4

This refactoring intends to optimize some parts of the code
and to fix sonar issues about cyclomatic complexity.
To this purpose, it introduces a few intermediate functions.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I933c58d12444f928fc0aca692f37423b205d3cd9

2 years agoAdd a feature to start swagger 90/97690/7
Guillaume Lambert [Thu, 30 Sep 2021 17:32:20 +0000 (19:32 +0200)]
Add a feature to start swagger

JIRA: TRNSPRTPCE-534
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: Ic48b0970386074e83d99515630f9e15bae37bf78

2 years agoRemove OpenROADM ospf YANG model rev 2020-05-29 48/97848/3
guillaume.lambert [Fri, 8 Oct 2021 09:47:02 +0000 (11:47 +0200)]
Remove OpenROADM ospf YANG model rev 2020-05-29

This model is not used by the current codebase
and prevents swagger from working correctly.

JIRA: TRNSPRTPCE-545 TRNSPRTPCE-534
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Id372a645a9913be27660853f91ffd264d071291f

2 years agoUse constants for PortMapping log messages Step 4 49/97849/1
guillaume.lambert [Fri, 8 Oct 2021 10:04:05 +0000 (12:04 +0200)]
Use constants for PortMapping log messages Step 4

Few PortMapping log messages were redundant and needed to be realigned.
They were fixed previously but this created new string for the words
"create" and "update" and "found".
Sonar complains they are used multiples times.
Since these words are shared among all PortMappingVersion*** classes,
migrating them to constants in the PortMappingUtils class is preferable.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I71a5e8eb654256004f11d10e9f3d3273d79bcede

2 years agoMerge "PortMapping Refactoring step 3"
Guillaume Lambert [Fri, 8 Oct 2021 09:54:59 +0000 (09:54 +0000)]
Merge "PortMapping Refactoring step 3"

2 years agoUpdate version configurations 93/97793/2
Gilles Thouenon [Wed, 6 Oct 2021 08:52:29 +0000 (10:52 +0200)]
Update version configurations

Phosphorus is going to be released.
These versions will apply to Sulfur development.

JIRA: TRNSPRTPCE-535
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: I764d6fd09bf825f1a34611027a32eac4e65cf550

2 years agoPortMapping Refactoring step 3 03/97703/4
guillaume.lambert [Fri, 1 Oct 2021 15:31:15 +0000 (17:31 +0200)]
PortMapping Refactoring step 3

This refactoring intends to optimize some parts of the code
and to fix sonar issues about cyclomatic complexity.
To this purpose, it introduces a few intermediate functions.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I5c1ce21ad982581920c3b57f52987ef433b91dc3

2 years agoPortMapping Refactoring step 2 82/97682/4
guillaume.lambert [Wed, 29 Sep 2021 08:57:03 +0000 (10:57 +0200)]
PortMapping Refactoring step 2

This refactoring intends to optimize some parts of the code
and to fix sonar issues about cyclomatic complexity.
It introduces intermediate functions, sometimes by reevaluating log
levels and messages content.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I625598fd935c296f59c9ad42966d5353c21a59d8

2 years agoPortMapping Refactoring step 1 61/97661/4
guillaume.lambert [Fri, 17 Sep 2021 08:47:28 +0000 (10:47 +0200)]
PortMapping Refactoring step 1

This refactoring intends to optimize some parts of the code
and to fix sonar issues about cyclomatic complexity.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ia82c6129d10becf97e161bf4eccb905c1fb850d7

2 years agoB100G end-to-end functional tests 81/97581/4
Christophe Betoule [Tue, 21 Sep 2021 13:21:01 +0000 (15:21 +0200)]
B100G end-to-end functional tests

- test the service creation and deletion for a 400GE service between
two 400G TPDR
- test the service creation and deletion for 100GE MXPDR (OTUC4, ODUC4
and 100G)

JIRA: TRNSPRTPCE-506 TRNSPRTPCE-508
Signed-off-by: Christophe Betoule <christophe.betoule@orange.com>
Change-Id: I163dd7fe977e5c2579a4ec8035a41db405210ab0

2 years agoCode consolidation for end-to-end B100G services 80/97580/4
Christophe Betoule [Tue, 21 Sep 2021 13:18:05 +0000 (15:18 +0200)]
Code consolidation for end-to-end B100G services

Code consolidation to operate the end-to-end creation and deletion of
a 400GE service over a 400G TPDR and a 100GE service on a 400Gbps MPDR

JIRA: TRNSPRTPCE-505 TRNSPRTPCE-507
Signed-off-by: Christophe Betoule <christophe.betoule@orange.com>
Change-Id: I121dcc5a99f5c1f46b1a070cfa927a7af949ab69

2 years agoUse constants for PortMapping log messages Step 3 40/97640/4
guillaume.lambert [Sun, 26 Sep 2021 18:56:56 +0000 (20:56 +0200)]
Use constants for PortMapping log messages Step 3

Few PortMapping log messages were redundant and needed to be realigned.
Some others were triggering Sonar issues.
Since these messages are shared among all PortMappingVersion*** classes,
migrating them to constants in the PortMappingUtils class is preferable.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I865145bc7207500d727e5778916d9f1f4879c1c0

2 years agoUse constants for PortMapping log messages Step 2 97/97597/10
guillaume.lambert [Wed, 22 Sep 2021 12:56:01 +0000 (14:56 +0200)]
Use constants for PortMapping log messages Step 2

Few PortMapping log messages were redundant and needed to be realigned.
Some others were triggering Sonar issues.
Since these messages are shared among all PortMappingVersion*** classes,
migrating them to constants in the PortMappingUtils class is preferable.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I2a0cb1788d1c078acdb448f995416f7e3ad79c3e

2 years agoUse constants for PortMapping log messages Step 1 14/97514/3
guillaume.lambert [Thu, 16 Sep 2021 09:56:41 +0000 (11:56 +0200)]
Use constants for PortMapping log messages Step 1

Few PortMapping log messages were redundant and needed to be realigned.
Some others were triggering Sonar issues.
Since these messages are shared among all PortMappingVersion*** classes,
migrating them to constants in the PortMappingUtils class is preferable.

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I944596cc57ae4a352309aeb590b440eadc48bf8c

2 years agoFix most PortMapping Sonar issues 05/97505/9
guillaume.lambert [Thu, 16 Sep 2021 09:56:41 +0000 (11:56 +0200)]
Fix most PortMapping Sonar issues

- use static HashMap instead of switch/case in MappingUtils
- return directly boolean expressions instead of using if-else blocks
- log every catched exceptions
- perform minor refactoring and realignments

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I2f262d94c04d256fb473b94a3815486d5636a14e

2 years agoAdd a PortMappingUtils class 09/97509/3
guillaume.lambert [Fri, 17 Sep 2021 09:05:43 +0000 (11:05 +0200)]
Add a PortMappingUtils class

- rename FnvUtils class to PortMappingUtils
- move createXpdrLogicalConnectionPort to it
- rename fnv1_64 function name to fnv1size64 to fulfill sonar regex rule
- add a new function to generate Degree TTP names
  and to fix a few sonar warnings

JIRA: TRNSPRTPCE-355 TRNSPRTPCE-356
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I8cac7d7fabdc5549e0fe92ddcd2da6d8bd907c87

2 years agoBump upstream dependencies 44/97544/1
Gilles Thouenon [Mon, 20 Sep 2021 11:35:37 +0000 (13:35 +0200)]
Bump upstream dependencies

Adopt:
- odlparent 9.0.6
- mdsal 8.0.5
- netconf 2.0.5

JIRA: TRNSPRTPCE-435
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: I0a909fc07d1d86f8c38f74b4fe93decedad15c9a

2 years agoNotification Stream selection update 91/97191/12
Vachhani, Shweta (sv111y) [Thu, 12 Aug 2021 13:43:59 +0000 (09:43 -0400)]
Notification Stream selection update

- Update NetConfTopologyListener to read notification streams supported
  by device.
- Update the code to look for device support for OPENROADM Stream.
- If OPENROADM stream is not supported by device, code will subscribe
  to NETCONF stream
- Sample CONFIGs are updated to have NETCONF stream in device model

JIRA: TRNSPRTPCE-493
Signed-off-by: Vachhani, Shweta (sv111y) <sv111y@att.com>
Change-Id: Icb9b77c12597625b13b6b689d270813d601c3153

2 years agoFix hybrid functional tests race condition 98/97398/2
guillaume.lambert [Mon, 6 Sep 2021 09:10:03 +0000 (11:10 +0200)]
Fix hybrid functional tests race condition

JIRA: TRNSPRTPCE-493 TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I68ec9cd733860c620a7d7684960ff62cc2310867

2 years agoGet rid of YangParserFactory 46/97346/7
guillaume.lambert [Fri, 27 Aug 2021 09:07:58 +0000 (11:07 +0200)]
Get rid of YangParserFactory

org.opendaylight.yangtools.yang.model.parser.api.YangParserFactory is
deprecated and marked for removals according to compilation warnings.

PCE Junit tests do not require anymore mocking this Object.

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

2 years agoFix unused dependencies warnings after bump to P 10/97310/13
guillaume.lambert [Tue, 24 Aug 2021 10:44:47 +0000 (12:44 +0200)]
Fix unused dependencies warnings after bump to P

JIRA: TRNSPRTPCE-435
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I904740e44c78f530126e4dd713443d5628ba09e4

2 years agoFix/Ignore raw type warnings after Phosphorus bump 08/97308/9
guillaume.lambert [Tue, 24 Aug 2021 10:04:49 +0000 (12:04 +0200)]
Fix/Ignore raw type warnings after Phosphorus bump

JIRA: TRNSPRTPCE-435
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I45ca9d8f3abceee8e53d5e90fd97f07299b6687d

2 years agoFix static methods warnings after Phosphorus bump 94/97294/9
guillaume.lambert [Mon, 23 Aug 2021 14:44:06 +0000 (16:44 +0200)]
Fix static methods warnings after Phosphorus bump

Static methods should be qualified by type name,
instead of by an expression.

JIRA: TRNSPRTPCE-435
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I2d298f7fd36af590e7745530a740efe32e23fd06

2 years agoMerge changes from topic "97346"
Gilles Thouenon [Mon, 13 Sep 2021 15:32:32 +0000 (15:32 +0000)]
Merge changes from topic "97346"

* changes:
  Ignore fallthrough warning after Phosphorus bump
  Ignore serializable warnings after Phosphorus bump
  Phosphorus migration
  Fix GNPy functional tests
  Change absolute path of leafref in GNPy model
  Refactor OLM timers management

2 years agoIgnore fallthrough warning after Phosphorus bump 81/97281/9
guillaume.lambert [Fri, 20 Aug 2021 15:46:41 +0000 (17:46 +0200)]
Ignore fallthrough warning after Phosphorus bump

JIRA: TRNSPRTPCE-435
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I07ea123534c8cb369014dcabac335f774ba1f6a0

2 years agoIgnore serializable warnings after Phosphorus bump 80/97280/8
guillaume.lambert [Fri, 20 Aug 2021 15:35:04 +0000 (17:35 +0200)]
Ignore serializable warnings after Phosphorus bump

JIRA: TRNSPRTPCE-435
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I24bd33d9a5aee4b5cdabb7386d056b45a5d68000

2 years agoPhosphorus migration 39/96939/13
Gilles Thouenon [Mon, 19 Jul 2021 13:58:00 +0000 (15:58 +0200)]
Phosphorus migration

Bump upstreams dependencies to:
- odlparent: 9.0.5
- mdsal: 8.0.4
- netconf: 2.0.3

Perform some code adaptations in all modules to allow project building.
- remove number of useless calls to .toString()
- fix issue regarding Tp Name in PCE now that Tp resource is correctly
  recognized as a TpId instead of an Object (thanks to an improvement of
  leafref management in mdsal)

Remove few useless dependencies.

Disable lighty.io runtime for functional tests
(no lighty version compatible with phosphorus dependencies yet)

Adapt GNPy UT resource file.

JIRA: TRNSPRTPCE-435
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: Icedf25d2158f35902ff13dce4d137c6eb0a9cd8c

2 years agoFix GNPy functional tests 74/97374/1
guillaume.lambert [Thu, 2 Sep 2021 12:23:44 +0000 (14:23 +0200)]
Fix GNPy functional tests

"A-to-Z" and "Z-to-A" items have been swapped in arrays returned by
the PCE computation API during the updates to handle high rates.

GNPy functional test must support any order.

JIRA: TRNSPRTPCE-403
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: If4db8598366bd1387d05dd65220beda589dbb4c1

2 years agoChange absolute path of leafref in GNPy model 73/97373/3
Gilles Thouenon [Thu, 2 Sep 2021 09:10:12 +0000 (11:10 +0200)]
Change absolute path of leafref in GNPy model

JIRA: TRNSPRTPCE-497
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: Ief01620be3f2842664dcba6aa7c4851c92e327d5

2 years agoMerge changes Ic53c9f04,Iae5644f6,Ib3975607
Guillaume Lambert [Wed, 1 Sep 2021 12:29:27 +0000 (12:29 +0000)]
Merge changes Ic53c9f04,Iae5644f6,Ib3975607

* changes:
  Refactor buildcontroller tox profile
  Refactor OLM PowerMgmtImpl class
  Add documentation to use tox and functional tests

2 years agoRefactor OLM timers management 67/97367/3
guillaume.lambert [Tue, 31 Aug 2021 09:59:25 +0000 (11:59 +0200)]
Refactor OLM timers management

OLM timer values are defined by OpenROADM whitepaper specifications.
For this reason, they are hardcoded with constants in the current code.
Though, there are at least 2 reasons to make them configurable:

1- At least one vendor product needs more than the OpenROADM whitepaper
   recommandation because it is not supporting GainLoss with
   target-output-power.

2- The OlmUtils constants are patched in functional tests to speed-up
   tests because the simulators needs less time to set the OLM up than
   real devices.

As a consequence,
- remove OlmUtils timers constants
- remove related command to patch them in tests scripts
- create a new constructor PowerMgmtImpl to allow any timers values
- modify OLM OSGi blueprint to set default values for these timers
  (Default values are the ones recommended in the OpenROADM whitepaper)
- modify lighty build to retrieve these timers from new CLI options
- adapt tests scripts and assembly ressources accordingly

JIRA: TRNSPRTPCE-496
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I71f9bdfd38c11ea3427ca2e661cd3590bc2863bf

2 years agoRefactor buildcontroller tox profile 43/97343/3
guillaume.lambert [Thu, 26 Aug 2021 12:50:27 +0000 (14:50 +0200)]
Refactor buildcontroller tox profile

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ic53c9f04ab7f35756792e615af299a98687bb288

2 years agoRefactor Notification support for 7.1 devices 32/97332/1
guillaume.lambert [Thu, 26 Aug 2021 07:44:22 +0000 (09:44 +0200)]
Refactor Notification support for 7.1 devices

JIRA: TRNSPRTPCE-446
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I38320571aca256f0bbd40d09c9f90af5e9b8687c

2 years agoNotification support for 7.1 devices 85/95985/4
Shweta Vachhani [Wed, 21 Apr 2021 18:10:35 +0000 (14:10 -0400)]
Notification support for 7.1 devices

1) New notification listeners classes for 7.1 model
2) Listener registration code for 7.1 listeners

JIRA: TRNSPRTPCE-446
Signed-off-by: Shweta Vachhani <sv111y@att.com>
Change-Id: I14a545bf7e48cadb8d16d038173f7b098c60fbc3

2 years agoUpdate NBINotifications docs 88/97188/13
Thierry Jiao [Thu, 12 Aug 2021 08:32:14 +0000 (10:32 +0200)]
Update NBINotifications docs

Updates the illustration "Example:service-create workflow" and the
description

Signed-off-by: Thierry Jiao <thierry.jiao@orange.com>
Change-Id: Icfb5da8d9ac489e790a4530694c73550bf837a29

2 years agoRefactor NBINotifications and serviceHandlerImpl 26/97126/11
Thierry Jiao [Tue, 10 Aug 2021 09:21:36 +0000 (11:21 +0200)]
Refactor NBINotifications and serviceHandlerImpl

This refactoring renames the models in YANG nbi-notifications file.
It also corrects a few typos, notifications and simplifies conditions.

Signed-off-by: Thierry Jiao <thierry.jiao@orange.com>
Change-Id: Ia23d44b2a158b4828b68c4a9ab2df0dcb121f034

2 years agoRefactor OLM PowerMgmtImpl class 00/97100/11
guillaume.lambert [Mon, 9 Aug 2021 10:06:27 +0000 (12:06 +0200)]
Refactor OLM PowerMgmtImpl class

The former implementation of OLM Power management ignored some spotbugs
warnings and triggered many alarms in SonarCloud, mainly about
commented-out lines of code and the SetPower method.
This method had 280 lines and its cyclomatic complexity was 43.
Current Sonar rules warns methods with more than 75 lines of code
and a cyclomatic complexity of 10.

As a consequence
- remove commented-out lines of code
- fix SpotBugs warnings and remove annotations to ignore them
- split the SetPower method into several pieces
- rework and optimize the code
- add TODO and FIXME comments for some parts of the code
  that may need to be reconsidered in the future

JIRA: TRNSPRTPCE-211 TRNSPRTPCE-494
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Iae5644f66cd6de6e17f81de3cd61dcb546ac2dd1

2 years agoAdd documentation to use tox and functional tests 94/97194/9
guillaume.lambert [Thu, 12 Aug 2021 15:05:01 +0000 (17:05 +0200)]
Add documentation to use tox and functional tests

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ib3975607aed1571961f54c151d908148326a0d14

2 years agoReenforce Lighty use in the gate 09/96809/7
guillaume.lambert [Tue, 6 Jul 2021 07:26:31 +0000 (09:26 +0200)]
Reenforce Lighty use in the gate

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

2 years agoEnforce sims download in the gate 10/96810/6
guillaume.lambert [Tue, 6 Jul 2021 09:06:02 +0000 (11:06 +0200)]
Enforce sims download in the gate

There is no point to perform functional tests suites if the related sims
download previously failed because of connectivity issues.

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

2 years agoImprove Karaf exec customization for tests 03/96803/5
guillaume.lambert [Mon, 5 Jul 2021 09:22:56 +0000 (11:22 +0200)]
Improve Karaf exec customization for tests

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I60f3010c13e9f101761a46b733982cc27df2c765

2 years agoImprove tox tests parallelization with Karaf 02/96802/4
guillaume.lambert [Mon, 5 Jul 2021 09:08:00 +0000 (11:08 +0200)]
Improve tox tests parallelization with Karaf

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I71038c8c51719158694167e95c26833978d0ff86

2 years agoRefactor Karaf post-install scripts for tests 01/96801/4
guillaume.lambert [Mon, 5 Jul 2021 08:35:17 +0000 (10:35 +0200)]
Refactor Karaf post-install scripts for tests

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I7e6d949887d41528545d78e15bc8ddee89019b75

2 years agoAllow tox tests with Karaf to run in parallel 79/96779/5
Guillaume Lambert [Fri, 2 Jul 2021 13:24:57 +0000 (15:24 +0200)]
Allow tox tests with Karaf to run in parallel

- rework tox depends parameter to allow 2 instances of Karaf to be run
  in parallel
- modify buildcontroller process to add specific Karaf build folders
  for each test suite. Karaf instances are tighly coupled to their build
  folder. Using a separate log file is not enough to allow concurrent
  accesses to work properly.
- create an environment variable and adapt tests script accordingly

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: I7fb608546beaaa19f0b046809c451303bd64c097

2 years agoAllow Karaf to use an alternative websocket port 70/96770/5
Guillaume Lambert [Thu, 1 Jul 2021 20:00:39 +0000 (22:00 +0200)]
Allow Karaf to use an alternative websocket port

In tests post install script
- generate configuration file template for restconf nc-bierman02
- patch Karaf exec to generate configuration file from environment
  variable and template

Allowing the controller configuration to listen to alternative ports
is a commodity to run functional tests in parallel.

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: Ib507f486103a9edcaa9a948644c3739ef7381460

2 years agoAllow Karaf to listen to alternative RMI ports 97/96697/8
guillaume.lambert [Mon, 28 Jun 2021 12:53:28 +0000 (14:53 +0200)]
Allow Karaf to listen to alternative RMI ports

In Karaf post-install script for tests
- generate configuration files templates for Karaf Management
- patch Karaf exec to generate configuration files from environment
  variables and templates

In tox.ini
- declare the related variables in SETENV parameters

Allowing the controller configuration to listen to alternative ports
is a commodity to run functional tests in parallel.

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ic2f0db92b9da14fcd65fc9840aa4365b8f9469f8

2 years agoAllow Karaf to listen to an alternative SSH port 96/96696/8
guillaume.lambert [Mon, 28 Jun 2021 12:41:50 +0000 (14:41 +0200)]
Allow Karaf to listen to an alternative SSH port

In Karaf post-install script for tests
- generate a configuration file template for Karaf Shell
- patch Karaf exec to generate configuration file from environment
  variable and template

In tox.ini
- declare the related variable in SETENV parameters

Allowing the controller configuration to listen to alternative ports
is a commodity to run functional tests in parallel.

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Id1b367aaaaccae4bcf74d1b6ac0aa4997f3083a6

2 years agoAllow Karaf to use altern. RESTCONF and akka ports 92/96692/6
guillaume.lambert [Mon, 28 Jun 2021 11:48:33 +0000 (13:48 +0200)]
Allow Karaf to use altern. RESTCONF and akka ports

In tests post install script
- generate configuration files templates for akka and RESTCONF
- patch Karaf exec to generate configuration files from environment
  variables and templates

Allowing the controller configuration to listen to alternative ports
is a commodity to run functional tests in parallel.

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Id068b557c7cb4676c7d7b742eb939a34a43e70ff

2 years agoCreate a Karaf post-install script for tests 89/96689/6
guillaume.lambert [Mon, 28 Jun 2021 08:54:10 +0000 (10:54 +0200)]
Create a Karaf post-install script for tests

- add a post-install shell script for Karaf and tests purpose
  This post-install script will be copied at build-time from
  src/main/assembly/ressources to target/assembly/ressources
- move the tox.ini sed command used to patch Karaf exec into this script
- update this command since there is no more quoting hell issues
- update tox.ini accordingly

JIRA: TRNSPRTPCE-482
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Iac1bfa3b4bf7a8d0e55130abf2f4cbf349f14ba4

2 years agoFallback gate to Karaf and sequence mode 19/96719/6
guillaume.lambert [Tue, 29 Jun 2021 18:17:58 +0000 (20:17 +0200)]
Fallback gate to Karaf and sequence mode

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

2 years agoAllow tox func tests suite to run in parallel 64/96664/20
Guillaume Lambert [Thu, 24 Jun 2021 13:50:15 +0000 (15:50 +0200)]
Allow tox func tests suite to run in parallel

- append PID to lighty controller log file
  This avoids parsing the file of another controller instance.
- increase various timeout limits
- rework tox "depends" parameters used to artificially create a sequel
  in parallel mode.
  tox -p auto strategy is only based on CPU core numbers and not memory
  nor any other parameter. This is not optimal since it can cause other
  resources starvation issues in the gate (but not locally).
  The new configuration proposed here chains in parallel:
    * PCE tests first then 1.2.1 device tests
    * 7.1 device tests first then 2.2.1 device tests
  This way, only 2 controller instances can be run simultaneously, what
  prevents resources from starvation in the gate.

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: I3a0a66a45a8e170b4554c9de769e1e65b96d224f

2 years agoSet different controller ports in tox tests suites 63/96663/15
Guillaume Lambert [Thu, 24 Jun 2021 13:01:55 +0000 (15:01 +0200)]
Set different controller ports in tox tests suites

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: I62243181953654c053166c8eb4f1fad82567f618

2 years agoAllow Lighty build to listen to alternative ports 62/96662/14
Guillaume Lambert [Thu, 24 Jun 2021 09:24:05 +0000 (11:24 +0200)]
Allow Lighty build to listen to alternative ports

- Add lighty configuration files templates for akka and RESTCONF
- Update lighty clean start script to generate from environment
  variables its configuration files (based on the new templates)

Allowing the controller configuration to listen to alternative ports
is a commodity to run functional tests in parallel.

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: Ib49dcad14e464bdf60c70dbebf6a22c5eba06699

2 years agoRefactor tests launching procedure 65/96565/20
Guillaume Lambert [Fri, 18 Jun 2021 20:18:39 +0000 (22:18 +0200)]
Refactor tests launching procedure

The possibility to run test separately was lost during preliminary work
to prepare jobs parallelization.
This refactoring restores that feature but with a different approach.
For example, the equivalents of the old commands
    $ tox -e topoPortmapping
and
    $ tox -e portmapping,pce
are now
    $ tox -e tests121 topo_portmapping
and
    $ tox -e tests121 "portmapping pce"
(preceded by $ tox -e buildcontroller)

The possibility to choose the script launcher command from a global
variable have been added.
For example,
    $ export LAUNCHER='python3'
allows to replace 'nosetests --with-xunit' by a straight call to python3
to have more debug output during tests.

Tests order can also be changed by directly modifying script filenames
without touching tox.ini. Filenames have been modified here to add a
numbering and keep the tests current order.

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: I725d1dfac42bd309d18fbf87ff1c85bc1bce5be9

2 years agoOutsource PCE tests scripts into a separate folder 70/96570/12
Guillaume Lambert [Mon, 21 Jun 2021 07:56:11 +0000 (09:56 +0200)]
Outsource PCE tests scripts into a separate folder

PCE tests are loosely coupled to a specific version of OpenROADM devices
and does not launch any simulator contrary to other functional tests.
Moving them to a separate folder will ease tests management in the gate.

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: Ide600a3c371b35114b594f119f3a10cb3aed310e

2 years agoOutsource tests scripts not in envlist 64/96564/10
Guillaume Lambert [Fri, 18 Jun 2021 12:13:52 +0000 (14:13 +0200)]
Outsource tests scripts not in envlist

Gnpy and nbinotifications tests requires docker and cannot be run
easily in the gate.
For this reason, they are not listed in tox.ini envlist.
Moving them to a separate folder will ease tests management in the gate.

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: I57b69bc3c4482c4ef2ed9d0aaeffd874b9925deb

2 years agoRefactor tox.ini to prepare parallelized jobs 59/96559/21
Guillaume Lambert [Fri, 18 Jun 2021 12:13:52 +0000 (14:13 +0200)]
Refactor tox.ini to prepare parallelized jobs

- split py3 profiles into several profiles
  and regroup tests by OpenROADM devices version
- separate the controller build from tests themselves in a dedicated
  profile
- use "depends" to state profiles dependencies.
  This is necessary so that tox can order tests sequences
  and decides which jobs can be run in parallel.
  This parameter requires tox versions >= 3.7.0

NB: at this stage, tests can no more be run standalone from a dedicated
tox profile.

JIRA: TRNSPRTPCE-482
Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
Change-Id: I8d583f01003c4d9ee690d866ff602757392c3304

2 years agoBump mdsal dependency to 7.0.9 for Si SR2 44/97244/1
guillaume.lambert [Tue, 17 Aug 2021 23:02:02 +0000 (01:02 +0200)]
Bump mdsal dependency to 7.0.9 for Si SR2

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

2 years agoBump Netconf dependency to 1.13.4 for Si SR2 22/97222/1
guillaume.lambert [Mon, 16 Aug 2021 14:14:21 +0000 (16:14 +0200)]
Bump Netconf dependency to 1.13.4 for Si SR2

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

2 years agoMerge changes I74e9bee3,Ia1ad6f9c,Ic47363f6,I2bba2b18,I507097db, ...
Guillaume Lambert [Fri, 13 Aug 2021 13:19:04 +0000 (13:19 +0000)]
Merge changes I74e9bee3,Ia1ad6f9c,Ic47363f6,I2bba2b18,I507097db, ...

* changes:
  Refactor SH RendererListenerImpl class
  Refactor DeviceRenderingTask classes
  Refactor RendererServiceOperationsImpl step 2
  Refactor OtnDeviceRendereringResult class
  Refactor OtnDeviceRendererServiceImpl class
  Refactor Renderer DeviceRenderingResult class
  Refactor Renderer DeviceRendererServiceImpl class
  Refactor Renderer ModelMappingUtils class
  Refactor RendererServiceOperationsImpl class
  Refactor common serviceType affectation
  Refactor PCE graph PostAlgoPathValidator class
  Refactor PCE calculation class

2 years agoFix OLM timer for Roadm crossconnect power setup 09/96509/6
Vachhani, Shweta (sv111y) [Thu, 10 Jun 2021 21:46:22 +0000 (17:46 -0400)]
Fix OLM timer for Roadm crossconnect power setup

Current timer is 2 mins of warm up time.
The value recommended by OpenROADM device white paper is 20 seconds.

JIRA: TRNSPRTPCE-480
Signed-off-by: Vachhani, Shweta (sv111y) <sv111y@att.com>
Change-Id: I5e8ac03892e9d1c36214733967dc721f504d6542

2 years agoRefactor SH RendererListenerImpl class 94/97094/3
guillaume.lambert [Fri, 6 Aug 2021 09:04:30 +0000 (11:04 +0200)]
Refactor SH RendererListenerImpl class

JIRA: TRNSPRTPCE-491
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I74e9bee317e5449e9c748986355a317d13cebb8a

2 years agoRefactor DeviceRenderingTask classes 91/97091/2
guillaume.lambert [Fri, 6 Aug 2021 08:16:15 +0000 (10:16 +0200)]
Refactor DeviceRenderingTask classes

JIRA: TRNSPRTPCE-491
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ia1ad6f9cde2f6e68510bd62336c7c8e6b8419427

2 years agoRefactor RendererServiceOperationsImpl step 2 90/97090/2
guillaume.lambert [Fri, 6 Aug 2021 06:59:25 +0000 (08:59 +0200)]
Refactor RendererServiceOperationsImpl step 2

JIRA: TRNSPRTPCE-491
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ic47363f657bb798d4a180833afc85edd345c0435

2 years agoRefactor OtnDeviceRendereringResult class 89/97089/1
guillaume.lambert [Thu, 5 Aug 2021 19:56:25 +0000 (21:56 +0200)]
Refactor OtnDeviceRendereringResult class

JIRA: TRNSPRTPCE-491
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I2bba2b18d749f477be95e262d3110fdc7b530e7e

2 years agoRefactor OtnDeviceRendererServiceImpl class 85/97085/3
guillaume.lambert [Thu, 5 Aug 2021 15:36:58 +0000 (17:36 +0200)]
Refactor OtnDeviceRendererServiceImpl class

JIRA: TRNSPRTPCE-491
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I507097db8ce2fb7ae6ca369226fb727f1251a431

2 years agoRefactor Renderer DeviceRenderingResult class 83/97083/1
guillaume.lambert [Thu, 5 Aug 2021 13:43:53 +0000 (15:43 +0200)]
Refactor Renderer DeviceRenderingResult class

JIRA: TRNSPRTPCE-491
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I80720d752c072b1f821053716a2ae48692dca087

2 years agoRefactor Renderer DeviceRendererServiceImpl class 82/97082/8
guillaume.lambert [Wed, 4 Aug 2021 14:46:01 +0000 (16:46 +0200)]
Refactor Renderer DeviceRendererServiceImpl class

JIRA: TRNSPRTPCE-491
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I5d2189933bcba56e4ecb631561b756ed02f6deef

2 years agoRefactor Renderer ModelMappingUtils class 81/97081/1
guillaume.lambert [Wed, 4 Aug 2021 13:59:26 +0000 (15:59 +0200)]
Refactor Renderer ModelMappingUtils class

JIRA: TRNSPRTPCE-491
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: If64273d93997beb875496efac850b8efa2bd88e7

2 years agoRefactor RendererServiceOperationsImpl class 77/97077/3
guillaume.lambert [Tue, 3 Aug 2021 19:47:18 +0000 (21:47 +0200)]
Refactor RendererServiceOperationsImpl class

JIRA: TRNSPRTPCE-489
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I7a65e2bd4e5c5f3e4f297304aa1cc5dba268d70c

2 years agoRefactor common serviceType affectation 66/97066/7
guillaume.lambert [Tue, 3 Aug 2021 15:18:40 +0000 (17:18 +0200)]
Refactor common serviceType affectation

JIRA: TRNSPRTPCE-488
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I2cf7126f92d2501a95a8c7f64b0dc5ea16cd855d

2 years agoRefactor PCE graph PostAlgoPathValidator class 53/97053/2
guillaume.lambert [Mon, 2 Aug 2021 14:07:02 +0000 (16:07 +0200)]
Refactor PCE graph PostAlgoPathValidator class

JIRA: TRNSPRTPCE-477
JIRA: TRNSPRTPCE-478
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: I248225a5912640fdd2f32b0142a213d4fc4284e6

2 years agoRefactor PCE calculation class 51/97051/2
guillaume.lambert [Mon, 2 Aug 2021 08:58:51 +0000 (10:58 +0200)]
Refactor PCE calculation class

Use switch/case structures for style coherency
and guard cause style to smooth indentation
and ternary operator to remove useless variable allocation.

JIRA: TRNSPRTPCE-485
Signed-off-by: guillaume.lambert <guillaume.lambert@orange.com>
Change-Id: Ibf7d7550b83b4c9e222415905045b4e0938842f6

2 years agoRefactor NBINotification & add ServiceListener tests 72/96672/5
Thierry Jiao [Thu, 24 Jun 2021 15:01:59 +0000 (17:01 +0200)]
Refactor NBINotification & add ServiceListener tests

- Refactor Subscriber and Publisher from nbinotifications
- Update NBINotifications unit tests
- Add new unit test for ServiceListener
- Update func test 'test_nbinotifications.py'

JIRA: TRNSPRTPCE-471
Signed-off-by: Thierry Jiao <thierry.jiao@orange.com>
Change-Id: Ie1161740432f12176acfb8b31658abc4a1190f62

2 years agoAdd service listener to notify Kafka 31/96531/9
Thierry Jiao [Mon, 14 Jun 2021 12:56:15 +0000 (14:56 +0200)]
Add service listener to notify Kafka

  - Implement a new listener 'ServiceListener' that sends a
    notification to the topic 'alarmservice' of the Kafka broker
    when a service breakdowns or is restored
  - Add a new RPC API named 'GetNotificationsAlarmService' to retrieve
    notifications from the topic 'alarmservice'
  - Add a new subscriber 'SubscriberAlarm' dedicated to read
    alarm notifications from topics Kafka
  - Add a new publisher 'PublisherAlarm' dedicated to write alarm
    notifications from topics Kafka
  - Update nbi-notifications unit tests

JIRA: TRNSPRTPCE-471
Signed-off-by: Thierry Jiao <thierry.jiao@orange.com>
Change-Id: I4b42c8a3282a805791ae6d9d046031dd385faaae

2 years agoManage OTN links at 400G 15/96915/12
Gilles Thouenon [Mon, 12 Jul 2021 11:34:41 +0000 (13:34 +0200)]
Manage OTN links at 400G

- put otn-link-type as prefix for link name
- propagate and use otn-link-type to differentiate treatments between
100G and 400G supported links
- use min and max trib slot and trib port comming from path-description
to update ODU4/ODUC4 links
- adapt existing UT

jira: TRNSPRTPCE-492
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: I4bef0c7edbe02f5b8cbee3f1db7bc32cd0746f59

2 years agoMove otn link update from renderer to SH 14/96914/10
Gilles Thouenon [Wed, 23 Jun 2021 09:49:41 +0000 (11:49 +0200)]
Move otn link update from renderer to SH

- align service-path delete on service-path create
- use DeviceRenderingTask to both create and delete optical service
- uses action to create service-path inputs
- use new link-tp object to notify otn-link termination-points to be
updated
- change updateOtnLink signature method to use new link-tp objects
notified by renderer
- use service-type to chose between service-path or otn-service-path
- adapt RendererListener of service handler to handle otn-link update
notifications received according to the service-type

JIRA: TRNSPRTPCE-491
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: Ic277dd716676053b62ca59c562e4077a8e45f92e

2 years agoRefactor: few renames in renderer 13/96913/8
Gilles Thouenon [Wed, 23 Jun 2021 08:16:47 +0000 (10:16 +0200)]
Refactor: few renames in renderer

Rename some methods links to transportpce yang models to be more
explicit.

JIRA: TRNSPRTPCE-490
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: I7ddf7aebac80842473abf9051aa1a344e74a2073

2 years agoRefactor: update transportpce yang models 12/96912/8
Gilles Thouenon [Fri, 18 Jun 2021 15:33:42 +0000 (17:33 +0200)]
Refactor: update transportpce yang models

- use grouping for nodes in transportpce-commpon-types
- add nodes in renderer notification
- put action as enumeration in renderer model
- add a link-tp grouping
- add a link-for-notif grouping to notify otn-topology for updates
- adapt code accordingly

JIRA: TRNSPRTPCE-490
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: I8308173d6fe83ad65cc1b7737cded8986267316c

2 years agoRefactor: change the way to select renderer 11/96911/8
Gilles Thouenon [Fri, 18 Jun 2021 11:58:35 +0000 (13:58 +0200)]
Refactor: change the way to select renderer

- introduce service-type from common module (and already used by pce) to
  choose adequate renderer (optical vs otn)
- update transportpce-device-renderer model by 1) replacing service-type
  (which is confusing) in otn-renderer api by service-format which is
  more appropriate 2) changing service-rate type to be aligned with
  service-create rpc input
- adapt the code consequently

JIRA: TRNSPRTPCE-489
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: Ia506a1af3a9b98516a0c73ed1f4f6671eab04ab6

2 years agoMove serviceType affectation to common 10/96910/6
Gilles Thouenon [Thu, 17 Jun 2021 13:31:12 +0000 (15:31 +0200)]
Move serviceType affectation to common

ServiceType is needed by both PCE and Renderer. It makes sence to get it
easily from common module instead of duplicating the treatment to obtain
it from the service-create rpc inputs.
Add also specific getOtnServiceType method for otn-services.

JIRA: TRNSPRTPCE-488
Signed-off-by: Gilles Thouenon <gilles.thouenon@orange.com>
Change-Id: Ie51255620623fb3e3030b25d1f6343455e427adb