@Override
    public void createPartControl(Composite parent) {
        this.tree = createNavigatorTree(parent, null);
        this.tree.setItemRenderer(new StatisticsNavigatorNodeRenderer(this));

        getViewSite().setSelectionProvider(tree.getViewer());
        getSite().getService(IContextService.class).activateContext(INavigatorModelView.NAVIGATOR_CONTEXT_ID);
        getSite().getService(IContextService.class).activateContext(INavigatorModelView.NAVIGATOR_VIEW_CONTEXT_ID);
//        EditorUtils.trackControlContext(getSite(), this.tree.getViewer().getControl(), INavigatorModelView.NAVIGATOR_CONTEXT_ID);
//        EditorUtils.trackControlContext(getSite(), this.tree.getViewer().getControl(), INavigatorModelView.NAVIGATOR_VIEW_CONTEXT_ID);

        UIExecutionQueue.queueExec(() -> {
            if (!tree.isDisposed()) {
                tree.setInput(getRootNode());
            }
        });
    }
This is a callback that will allow us to create the viewer and initialize
it.
plugins/org.jkiss.dbeaver.ui.navigator/src/org/jkiss/dbeaver/ui/navigator/database/NavigatorViewBase.java