Cross-relations are not supported by configdb.db.schema.get_dependency_sequence
If we have a relation between two entities that is referenced to in both (think of user - groups, as usual), the configdb.db.schema.get_dependency_sequence will not only not be able to resolve it, but it will also enter an infinite loop.
This is a grave bug that needs to be addressed or we won't be able to make backups in such cases.