use of org.apache.flink.connector.pulsar.sink.config.SinkConfiguration in project flink by apache.
the class TopicMetadataListenerTest method sinkConfiguration.
private SinkConfiguration sinkConfiguration(long interval) {
Configuration configuration = operator().config();
configuration.set(PULSAR_TOPIC_METADATA_REFRESH_INTERVAL, interval);
return new SinkConfiguration(configuration);
}
use of org.apache.flink.connector.pulsar.sink.config.SinkConfiguration in project flink by apache.
the class TopicMetadataListenerTest method listenEmptyTopics.
@Test
void listenEmptyTopics() {
TopicMetadataListener listener = new TopicMetadataListener();
SinkConfiguration configuration = sinkConfiguration(Duration.ofMinutes(5).toMillis());
TestProcessingTimeService timeService = new TestProcessingTimeService();
List<String> topics = listener.availableTopics();
assertThat(topics).isEmpty();
listener.open(configuration, timeService);
topics = listener.availableTopics();
assertThat(topics).isEmpty();
}
Aggregations