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

Upgrade many dependencies #164

Open
wants to merge 3 commits 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
Binary file modified .mvn/wrapper/maven-wrapper.jar
Binary file not shown.
19 changes: 18 additions & 1 deletion .mvn/wrapper/maven-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1 +1,18 @@
distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.6.3/apache-maven-3.6.3-bin.zip
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.0/apache-maven-3.9.0-bin.zip
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.1/maven-wrapper-3.1.1.jar
4 changes: 2 additions & 2 deletions README.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -622,12 +622,12 @@ or all Java archives, that are contained in the build directory:
List<JavaArchive> javaArchives = builtProject.getArchives(JavaArchive.class);
....

Let's say that we want to use Maven 3.1.0 for building a project with a goal `install` and property `wildfly=true`. We also don't want to display the build output a we want to ignore all possible build failures:
Let's say that we want to use Maven 3.6.3 for building a project with a goal `install` and property `wildfly=true`. We also don't want to display the build output a we want to ignore all possible build failures:
[source,java]
....
EmbeddedMaven
.forProject("path/to/pom.xml")
.useMaven3Version("3.1.0")
.useMaven3Version("3.6.3")
.setGoals("install")
.addProperty("wildfly", "true")
.setQuiet()
Expand Down
4 changes: 3 additions & 1 deletion bom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@

<jboss.releases.repo.url>https://repository.jboss.org/nexus/service/local/staging/deploy/maven2/</jboss.releases.repo.url>
<jboss.snapshots.repo.url>https://repository.jboss.org/nexus/content/repositories/snapshots/</jboss.snapshots.repo.url>
<version.org.apache.maven>3.6.3</version.org.apache.maven>
<version.org.apache.maven>3.9.0</version.org.apache.maven>

</properties>

Expand Down Expand Up @@ -146,6 +146,7 @@
<plugins>
<plugin>
<artifactId>maven-release-plugin</artifactId>
<version>2.5.3</version>
<configuration>
<pushChanges>false</pushChanges>
<localCheckout>true</localCheckout>
Expand All @@ -171,6 +172,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>3.0.1</version>
<configuration>
<useAgent>true</useAgent>
</configuration>
Expand Down
2 changes: 1 addition & 1 deletion gradle/impl-gradle-embedded-archive/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
<repository>
<id>jfrog</id>
<name>jfrog</name>
<url>https://repo.jfrog.org/artifactory/gradle</url>
<url>https://repo.gradle.org/artifactory/repo</url>
</repository>
</repositories>
</project>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
apply plugin: 'java'
apply plugin: 'maven'
apply plugin: 'maven-publish'

group = 'org.jboss.shrinkwrap.resolver.test'
version = '1.0.0'
Expand All @@ -10,9 +10,9 @@ repositories {
}

dependencies {
compile 'commons-codec:commons-codec:1.7'
testCompile 'junit:junit:4.10'
compile('org.jboss.spec:jboss-javaee-web-6.0:3.0.2.Final') {
implementation 'commons-codec:commons-codec:1.7'
testImplementation 'junit:junit:4.10'
implementation('org.jboss.spec:jboss-javaee-web-6.0:3.0.2.Final') {
exclude(module: 'xalan')
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apply plugin: 'maven'
apply plugin: 'maven-publish'

group = 'org.jboss.shrinkwrap.resolver.test'
version = '1.0.0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ repositories {
}

dependencies {
compile 'commons-codec:commons-codec:1.7'
testCompile 'junit:junit:4.10'
compile('org.jboss.spec:jboss-javaee-web-6.0:3.0.2.Final') {
implementation 'commons-codec:commons-codec:1.7'
testImplementation 'junit:junit:4.10'
implementation('org.jboss.spec:jboss-javaee-web-6.0:3.0.2.Final') {
exclude(module: 'xalan')
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ repositories {
}

dependencies {
compile(project(':module-one'))
implementation(project(':module-one'))
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apply plugin: 'war'
apply plugin: 'java'
apply plugin: 'maven'
apply plugin: 'maven-publish'

group = 'org.jboss.shrinkwrap.resolver.test'
version = '1.0.0'
Expand All @@ -11,8 +11,8 @@ repositories {
}

dependencies {
compile group: 'commons-codec', name: 'commons-codec', version:'1.7'
testCompile group: 'junit', name: 'junit', version:'4.10'
implementation group: 'commons-codec', name: 'commons-codec', version:'1.7'
testImplementation group: 'junit', name: 'junit', version:'4.10'
providedCompile group: 'org.slf4j', name: 'slf4j-api', version:'1.6.1'
providedCompile(group: 'org.jboss.spec', name: 'jboss-javaee-web-6.0', version:'3.0.2.Final') {
exclude(module: 'xalan')
Expand Down
2 changes: 1 addition & 1 deletion gradle/impl-gradle/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
<repository>
<id>jfrog</id>
<name>jfrog</name>
<url>https://repo.jfrog.org/artifactory/gradle</url>
<url>https://repo.gradle.org/artifactory/repo</url>
</repository>
</repositories>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ repositories {
}

dependencies {
compile 'org.arquillian.container:arquillian-container-chameleon:1.0.0.Beta3'
implementation 'org.arquillian.container:arquillian-container-chameleon:1.0.0.Beta3'
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ dependencyManagement {
}

dependencies {
compile 'org.slf4j:slf4j-simple:1.7.5'
testCompile 'junit:junit:4.12'
compile 'org.apache.deltaspike.core:deltaspike-core-api'
runtime 'org.apache.deltaspike.core:deltaspike-core-impl'
implementation 'org.slf4j:slf4j-simple:1.7.5'
testImplementation 'junit:junit:4.12'
implementation 'org.apache.deltaspike.core:deltaspike-core-api'
runtimeOnly 'org.apache.deltaspike.core:deltaspike-core-impl'
}
4 changes: 2 additions & 2 deletions gradle/impl-gradle/src/test/resources/simple/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ repositories {
}

dependencies {
compile 'org.slf4j:slf4j-simple:1.7.5'
testCompile 'junit:junit:4.12'
implementation 'org.slf4j:slf4j-simple:1.7.5'
testImplementation 'junit:junit:4.12'
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
public interface DistributionStage<NEXT_STEP extends BuildStage<DAEMON_TRIGGER_TYPE>, DAEMON_TRIGGER_TYPE extends DaemonBuildTrigger>
extends BuildStage<DAEMON_TRIGGER_TYPE> {

String DEFAULT_MAVEN_VERSION = "3.6.3";
String DEFAULT_MAVEN_VERSION = "3.9.0";

/**
* Configures EmbeddedMaven to build project with Maven 3 of given version. If the zip file is not cached in directory
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ class MavenRemoteRepositoryImpl implements MavenRemoteRepository {

String id, layout;
URL url;
MavenUpdatePolicy upPolicy = null;
MavenChecksumPolicy ckPolicy = null;
MavenUpdatePolicy upPolicy = MavenUpdatePolicy.UPDATE_POLICY_DAILY;
MavenChecksumPolicy ckPolicy = MavenChecksumPolicy.CHECKSUM_POLICY_WARN;

/**
* Builds a new remote repository.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ protected AbstractCompilingProcessor<ARCHIVETYPE> compile(File inputDirectory, F

JavacCompiler compiler = new JavacCompiler();
CompilerConfiguration configuration = getCompilerConfiguration();
configuration.setForceJavacCompilerUse(true);

if (log.isLoggable(Level.FINE)) {
log.log(Level.FINE, "Compiling sources from {0} directory into {1}",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@ public CompilerPluginConfiguration(ParsedPomFile pomFile) {
Properties properties = pomFile.getProperties();
this.verbose = ConfigurationUtils.valueAsBoolean(rawValues, new Key("verbose"), false);
this.sourceVersion = ConfigurationUtils.valueAsString(rawValues, new Key("source"),
properties.getProperty("maven.compiler.source", "1.5"));
properties.getProperty("maven.compiler.source", "1.8"));
this.targetVersion = ConfigurationUtils.valueAsString(rawValues, new Key("target"),
properties.getProperty("maven.compiler.target", "1.5"));
properties.getProperty("maven.compiler.target", "1.8"));
this.encoding = ConfigurationUtils.valueAsString(rawValues,
new Key("encoding"),
properties.getProperty("project.build.sourceEncoding", ""));
Expand Down
5 changes: 4 additions & 1 deletion maven/impl-maven-embedded/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,10 @@
<dependency>
<groupId>commons-codec</groupId>
<artifactId>commons-codec</artifactId>
<version>1.10</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
</dependency>

<!-- testing -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
public class InvokerEquippedEmbeddedMavenForMultiModuleSampleTestCase {

@Test
public void testMultiModuleSampleBuildWithMaven305() {
public void testMultiModuleSampleBuildWithMaven363() {
InvocationRequest request = new DefaultInvocationRequest();
Invoker invoker = new DefaultInvoker();

Expand All @@ -50,11 +50,11 @@ public void testMultiModuleSampleBuildWithMaven305() {

BuiltProject builtProject = EmbeddedMaven
.withMavenInvokerSet(request, invoker)
.useMaven3Version("3.0.5")
.useMaven3Version("3.6.3")
.build();
builtProject.setMavenLog(logBuffer.toString());

verifyMavenVersion(builtProject, "3.0.5");
verifyMavenVersion(builtProject, "3.6.3");
verifyMultiModuleSample(builtProject, true);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
public class InvokerEquippedEmbeddedMavenForWarSampleTestCase {

@Test
public void testWarSampleBuildWithMaven310() {
public void testWarSampleBuildWithMaven363() {
InvocationRequest request = new DefaultInvocationRequest();
Invoker invoker = new DefaultInvoker();

Expand All @@ -44,12 +44,12 @@ public void testWarSampleBuildWithMaven310() {

BuiltProject builtProject = EmbeddedMaven
.withMavenInvokerSet(request, invoker)
.useMaven3Version("3.1.0")
.useMaven3Version("3.6.3")
.build();
builtProject.setMavenLog(logBuffer.toString());

verifyWarSampleWithSources(builtProject);
verifyMavenVersion(builtProject, "3.1.0");
verifyMavenVersion(builtProject, "3.6.3");
}

@Test(expected = IllegalStateException.class)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@
public class PomEquippedEmbeddedMavenForMultiModuleSampleTestCase {

@Test
public void testMultiModuleSampleBuildWithMaven305() {
public void testMultiModuleSampleBuildWithMaven363() {
BuiltProject builtProject = EmbeddedMaven
.forProject(pathToMultiModulePom)
.useMaven3Version("3.0.5")
.useMaven3Version("3.6.3")
.setGoals("install")
.addProperty(multiModuleactivateModulesParamKey, multiModuleactivateModulesParamValue)
.addProperty(archiveNameModuleTwoParamKey, archiveNameModuleTwoParamValue)
.setShowVersion(true)
.build();

verifyMavenVersion(builtProject, "3.0.5");
verifyMavenVersion(builtProject, "3.6.3");
verifyMultiModuleSample(builtProject, true);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,17 @@
public class PomEquippedEmbeddedMavenForWarSampleTestCase {

@Test
public void testWarSampleBuildWithMaven310() {
public void testWarSampleBuildWithMaven363() {

BuiltProject builtProject = EmbeddedMaven
.forProject(pathToWarSamplePom)
.useMaven3Version("3.1.0")
.useMaven3Version("3.6.3")
.setGoals("clean", "package", "source:jar")
.setShowVersion(true)
.build();

verifyWarSampleWithSources(builtProject);
verifyMavenVersion(builtProject, "3.1.0");
verifyMavenVersion(builtProject, "3.6.3");
}

@Test(expected = IllegalStateException.class)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ public BuiltProject build(String expectedRegex, CountDownLatch countDownLatch) {

if (mavenInstallation != null) {
invoker.setMavenHome(mavenInstallation);
invocationRequest.setMavenHome(mavenInstallation);
}

setOutputHandlers(expectedRegex, countDownLatch);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ boolean waitTillMarkerFileIsGone(long timeoutInMilliseconds, String processName)
}
System.out.println();

return count == 100 && isMarkerFilePresent();
return isMarkerFilePresent();
}

boolean isMarkerFilePresent() {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
package org.jboss.shrinkwrap.resolver.impl.maven.embedded;

import static org.assertj.core.api.Assertions.assertThat;

import java.io.File;
import java.io.IOException;
import java.net.URL;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

import org.junit.Rule;
import org.junit.Test;
import org.junit.contrib.java.lang.system.SystemOutRule;
import org.junit.rules.TemporaryFolder;

import static org.assertj.core.api.Assertions.assertThat;

public class DistributionStageImplTestCase {

@Rule
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,8 @@ public void testDownloadMaven339AndExtractAndCheckCacheIsUsed() {
verifyDownloadAndExtraction("3.3.9");

// check if new Dir will be created for different Maven version
EmbeddedMaven.forProject(pathToJarSamplePom).useMaven3Version("3.1.0");
verifyExtraction(2, "apache-maven-3.3.9", "apache-maven-3.1.0");
EmbeddedMaven.forProject(pathToJarSamplePom).useMaven3Version("3.6.3");
verifyExtraction(2, "apache-maven-3.3.9", "apache-maven-3.6.3");
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public class InvokerEquippedEmbeddedMavenForMultiModuleSampleTestCase {
public final TestWorkDirRule workDirRule = new TestWorkDirRule();

@Test
public void testMultiModuleSampleBuildWithMaven305() {
public void testMultiModuleSampleBuildWithMaven363() {
InvocationRequest request = new DefaultInvocationRequest();
Invoker invoker = new DefaultInvoker();

Expand All @@ -55,11 +55,11 @@ public void testMultiModuleSampleBuildWithMaven305() {

BuiltProject builtProject = EmbeddedMaven
.withMavenInvokerSet(request, invoker)
.useMaven3Version("3.0.5")
.useMaven3Version("3.6.3")
.build();
builtProject.setMavenLog(logBuffer.toString());

verifyMavenVersion(builtProject, "3.0.5");
verifyMavenVersion(builtProject, "3.6.3");
verifyMultiModuleSample(builtProject, true);
}

Expand Down
Loading