You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "Jimmyweng006 (via GitHub)" <gi...@apache.org> on 2025/08/02 14:14:59 UTC

[PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Jimmyweng006 opened a new pull request, #8891:
URL: https://github.com/apache/ozone/pull/8891

   ## What changes were proposed in this pull request?
   
   Fix Javadoc aggregation build failures
   
   Please describe your PR in detail:
   * Adding an explicit 'protobuf-java' dependency to the maven-javadoc-plugin to fix 'OneofDescriptor' symbol not found errors.
   * Skipping Javadoc generation for the 'mini-cluster' module, as its main sources incorrectly depend on test utilities.
   * Excluding all 'package-info.java' files from the aggregation to prevent 'package has already been annotated' errors from conflicting definitions.
   
   ## What is the link to the Apache JIRA
   
   [HDDS-13143](https://issues.apache.org/jira/browse/HDDS-13143)
   
   ## How was this patch tested?
   
   The patch was verified by running **mvn clean javadoc:aggregate** from the project root. 
   
   The command completed successfully, and the generated Javadoc is available and renders correctly at target/reports/apidocs/index.html.
   
   <img width="2529" height="1283" alt="image" src="https://github.com/user-attachments/assets/5f56c63d-a313-41e9-be10-efc2e2a01726" />
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on code in PR #8891:
URL: https://github.com/apache/ozone/pull/8891#discussion_r2250119160


##########
hadoop-ozone/mini-cluster/pom.xml:
##########
@@ -25,6 +25,10 @@
   <name>Apache Ozone Mini Cluster</name>
   <description>Apache Ozone Mini Cluster for Integration Tests</description>
 
+  <properties>

Review Comment:
   tests don't need javadoc, so this is fine.
   Curious: does javadoc fail in this module?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3230094539

   I'm not sure what i did, but now whenever i run mvn javadoc:aggregate i got a huge load of errors with this PR..


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "Jimmyweng006 (via GitHub)" <gi...@apache.org>.
Jimmyweng006 commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3350735802

   Thanks @adoroszlai and @jojochuang for reviewing the PR, and @peterxcli for the CI suggestion that made this patch more robust.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "peterxcli (via GitHub)" <gi...@apache.org>.
peterxcli commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3319779597

   Please request a review from me and others whenever you think this is ready.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "Jimmyweng006 (via GitHub)" <gi...@apache.org>.
Jimmyweng006 commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3324526218

   @peterxcli Sure, I will change PR to ready for review once archive issue resolved.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "Jimmyweng006 (via GitHub)" <gi...@apache.org>.
Jimmyweng006 commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3349806111

   Hi @peterxcli , archive issue is resolved now https://github.com/Jimmyweng006/ozone/actions/runs/18117260501/job/51556021789#step:17:19
   
   Please help to have a look again. Thank you.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3208936148

   > So I think even with excludePackageNames present, <maven.javadoc.skip>true</maven.javadoc.skip> is still necessary.
   
   Actually that's not my question. The latest commit meant to exclude generated protobuf and grpc class path.
   
   I think this is what we want. I'll double check again and if nothing else I'll merge it later.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "peterxcli (via GitHub)" <gi...@apache.org>.
peterxcli commented on code in PR #8891:
URL: https://github.com/apache/ozone/pull/8891#discussion_r2389771809


##########
.github/workflows/check.yml:
##########
@@ -254,7 +255,10 @@ jobs:
         uses: actions/upload-artifact@v4
         with:
           name: ${{ (inputs.split && format('{0}-{1}', inputs.script, inputs.split)) || inputs.script }}
-          path: target/${{ inputs.script }}
+          path: |
+            target/${{ inputs.script }}

Review Comment:
   this can be removed I guess?



##########
.github/workflows/check.yml:
##########
@@ -254,7 +255,10 @@ jobs:
         uses: actions/upload-artifact@v4
         with:
           name: ${{ (inputs.split && format('{0}-{1}', inputs.script, inputs.split)) || inputs.script }}
-          path: target/${{ inputs.script }}
+          path: |
+            target/${{ inputs.script }}
+            target/reports/apidocs
+            target/site/apidocs

Review Comment:
   I guess we only need one of these?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "peterxcli (via GitHub)" <gi...@apache.org>.
peterxcli commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3301348291

   The wf step is pass. so this looks good.
   however the build wasn't archived: 
   https://github.com/Jimmyweng006/ozone/actions/runs/17772989311/job/50516184308#step:17:19 .
   It would be better to change the javadoc dir to the right path.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "peterxcli (via GitHub)" <gi...@apache.org>.
peterxcli commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3301322217

   @Jimmyweng006 Do you think this is ready?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "adoroszlai (via GitHub)" <gi...@apache.org>.
adoroszlai commented on code in PR #8891:
URL: https://github.com/apache/ozone/pull/8891#discussion_r2250526907


##########
pom.xml:
##########
@@ -1818,9 +1818,19 @@
           <artifactId>maven-javadoc-plugin</artifactId>
           <version>${maven-javadoc-plugin.version}</version>
           <configuration>
+            <sourceFileExcludes>
+              <exclude>**/package-info.java</exclude>
+            </sourceFileExcludes>
             <doclint>none</doclint>
             <notimestamp>true</notimestamp>
           </configuration>
+          <dependencies>
+            <dependency>
+              <groupId>com.google.protobuf</groupId>
+              <artifactId>protobuf-java</artifactId>
+              <version>${grpc.protobuf-compile.version}</version>
+            </dependency>
+          </dependencies>

Review Comment:
   Instead of adding protobuf as depenency, I think we should skip creating javadoc for generated code.  Please see HDDS-11142.



##########
hadoop-ozone/mini-cluster/pom.xml:
##########
@@ -25,6 +25,10 @@
   <name>Apache Ozone Mini Cluster</name>
   <description>Apache Ozone Mini Cluster for Integration Tests</description>
 
+  <properties>

Review Comment:
   @jojochuang you have reported the failure in this module:
   
   ```
   hadoop-ozone/mini-cluster/src/main/java/org/apache/hadoop/ozone/MiniOzoneHAClusterImpl.java:22: error: package org.apache.ozone.test.GenericTestUtils does not exist
   [ERROR] import static org.apache.ozone.test.GenericTestUtils.PortAllocator.getFreePort;
   ...
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "Jimmyweng006 (via GitHub)" <gi...@apache.org>.
Jimmyweng006 commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3289644474

   Hi @jojochuang ,
   
   Not sure what steps you perform, but from my side after
   1. mvn clean install -U -DskipTests
   2. mvn javadoc:aggregate
   
   API doc will be generated without errors.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "peterxcli (via GitHub)" <gi...@apache.org>.
peterxcli merged PR #8891:
URL: https://github.com/apache/ozone/pull/8891


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "peterxcli (via GitHub)" <gi...@apache.org>.
peterxcli commented on code in PR #8891:
URL: https://github.com/apache/ozone/pull/8891#discussion_r2354335090


##########
hadoop-ozone/dev-support/checks/javadoc.sh:
##########
@@ -0,0 +1,27 @@
+#!/usr/bin/env bash
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+set -e
+
+DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
+cd "$DIR/../../.." || exit 1
+
+export MAVEN_OPTS="\
+-Dmaven.wagon.http.pool=false \
+-Dmaven.wagon.http.retryHandler.class=standard \
+-Dmaven.wagon.http.retryHandler.count=3"

Review Comment:
   ```suggestion
   export MAVEN_OPTS="\
   -Dmaven.wagon.http.pool=false \
   -Dmaven.wagon.http.retryHandler.class=standard \
   -Dmaven.wagon.http.retryHandler.count=3 \
   -DreportOutputDirectory=target \
   -DdestDir=javadoc"
   ```
   This might work.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3186387957

   Pushed an update to exclude generated code path


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3190962556

   @Jimmyweng006 thought on this?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "Jimmyweng006 (via GitHub)" <gi...@apache.org>.
Jimmyweng006 commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3194111598

   Thanks for the suggestion @jojochuang .
   
   I removed <maven.javadoc.skip>true</maven.javadoc.skip> from both the csi and mini-cluster modules to see if the new exclusion rule would be sufficient on its own.
   
   The result was that the mvn javadoc:aggregate build failed with the exact same cannot find symbol: OneofDescriptor error.
   
   So I think even with **excludePackageNames** present, **<maven.javadoc.skip>true</maven.javadoc.skip>** is still necessary.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "Jimmyweng006 (via GitHub)" <gi...@apache.org>.
Jimmyweng006 commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3216565117

   Ok got it, thanks @jojochuang !


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "Jimmyweng006 (via GitHub)" <gi...@apache.org>.
Jimmyweng006 commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3299485923

   Sure let me try to add it.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-13144. Fix mvn javadoc:aggregate goal. [ozone]

Posted by "peterxcli (via GitHub)" <gi...@apache.org>.
peterxcli commented on PR #8891:
URL: https://github.com/apache/ozone/pull/8891#issuecomment-3350636445

   Thanks @Jimmyweng006 for the patch. Thanks @adoroszlai and @jojochuang for reviewing!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org