private static SortedSet<ProcessId> mkOrderedSet(final ProcessId... clients) {
        final List<ProcessId> clientList = asList(clients);
        final SortedSet<ProcessId> set = new TreeSet<>(Comparator.comparing(clientList::indexOf));
        set.addAll(clientList);
        return set;
    }
Creates a SortedSet with the sort order being the order of elements in the parameter list
streams/src/test/java/org/apache/kafka/streams/processor/internals/assignment/TaskMovementTest.java