vertx / io.vertx.kafka.admin / AdminUtils / createTopic

# createTopic

`abstract fun createTopic(topicName: String, partitionCount: Int, replicationFactor: Int, completionHandler: Handler<AsyncResult<Void>>): Unit`

Creates a new Kafka topic on all Brokers managed by the given Zookeeper instance(s)

### Parameters

`topicName` - Name of the to-be-created topic

`partitionCount` - Number of partitions

`replicationFactor` - Number of replicates. Must be lower or equal to the number of available Brokers

`completionHandler` - vert.x callback

`abstract fun createTopic(topicName: String, partitionCount: Int, replicationFactor: Int, topicConfig: MutableMap<String, String>, completionHandler: Handler<AsyncResult<Void>>): Unit`

Creates a new Kafka topic on all Brokers managed by the given Zookeeper instance(s). In contrast to @see `#createTopic(String, int, int, Handler)`, one can pass in additional configuration parameters as a map (String -> String).

### Parameters

`topicName` - Name of the to-be-created topic

`partitionCount` - Number of partitions

`replicationFactor` - Number of replicates. Must be lower or equal to the number of available Brokers

`topicConfig` - map with additional topic configuration parameters

`completionHandler` - vert.x callback