Skip to content
This repository has been archived by the owner on Nov 4, 2024. It is now read-only.

Commit

Permalink
added logging dependency and messages
Browse files Browse the repository at this point in the history
Signed-off-by: Fiona Ampofo <64271621+Akyiaa@users.noreply.github.com>
  • Loading branch information
Akyiaa committed Mar 4, 2024
1 parent 5cbddd7 commit 70e0bb6
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
8 changes: 7 additions & 1 deletion galasa-maven-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@
<version>2.9.0</version>
</dependency>


<dependency>
<groupId>org.apache.felix</groupId>
<artifactId>org.apache.felix.bundlerepository</artifactId>
Expand All @@ -154,6 +153,13 @@
<artifactId>assertj-core</artifactId>
<version>3.25.3</version>
</dependency>

<dependency>
<groupId>org.netbeans.external</groupId>
<artifactId>org-apache-commons-logging</artifactId>
<version>RELEASE210</version>
</dependency>

</dependencies>

<build>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugin.MojoFailureException;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.maven.plugins.annotations.LifecyclePhase;
import org.apache.maven.plugins.annotations.Mojo;
import org.apache.maven.plugins.annotations.Parameter;
Expand Down Expand Up @@ -54,6 +56,8 @@ public class DeployTestCatalog extends AbstractMojo {
private boolean skip = setCorrectBooleanValue(correctSkip, typoSkip);
private boolean skipDeploy = setCorrectBooleanValue(correctSkipDeploy, typoSkipDeploy);

private Log logger = LogFactory.getLog(DeployTestCatalog.class);

/**
* In order to slowly deprecate the plugin with the wrong plugin spelling of 'catatlog',
* this function checks if either variation (the typo or correct spelling) of the plugin has been set to true,
Expand Down Expand Up @@ -113,9 +117,9 @@ public void execute() throws MojoExecutionException, MojoFailureException {
Properties bootstrapProperties = new Properties();
try {
URLConnection connection = bootstrapUrl.openConnection();
getLog().info("URLConnection: " + connection);
logger.info("URLConnection: " + connection);
bootstrapProperties.load(connection.getInputStream());
getLog().info("bootstrapProperties loaded: " + bootstrapProperties);
logger.info("bootstrapProperties loaded: " + bootstrapProperties);
} catch (Exception e) {
throw new MojoExecutionException("Unable to load the bootstrap properties", e);
}
Expand Down

0 comments on commit 70e0bb6

Please sign in to comment.