using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace JiShe.CollectBus.Kafka.AdminClient
{
public interface IAdminClientService
{
///
/// 创建Kafka主题
///
/// 主题名称
/// 主题分区数量
/// 副本数量,不能高于Brokers数量
///
Task CreateTopicAsync(string topic, int numPartitions, short replicationFactor);
///
/// 删除Kafka主题
///
///
///
Task DeleteTopicAsync(string topic);
///
/// 获取Kafka主题列表
///
///
Task> ListTopicsAsync();
///
/// 判断Kafka主题是否存在
///
///
///
Task TopicExistsAsync(string topic);
///
/// 检测分区是否存在
///
///
///
///
Dictionary CheckPartitionsExists(string topic, int[] partitions);
///
/// 检测分区是否存在
///
///
///
///
bool CheckPartitionsExist(string topic, int targetPartition);
///
/// 获取主题的分区数量
///
///
///
int GetTopicPartitionsNum(string topic);
}
}