private void validateInstanceBindings(
            Model model,
            ResourceShape resource,
            IdentifierBindingIndex bindingIndex,
            List<ValidationEvent> events
    ) {
        for (ShapeId operationId : resource.getAllOperations()) {
            if (bindingIndex.getOperationBindingType(resource, operationId) != BindingType.INSTANCE) {
                continue;
            }

            OperationShape operation = model.expectShape(operationId, OperationShape.class);
            if (!hasAllIdentifiersBound(model, resource, operation, bindingIndex)) {
                String expectedIdentifiers = createBindingMessage(resource.getIdentifiers());
                String boundIds = createBindingMessage(bindingIndex.getOperationInputBindings(resource, operation));
                events.add(error(operation,
                        format(
                                "This operation does not form a valid instance operation when bound to resource `%s`. "
                                        + "All of the identifiers of the resource were not implicitly or explicitly "
                                        + "bound to the input of the operation. Expected the following identifier "
                                        + "bindings: [%s]. Found the following identifier bindings: [%s]",
                                resource.getId(),
                                expectedIdentifiers,
                                boundIds)));
            }
        }
    }
Validates that operations bound to resource shapes have identifier
bindings for all the identifiers of the parent of the binding resource,
that operations bound to a resource with the {@code collection}
trait are bound using a collection binding, and operations bound with
no {@code collection} trait are bound using an instance binding.
smithy-model/src/main/java/software/amazon/smithy/model/validation/validators/ResourceIdentifierBindingValidator.java