本文整理了Java中com.salesforce.kafka.test.ZookeeperTestServer.stop()
方法的一些代码示例,展示了ZookeeperTestServer.stop()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZookeeperTestServer.stop()
方法的具体详情如下:
包路径:com.salesforce.kafka.test.ZookeeperTestServer
类名称:ZookeeperTestServer
方法名:stop
[英]Stops the internal Test zookeeper server instance.
[中]停止内部测试zookeeper服务器实例。
代码示例来源:origin: salesforce/kafka-junit
/**
* Alias for stop().
*/
@Override
public void close() {
stop();
}
代码示例来源:origin: salesforce/kafka-junit
/**
* Here we shut down the internal test zookeeper service.
* @throws RuntimeException on shutdown errors.
*/
private void after() throws RuntimeException {
getZookeeperTestServer().stop();
}
代码示例来源:origin: com.salesforce.kafka.test/kafka-junit4
/**
* Here we shut down the internal test zookeeper service.
* @throws RuntimeException on shutdown errors.
*/
private void after() throws RuntimeException {
getZookeeperTestServer().stop();
}
代码示例来源:origin: salesforce/kafka-junit
/**
* Here we shut down the internal test zookeeper service.
* @throws RuntimeException on shutdown errors.
*/
@Override
public void afterAll(ExtensionContext context) {
getZookeeperTestServer().stop();
}
}
代码示例来源:origin: salesforce/kafka-junit
/**
* Shuts the cluster down.
* @throws Exception on shutdown errors.
*/
public void stop() throws Exception {
// Loop over brokers
for (final KafkaTestServer kafkaBroker : brokers) {
kafkaBroker.stop();
}
// Stop zkServer
zkTestServer.stop();
}
代码示例来源:origin: salesforce/kafka-junit
/**
* Closes the internal servers. Failing to call this at the end of your tests will likely
* result in leaking instances.
* @throws Exception on shutdown errors.
*/
@Override
public void close() throws Exception {
if (broker != null) {
// Shutdown and reset.
broker.shutdown();
}
// Conditionally close zookeeper
if (zookeeperTestServer != null && isManagingZookeeper) {
// Call stop() on zk server instance. This will not cleanup temp data.
zookeeperTestServer.stop();
}
}
内容来源于网络,如有侵权,请联系作者删除!