Installation Feature
~~~~~~~~~~~~~~~~~~~~
+Creation of services with TransportPCE controller on real optical devices takes a rather long while,
+due to the fact that the output optical power level modification on interfaces requires time for stabilisation
+level. Per default values of TransportPCE timers are those recommended by OpenROADM MSA, respectively 120 000
+and 20 000 seconds.
+When running TransportPCE controller with honeynode simulators, which is the case of all TransportPCE functional tests,
+we don't need so important timer values. You can considerably speed tests using respectively 3000 and 2000 seconds.
+To that end, before running OpenDaylight, set OLM_TIMER1 and OLM_TIMER2 as environment variables.
+For example::
+
+ export OLM_TIMER1=3000 OLM_TIMER2=2000
+
+To come back with per default values for these timers, just logout from OpenDaylight controller, and unset your
+environment variables, and start again the controller::
+
+ unset OLM_TIMER1 OLM_TIMER2
+
+
Run OpenDaylight and install TransportPCE Service *odl-transportpce* as below::
feature:install odl-transportpce
<skipTests>true</skipTests>
</configuration>
</plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>attach-artifact</id>
+ <phase>test</phase>
+ <goals>
+ <goal>attach-artifact</goal>
+ </goals>
+ <configuration>
+ <artifacts>
+ <artifact>
+ <file>${basedir}/src/main/resources/org.opendaylight.transportpce.cfg</file>
+ <type>cfg</type>
+ <classifier>config</classifier>
+ </artifact>
+ </artifacts>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
</build>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!-- Copyright © 2021 Orange and others. All rights reserved. This program
+ and the accompanying materials are made available under the terms of the
+ Eclipse Public License v1.0 which accompanies this distribution, and is available
+ at http://www.eclipse.org/legal/epl-v10.html INTERNAL -->
+<features xmlns="http://karaf.apache.org/xmlns/features/v1.4.0" name="odl-transportpce">
+ <feature name="odl-transportpce">
+ <configfile finalname="etc/org.opendaylight.transportpce.cfg" override="true">
+ mvn:${project.groupId}/${project.artifactId}/${project.version}/cfg/config
+ </configfile>
+ </feature>
+</features>
\ No newline at end of file
--- /dev/null
+timer1=${env:OLM_TIMER1:-120000}
+timer2=${env:OLM_TIMER2:-20000}
\ No newline at end of file
sed -e 's/1099/ODL_RMI_REGISTRY_PORT/' -e 's/44444/ODL_RMI_SERVER_PORT/' ../etc/org.apache.karaf.management.cfg > org.apache.karaf.management._template.cfg
sed 's/^[#|]websocket-port=8185/websocket-port=ODL_WEBSOCKET_PORT/' ../system/org/opendaylight/netconf/sal-rest-connector-config/[0-9.]*/sal-rest-connector-config-[0-9.]*-restconf.cfg >org.opendaylight.restconf._template.cfg
-echo 'timer1=3000' >../etc/org.opendaylight.transportpce.olm.cfg
-echo 'timer2=2000' >>../etc/org.opendaylight.transportpce.olm.cfg
-
sed -i'_' -e '1 a\
\
. \$(dirname \$0)/\.\./\.\./\.\./\.\./tests/reflectwarn.sh\
xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.1.0"
odl:use-default-for-reference-types="true">
- <cm:property-placeholder persistent-id="org.opendaylight.transportpce.olm" update-strategy="reload">
+ <cm:property-placeholder persistent-id="org.opendaylight.transportpce" update-strategy="reload">
<cm:default-properties>
- <cm:property name="timer1" value="120000" />
- <cm:property name="timer2" value="20000" />
+ <cm:property name="timer1" value="" />
+ <cm:property name="timer2" value="" />
<!--The following values are used to speed-up tests with simulators without convergence times-->
<!--cm:property name="timer1" value="3000" /-->
<!--cm:property name="timer2" value="2000" /-->
export USE_ODL_ALT_RMI_REGISTRY_PORT=1100
export USE_ODL_ALT_RMI_SERVER_PORT=44445
export USE_ODL_ALT_RESTCONF_PORT=8182
+export OLM_TIMER1=3000
+export OLM_TIMER2=2000
\ No newline at end of file
export USE_ODL_ALT_RMI_REGISTRY_PORT=1101
export USE_ODL_ALT_RMI_SERVER_PORT=44446
export USE_ODL_ALT_RESTCONF_PORT=8183
+export OLM_TIMER1=3000
+export OLM_TIMER2=2000
\ No newline at end of file
export USE_ODL_ALT_RMI_REGISTRY_PORT=1102
export USE_ODL_ALT_RMI_SERVER_PORT=44447
export USE_ODL_ALT_RESTCONF_PORT=8184
+export OLM_TIMER1=3000
+export OLM_TIMER2=2000
\ No newline at end of file
setupdir = tests/
[testenv]
-passenv = USE_LIGHTY http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY
-#setenv =
+passenv = USE_LIGHTY http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY OLM_TIMER1 OLM_TIMER2
+setenv =
# USE_LIGHTY=True
+ OLM_TIMER1=3000
+ OLM_TIMER2=2000
+
usedevelop = true
basepython = python3
deps =
depends = buildcontroller,sims221
whitelist_externals = launch_tests.sh
dockercmd.sh
-passenv = LAUNCHER USE_LIGHTY USE_ODL_RESTCONF_VERSION
+passenv = LAUNCHER USE_LIGHTY USE_ODL_RESTCONF_VERSION OLM_TIMER1 OLM_TIMER2
+setenv =
+ OLM_TIMER1=3000
+ OLM_TIMER2=2000
+
commands =
./dockercmd.sh run -d -p 2181:2181 -p 9092:9092 --env ADVERTISED_LISTENERS=PLAINTEXT://localhost:9092 --name tpce_kafka1 teivah/kafka:2.0.0
./launch_tests.sh with_docker nbinotifications