public static class EndpointReadyFutures.Builder extends Object
Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
EndpointReadyFutures.Builder |
addReadinessFuture(String name,
CompletableFuture<?> future)
Add a readiness future that will block all endpoints.
|
EndpointReadyFutures.Builder |
addReadinessFutures(String name,
Map<org.apache.kafka.common.Endpoint,? extends CompletionStage<?>> newFutures)
Add readiness futures for individual endpoints.
|
EndpointReadyFutures |
build(Optional<org.apache.kafka.server.authorizer.Authorizer> authorizer,
org.apache.kafka.server.authorizer.AuthorizerServerInfo info)
Build the EndpointReadyFutures object.
|
public EndpointReadyFutures.Builder addReadinessFuture(String name, CompletableFuture<?> future)
name
- The future name.future
- The future object.public EndpointReadyFutures.Builder addReadinessFutures(String name, Map<org.apache.kafka.common.Endpoint,? extends CompletionStage<?>> newFutures)
name
- The future name.newFutures
- A map from endpoints to futures.public EndpointReadyFutures build(Optional<org.apache.kafka.server.authorizer.Authorizer> authorizer, org.apache.kafka.server.authorizer.AuthorizerServerInfo info)
authorizer
- The authorizer to use, if any. Will be started.info
- Server information to be passed to the authorizer.