getTopologicalOrder

Returns nodes in topological order for execution