Skip to content

Commit 518256b

Browse files
committed
Install compiled artifacts
Multi-Release JARs are causing error_prone/javadoc/surefire to use the latest compilation unit while resolving dependencies for other modules.
1 parent be9dfef commit 518256b

File tree

2 files changed

+17
-4
lines changed

2 files changed

+17
-4
lines changed

.github/workflows/ci.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ jobs:
8282
- name: Maven Checks
8383
run: |
8484
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
85-
$MAVEN clean verify -B --strict-checksums -V -T 1C -DskipTests -P ci
85+
$MAVEN clean install verify -B --strict-checksums -V -T 1C -DskipTests -P ci
8686
- name: Remove Trino from local Maven repo to avoid caching it
8787
# Avoid caching artifacts built in this job, cache should only include dependencies
8888
if: steps.cache.outputs.cache-hit != 'true' && matrix.cache == 'true'
@@ -197,7 +197,7 @@ jobs:
197197
run: |
198198
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
199199
# Skip checks, these are run in `maven-checks` job and e.g. checkstyle is expensive.
200-
$MAVEN ${MAVEN_TEST} -T 1C clean compile test-compile -DskipTests -Dair.check.skip-all=true ${MAVEN_GIB} -Dgib.buildUpstream=never -P errorprone-compiler \
200+
$MAVEN ${MAVEN_TEST} -T 1C clean compile test-compile install -DskipTests -Dair.check.skip-all=true ${MAVEN_GIB} -Dgib.buildUpstream=never -P errorprone-compiler \
201201
-pl '!:trino-docs,!:trino-server'
202202
203203
test-jdbc-compatibility:
@@ -328,7 +328,7 @@ jobs:
328328
- name: Maven Tests
329329
id: tests
330330
run: |
331-
$MAVEN test ${MAVEN_TEST} -pl '
331+
$MAVEN test install ${MAVEN_TEST} -pl '
332332
!:trino-base-jdbc,
333333
!:trino-bigquery,
334334
!:trino-cassandra,

client/trino-client/pom.xml

+14-1
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,20 @@
157157
<groupId>org.apache.maven.plugins</groupId>
158158
<artifactId>maven-compiler-plugin</artifactId>
159159
<executions>
160-
<!-- Order is important - we want to attach JDK 11 to the reactor -->
160+
<execution>
161+
<id>compile-java-11</id>
162+
<goals>
163+
<goal>compile</goal>
164+
</goals>
165+
<phase>compile</phase>
166+
<configuration>
167+
<multiReleaseOutput>true</multiReleaseOutput>
168+
<release>11</release>
169+
<compileSourceRoots>
170+
<compileSourceRoot>${project.basedir}/src/main/java</compileSourceRoot>
171+
</compileSourceRoots>
172+
</configuration>
173+
</execution>
161174
<execution>
162175
<id>compile-java-22</id>
163176
<goals>

0 commit comments

Comments
 (0)