[ https://issues.apache.org/jira/browse/MCLEAN-116?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17806460#comment-17806460 ]
ASF GitHub Bot commented on MCLEAN-116: --------------------------------------- Bukama opened a new pull request, #37: URL: https://github.com/apache/maven-clean-plugin/pull/37 Following this checklist to help us incorporate your contribution quickly and easily: - [x] Make sure there is a [JIRA issue](https://issues.apache.org/jira/browse/MCLEAN) filed for the change (usually before you start working on it). Trivial changes like typos do not require a JIRA issue. Your pull request should address just this issue, without pulling in other changes. - [ ] Each commit in the pull request should have a meaningful subject line and body. - [x] Format the pull request title like `[MCLEAN-XXX] - Fixes bug in ApproximateQuantiles`, where you replace `MCLEAN-XXX` with the appropriate JIRA issue. Best practice is to use the JIRA issue title in the pull request title and in the first line of the commit message. - [x] Write a pull request description that is detailed enough to understand what the pull request does, how, and why. - [x] Run `mvn clean verify` to make sure basic checks pass. A more thorough check will be performed on your pull request automatically. - [x] You have run the integration tests successfully (`mvn -Prun-its clean verify`). If your pull request is about ~20 lines of code you don't need to sign an [Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf) if you are unsure please ask on the developers list. To make clear that you license your contribution under the [Apache License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0) you have to acknowledge this by using the following check-box. - [x] I hereby declare this contribution to be licenced under the [Apache License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0) - [ ] In any other case, please file an [Apache Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf). ---------- Provided commit message for squashing ``` [MCLEAN-116] Use default Log interface Submitted by: Matthias Bünger The logging interface of the Cleaner class was not able to log exceptions in a suitable way. So it was replaced by the default logging interface provided by the AbstractMojo class. As the AbstractMojo always returns a log instance (therefore never null) the null checks were removed and the same Systemlogger was used in the tests. ``` As changes are more than 20 lines I will file the icla later the day. > Create interface method to catch exceptions > ------------------------------------------- > > Key: MCLEAN-116 > URL: https://issues.apache.org/jira/browse/MCLEAN-116 > Project: Maven Clean Plugin > Issue Type: Improvement > Affects Versions: 3.3.2 > Reporter: Matthias Bünger > Priority: Minor > > As stated multiple times in the {{Cleaner}} class, the {{Logger}} interface > of this class does not provide a method to log exceptions and needs a > refactoring > {code:java} > // ... > if (logDebug != null) { > // TODO: this Logger interface cannot log exceptions and > needs refactoring > logDebug.log("Unable to fast delete directory: " + e); > } > // ... > private interface Logger { > void log(CharSequence message); > } > {code} > However: Many plugins, e.g. the javadoc-plugin or the pmg-plugin use the > {{org.apache.maven.plugin.logging.Log}} interface. Therefor using this > interface instead an own could be a better solution than adding a new method > to the interface in the {{Cleaner}} class. > _This ticket was created to have this task in the issue tracker_ -- This message was sent by Atlassian Jira (v8.20.10#820010)