Package org.opennms.core.ipc.twin.test
Class AbstractTwinBrokerIT
- java.lang.Object
-
- org.opennms.core.ipc.twin.test.AbstractTwinBrokerIT
-
public abstract class AbstractTwinBrokerIT extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAbstractTwinBrokerIT.Tracker<T>
-
Field Summary
Fields Modifier and Type Field Description TwinPublisherpublisherTwinSubscribersubscriber
-
Constructor Summary
Constructors Constructor Description AbstractTwinBrokerIT()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract TwinPublishercreatePublisher()protected abstract TwinSubscribercreateSubscriber(MinionIdentity identity)voidsetup()voidteardown()voidtestMultipleSubscribers()Tests that multiple subscribers get the same update.voidtestMultipleSubscription()Tests that multiple subscriptions exists for the same key.voidtestPublisherRestart()Tests that subscription works if publisher gets restarted.voidtestPublishSubscribe()Tests that an object can be published and the same object can be received by the subscriber.voidtestPublishSubscribeWithTrapdConfig()voidtestSubscribeBeforePublish()Tests that a subscriber can register before a publisher exists.voidtestSubscriberClose()Tests that subscription can be closed and reopened.voidtestSubscriberCloseBeforeRegister()Tests that subscription can be closed before registration.voidtestUpdates()Tests that a publisher can update an object and the subscriber will receives all versions.
-
-
-
Field Detail
-
publisher
public TwinPublisher publisher
-
subscriber
public TwinSubscriber subscriber
-
-
Method Detail
-
createPublisher
protected abstract TwinPublisher createPublisher() throws Exception
- Throws:
Exception
-
createSubscriber
protected abstract TwinSubscriber createSubscriber(MinionIdentity identity) throws Exception
- Throws:
Exception
-
testPublishSubscribe
public void testPublishSubscribe() throws ExceptionTests that an object can be published and the same object can be received by the subscriber.- Throws:
Exception
-
testUpdates
public void testUpdates() throws ExceptionTests that a publisher can update an object and the subscriber will receives all versions.- Throws:
Exception
-
testSubscribeBeforePublish
public void testSubscribeBeforePublish() throws ExceptionTests that a subscriber can register before a publisher exists.- Throws:
Exception
-
testMultipleSubscription
public void testMultipleSubscription() throws ExceptionTests that multiple subscriptions exists for the same key.- Throws:
Exception
-
testMultipleSubscribers
public void testMultipleSubscribers() throws ExceptionTests that multiple subscribers get the same update.- Throws:
Exception
-
testPublisherRestart
public void testPublisherRestart() throws ExceptionTests that subscription works if publisher gets restarted.- Throws:
Exception
-
testSubscriberClose
public void testSubscriberClose() throws ExceptionTests that subscription can be closed and reopened.- Throws:
Exception
-
testSubscriberCloseBeforeRegister
public void testSubscriberCloseBeforeRegister() throws ExceptionTests that subscription can be closed before registration.- Throws:
Exception
-
testPublishSubscribeWithTrapdConfig
public void testPublishSubscribeWithTrapdConfig() throws IOException- Throws:
IOException
-
-