-
Notifications
You must be signed in to change notification settings - Fork 90
Remove standard maven-compiler plugin for applications with boot parent #428
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
Comments
@fabapp2 - would like to try creating a new recipe. Maybe I can pick this one to get started? |
Great, thanks! 🚀 |
The description is rather minimal, don't hesitate to pull all information you need. |
Hey @fabapp2 : Just wanted to share my understanding of the changes required . Could you let me know of anything i have missed Recipe: Conditions:
Action:
Also, I was not sure about replacing the Java properties and what is to be done. Spring boot parent already defines these properties:
|
Hi @ahmedmq, thanks for your analysis! Your observations are all correct for my understanding. I can see the recipe doing two things: . Always clean up properties Clean up properties
Otherwise
PlatUML code: gh428.puml.txt Removing the plugin
It's probably a good idea to have two Your thoughts on this? |
I think i get it. Let me start and I will reach out if I get stuck |
…nt - gh-428 (#508) - Add New recipe and condition - Enhance PomBuilder.java - Use MavenBuildFileRefactoring to apply recipe, similar to JavaRefactoring - Refactor getPlugins() method in OpenRewriteMavenBuildFile - Extract Plugin interface and refactor Maven Plugin implementation - Create new interface `Plugin#Configuration` and implementation - Refactor `Plugin#Execution` into `OpenRewriteMavenPlugin#OpenRewriteMavenPluginExecution` - Add deleteProperty() API to BuildFile - setProperty() API no longer removes the maven property if the value supplied is null. - Add maven plugin configuration to PomBuilder - Use Jackson XML pretty print to generate XML string for plugin configuration - Add findPlugins API to BuildFile - Use Plugin interface instead of OpenRewriteMavenPlugin implementation in dealing with objects - Refactor Maven compiler plugin actions - Clean up BuildFile API
…nt - gh-428 (#508) - Add New recipe and condition - Enhance PomBuilder.java - Use MavenBuildFileRefactoring to apply recipe, similar to JavaRefactoring - Refactor getPlugins() method in OpenRewriteMavenBuildFile - Extract Plugin interface and refactor Maven Plugin implementation - Create new interface `Plugin#Configuration` and implementation - Refactor `Plugin#Execution` into `OpenRewriteMavenPlugin#OpenRewriteMavenPluginExecution` - Add deleteProperty() API to BuildFile - setProperty() API no longer removes the maven property if the value supplied is null. - Add maven plugin configuration to PomBuilder - Use Jackson XML pretty print to generate XML string for plugin configuration - Add findPlugins API to BuildFile - Use Plugin interface instead of OpenRewriteMavenPlugin implementation in dealing with objects - Refactor Maven compiler plugin actions - Clean up BuildFile API
What needs to be done
Provide a recipe
remove-redundant-maven-compiler-plugin
that removes redundantmaven-compiler-plugin
configurations in Spring Boot applications that have a spring-boot parent where the compiler-plugin is managed.Why it needs to be done
Cleaner pom.xml by using Spring Boot's plugin management
Acceptance Criteria
Given: A pom.xml with direct or indirect spring-boot-starter-parent and a standard
maven-compiler-plugin
configuration with onlysource
andtarget
When:
remove-redundant-maven-compiler-plugin
is appliedThen: The
maven-compiler-plugin
is removed and Properties defining the java version are replaced withjava.version
property used by boot.Additional Information
The text was updated successfully, but these errors were encountered: