Fail Gradle build for Javadoc warnings

In order to catch Javadoc errors in the build, we now enable the
`Xwerror` flag for the `javadoc` tool. In addition, we now use
`Xdoclint:syntax` instead of `Xdoclint:none` in order to validate
syntax within our Javadoc.

This commit fixes all resulting Javadoc errors and warnings.

This commit also upgrades to Undertow 2.2.12.Final and fixes the
artifact names for exclusions for the Servlet and annotations APIs.

The incorrect exclusion of the Servlet API resulted in the Servlet API
being on the classpath twice for the javadoc task, which resulted in the
following warnings in previous builds.

javadoc: warning - Multiple sources of package comments found for package "javax.servlet"
javadoc: warning - Multiple sources of package comments found for package "javax.servlet.http"
javadoc: warning - Multiple sources of package comments found for package "javax.servlet.descriptor"
javadoc: warning - Multiple sources of package comments found for package "javax.servlet.annotation"

Closes gh-27480
This commit is contained in:
Sam Brannen
2021-09-29 14:02:37 +02:00
parent 040445612f
commit 96e4d3a530
81 changed files with 251 additions and 250 deletions

View File

@@ -256,7 +256,7 @@ public abstract class AbstractRequestExpectationManager implements RequestExpect
/**
* Invoke this for an expectation that has been matched.
* <p>The count of the given expectation is incremented, then it is
* either stored if remainingCount > 0 or removed otherwise.
* either stored if remainingCount &gt; 0 or removed otherwise.
*/
public void update(RequestExpectation expectation) {
expectation.incrementAndValidate();

View File

@@ -80,7 +80,7 @@ public class FluxExchangeResult<T> extends ExchangeResult {
* .exchange()
* .expectStatus().isOk()
* .returnResult()
* .consumeWith(result -> assertThat(...);
* .consumeWith(result -&gt; assertThat(...);
* </pre>
* @param consumer the consumer for {@code "this"} instance
*/

View File

@@ -448,15 +448,15 @@ public interface WebTestClient {
* <pre>
* client.get().uri("/accounts/1")
* .exchange()
* .expectBody(Person.class).consumeWith(exchangeResult -> ... ));
* .expectBody(Person.class).consumeWith(exchangeResult -&gt; ... ));
*
* client.get().uri("/accounts")
* .exchange()
* .expectBodyList(Person.class).consumeWith(exchangeResult -> ... ));
* .expectBodyList(Person.class).consumeWith(exchangeResult -&gt; ... ));
*
* client.get().uri("/accounts/1")
* .exchange()
* .expectBody().consumeWith(exchangeResult -> ... ));
* .expectBody().consumeWith(exchangeResult -&gt; ... ));
* </pre>
* <p>Note that the configured consumer does not apply to responses
* decoded to {@code Flux<T>} which can be consumed outside the workflow
@@ -802,8 +802,8 @@ public interface WebTestClient {
* <pre class="code">
* webTestClient.get().uri("/hello").exchange()
* .expectAll(
* responseSpec -> responseSpec.expectStatus().isOk(),
* responseSpec -> responseSpec.expectBody(String.class).isEqualTo("Hello, World!")
* responseSpec -&gt; responseSpec.expectStatus().isOk(),
* responseSpec -&gt; responseSpec.expectBody(String.class).isEqualTo("Hello, World!")
* );
* </pre>
* @param consumers the list of {@code ResponseSpec} consumers