diff --git a/Jenkinsfile b/Jenkinsfile
index 9056d0747..4dd7f0e08 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -10,22 +10,18 @@
* to use the software.
*/
-def runBuildStage(String buildMode, String linkMode) {
- def cmd = "python3 ${env.WORKSPACE}/resources/ci_cd/linux_build.py"
- cmd += " --build-mode ${buildMode}"
- cmd += " --link-mode ${linkMode}"
- cmd += " --build-dir ${get_build_directory(buildMode, linkMode)}"
- sh(cmd)
-}
-
-def get_build_directory(String buildMode, String linkMode) {
- return "build_${buildMode}_${linkMode}"
-}
+/**
+ * Hold information about the pipeline.
+ */
+Map pipelineInfo = [:]
pipeline {
- agent none
+ agent {
+ label "${runInsideExecutor.labelFromJobName()}"
+ }
options {
+ skipDefaultCheckout()
disableConcurrentBuilds()
/*
To avoid excessive resource usage in server, we limit the number
@@ -48,70 +44,102 @@ pipeline {
}
stages {
- stage('Build sequence') {
- agent {
- dockerfile {
- filename 'resources/docker/Dockerfile.linux'
- label 'docker'
+ stage('Configuration') {
+ steps {
+ script {
+ checkoutCommunityRepoBranch(
+ 'rticonnextdds-examples',
+ env.BRANCH_NAME,
+ false,
+ )
+ pipelineInfo.dockerDir = "${env.WORKSPACE}/resources/docker/"
+ pipelineInfo.staticAnalysisDir = "${env.WORKSPACE}/static_analysis_report"
+ runInsideExecutor(
+ '',
+ pipelineInfo.dockerDir,
+ ) {
+ pipelineInfo.connextArch = getEnvVar('CONNEXTDDS_ARCH')
+ }
}
}
-
- environment {
- RTI_INSTALLATION_PATH = "${env.WORKSPACE}"
+ }
+ stage('Download Packages') {
+ steps {
+ runInsideExecutor(
+ '',
+ pipelineInfo.dockerDir,
+ ) {
+ script {
+ def version = readFile('VERSION').readLines()[0].trim()
+ pipelineInfo.connextDir = installConnext(
+ pipelineInfo.connextArch,
+ env.WORKSPACE,
+ version
+ )
+ }
+ }
}
-
- stages {
- stage('Download Packages') {
- steps {
- sh 'pip3 install -r resources/ci_cd/requirements.txt'
-
- withAWSCredentials {
- withCredentials([
- string(credentialsId: 's3-bucket', variable: 'RTI_AWS_BUCKET'),
- string(credentialsId: 's3-path', variable: 'RTI_AWS_PATH'),
- ]) {
- sh 'python3 resources/ci_cd/linux_install.py -a $CONNEXTDDS_ARCH'
- }
- }
+ }
+ stage('Build all modes') {
+ matrix {
+ axes {
+ axis {
+ name 'buildMode'
+ values 'release', 'debug'
+ }
+ axis {
+ name 'linkMode'
+ values 'static', 'dynamic'
}
}
-
- stage('Build all modes') {
- matrix {
- axes {
- axis {
- name 'buildMode'
- values 'release', 'debug'
- }
- axis {
- name 'linkMode'
- values 'static', 'dynamic'
- }
- }
- stages {
- stage('Build single mode') {
- steps {
- echo("Build ${buildMode}/${linkMode}")
- runBuildStage(buildMode, linkMode)
- }
+ stages {
+ stage('Build single mode') {
+ steps {
+ runInsideExecutor(
+ '',
+ pipelineInfo.dockerDir,
+ ) {
+ echo("Building ${buildMode}/${linkMode}")
+ buildExamples(
+ pipelineInfo.connextArch,
+ pipelineInfo.connextDir,
+ buildMode,
+ linkMode,
+ env.WORKSPACE,
+ )
}
}
}
}
-
- stage('Static Analysis') {
- steps {
- sh "python3 resources/ci_cd/linux_static_analysis.py --build-dir ${get_build_directory('release', 'dynamic')}"
- }
- }
}
-
- post {
- cleanup {
- cleanWs()
+ }
+ stage('Static Analysis') {
+ steps {
+ runInsideExecutor(
+ '',
+ pipelineInfo.dockerDir,
+ ) {
+ runStaticAnalysis(
+ buildExamples.getBuildDirectory('release', 'dynamic'),
+ pipelineInfo.connextDir,
+ pipelineInfo.staticAnalysisDir,
+ )
}
+ publishHTML(target: [
+ allowMissing: true,
+ alwaysLinkToLastBuild: true,
+ keepAll: true,
+ reportDir: pipelineInfo.staticAnalysisDir,
+ reportFiles: 'index.html',
+ reportName: 'LLVM Scan build static analysis',
+ ])
}
}
}
+ post {
+ cleanup {
+ cleanWs()
+ }
+ }
}
diff --git a/README.md b/README.md
index 9c9a6550f..cb4028238 100644
--- a/README.md
+++ b/README.md
@@ -11,12 +11,11 @@ automatically be included in the [RTI Community Portal Examples
Section](http://community.rti.com). See [CONTRIBUTING.md](https://github.com/rticommunity/rticonnextdds-examples/blob/master/CONTRIBUTING.md)
for further information about how to contribute with new examples to this repository.
-The examples contained in the
-[master](https://github.com/rticommunity/rticonnextdds-examples/tree/master)
-branch of this repository have been built and tested against RTI Connext DDS
-7.3.0. If you need examples that have been built and tested against older
-versions of RTI Connext DDS, please check out the appropriate branch:
+The examples contained in this branch were built and tested against **RTI Connext DDS
+7.3.1**. If you need examples that have been built and tested against previous
+versions of RTI Connext DDS, please check out the corresponding release branch:
+- [release/7.3.0](https://github.com/rticommunity/rticonnextdds-examples/tree/release/7.3.0)
- [release/7.2.0](https://github.com/rticommunity/rticonnextdds-examples/tree/release/7.2.0)
- [release/7.1.0](https://github.com/rticommunity/rticonnextdds-examples/tree/release/7.1.0)
- [release/7.0.0](https://github.com/rticommunity/rticonnextdds-examples/tree/release/7.0.0)
diff --git a/VERSION b/VERSION
index 8b23b8d47..34a8f745d 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-7.3.0
\ No newline at end of file
+7.3.1
\ No newline at end of file
diff --git a/examples/connext_dds/asynchronous_publication/cs/AsyncPublicationExample.csproj b/examples/connext_dds/asynchronous_publication/cs/AsyncPublicationExample.csproj
index f98097ce9..deaa91fde 100644
--- a/examples/connext_dds/asynchronous_publication/cs/AsyncPublicationExample.csproj
+++ b/examples/connext_dds/asynchronous_publication/cs/AsyncPublicationExample.csproj
@@ -6,7 +6,7 @@
-
+
diff --git a/examples/connext_dds/custom_flow_controller/cs/FlowControllerExample.csproj b/examples/connext_dds/custom_flow_controller/cs/FlowControllerExample.csproj
index f98097ce9..deaa91fde 100644
--- a/examples/connext_dds/custom_flow_controller/cs/FlowControllerExample.csproj
+++ b/examples/connext_dds/custom_flow_controller/cs/FlowControllerExample.csproj
@@ -6,7 +6,7 @@
-
+
diff --git a/examples/connext_dds/dynamic_data_sequences/cs/DynamicDataSequencesExample.csproj b/examples/connext_dds/dynamic_data_sequences/cs/DynamicDataSequencesExample.csproj
index 287615508..c0d9c4393 100644
--- a/examples/connext_dds/dynamic_data_sequences/cs/DynamicDataSequencesExample.csproj
+++ b/examples/connext_dds/dynamic_data_sequences/cs/DynamicDataSequencesExample.csproj
@@ -6,7 +6,7 @@
-
+
diff --git a/examples/connext_dds/dynamic_data_skip_serialization/c++11/CMakeLists.txt b/examples/connext_dds/dynamic_data_skip_serialization/c++11/CMakeLists.txt
index 6cfe98894..3ea500041 100644
--- a/examples/connext_dds/dynamic_data_skip_serialization/c++11/CMakeLists.txt
+++ b/examples/connext_dds/dynamic_data_skip_serialization/c++11/CMakeLists.txt
@@ -20,7 +20,7 @@ connextdds_configure_cmake_utils()
# Find the RTI Connext DDS libraries
if(NOT RTIConnextDDS_FOUND)
find_package(RTIConnextDDS
- "7.3.0"
+ "7.3.1"
REQUIRED
COMPONENTS
core
diff --git a/examples/connext_dds/dynamic_data_using_publisher_subscriber/cs/Shapes.csproj b/examples/connext_dds/dynamic_data_using_publisher_subscriber/cs/Shapes.csproj
index f98097ce9..deaa91fde 100644
--- a/examples/connext_dds/dynamic_data_using_publisher_subscriber/cs/Shapes.csproj
+++ b/examples/connext_dds/dynamic_data_using_publisher_subscriber/cs/Shapes.csproj
@@ -6,7 +6,7 @@
-
+
diff --git a/examples/connext_dds/group_coherent_presentation/cs/GroupCoherentExample.csproj b/examples/connext_dds/group_coherent_presentation/cs/GroupCoherentExample.csproj
index f98097ce9..deaa91fde 100644
--- a/examples/connext_dds/group_coherent_presentation/cs/GroupCoherentExample.csproj
+++ b/examples/connext_dds/group_coherent_presentation/cs/GroupCoherentExample.csproj
@@ -6,7 +6,7 @@
-
+
diff --git a/examples/connext_dds/partitions/cs/PartitionsExample.csproj b/examples/connext_dds/partitions/cs/PartitionsExample.csproj
index e10ab88df..0a38e18a3 100644
--- a/examples/connext_dds/partitions/cs/PartitionsExample.csproj
+++ b/examples/connext_dds/partitions/cs/PartitionsExample.csproj
@@ -6,7 +6,7 @@
-
+
diff --git a/examples/connext_dds/request_reply/cs/Primes.csproj b/examples/connext_dds/request_reply/cs/Primes.csproj
index 08b6eb466..dde8693a0 100644
--- a/examples/connext_dds/request_reply/cs/Primes.csproj
+++ b/examples/connext_dds/request_reply/cs/Primes.csproj
@@ -6,7 +6,7 @@
-
+
diff --git a/examples/connext_secure/cds/c++11/USER_QOS_PROFILES.xml b/examples/connext_secure/cds/c++11/USER_QOS_PROFILES.xml
index fb960f9df..2403e9762 100644
--- a/examples/connext_secure/cds/c++11/USER_QOS_PROFILES.xml
+++ b/examples/connext_secure/cds/c++11/USER_QOS_PROFILES.xml
@@ -11,7 +11,7 @@ any incidental or consequential damages arising out of the use or inability
to use the software. -->
+ xsi:noNamespaceSchemaLocation="http://community.rti.com/schema/7.3.1/rti_dds_profiles.xsd">
+ xsi:noNamespaceSchemaLocation="http://community.rti.com/schema/7.3.1/rti_cloud_discovery_service.xsd">
diff --git a/examples/connext_secure/certificate_revocation_list/c++11/USER_QOS_PROFILES.xml b/examples/connext_secure/certificate_revocation_list/c++11/USER_QOS_PROFILES.xml
index 8d75fa06f..4e7ae2d5d 100644
--- a/examples/connext_secure/certificate_revocation_list/c++11/USER_QOS_PROFILES.xml
+++ b/examples/connext_secure/certificate_revocation_list/c++11/USER_QOS_PROFILES.xml
@@ -11,7 +11,7 @@ any incidental or consequential damages arising out of the use or inability
to use the software. -->
+ xsi:noNamespaceSchemaLocation="http://community.rti.com/schema/7.3.1/rti_dds_profiles.xsd">
diff --git a/examples/connext_secure/certificate_revocation_list/security/xml/Governance.xml b/examples/connext_secure/certificate_revocation_list/security/xml/Governance.xml
index 1075f05c3..a2bfb86ff 100644
--- a/examples/connext_secure/certificate_revocation_list/security/xml/Governance.xml
+++ b/examples/connext_secure/certificate_revocation_list/security/xml/Governance.xml
@@ -1,6 +1,6 @@
+ xsi:noNamespaceSchemaLocation="http://community.rti.com/schema/7.3.1/dds_security_governance.xsd">
diff --git a/examples/connext_secure/certificate_revocation_list/security/xml/Permissions.xml b/examples/connext_secure/certificate_revocation_list/security/xml/Permissions.xml
index 02f1289c6..bc8548387 100644
--- a/examples/connext_secure/certificate_revocation_list/security/xml/Permissions.xml
+++ b/examples/connext_secure/certificate_revocation_list/security/xml/Permissions.xml
@@ -1,7 +1,7 @@
+ xsi:noNamespaceSchemaLocation="http://community.rti.com/schema/7.3.1/dds_security_permissions.xsd">
C = US, ST = CA, L = Santa Clara, O = Real Time Innovations, emailAddress = ecdsa01ParticipantA@rti.com, CN = Crl Participant A
diff --git a/examples/connext_secure/lightweight/c++11/USER_QOS_PROFILES.xml b/examples/connext_secure/lightweight/c++11/USER_QOS_PROFILES.xml
index c866c262b..e90ddb9a9 100644
--- a/examples/connext_secure/lightweight/c++11/USER_QOS_PROFILES.xml
+++ b/examples/connext_secure/lightweight/c++11/USER_QOS_PROFILES.xml
@@ -11,7 +11,7 @@ any incidental or consequential damages arising out of the use or inability
to use the software. -->
+ xsi:noNamespaceSchemaLocation="http://community.rti.com/schema/7.3.1/rti_dds_profiles.xsd">
diff --git a/examples/connext_secure/lightweight/security/xml/governance_lws.xml b/examples/connext_secure/lightweight/security/xml/governance_lws.xml
index 4de78877d..a9d2bc6e0 100644
--- a/examples/connext_secure/lightweight/security/xml/governance_lws.xml
+++ b/examples/connext_secure/lightweight/security/xml/governance_lws.xml
@@ -1,6 +1,6 @@
+ xsi:noNamespaceSchemaLocation="http://community.rti.com/schema/7.3.1/dds_security_governance.xsd">
diff --git a/examples/connext_secure/lightweight/security/xml/permissions.xml b/examples/connext_secure/lightweight/security/xml/permissions.xml
index 8047223e7..71fcf6e83 100644
--- a/examples/connext_secure/lightweight/security/xml/permissions.xml
+++ b/examples/connext_secure/lightweight/security/xml/permissions.xml
@@ -1,7 +1,7 @@
+ xsi:noNamespaceSchemaLocation="http://community.rti.com/schema/7.3.1/dds_security_permissions.xsd">
/C=US/ST=CA/L=Santa Clara/O=Real Time Innovations/emailAddress=ecdsa01ParticipantA@rti.com/CN=Lightweight Participant A
diff --git a/resources/docker/Dockerfile.linux b/resources/docker/Dockerfile.linux
index d3a71c2f8..e67bb57bd 100644
--- a/resources/docker/Dockerfile.linux
+++ b/resources/docker/Dockerfile.linux
@@ -11,20 +11,27 @@
FROM ubuntu:20.04
-ENV CONNEXTDDS_ARCH="x64Linux4gcc7.3.0"
+ARG USER_NAME=jenkins
+ARG USER_UID
+
ENV DEBIAN_FRONTEND="noninteractive"
+ENV CONNEXTDDS_ARCH="x64Linux4gcc7.3.0"
RUN apt-get update && apt-get install -y \
- gcc \
- g++ \
- clang \
- libssl-dev \
- make \
- cmake \
- python3 \
- python3-pip \
- clang-tools-10 \
- && rm -rf /var/lib/apt/lists/* \
- && useradd -u 789 -m jenkins
+ gcc \
+ g++ \
+ clang \
+ clang-tools-10 \
+ make \
+ cmake \
+ libssl-dev \
+ python3 \
+ python3-pip \
+ python3-venv \
+ python3-distutils \
+ && rm -rf /var/lib/apt/lists/*
+
+RUN useradd -u ${USER_UID} -m ${USER_NAME}
+ENV PATH=/home/$USER_NAME/.local/bin:$PATH
-ENV PATH=/usr/share/clang/scan-build-py-10/bin:${PATH}
+USER $USER_NAME