Search in sources :

Example 1 with DeleteConsumerGroupOffsetsHandler

use of org.apache.kafka.clients.admin.internals.DeleteConsumerGroupOffsetsHandler in project kafka by apache.

the class KafkaAdminClient method deleteConsumerGroupOffsets.

@Override
public DeleteConsumerGroupOffsetsResult deleteConsumerGroupOffsets(String groupId, Set<TopicPartition> partitions, DeleteConsumerGroupOffsetsOptions options) {
    SimpleAdminApiFuture<CoordinatorKey, Map<TopicPartition, Errors>> future = DeleteConsumerGroupOffsetsHandler.newFuture(groupId);
    DeleteConsumerGroupOffsetsHandler handler = new DeleteConsumerGroupOffsetsHandler(groupId, partitions, logContext);
    invokeDriver(handler, future, options.timeoutMs);
    return new DeleteConsumerGroupOffsetsResult(future.get(CoordinatorKey.byGroupId(groupId)), partitions);
}
Also used : CoordinatorKey(org.apache.kafka.clients.admin.internals.CoordinatorKey) DeleteConsumerGroupOffsetsHandler(org.apache.kafka.clients.admin.internals.DeleteConsumerGroupOffsetsHandler) Map(java.util.Map) TreeMap(java.util.TreeMap) HashMap(java.util.HashMap)

Aggregations

HashMap (java.util.HashMap)1 Map (java.util.Map)1 TreeMap (java.util.TreeMap)1 CoordinatorKey (org.apache.kafka.clients.admin.internals.CoordinatorKey)1 DeleteConsumerGroupOffsetsHandler (org.apache.kafka.clients.admin.internals.DeleteConsumerGroupOffsetsHandler)1