private Collection<Partition> initializePartitions(String name, String topicName, int defaultPartitionCount) {
		Collection<Partition> partitions;
		try {
			// existing topics for named channels or taps should never be repartitioned
			if ((isNamedChannel(name) || isTap(name)) && topicExists(topicName)) {
				partitions = getPartitions(topicName);
			}
			else {
				partitions = ensureTopicCreated(topicName, defaultPartitionCount, defaultReplicationFactor, true);
			}
		}
		catch (Exception exception) {
			throw new RuntimeException("Cannot initialize message bus:", exception);
		}
		return partitions;
	}
Set the {@link OffsetManagement} to use. Default:
{@link OffsetManagement#kafkaTopic}.
@param offsetManagement the offsetManagement.
spring-xd-messagebus-kafka/src/main/java/org/springframework/xd/dirt/integration/kafka/KafkaMessageBus.java