本文整理汇总了Java中org.opendaylight.controller.config.manager.impl.dependencyresolver.DestroyedModule类的典型用法代码示例。如果您正苦于以下问题:Java DestroyedModule类的具体用法?Java DestroyedModule怎么用?Java DestroyedModule使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
DestroyedModule类属于org.opendaylight.controller.config.manager.impl.dependencyresolver包,在下文中一共展示了DestroyedModule类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: close
import org.opendaylight.controller.config.manager.impl.dependencyresolver.DestroyedModule; //导入依赖的package包/类
/**
* Abort open transactions and unregister read only modules. Since this class is
* not responsible for registering itself under
* {@link org.opendaylight.controller.config.api.ConfigRegistry#OBJECT_NAME}, it
* will not unregister itself here.
*/
@Override
public void close() {
if (!closed.compareAndSet(false, true)) {
return;
}
// abort transactions
Map<String, Entry<ConfigTransactionControllerInternal, ConfigTransactionLookupRegistry>> transactions =
transactionsHolder.getCurrentTransactions();
for (Entry<ConfigTransactionControllerInternal, ConfigTransactionLookupRegistry>
configTransactionControllerEntry : transactions.values()) {
ConfigTransactionControllerInternal configTransactionController = configTransactionControllerEntry.getKey();
configTransactionControllerEntry.getValue().close();
configTransactionController.abortConfig();
}
// destroy all live objects one after another in order of the dependency
// hierarchy, from top to bottom
List<DestroyedModule> destroyedModules = currentConfig.getModulesToBeDestroyed();
LOG.info("ConfigRegistry closing - destroying {} modules", destroyedModules.size());
for (DestroyedModule destroyedModule : destroyedModules) {
destroyedModule.close();
}
// unregister MBeans that failed to unregister properly
baseJMXRegistrator.close();
// remove jmx servers
MBeanServerFactory.releaseMBeanServer(registryMBeanServer);
MBeanServerFactory.releaseMBeanServer(transactionsMBeanServer);
LOG.info("ConfigRegistry closed");
}
示例2: getModulesToBeDestroyed
import org.opendaylight.controller.config.manager.impl.dependencyresolver.DestroyedModule; //导入依赖的package包/类
public List<DestroyedModule> getModulesToBeDestroyed() {
List<DestroyedModule> result = new ArrayList<>();
for (ModuleInternalInfo moduleInternalInfo : getEntries()) {
result.add(moduleInternalInfo.toDestroyedModule());
}
Collections.sort(result);
return result;
}
示例3: toDestroyedModule
import org.opendaylight.controller.config.manager.impl.dependencyresolver.DestroyedModule; //导入依赖的package包/类
public DestroyedModule toDestroyedModule() {
return new DestroyedModule(getIdentifier(), getReadableModule().getInstance(), getModuleJMXRegistrator(),
getOsgiRegistration(), getOrderingIdx(), runtimeBeanRegistrator);
}
示例4: CommitInfo
import org.opendaylight.controller.config.manager.impl.dependencyresolver.DestroyedModule; //导入依赖的package包/类
public CommitInfo(final List<DestroyedModule> destroyedFromPreviousTransactions,
final Map<ModuleIdentifier, ModuleInternalTransactionalInfo> commitMap) {
this.destroyedFromPreviousTransactions = Collections.unmodifiableList(destroyedFromPreviousTransactions);
this.commitMap = Collections.unmodifiableMap(commitMap);
}
示例5: getDestroyedFromPreviousTransactions
import org.opendaylight.controller.config.manager.impl.dependencyresolver.DestroyedModule; //导入依赖的package包/类
/**
* Get ordered list of modules that can be closed in the same order, i.e. first
* element will be a leaf on which no other module depends, n-th element can
* only have dependencies with index smaller than n.
*
* @return list of destroyed modules
*/
public List<DestroyedModule> getDestroyedFromPreviousTransactions() {
return destroyedFromPreviousTransactions;
}