Class ServiceRecoveryListener
- java.lang.Object
-
- org.opendaylight.serviceutils.tools.mdsal.listener.AbstractClusteredSyncDataTreeChangeListener<Operations>
-
- org.opendaylight.serviceutils.srm.impl.ServiceRecoveryListener
-
- All Implemented Interfaces:
AutoCloseable
,EventListener
,org.opendaylight.mdsal.binding.api.ClusteredDataTreeChangeListener<Operations>
,org.opendaylight.mdsal.binding.api.DataTreeChangeListener<Operations>
,ChainableDataTreeChangeListener<Operations>
@Singleton @RequireServiceComponentRuntime public final class ServiceRecoveryListener extends AbstractClusteredSyncDataTreeChangeListener<Operations>
-
-
Constructor Summary
Constructors Constructor Description ServiceRecoveryListener(org.opendaylight.mdsal.binding.api.DataBroker dataBroker, ServiceRecoveryRegistry serviceRecoveryRegistry)
-
Method Summary
All Methods Instance Methods Concrete Methods Default Methods Deprecated Methods Modifier and Type Method Description void
add(org.opendaylight.yangtools.yang.binding.InstanceIdentifier<Operations> instanceIdentifier, Operations operations)
Deprecated.void
add(T newDataObject)
Deprecated.void
addAfterListener(org.opendaylight.mdsal.binding.api.DataTreeChangeListener<T> listener)
Adds a "chained" DataTreeChangeListener, to whichDataTreeChangeListener.onDataTreeChanged(java.util.Collection)
calls are forwarded AFTER having been processed by this DataTreeChangeListener.void
addBeforeListener(org.opendaylight.mdsal.binding.api.DataTreeChangeListener<T> listener)
Adds a "chained" DataTreeChangeListener, to whichDataTreeChangeListener.onDataTreeChanged(java.util.Collection)
calls are forwarded BEFORE having been processed by this DataTreeChangeListener.void
close()
protected org.opendaylight.mdsal.binding.api.DataBroker
getDataBroker()
protected org.opendaylight.serviceutils.tools.mdsal.listener.DataStoreMetrics
getDataStoreMetrics()
default void
onDataTreeChanged(@NonNull Collection<org.opendaylight.mdsal.binding.api.DataTreeModification<T>> changes, org.opendaylight.serviceutils.tools.mdsal.listener.DataStoreMetrics dataStoreMetrics)
Deprecated.Default method invoked upon data tree change, in turn it calls the appropriate method (add, update, remove) depending on the type of change.void
register()
void
remove(org.opendaylight.yangtools.yang.binding.InstanceIdentifier<Operations> instanceIdentifier, Operations removedDataObject)
Deprecated.void
remove(T removedDataObject)
Deprecated.void
update(org.opendaylight.yangtools.yang.binding.InstanceIdentifier<Operations> instanceIdentifier, Operations originalDataObject, Operations updatedDataObject)
Deprecated.void
update(T originalDataObject, T updatedDataObject)
Deprecated.-
Methods inherited from class org.opendaylight.serviceutils.tools.mdsal.listener.AbstractClusteredSyncDataTreeChangeListener
onDataTreeChanged
-
-
-
-
Constructor Detail
-
ServiceRecoveryListener
@Inject public ServiceRecoveryListener(org.opendaylight.mdsal.binding.api.DataBroker dataBroker, ServiceRecoveryRegistry serviceRecoveryRegistry)
-
-
Method Detail
-
add
@Deprecated public void add(org.opendaylight.yangtools.yang.binding.InstanceIdentifier<Operations> instanceIdentifier, Operations operations)
Deprecated.
-
remove
@Deprecated public void remove(org.opendaylight.yangtools.yang.binding.InstanceIdentifier<Operations> instanceIdentifier, Operations removedDataObject)
Deprecated.
-
update
@Deprecated public void update(org.opendaylight.yangtools.yang.binding.InstanceIdentifier<Operations> instanceIdentifier, Operations originalDataObject, Operations updatedDataObject)
Deprecated.
-
addBeforeListener
public void addBeforeListener(org.opendaylight.mdsal.binding.api.DataTreeChangeListener<T> listener)
Description copied from interface:ChainableDataTreeChangeListener
Adds a "chained" DataTreeChangeListener, to whichDataTreeChangeListener.onDataTreeChanged(java.util.Collection)
calls are forwarded BEFORE having been processed by this DataTreeChangeListener.If an asychronous DataTreeChangeListener supports chaining, it must forward the onDataTreeChanged() call BEFORE event are submitted to its async executor for processing.
- Specified by:
addBeforeListener
in interfaceChainableDataTreeChangeListener<T extends org.opendaylight.yangtools.yang.binding.DataObject>
- Parameters:
listener
- the chained DataTreeChangeListener to invoke after this one
-
addAfterListener
public void addAfterListener(org.opendaylight.mdsal.binding.api.DataTreeChangeListener<T> listener)
Description copied from interface:ChainableDataTreeChangeListener
Adds a "chained" DataTreeChangeListener, to whichDataTreeChangeListener.onDataTreeChanged(java.util.Collection)
calls are forwarded AFTER having been processed by this DataTreeChangeListener.If an asychronous DataTreeChangeListener supports chaining, it must forward the onDataTreeChanged() call ONLY AFTER its async executor processed the event.
- Specified by:
addAfterListener
in interfaceChainableDataTreeChangeListener<T extends org.opendaylight.yangtools.yang.binding.DataObject>
- Parameters:
listener
- the chained DataTreeChangeListener to invoke after this one
-
register
@PostConstruct public void register()
-
getDataBroker
protected org.opendaylight.mdsal.binding.api.DataBroker getDataBroker()
-
getDataStoreMetrics
protected org.opendaylight.serviceutils.tools.mdsal.listener.DataStoreMetrics getDataStoreMetrics()
-
close
@PreDestroy public void close()
- Specified by:
close
in interfaceAutoCloseable
-
add
@Deprecated public void add(T newDataObject)
Deprecated.
-
remove
@Deprecated public void remove(T removedDataObject)
Deprecated.
-
update
@Deprecated public void update(T originalDataObject, T updatedDataObject)
Deprecated.
-
onDataTreeChanged
public default void onDataTreeChanged(@NonNull Collection<org.opendaylight.mdsal.binding.api.DataTreeModification<T>> changes, org.opendaylight.serviceutils.tools.mdsal.listener.DataStoreMetrics dataStoreMetrics)
Deprecated.Default method invoked upon data tree change, in turn it calls the appropriate method (add, update, remove) depending on the type of change.- Parameters:
changes
- collection of changesdataStoreMetrics
- data store metrics
-
-