Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test Maven 4.0.0-rc1 #24247

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ the POMs to each module. If that doesn't work, you can do it manually:
Note that the version of errorprone used by the IDEA plugin might be older than
the one configured in the `pom.xml` and you might need to disable some checks
that are not yet supported by that older version. When in doubt, always check
with the full Maven build (``./mvnw clean install -DskipTests -Perrorprone-compiler``).
with the full Maven build (``./mvnw clean package -DskipTests -Perrorprone-compiler``).

### Language injection in IDE

Expand Down
2 changes: 1 addition & 1 deletion .github/actions/compile-commit/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ runs:

# For building with Maven we need MAVEN_OPTS to equal MAVEN_INSTALL_OPTS
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN install \
$MAVEN package \
${MAVEN_COMPILE_COMMITS} `# defaults, kept in sync with ci.yml` \
-Dair.check.skip-all=false -Dair.check.skip-basic=true -Dair.check.skip-extended=true -Dair.check.skip-checkstyle=false \
${MAVEN_GIB}
Expand Down
29 changes: 15 additions & 14 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ jobs:
- name: Check SPI backward compatibility
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN clean install ${MAVEN_FAST_INSTALL} -pl :trino-spi -am
$MAVEN clean package ${MAVEN_FAST_INSTALL} -pl :trino-spi -am
$MAVEN clean verify -B --strict-checksums -DskipTests -pl :trino-spi
- name: Maven Checks
run: |
Expand All @@ -104,10 +104,10 @@ jobs:
with:
cache: 'restore'
cleanup-node: true
- name: Maven Install
- name: Maven Package
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN clean install ${MAVEN_FAST_INSTALL} -pl '!:trino-docs,!:trino-server-rpm'
$MAVEN clean package ${MAVEN_FAST_INSTALL} -pl '!:trino-docs,!:trino-server-rpm'
- name: Test Server RPM
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
Expand Down Expand Up @@ -192,11 +192,11 @@ jobs:
timeout-minutes: 10
with:
cache: restore
- name: Maven Install
- name: Maven Package
run: |
# build everything to make sure dependencies of impacted modules are present
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN clean install ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -pl '!:trino-docs,!:trino-server,!:trino-server-rpm'
$MAVEN clean package ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -pl '!:trino-docs,!:trino-server,!:trino-server-rpm'
- name: Error Prone Checks
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
Expand All @@ -219,10 +219,11 @@ jobs:
timeout-minutes: 10
with:
cache: restore
- name: Maven Install
cleanup-node: true
- name: Maven Package
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN clean install ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -Dgib.logImpactedTo=gib-impacted.log -pl '!:trino-docs,!:trino-server,!:trino-server-rpm'
$MAVEN clean package ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -Dgib.logImpactedTo=gib-impacted.log -pl '!:trino-docs,!:trino-server,!:trino-server-rpm'
- name: Test old JDBC vs current server
id: tests-old
run: |
Expand Down Expand Up @@ -267,7 +268,7 @@ jobs:
- name: Install Hive Module
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN clean install ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -Dgib.logImpactedTo=gib-impacted.log -am -pl :trino-hive
$MAVEN clean package ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -Dgib.logImpactedTo=gib-impacted.log -am -pl :trino-hive
- name: Run Hive AWS Tests
id: tests
env:
Expand Down Expand Up @@ -325,10 +326,10 @@ jobs:
with:
cache: restore
cleanup-node: true
- name: Maven Install
- name: Maven Package
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN clean install ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -pl '!:trino-docs,!:trino-server,!:trino-server-rpm'
$MAVEN clean package ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -pl '!:trino-docs,!:trino-server,!:trino-server-rpm'
- name: Maven Tests
id: tests
run: |
Expand Down Expand Up @@ -514,10 +515,10 @@ jobs:
cache: restore
cleanup-node: ${{ format('{0}', matrix.modules == 'plugin/trino-singlestore' || matrix.modules == 'plugin/trino-exasol') }}
java-version: ${{ matrix.jdk != '' && matrix.jdk || '23' }}
- name: Maven Install
- name: Maven Package
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN clean install ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -am -pl "${{ matrix.modules }}"
$MAVEN clean package ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -am -pl "${{ matrix.modules }}"
- name: Maven Tests
id: tests
if: >-
Expand Down Expand Up @@ -833,10 +834,10 @@ jobs:
# it relies on the Provisio plugin to find the right artifacts
- 'core/trino-server/**'
- '.github/**'
- name: Maven Install
- name: Maven Package
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$MAVEN clean install ${MAVEN_FAST_INSTALL} -pl '!:trino-docs,!:trino-server-rpm'
$MAVEN clean package ${MAVEN_FAST_INSTALL} -pl '!:trino-docs,!:trino-server-rpm'
- name: Map impacted plugins to features
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ jobs:
- name: Maven Checks
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$RETRY $MAVEN install -B --strict-checksums -V -T 1C -DskipTests -P ci -am -pl ':trino-docs'
$RETRY $MAVEN package -B --strict-checksums -V -T 1C -DskipTests -P ci -am -pl ':trino-docs'
- name: Clean local Maven repo
# Avoid creating a cache entry because this job doesn't download all dependencies
if: steps.cache.outputs.cache-hit != 'true'
Expand All @@ -79,10 +79,10 @@ jobs:
fetch-depth: 0 # checkout all commits, as the build result depends on `git describe` equivalent
- uses: ./.github/actions/setup
timeout-minutes: 10
- name: Maven Install
- name: Maven Package
run: |
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
$RETRY $MAVEN install ${MAVEN_FAST_INSTALL} -am -pl $(echo '${{ matrix.modules }}' | cut -d' ' -f1)
$RETRY $MAVEN package ${MAVEN_FAST_INSTALL} -am -pl $(echo '${{ matrix.modules }}' | cut -d' ' -f1)
- name: Maven Tests
id: tests
run: $MAVEN test ${MAVEN_TEST} -pl ${{ matrix.modules }}
Expand Down
2 changes: 1 addition & 1 deletion .mvn/wrapper/maven-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@
# under the License.
wrapperVersion=3.3.2
distributionType=only-script
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.9/apache-maven-3.9.9-bin.zip
distributionUrl=https://dist.apache.org/repos/dist/dev/maven/maven-4/4.0.0-rc-1/binaries/apache-maven-4.0.0-rc-1-bin.zip
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Trino supports [reproducible builds](https://reproducible-builds.org) as of vers
Trino is a standard Maven project. Simply run the following command from the
project root directory:

./mvnw clean install -DskipTests
./mvnw clean package -DskipTests

On the first build, Maven downloads all the dependencies from the internet
and caches them in the local repository (`~/.m2/repository`), which can take a
Expand Down
4 changes: 2 additions & 2 deletions core/docker/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,12 @@ if [ -n "$TRINO_VERSION" ]; then
for artifactId in io.trino:trino-server:"${TRINO_VERSION}":tar.gz io.trino:trino-cli:"${TRINO_VERSION}":jar:executable; do
"${SOURCE_DIR}/mvnw" -C dependency:get -Dtransitive=false -Dartifact="$artifactId"
done
local_repo=$("${SOURCE_DIR}/mvnw" -B help:evaluate -Dexpression=settings.localRepository -q -DforceStdout)
local_repo=$("${SOURCE_DIR}/mvnw" -B help:evaluate --raw-streams -Dexpression=settings.localRepository -q -DforceStdout)
trino_server="$local_repo/io/trino/trino-server/${TRINO_VERSION}/trino-server-${TRINO_VERSION}.tar.gz"
trino_client="$local_repo/io/trino/trino-cli/${TRINO_VERSION}/trino-cli-${TRINO_VERSION}-executable.jar"
chmod +x "$trino_client"
else
TRINO_VERSION=$("${SOURCE_DIR}/mvnw" -f "${SOURCE_DIR}/pom.xml" --quiet help:evaluate -Dexpression=project.version -DforceStdout)
TRINO_VERSION=$("${SOURCE_DIR}/mvnw" -f "${SOURCE_DIR}/pom.xml" --raw-streams --quiet help:evaluate -Dexpression=project.version -DforceStdout)
echo "🎯 Using currently built artifacts from the core/trino-server and client/trino-cli modules and version ${TRINO_VERSION}"
trino_server="${SOURCE_DIR}/core/trino-server/target/trino-server-${TRINO_VERSION}.tar.gz"
trino_client="${SOURCE_DIR}/client/trino-cli/target/trino-cli-${TRINO_VERSION}-executable.jar"
Expand Down
4 changes: 2 additions & 2 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,13 +92,13 @@ Trino build. You only need to have built the current Trino version from the root
That is, before building the docs the first time, run the following command:

```bash
./mvnw clean install -DskipTests
./mvnw clean package -DskipTests
```

Subsequently, you can build the doc site using the Maven wrapper script:

```bash
./mvnw -pl docs clean install
./mvnw -pl docs clean package
```

If you have Maven installed and available on the path, you can use the `mvn` command
Expand Down
2 changes: 1 addition & 1 deletion testing/trino-product-tests-launcher/bin/run-launcher
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ launcher_jar="${target}/trino-product-tests-launcher-${trino_version}-executable

if ! test -x "${launcher_jar}"; then
echo "Could not find launcher jar ${launcher_jar}." >&2
echo "Run \`${mvn} clean install -pl :trino-product-tests-launcher -DskipTests\`" >&2
echo "Run \`${mvn} clean package -pl :trino-product-tests-launcher -DskipTests\`" >&2
exit 3
fi

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ maven_run_tests="${maven} clean test ${MAVEN_TEST:--B} -pl :trino-test-jdbc-comp

"${maven}" -version

current_version=$(${maven} help:evaluate -Dexpression=project.version -q -DforceStdout)
current_version=$(${maven} help:evaluate --raw-streams -Dexpression=project.version -q -DforceStdout)
previous_released_version=$((${current_version%-SNAPSHOT}-1))
first_tested_version=352
# test n-th version only
Expand Down
7 changes: 0 additions & 7 deletions testing/trino-test-jdbc-compatibility-old-server/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,6 @@
<include>trino-test-jdbc-compatibility-old-server-version.txt</include>
</includes>
</resource>
<resource>
<filtering>false</filtering>
<directory>src/main/resources</directory>
<excludes>
<exclude>trino-test-jdbc-compatibility-old-server-version.txt</exclude>
</excludes>
</resource>
</resources>

<plugins>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public void testUploadTestResultsCondition()
String uploadTestResultsStepName = "Upload test results";
Set<String> nonTestSteps = ImmutableSet.of(
uploadTestResultsStepName,
"Maven Install");
"Maven Package");

Yaml yaml = new Yaml();
Map<?, ?> workflow = yaml.load(new StringReader(Files.readString(findRepositoryRoot().resolve(CI_YML_REPO_PATH))));
Expand Down