@Override
    public ExplorerTreeNode findByUUID(final String uuid) {
        if (uuid == null) {
            return null;
        }

        final List<ExplorerTreeNode> list = JooqUtil.contextResult(explorerDbConnProvider, context ->
                        context
                                .selectFrom(n)
                                .where(n.UUID.eq(uuid))
                                .fetch())
                .map(this::mapRecord);

        if (list.isEmpty()) {
            return null;
        }

        if (list.size() > 1) {
            throw new RuntimeException("Found more than 1 tree node with uuid=" + uuid);
        }

        return list.get(0);
    }
Get the root node containing a particular node, or the node itself if it is a root node.
stroom-explorer/stroom-explorer-impl-db/src/main/java/stroom/explorer/impl/db/ExplorerTreeDaoImpl.java