use of org.jkiss.dbeaver.model.runtime.DefaultProgressMonitor in project dbeaver by serge-rider.
the class DatabaseConsumerSettings method loadNode.
public void loadNode(IRunnableContext runnableContext) {
if (containerNode == null && !CommonUtils.isEmpty(containerNodePath)) {
if (!CommonUtils.isEmpty(containerNodePath)) {
try {
runnableContext.run(true, true, new IRunnableWithProgress() {
@Override
public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
try {
DBNNode node = DBeaverCore.getInstance().getNavigatorModel().getNodeByPath(new DefaultProgressMonitor(monitor), containerNodePath);
if (node instanceof DBNDatabaseNode) {
containerNode = (DBNDatabaseNode) node;
}
} catch (DBException e) {
throw new InvocationTargetException(e);
}
}
});
checkContainerConnection(runnableContext);
} catch (InvocationTargetException e) {
log.error("Error getting container node", e.getTargetException());
} catch (InterruptedException e) {
// ignore
}
}
}
}
Aggregations