net.mguenther.kafka.junit.EmbeddedLifecycle Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of kafka-junit Show documentation
Show all versions of kafka-junit Show documentation
Provides an embedded Kafka cluster consisting of Apache ZooKeeper, Apache Kafka Brokers and Kafka Connect
workers in distributed mode along with a rich set of convenient accessors and fault injectors to interact
with the embedded Kafka cluster. Supports working against external clusters as well.
package net.mguenther.kafka.junit;
public interface EmbeddedLifecycle {
/**
* Starts the embedded component. After this method completes the component *must* fully
* operational.
*
* @throws RuntimeException
* this method can and should throw an {@link RuntimeException} to indicate that the
* component could not be deployed
*/
void start();
/**
* Stops the embedded component. After this method completes all acquired resources are
* freed and the component is properly shut down. The component is no longer operational
* after this.
*
* @throws RuntimeException
* this method can and should throw an {@link RuntimeException} to indicate that the
* component could not be shut down
*/
void stop();
}