public class DeviceContextImpl extends Object implements DeviceContext, ExtensionConverterProviderKeeper
Modifier and Type | Method and Description |
---|---|
<T extends org.opendaylight.yangtools.yang.binding.DataObject> |
addDeleteToTxChain(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType store,
org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path)
Method creates delete operation for provided path in underlying transaction chain.
|
boolean |
canUseSingleLayerSerialization()
Checks if device and controller supports single layer serialization.
|
void |
close() |
com.google.common.util.concurrent.ListenableFuture<Void> |
closeServiceInstance() |
<T> RequestContext<T> |
createRequestContext()
Method returns new request context for current request.
|
DeviceFlowRegistry |
getDeviceFlowRegistry()
Method exposes flow registry used for storing flow ids identified by calculated flow hash.
|
DeviceGroupRegistry |
getDeviceGroupRegistry()
Method exposes device group registry used for storing group ids.
|
DeviceInfo |
getDeviceInfo()
Get device info.
|
DeviceMeterRegistry |
getDeviceMeterRegistry()
Method exposes device meter registry used for storing meter ids.
|
DeviceState |
getDeviceState()
Method provides state of device represented by this device context.
|
ExtensionConverterProvider |
getExtensionConverterProvider()
Returns the extension converters registry access point for by inner infrastructure.
|
org.opendaylight.mdsal.singleton.common.api.ServiceGroupIdentifier |
getIdentifier() |
MessageSpy |
getMessageSpy()
Gets message spy.
|
<T extends OfHeader> |
getMultiMsgCollector(RequestContext<List<T>> requestContext)
Gets multi msg collector.
|
ConnectionContext |
getPrimaryConnectionContext()
Getter.
|
org.opendaylight.controller.md.sal.binding.api.ReadOnlyTransaction |
getReadTransaction()
Method exposes transaction created for device
represented by this context.
|
boolean |
initialSubmitTransaction()
Method for initial submit transaction after successful initial gathering.
|
void |
instantiateServiceInstance() |
boolean |
isTransactionsEnabled()
Method returns true if transaction chain manager is enabled.
|
void |
onPublished()
Indicates that device context is fully published (e.g.: packetIn messages should be passed).
|
void |
onStateAcquired(ContextChainState state)
Event triggered on context chain state change.
|
TranslatorLibrary |
oook()
Getter.
|
boolean |
processAlienMessage(OfHeader message)
Method processes alien message from device.
|
void |
processExperimenterMessage(ExperimenterMessage notification)
Processing of experimenter symmetric message from device.
|
void |
processFlowRemovedMessage(FlowRemoved flowRemoved)
Method process async flow removed from device.
|
void |
processPacketInMessage(PacketInMessage packetInMessage)
Method process async packet in from device.
|
void |
processPortStatusMessage(PortStatusMessage portStatus)
Method process async port status from device.
|
void |
processReply(OfHeader ofHeader)
Method that set future to context in Map.
|
void |
processReply(Xid xid,
List<? extends OfHeader> ofHeaderList)
Method that set future to context in Map.
|
void |
registerMastershipWatcher(ContextChainMastershipWatcher newWatcher)
Registers mastership change listener to context.
|
void |
setExtensionConverterProvider(ExtensionConverterProvider extensionConverterProvider)
Sets the ExtensionConverterProvider.
|
void |
setNotificationPublishService(org.opendaylight.controller.md.sal.binding.api.NotificationPublishService notificationPublishService)
Sets notification publish service.
|
boolean |
submitTransaction()
Method submits Transaction to DataStore.
|
boolean |
syncSubmitTransaction()
Method submits Transaction to DataStore and wait till completes by doing get on tx future.
|
void |
updatePacketInRateLimit(long upperBound)
change packetIn rate limiter borders.
|
<T extends org.opendaylight.yangtools.yang.binding.DataObject> |
writeToTransaction(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType store,
org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path,
T data)
Method creates put operation using provided data in underlying transaction chain.
|
<T extends org.opendaylight.yangtools.yang.binding.DataObject> |
writeToTransactionWithParentsSlow(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType store,
org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path,
T data)
Method creates put operation using provided data in underlying transaction
chain and flag to create missing parents.
|
public boolean initialSubmitTransaction()
DeviceContext
initialSubmitTransaction
in interface DeviceContext
public DeviceState getDeviceState()
DeviceContext
getDeviceState
in interface DeviceContext
DeviceState
public org.opendaylight.controller.md.sal.binding.api.ReadOnlyTransaction getReadTransaction()
TxFacade
getReadTransaction
in interface TxFacade
public boolean isTransactionsEnabled()
TxFacade
isTransactionsEnabled
in interface TxFacade
public <T extends org.opendaylight.yangtools.yang.binding.DataObject> void writeToTransaction(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType store, org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path, T data)
TxFacade
writeToTransaction
in interface TxFacade
public <T extends org.opendaylight.yangtools.yang.binding.DataObject> void writeToTransactionWithParentsSlow(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType store, org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path, T data)
TxFacade
writeToTransactionWithParentsSlow
in interface TxFacade
public <T extends org.opendaylight.yangtools.yang.binding.DataObject> void addDeleteToTxChain(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType store, org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path)
TxFacade
addDeleteToTxChain
in interface TxFacade
public boolean submitTransaction()
TxFacade
submitTransaction
in interface TxFacade
public boolean syncSubmitTransaction()
TxFacade
syncSubmitTransaction
in interface TxFacade
public ConnectionContext getPrimaryConnectionContext()
DeviceContext
getPrimaryConnectionContext
in interface DeviceContext
public DeviceFlowRegistry getDeviceFlowRegistry()
DeviceRegistry
getDeviceFlowRegistry
in interface DeviceRegistry
public DeviceGroupRegistry getDeviceGroupRegistry()
DeviceRegistry
getDeviceGroupRegistry
in interface DeviceRegistry
public DeviceMeterRegistry getDeviceMeterRegistry()
DeviceRegistry
getDeviceMeterRegistry
in interface DeviceRegistry
public void processReply(OfHeader ofHeader)
DeviceReplyProcessor
processReply
in interface DeviceReplyProcessor
ofHeader
- openflow headerpublic void processReply(Xid xid, List<? extends OfHeader> ofHeaderList)
DeviceReplyProcessor
processReply
in interface DeviceReplyProcessor
xid
- xidofHeaderList
- openflow header listpublic void processFlowRemovedMessage(FlowRemoved flowRemoved)
DeviceReplyProcessor
processFlowRemovedMessage
in interface DeviceReplyProcessor
flowRemoved
- flow removedpublic void processPortStatusMessage(PortStatusMessage portStatus)
DeviceReplyProcessor
processPortStatusMessage
in interface DeviceReplyProcessor
portStatus
- port statuspublic void processPacketInMessage(PacketInMessage packetInMessage)
DeviceReplyProcessor
processPacketInMessage
in interface DeviceReplyProcessor
packetInMessage
- packet in messagepublic void processExperimenterMessage(ExperimenterMessage notification)
DeviceReplyProcessor
processExperimenterMessage
in interface DeviceReplyProcessor
notification
- notificationpublic boolean processAlienMessage(OfHeader message)
DeviceReplyProcessor
processAlienMessage
in interface DeviceReplyProcessor
message
- alien messagepublic TranslatorLibrary oook()
DeviceContext
oook
in interface DeviceContext
public void setNotificationPublishService(org.opendaylight.controller.md.sal.binding.api.NotificationPublishService notificationPublishService)
DeviceContext
setNotificationPublishService
in interface DeviceContext
notificationPublishService
- the notification publish servicepublic MessageSpy getMessageSpy()
DeviceContext
getMessageSpy
in interface DeviceContext
public void onPublished()
DeviceContext
onPublished
in interface DeviceContext
public <T extends OfHeader> MultiMsgCollector<T> getMultiMsgCollector(RequestContext<List<T>> requestContext)
DeviceContext
getMultiMsgCollector
in interface DeviceContext
T
- the type parameterrequestContext
- the request contextpublic void updatePacketInRateLimit(long upperBound)
DeviceContext
updatePacketInRateLimit
in interface DeviceContext
upperBound
- max amount of outstanding packetInspublic void setExtensionConverterProvider(ExtensionConverterProvider extensionConverterProvider)
ExtensionConverterProviderKeeper
setExtensionConverterProvider
in interface ExtensionConverterProviderKeeper
extensionConverterProvider
- the ExtensionConverterProviderpublic ExtensionConverterProvider getExtensionConverterProvider()
ExtensionConverterProviderKeeper
getExtensionConverterProvider
in interface ExtensionConverterProviderKeeper
public com.google.common.util.concurrent.ListenableFuture<Void> closeServiceInstance()
closeServiceInstance
in interface org.opendaylight.mdsal.singleton.common.api.ClusterSingletonService
public DeviceInfo getDeviceInfo()
OFPContext
getDeviceInfo
in interface OFPContext
public void registerMastershipWatcher(@Nonnull ContextChainMastershipWatcher newWatcher)
OFPContext
registerMastershipWatcher
in interface OFPContext
newWatcher
- mastership change listener@Nonnull public org.opendaylight.mdsal.singleton.common.api.ServiceGroupIdentifier getIdentifier()
getIdentifier
in interface org.opendaylight.yangtools.concepts.Identifiable<org.opendaylight.mdsal.singleton.common.api.ServiceGroupIdentifier>
public void close()
close
in interface AutoCloseable
close
in interface OFPContext
public boolean canUseSingleLayerSerialization()
DeviceContext
canUseSingleLayerSerialization
in interface DeviceContext
public void instantiateServiceInstance()
instantiateServiceInstance
in interface org.opendaylight.mdsal.singleton.common.api.ClusterSingletonService
@Nullable public <T> RequestContext<T> createRequestContext()
RequestContextStack
createRequestContext
in interface RequestContextStack
public void onStateAcquired(ContextChainState state)
ContextChainStateListener
onStateAcquired
in interface ContextChainStateListener
state
- context chain stateCopyright © 2019 OpenDaylight. All rights reserved.