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

Remove ant dependency and update exception handling #1662

Merged
merged 3 commits into from
Apr 18, 2023

Conversation

cherylking
Copy link
Member

@cherylking cherylking commented Apr 18, 2023

Preparation to remove all references to Maven 2.x APIs (org.codehaus) related to #1651.

  1. Added our own AntTaskFactory to replace org.codehaus.mojo.pluginsupport.ant.AntHelper.
  2. Changed all goal implementations to throw MojoExecutionException as a precursor to having AbstractLibertySupport extend org.apache.maven.plugin.AbstractMojo instead of org.codehaus.mojo.pluginsupport.MojoSupport.
  3. Moved code from doExecute methods into their own method that throws MojoExecutionException in order to identify all other exceptions that need to be caught and wrapped in a MojoExecutionException. The protected void doExecute() throws Exception methods will get replaced by @Override public void execute() throws MojoExecutionException once the inheritance is changed.
  4. Changed all references to the log variable to use getLog() instead. Modified CommonLogger to instantiate a org.apache.maven.plugin.logging.SystemStreamLog if no logger was available when instantiated.

Copy link
Member

@mattbsox mattbsox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants