Skip to content

Fix import order. Fixes Checkstyle error at build time#3308

Closed
martin-g wants to merge 1 commit intoapache:trunkfrom
martin-g:fix-checkstyle-error
Closed

Fix import order. Fixes Checkstyle error at build time#3308
martin-g wants to merge 1 commit intoapache:trunkfrom
martin-g:fix-checkstyle-error

Conversation

@martin-g
Copy link
Member

What changes were proposed in this pull request?

This PR changes the order of imports in a .java file.
Currently the build breaks with:

INFO] --- maven-checkstyle-plugin:2.17:check (checkstyle) @ ambari-server ---
[INFO] Starting audit...
[ERROR] /home/ubuntu/git/apache/ambari/ambari-server/src/main/java/org/apache/ambari/server/orm/entities/HostStateEntity.java:36: Wrong order for 'java.util.Objects' import. [ImportOrder]
Audit done.
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] Ambari Admin View 3.0.0.0-SNAPSHOT ................. SUCCESS [  8.914 s]
[INFO] ambari-utility 3.0.0.0-SNAPSHOT .................... SUCCESS [01:28 min]
[INFO] Ambari Server SPI 3.0.0.0-SNAPSHOT ................. SUCCESS [  5.731 s]
[INFO] Ambari Service Advisor 1.0.0.0-SNAPSHOT ............ SUCCESS [  3.070 s]
[INFO] Ambari Server 3.0.0.0-SNAPSHOT ..................... FAILURE [13:54 min]
[INFO] Ambari Functional Tests 3.0.0.0-SNAPSHOT ........... SKIPPED
[INFO] Ambari Agent 3.0.0.0-SNAPSHOT ...................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  15:40 min
[INFO] Finished at: 2021-05-13T08:59:12+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-checkstyle-plugin:2.17:check (checkstyle) on project ambari-server: Failed during checkstyle execution: There is 1 error reported by Checkstyle 8.9 with /home/ubuntu/git/apache/ambari/ambari-server/checkstyle.xml ruleset. -> [Help 1]
[ERROR] 

How was this patch tested?

The build passed after this change.

@martin-g
Copy link
Member Author

It seems there is PR already: #3295

@martin-g martin-g closed this May 13, 2021
@martin-g martin-g deleted the fix-checkstyle-error branch May 13, 2021 08:10
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.

1 participant