Skip to content

Commit

Permalink
fixes #36 resolve the javadoc issues (#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
stevehu authored Apr 8, 2021
1 parent da1b5eb commit 21b5e88
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ private CompletableFutures() {
*
* <p>If any of the {@code futures} fail, the resulting {@code CompletableFuture} will complete
* exceptionally with that future's failure.
* @param futures a list of futures
* @param <T> paramter
* @return completableFuture of list
*/
public static <T> CompletableFuture<List<T>> allAsList(List<CompletableFuture<T>> futures) {
return CompletableFuture.allOf(futures.toArray(new CompletableFuture[0]))
Expand All @@ -41,6 +44,9 @@ public static <T> CompletableFuture<List<T>> allAsList(List<CompletableFuture<T>
/**
* Returns a {@link CompletableFuture} that is completed exceptionally with the given {@code
* exception}.
* @param exception Throwable
* @param <T> parameter
* @return completableFuture
*/
public static <T> CompletableFuture<T> failedFuture(Throwable exception) {
CompletableFuture<T> future = new CompletableFuture<>();
Expand All @@ -56,6 +62,12 @@ public static <T> CompletableFuture<T> failedFuture(Throwable exception) {
* same value. If {@code future} completes exceptionally with an {@code exceptionClass}, the
* returned future completes with the result of the {@code handler}. Otherwise, the returned
* future will complete exceptionally with the same exception as {@code future}.
* @param future the completable future
* @param exceptionClass exception class
* @param handler the function handler
* @param <T> parameter
* @param <E> parameter
* @return T
*/
public static <T, E extends Throwable> CompletableFuture<T> catchingCompose(
CompletableFuture<T> future,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ public interface RecordSerializer {
* Serializes the given {@code data} into a {@link byte[]}.
*
* <p>Returns {@link Optional#empty()} if {@code data} {@link JsonNode#isNull() is null}.
* @return Optional ByteString
* @param format the format
* @param topicName the topic name
* @param schema the optional schema
* @param data the json node
* @param isKey the key indicator
*/
Optional<ByteString> serialize(
EmbeddedFormat format,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,15 @@ public interface SchemaManager {
* ID or schema version will result in {@link
* org.apache.kafka.common.errors.SerializationException}, as it will any other Schema Registry
* related error. Invalid combination of options will result in {@link IllegalArgumentException}.
* @return RegisteredSchema
* @param topicName the topic name
* @param format the format
* @param subject the subject
* @param subjectNameStrategy subject name strategy
* @param schemaId schema id
* @param schemaVersion schema version
* @param rawSchema raw schema
* @param isKey indicator if it is the key
*/
RegisteredSchema getSchema(
String topicName,
Expand Down

0 comments on commit 21b5e88

Please sign in to comment.