private Map<String, Set<OperationShape>> computeWaiterNamesToOperations(Model model, ServiceShape service) {
        TopDownIndex index = TopDownIndex.of(model);
        Map<String, Set<OperationShape>> waiterNamesToOperations = new TreeMap<>();

        for (OperationShape operation : index.getContainedOperations(service)) {
            operation.getTrait(WaitableTrait.class).ifPresent(trait -> {
                for (String name : trait.getWaiters().keySet()) {
                    Set<OperationShape> operations = waiterNamesToOperations.computeIfAbsent(
                            name.toLowerCase(Locale.ENGLISH),
                            n -> new HashSet<>());
                    operations.add(operation);
                }
            });
        }

        return waiterNamesToOperations;
    }
Ensures that no two waiters use the same case-insensitive name in the
closure of a service.
smithy-waiters/src/main/java/software/amazon/smithy/waiters/UniqueWaiterNamesValidator.java