maven-compiler-plugin maintenance (#1731)
* Override inheritance of HAPI's old maven-compiler-plugin and stop using deprecated forceJavacCompilerUse * Take checkstyle plugin out of default build * Use less for initial JVM opts (maybe forked compilers will need this) * Try on a mac? * Report free space, add MAVEN_OPTS * No MAVEN_OPTS? * Back to ubuntu * Try some compiler args and max mem * Try some MaxRamPercentage on surefire too * Try 75.0 MaxRamPercentage * 60? * Update surefire version, even less Xmx * Revert I18nBase style fix (get tests to pass, apply later) * Now that memory is less of an issue, try checkstyle again * Fix missing single quote * Try 50% of 7G for Xmx
This commit is contained in:
parent
4b374cb57b
commit
093fbbc0f3
|
@ -15,7 +15,7 @@ public class TestConfig {
|
||||||
@Getter @Setter
|
@Getter @Setter
|
||||||
private boolean rebuildCache = System.getProperty(FHIR_TXCACHE_REBUILD) != null && "TRUE".equalsIgnoreCase(System.getProperty(FHIR_TXCACHE_REBUILD));
|
private boolean rebuildCache = System.getProperty(FHIR_TXCACHE_REBUILD) != null && "TRUE".equalsIgnoreCase(System.getProperty(FHIR_TXCACHE_REBUILD));
|
||||||
|
|
||||||
@Getter @Setter
|
@Setter
|
||||||
private String txCacheDirectory = TestConstants.TX_CACHE;
|
private String txCacheDirectory = TestConstants.TX_CACHE;
|
||||||
|
|
||||||
@Getter @Setter
|
@Getter @Setter
|
||||||
|
|
76
pom.xml
76
pom.xml
|
@ -25,7 +25,7 @@
|
||||||
<jackson_version>2.17.0</jackson_version>
|
<jackson_version>2.17.0</jackson_version>
|
||||||
<junit_jupiter_version>5.9.2</junit_jupiter_version>
|
<junit_jupiter_version>5.9.2</junit_jupiter_version>
|
||||||
<junit_platform_launcher_version>1.8.2</junit_platform_launcher_version>
|
<junit_platform_launcher_version>1.8.2</junit_platform_launcher_version>
|
||||||
<maven_surefire_version>3.0.0-M5</maven_surefire_version>
|
<maven_surefire_version>3.1.2</maven_surefire_version>
|
||||||
<maven_clean_version>3.1.0</maven_clean_version>
|
<maven_clean_version>3.1.0</maven_clean_version>
|
||||||
<okhttp.version>4.11.0</okhttp.version>
|
<okhttp.version>4.11.0</okhttp.version>
|
||||||
<jacoco_version>0.8.12</jacoco_version>
|
<jacoco_version>0.8.12</jacoco_version>
|
||||||
|
@ -361,7 +361,7 @@
|
||||||
<!-- We need to include the ${argLine} here so the Jacoco test arguments are included in the
|
<!-- We need to include the ${argLine} here so the Jacoco test arguments are included in the
|
||||||
Surefire testing run. This may appear as an error in some IDEs, but it will run regardless.
|
Surefire testing run. This may appear as an error in some IDEs, but it will run regardless.
|
||||||
-->
|
-->
|
||||||
<argLine>@{argLine} -Xmx5632m</argLine>
|
<argLine>@{argLine} -Xmx3500m -XX:MaxRAMPercentage=50.0</argLine>
|
||||||
<systemPropertyVariables>
|
<systemPropertyVariables>
|
||||||
<java.locale.providers>COMPAT</java.locale.providers>
|
<java.locale.providers>COMPAT</java.locale.providers>
|
||||||
<!-- For JUnit4 use TestUtilities.runningAsSurefire() or
|
<!-- For JUnit4 use TestUtilities.runningAsSurefire() or
|
||||||
|
@ -385,6 +385,18 @@
|
||||||
<formats>sarif,html</formats>
|
<formats>sarif,html</formats>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<artifactId>maven-checkstyle-plugin</artifactId>
|
||||||
|
<version>3.2.0</version>
|
||||||
|
<configuration>
|
||||||
|
<skip>true</skip>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<inherited>false</inherited>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</pluginManagement>
|
</pluginManagement>
|
||||||
<plugins>
|
<plugins>
|
||||||
|
@ -395,41 +407,25 @@
|
||||||
<skip>true</skip>
|
<skip>true</skip>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-checkstyle-plugin</artifactId>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<phase>process-sources</phase>
|
|
||||||
<goals>
|
|
||||||
<goal>checkstyle</goal>
|
|
||||||
</goals>
|
|
||||||
<configuration>
|
|
||||||
<failsOnError>true</failsOnError>
|
|
||||||
<suppressionsLocation>${project.basedir}/checkstyle_suppressions.xml</suppressionsLocation>
|
|
||||||
<enableRulesSummary>true</enableRulesSummary>
|
|
||||||
<enableSeveritySummary>true</enableSeveritySummary>
|
|
||||||
<consoleOutput>true</consoleOutput>
|
|
||||||
<configLocation>${checkstyle_config_location}/checkstyle.xml</configLocation>
|
|
||||||
</configuration>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
<version>3.13.0</version>
|
<version>3.13.0</version>
|
||||||
<configuration>
|
<configuration>
|
||||||
|
|
||||||
<release>11</release>
|
<release>11</release>
|
||||||
|
|
||||||
<forceJavacCompilerUse>false</forceJavacCompilerUse>
|
<forceLegacyJavacApi>false</forceLegacyJavacApi>
|
||||||
<encoding>UTF-8</encoding>
|
<encoding>UTF-8</encoding>
|
||||||
<!-- Allows running the compiler in a separate process. If false it uses the built in compiler,
|
<!-- Allows running the compiler in a separate process. If false it uses the built-in compiler,
|
||||||
while if true it will use an executable. -->
|
while if true it will use an executable. -->
|
||||||
<fork>true</fork>
|
<fork>true</fork>
|
||||||
<meminitial>512m</meminitial>
|
<meminitial>512m</meminitial>
|
||||||
<maxmem>5632m</maxmem>
|
<maxmem>768m</maxmem>
|
||||||
<debug>true</debug>
|
<debug>true</debug>
|
||||||
|
<compilerArgs>
|
||||||
|
<arg>-J-XX:MaxRAMPercentage=50.0</arg>
|
||||||
|
</compilerArgs>
|
||||||
</configuration>
|
</configuration>
|
||||||
<executions>
|
<executions>
|
||||||
<!-- Replacing default-compile as it is treated specially by maven -->
|
<!-- Replacing default-compile as it is treated specially by maven -->
|
||||||
|
@ -840,6 +836,36 @@
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
</profile>
|
</profile>
|
||||||
|
<profile>
|
||||||
|
<id>CHECKSTYLE</id>
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-checkstyle-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<skip>false</skip>
|
||||||
|
</configuration>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<phase>process-sources</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>checkstyle</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<failsOnError>true</failsOnError>
|
||||||
|
<suppressionsLocation>${project.basedir}/checkstyle_suppressions.xml</suppressionsLocation>
|
||||||
|
<enableRulesSummary>true</enableRulesSummary>
|
||||||
|
<enableSeveritySummary>true</enableSeveritySummary>
|
||||||
|
<consoleOutput>true</consoleOutput>
|
||||||
|
<configLocation>${checkstyle_config_location}/checkstyle.xml</configLocation>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
</profile>
|
||||||
</profiles>
|
</profiles>
|
||||||
<reporting>
|
<reporting>
|
||||||
<plugins>
|
<plugins>
|
||||||
|
|
|
@ -25,12 +25,17 @@ jobs:
|
||||||
inputs:
|
inputs:
|
||||||
mavenPomFile: 'pom.xml'
|
mavenPomFile: 'pom.xml'
|
||||||
${{ if eq(parameters.signArtifacts, true) }}:
|
${{ if eq(parameters.signArtifacts, true) }}:
|
||||||
options: '--settings $(Agent.TempDirectory)/settings.xml -Dmaven.repo.local=$(MAVEN_CACHE_FOLDER) -DskipTests -DdeployToSonatype'
|
options: '--settings $(Agent.TempDirectory)/settings.xml -Dmaven.repo.local=$(MAVEN_CACHE_FOLDER) -DskipTests -DdeployToSonatype -P CHECKSTYLE'
|
||||||
${{ else }}:
|
${{ else }}:
|
||||||
options: '-Dmaven.repo.local=$(MAVEN_CACHE_FOLDER) -DskipTests'
|
options: '-Dmaven.repo.local=$(MAVEN_CACHE_FOLDER) -DskipTests -P CHECKSTYLE'
|
||||||
mavenOptions: '-Xmx3072m'
|
mavenOptions: '-Xmx768m'
|
||||||
javaHomeOption: 'JDKVersion'
|
javaHomeOption: 'JDKVersion'
|
||||||
jdkVersionOption: '1.11'
|
jdkVersionOption: '1.11'
|
||||||
jdkArchitectureOption: 'x64'
|
jdkArchitectureOption: 'x64'
|
||||||
publishJUnitResults: false
|
publishJUnitResults: false
|
||||||
goals: 'install'
|
goals: 'install'
|
||||||
|
- task: Bash@3
|
||||||
|
displayName: Report free disk space
|
||||||
|
inputs:
|
||||||
|
targetType: 'inline'
|
||||||
|
script: df -H .
|
Loading…
Reference in New Issue