Skip to content
This repository was archived by the owner on Jan 9, 2020. It is now read-only.

Commit b139b46

Browse files
ash211foxish
authored andcommitted
Fix lint-check failures and javadoc8 break (#187)
* [MINOR][BUILD] Fix lint-check failures and javadoc8 break ## What changes were proposed in this pull request? This PR proposes to fix lint-check failures and javadoc8 break. Few errors were introduced as below: **lint-check failures** ``` [ERROR] src/test/java/org/apache/spark/network/TransportClientFactorySuite.java:[45,1] (imports) RedundantImport: Duplicate import to line 43 - org.apache.spark.network.util.MapConfigProvider. [ERROR] src/main/java/org/apache/spark/unsafe/types/CalendarInterval.java:[255,10] (modifier) RedundantModifier: Redundant 'final' modifier. ``` **javadoc8** ``` [error] .../spark/sql/core/target/java/org/apache/spark/sql/streaming/StreamingQueryProgress.java:19: error: bad use of '>' [error] * "max" -> "2016-12-05T20:54:20.827Z" // maximum event time seen in this trigger [error] ^ [error] .../spark/sql/core/target/java/org/apache/spark/sql/streaming/StreamingQueryProgress.java:20: error: bad use of '>' [error] * "min" -> "2016-12-05T20:54:20.827Z" // minimum event time seen in this trigger [error] ^ [error] .../spark/sql/core/target/java/org/apache/spark/sql/streaming/StreamingQueryProgress.java:21: error: bad use of '>' [error] * "avg" -> "2016-12-05T20:54:20.827Z" // average event time seen in this trigger [error] ^ [error] .../spark/sql/core/target/java/org/apache/spark/sql/streaming/StreamingQueryProgress.java:22: error: bad use of '>' [error] * "watermark" -> "2016-12-05T20:54:20.827Z" // watermark used in this trigger [error] ``` ## How was this patch tested? Manually checked as below: **lint-check failures** ``` ./dev/lint-java Checkstyle checks passed. ``` **javadoc8** This seems hidden in the API doc but I manually checked after removing access modifier as below: It looks not rendering properly (scaladoc). ![2016-12-16 3 40 34](https://cloud.githubusercontent.com/assets/6477701/21255175/8df1fe6e-c3ad-11e6-8cda-ce7f76c6677a.png) After this PR, it renders as below: - scaladoc ![2016-12-16 3 40 23](https://cloud.githubusercontent.com/assets/6477701/21255135/4a11dab6-c3ad-11e6-8ab2-b091c4f45029.png) - javadoc ![2016-12-16 3 41 10](https://cloud.githubusercontent.com/assets/6477701/21255137/4bba1d9c-c3ad-11e6-9b88-62f1f697b56a.png) Author: hyukjinkwon <[email protected]> Closes apache#16307 from HyukjinKwon/lint-javadoc8. (cherry picked from commit ed84cd0) * Bring back needed import
1 parent 2382ea6 commit b139b46

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

common/unsafe/src/main/java/org/apache/spark/unsafe/types/CalendarInterval.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ public static long parseSecondNano(String secondNano) throws IllegalArgumentExce
252252
public final int months;
253253
public final long microseconds;
254254

255-
public final long milliseconds() {
255+
public long milliseconds() {
256256
return this.microseconds / MICROS_PER_MILLI;
257257
}
258258

sql/core/src/main/scala/org/apache/spark/sql/streaming/progress.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,12 @@ class StateOperatorProgress private[sql](
6868
* incremented.
6969
* @param durationMs The amount of time taken to perform various operations in milliseconds.
7070
* @param eventTime Statistics of event time seen in this batch. It may contain the following keys:
71-
* {
71+
* {{{
7272
* "max" -> "2016-12-05T20:54:20.827Z" // maximum event time seen in this trigger
7373
* "min" -> "2016-12-05T20:54:20.827Z" // minimum event time seen in this trigger
7474
* "avg" -> "2016-12-05T20:54:20.827Z" // average event time seen in this trigger
7575
* "watermark" -> "2016-12-05T20:54:20.827Z" // watermark used in this trigger
76-
* }
76+
* }}}
7777
* All timestamps are in ISO8601 format, i.e. UTC timestamps.
7878
* @param stateOperators Information about operators in the query that store state.
7979
* @param sources detailed statistics on data being read from each of the streaming sources.

0 commit comments

Comments
 (0)