class UserUpdater {

    Collection<HierarchyTreeNode> buildHierarchyTrees(@NonNull Collection<LdapUserNode> rootNodes, @NonNull Collection<LdapUserNode> allNodes) {
        var dnNodeMap = allNodes.stream()
                .collect(Collectors.toMap(LdapUserNode::getDn, Function.identity()));

        return rootNodes.stream()
                .map(rootNode -> {
                    var childNodesInLevelOrder = getChildNodesInLevelOrder(rootNode, dnNodeMap);

                    return buildHierarchyNode(rootNode, childNodesInLevelOrder);
                })
                .collect(Collectors.toList());
    }

    public  UserUpdater(HierarchyTreeNodeRepository hierarchyTreeNodeRepo,
                       RepositoryUserService repoUserService,
                       UserDataRepository userDataRepo,
                       LdapAdapter ldapAdapter,
                       List<Normalizer<UserData>> normalizers);

}