X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=jjb%2Fintegration%2Fintegration-macros.yaml;h=2ab9bb4fc9aa28687f0ebfa9ebfff99cd2c3e6e5;hb=d5e8f4f356e0c31c3a806328a67887aecfa2e709;hp=fbaafd57a72a6b846d0f95e374a9fc4e19b34d4a;hpb=f0a041288926db430da904b18a2f8a627248c569;p=releng%2Fbuilder.git diff --git a/jjb/integration/integration-macros.yaml b/jjb/integration/integration-macros.yaml index fbaafd57a..2ab9bb4fc 100644 --- a/jjb/integration/integration-macros.yaml +++ b/jjb/integration/integration-macros.yaml @@ -12,12 +12,12 @@ - parameter: name: distribution-karaf-version # Arguments: - # karaf-version: Provide, otherwise releng-defaults value is used. + # karaf-version: Provide, otherwise defaults.yaml value is used. parameters: - string: name: KARAF_VERSION default: '{karaf-version}' - description: 'karaf3 or karaf4, affects ODL deploy scripts' + description: 'karaf3, karaf4, odl, affects ODL deploy scripts' - parameter: name: integration-bundle-url @@ -27,6 +27,14 @@ default: '{bundle-url}' description: 'URL to karaf distribution zip' +- parameter: + name: integration-repo-url + parameters: + - string: + name: REPO_URL + default: '{repo-url}' + description: 'URL to feature repo artifact' + - parameter: name: integration-jdk-version parameters: @@ -71,6 +79,22 @@ default: '{stream}' description: 'Distribution stream string, for suites to know which behavior to expect' +- parameter: + name: integration-script-plan + parameters: + - string: + name: SCRIPTPLAN + default: '{script-plan}' + description: 'Script plan we will run before downloading and un-archiving am ODL distribution' + +- parameter: + name: integration-config-plan + parameters: + - string: + name: CONFIGPLAN + default: '{config-plan}' + description: 'Config plan we will run after un-archiving and starting an ODL distribution' + - parameter: name: integration-stream-test-plan parameters: @@ -96,8 +120,8 @@ description: | List of space-separated suites. Useful when running specific suites within a testplan. Do not include ${{WORKSPACE}}/test/csit/suites/ in the values: - (ex. openstack/connectivity/l2.robot openstack/tempest/tempest.robot - integration/test/csit/suites/netvirt/ElanService/). + (ex. openstack/connectivity/l2.robot openstack/clustering/ha_l2.robot + openstack/tempest/tempest.robot netvirt/elan/elan.robot). - parameter: name: integration-test-options @@ -186,7 +210,7 @@ exclude-no-code-change: false - draft-published-event - comment-added-contains-event: - comment-contains-value: recheck + comment-contains-value: '^Patch Set[ ]+[0-9]+:([ ]+|[\n]+)(recheck|reverify)$' override-votes: true gerrit-build-unstable-verified-value: +1 gerrit-build-unstable-codereview-value: 0 @@ -522,44 +546,86 @@ publishers: - postbuildscript: builders: - - shell: | - #!/bin/bash - cd $WORKSPACE - mkdir -p ./archives - curl --output robot-plugin.zip "$BUILD_URL/robot/report/*zip*/robot-plugin.zip" - unzip -d ./archives robot-plugin.zip - mv *.log *.log.gz *.csv *.png ./archives || true # Don't fail if file missing - # TODO: Can the following line ever fail? - find . -type f -name *.hprof -print0 | tar -cvf - --null -T - | xz --threads=0 > ./archives/hprof.tar.xz - # TODO: Tweak the compression level if better ratio (or speed) is needed. - script-only-if-succeeded: 'False' - script-only-if-failed: 'False' - mark-unstable-if-failed: 'True' + - role: BOTH + build-on: + - ABORTED + - FAILURE + - NOT_BUILT + - SUCCESS + - UNSTABLE + build-steps: + - shell: | + #!/bin/bash + cd $WORKSPACE + mkdir -p ./archives + for i in `seq 1 ${NUM_ODL_SYSTEM}`; do + NODE_FOLDER="./archives/odl_${i}" + mkdir -p ${NODE_FOLDER} + mv odl${i}_karaf* ${NODE_FOLDER} || true + mv karaf_${i}_*_threads* ${NODE_FOLDER} || true + mv *_${i}.png ${NODE_FOLDER} || true + done + curl --output robot-plugin.zip "$BUILD_URL/robot/report/*zip*/robot-plugin.zip" + unzip -d ./archives robot-plugin.zip + mv *.log *.log.gz *.csv *.png ./archives || true # Don't fail if file missing + # TODO: Can the following line ever fail? + find . -type f -name *.hprof -print0 \ + | tar -cvf - --null -T - | xz --threads=0 > ./archives/hprof.tar.xz + # TODO: Tweak the compression level if better ratio (or speed) is needed. + mark-unstable-if-failed: true + - publisher: name: integration-csit-run-postscript publishers: - postbuildscript: builders: - - config-file-provider: - files: - - file-id: 'odl-elastic-cloud' - target: '${HOME}/.netrc' - - shell: | - #!/bin/bash - #The following script runs any configurable postplan stored in test/csit/postplans. - if [ -f "${WORKSPACE}/test/csit/postplans/${TESTPLAN}" ]; then - echo "postplan exists!!!" - echo "Changing the postplan path..." - script_name=${WORKSPACE}/test/csit/postplans/${TESTPLAN} - cat ${script_name} | sed "s:integration:${WORKSPACE}:" > postplan.txt - cat postplan.txt - egrep -v '(^[[:space:]]*#|^[[:space:]]*$)' postplan.txt | while read -r line ; do - echo "Executing ${line}..." - ${line} - done - fi - rm ${HOME}/.netrc - script-only-if-succeeded: 'False' - script-only-if-failed: 'False' - mark-unstable-if-failed: 'True' + - role: BOTH + build-on: + - ABORTED + - FAILURE + - NOT_BUILT + - SUCCESS + - UNSTABLE + build-steps: + - config-file-provider: + files: + - file-id: 'odl-elastic-cloud' + target: '${HOME}/.netrc' + - shell: | + #!/bin/bash + #The following script runs any configurable postplan stored in test/csit/postplans. + if [ -f "${WORKSPACE}/test/csit/postplans/${TESTPLAN}" ]; then + echo "postplan exists!!!" + echo "Changing the postplan path..." + script_name=${WORKSPACE}/test/csit/postplans/${TESTPLAN} + cat ${script_name} | sed "s:integration:${WORKSPACE}:" > postplan.txt + cat postplan.txt + egrep -v '(^[[:space:]]*#|^[[:space:]]*$)' postplan.txt | while read -r line ; do + echo "Executing ${line}..." + ${line} + done + fi + rm ${HOME}/.netrc + mark-unstable-if-failed: true + +- publisher: + name: integration-csit-collect-netvirt-logs + publishers: + - postbuildscript: + builders: + - role: BOTH + build-on: + - ABORTED + - FAILURE + - NOT_BUILT + - SUCCESS + - UNSTABLE + build-steps: + - inject: + properties-file: 'slave_addresses.txt' + - shell: | + #!/bin/bash + source /tmp/common-functions.sh ${BUNDLEFOLDER} + collect_netvirt_logs + mark-unstable-if-failed: true