Skip to content

Commit

Permalink
add rust toolchain to docker image and enabled integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dbw9580 committed Sep 25, 2023
1 parent 5dd66df commit 9205036
Show file tree
Hide file tree
Showing 8 changed files with 67 additions and 10 deletions.
2 changes: 2 additions & 0 deletions dev/github/Dockerfile-jdk11
Original file line number Diff line number Diff line change
Expand Up @@ -153,3 +153,5 @@ RUN ARCH=$(dpkg --print-architecture) && \
wget --quiet https://releases.hashicorp.com/terraform/1.0.1/terraform_1.0.1_linux_${ARCH}.zip && \
unzip -o ./terraform_1.0.1_linux_${ARCH}.zip -d /usr/local/bin/ && \
rm terraform_1.0.1_linux_${ARCH}.zip
# Rust toolchains for native components
RUN apt-get install -y rust-all
2 changes: 2 additions & 0 deletions dev/github/Dockerfile-jdk17
Original file line number Diff line number Diff line change
Expand Up @@ -158,3 +158,5 @@ RUN ARCH=$(dpkg --print-architecture) && \
wget --quiet https://releases.hashicorp.com/terraform/1.0.1/terraform_1.0.1_linux_${ARCH}.zip && \
unzip -o ./terraform_1.0.1_linux_${ARCH}.zip -d /usr/local/bin/ && \
rm terraform_1.0.1_linux_${ARCH}.zip
# Rust toolchains for native components
RUN apt-get install -y rust-all
3 changes: 3 additions & 0 deletions dev/github/Dockerfile-jdk8
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,6 @@ RUN ARCH=$(dpkg --print-architecture) && \
wget --quiet https://releases.hashicorp.com/terraform/1.0.1/terraform_1.0.1_linux_${ARCH}.zip && \
unzip -o ./terraform_1.0.1_linux_${ARCH}.zip -d /usr/local/bin/ && \
rm terraform_1.0.1_linux_${ARCH}.zip

# Rust toolchains for native components
RUN apt-get install -y rust-all
5 changes: 3 additions & 2 deletions dev/github/run_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ PATH_BACKUP=${PATH}
JAVA_HOME=/usr/local/openjdk-8
PATH=$JAVA_HOME/bin:$PATH
mvn -Duser.home=/home/jenkins -T 4C clean install -Dfindbugs.skip -Dcheckstyle.skip -DskipTests -Dmaven.javadoc.skip \
-Dlicense.skip -Dsort.skip ${mvn_args}
-Dlicense.skip -Dsort.skip -Pnative-components ${mvn_args}

# Set things up so that the current user has a real name and can authenticate.
myuid=$(id -u)
Expand All @@ -56,4 +56,5 @@ fi

# Run tests
mvn -Duser.home=/home/jenkins test -Dmaven.main.skip -Dskip.protoc=true -Dmaven.javadoc.skip -Dlicense.skip=true \
-Dcheckstyle.skip=true -Dfindbugs.skip=true -Dsort.skip -Dsurefire.forkCount=${ALLUXIO_FORK_COUNT} ${mvn_args}
-Dcheckstyle.skip=true -Dfindbugs.skip=true -Dsort.skip -Pnative-components -Dsurefire.forkCount=${ALLUXIO_FORK_COUNT} \
${mvn_args}
38 changes: 31 additions & 7 deletions native/rust/archetype/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,18 +49,42 @@
</excludes>
</resource>
</resources>
<testResources>
<testResource>
<filtering>true</filtering>
<directory>src/test/resources</directory>
<includes>
<include>projects/test/archetype.properties</include>
</includes>
</testResource>
<testResource>
<filtering>false</filtering>
<directory>src/test/resources</directory>
<excludes>
<exclude>projects/test/archetype.properties</exclude>
</excludes>
</testResource>
</testResources>

<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-archetype-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
<executions>
<execution>
<id>default-integration-test</id>
<goals>
<goal>integration-test</goal>
</goals>
<configuration>
<!-- adding -DskipITs can be used to skip this IT from the command line -->
<skip>false</skip>
<properties>
<build.path>${build.path}</build.path>
</properties>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#
# The Alluxio Open Foundation licenses this work under the Apache License, version 2.0
# (the "License"). You may not use this work except in compliance with the License, which is
# available at www.apache.org/licenses/LICENSE-2.0
#
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
# either express or implied, as more fully set forth in the License.
#
# See the NOTICE file distributed with this work for information regarding copyright ownership.
#

package=alluxio
groupId=org.alluxio
artifactId=alluxio-rust-example
version=${project.version}
cargo_crate_name=example
cargo_crate_type=cdylib
toolchain_version=${toolchain.version}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
verify
8 changes: 7 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,6 @@
<module>common</module>
<module>dora</module>
<module>webui</module>
<module>native</module>
</modules>

<dependencyManagement>
Expand Down Expand Up @@ -1739,5 +1738,12 @@
</plugins>
</build>
</profile>

<profile>
<id>native-components</id>
<modules>
<module>native</module>
</modules>
</profile>
</profiles>
</project>

0 comments on commit 9205036

Please sign in to comment.