Skip to content

Commit cda17df

Browse files
authored
RATIS-2589. Fix Javadoc warnings (#1505)
1 parent 86f2438 commit cda17df

8 files changed

Lines changed: 14 additions & 13 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ jobs:
5555
java-version: ${{ matrix.java }}
5656
needs-source-tarball: true
5757
script: compile
58-
script-args: -Dmaven.compiler.release=${{ matrix.java }}
58+
script-args: -Prelease -Dmaven.compiler.release=${{ matrix.java }} -Dmaven.javadoc.failOnWarnings=${{ matrix.java != 8 }}
5959
split: ${{ matrix.java }}
6060
timeout-minutes: 30
6161
secrets:

dev-support/checks/compile.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ source "${DIR}/../find_maven.sh"
2020

2121
: ${WITH_COVERAGE:="false"}
2222

23-
MAVEN_OPTIONS='-V -B -Dmaven.javadoc.skip=true -DskipTests'
23+
MAVEN_OPTIONS='-V -B -DskipTests'
2424

2525
if [[ "${WITH_COVERAGE}" != "true" ]]; then
2626
MAVEN_OPTIONS="${MAVEN_OPTIONS} -Djacoco.skip"

ratis-client/src/main/java/org/apache/ratis/client/api/DataStreamInput.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,9 @@ public interface DataStreamInput extends Closeable {
3030
/**
3131
* Read the next chunk in the stream asynchronously.
3232
* The caller owns the returned {@link DataStreamReply} which is a {@link ReferenceCountedObject}.
33-
* and a {@link DataStreamPacket}. Access the buffer via {@link DataStreamPacket#nioBuffer()}
34-
* or {@link DataStreamPacket#nioBuffers()}.
33+
* and a {@link org.apache.ratis.protocol.DataStreamPacket}.
34+
* Access the buffer via {@link org.apache.ratis.protocol.DataStreamPacket#nioBuffer()}
35+
* or {@link org.apache.ratis.protocol.DataStreamPacket#nioBuffers()}.
3536
* It must call {@link ReferenceCountedObject#release()} after consuming it.
3637
*
3738
* @return a future of the reference-counted reply.

ratis-client/src/main/java/org/apache/ratis/client/api/SnapshotManagementApi.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ default RaftClientReply create(boolean force, long timeoutMs) throws IOException
4040
/**
4141
* Trigger to create a snapshot.
4242
*
43-
* @param creationGap When (creationGap > 0) and (lastAppliedIndex - lastSnapshotIndex < creationGap),
43+
* @param creationGap When (creationGap &gt; 0) and (lastAppliedIndex - lastSnapshotIndex &lt; creationGap),
4444
* return lastSnapshotIndex; otherwise, take a new snapshot and then return its index.
4545
* When creationGap == 0, use the server configured value as the creationGap.
4646
* @return a reply. When {@link RaftClientReply#isSuccess()} is true,

ratis-common/src/main/java/org/apache/ratis/util/LifeCycle.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,13 @@
4040
* | -------------------------------- |
4141
* | | ------------------------ | |
4242
* | | | | | |
43-
* | | PAUSED <---- PAUSING---- | | |
43+
* | | PAUSED «---- PAUSING---- | | |
4444
* | | | ^ | | | | |
4545
* | | V | | V V V V
46-
* NEW --> STARTING --> RUNNING --|--> CLOSING --> [CLOSED]
46+
* NEW --» STARTING --» RUNNING --|--» CLOSING --» [CLOSED]
4747
* ^ | | | | ^
4848
* | | | V V |
49-
* ------- -------> EXCEPTION -----
49+
* ------- -------» EXCEPTION -----
5050
* </pre>
5151
*/
5252
public class LifeCycle {

ratis-server-api/src/main/java/org/apache/ratis/server/DataStreamMap.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,6 @@ public interface DataStreamMap {
2929
CompletableFuture<DataStream> computeIfAbsent(ClientInvocationId invocationId,
3030
Function<ClientInvocationId, CompletableFuture<DataStream>> newDataStream);
3131

32-
/** Similar to {@link java.util.Map#remove(java.lang.Object). */
32+
/** Similar to {@link java.util.Map#remove(java.lang.Object)}. */
3333
CompletableFuture<DataStream> remove(ClientInvocationId invocationId);
3434
}

ratis-server-api/src/main/java/org/apache/ratis/server/raftlog/RaftLogSequentialOps.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ default CompletableFuture<Long> appendEntry(LogEntryProto entry, TransactionCont
134134
/**
135135
* The same as append(Arrays.asList(entries)).
136136
*
137-
* @deprecated use {@link #append(List)}
137+
* @deprecated use {@link RaftLogSequentialOps#append(List)}
138138
*/
139139
@Deprecated
140140
default List<CompletableFuture<Long>> append(LogEntryProto... entries) {

ratis-server-api/src/main/java/org/apache/ratis/statemachine/StateMachine.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ default void notifySnapshotInstalled(InstallSnapshotResult result, long snapshot
226226

227227
/**
228228
* Notify the {@link StateMachine} that the server for this division has been shut down.
229-
* @Deprecated please use/override {@link #notifyServerShutdown(RoleInfoProto, boolean)} instead
229+
* @deprecated please use/override {@link #notifyServerShutdown(RoleInfoProto, boolean)} instead
230230
*/
231231
@Deprecated
232232
default void notifyServerShutdown(RoleInfoProto roleInfo) {
@@ -503,15 +503,15 @@ default FollowerEventApi followerEvent() {
503503
CompletableFuture<Message> query(Message request);
504504

505505
/**
506-
* Query the state machine, provided minIndex <= commit index.
506+
* Query the state machine, provided minIndex &lt;= commit index.
507507
* The request must be read-only.
508508
* Since the commit index of this server may lag behind the Raft service,
509509
* the returned result may possibly be stale.
510510
*
511511
* When minIndex > {@link #getLastAppliedTermIndex()},
512512
* the state machine may choose to either
513513
* (1) return exceptionally, or
514-
* (2) wait until minIndex <= {@link #getLastAppliedTermIndex()} before running the query.
514+
* (2) wait until minIndex &lt;= {@link #getLastAppliedTermIndex()} before running the query.
515515
*/
516516
CompletableFuture<Message> queryStale(Message request, long minIndex);
517517

0 commit comments

Comments
 (0)