use of org.apache.kafka.streams.errors.TopologyException in project apache-kafka-on-k8s by banzaicloud.
the class InternalTopologyBuilderTest method testAddProcessorWithSameName.
@Test
public void testAddProcessorWithSameName() {
builder.addSource(null, "source", null, null, null, "topic-1");
builder.addProcessor("processor", new MockProcessorSupplier(), "source");
try {
builder.addProcessor("processor", new MockProcessorSupplier(), "source");
fail("Should throw TopologyException with processor name conflict");
} catch (final TopologyException expected) {
/* ok */
}
}
use of org.apache.kafka.streams.errors.TopologyException in project apache-kafka-on-k8s by banzaicloud.
the class InternalTopologyBuilderTest method testAddStateStoreWithDuplicates.
@Test
public void testAddStateStoreWithDuplicates() {
builder.addStateStore(new MockStateStoreSupplier("store", false));
try {
builder.addStateStore(new MockStateStoreSupplier("store", false));
fail("Should throw TopologyException with store name conflict");
} catch (final TopologyException expected) {
/* ok */
}
}
use of org.apache.kafka.streams.errors.TopologyException in project apache-kafka-on-k8s by banzaicloud.
the class InternalTopologyBuilderTest method testAddStateStoreWithSink.
@Test
public void testAddStateStoreWithSink() {
builder.addSink("sink-1", "topic-1", null, null, null);
try {
builder.addStateStore(new MockStateStoreSupplier("store", false), "sink-1");
fail("Should throw TopologyException with store cannot be added to sink");
} catch (final TopologyException expected) {
/* ok */
}
}
Aggregations