public static ConnectProtocolCompatibility compatibility(String name) {
        return Arrays.stream(ConnectProtocolCompatibility.values())
                .filter(mode -> mode.name().equalsIgnoreCase(name))
                .findFirst()
                .orElseThrow(() -> new IllegalArgumentException(
                        "Unknown Connect protocol compatibility mode: " + name));
    }
Return the enum that corresponds to the name that is given as an argument;
if no mapping is found {@code IllegalArgumentException} is thrown.

@param name the name of the protocol compatibility mode
@return the enum that corresponds to the protocol compatibility mode
connect/runtime/src/main/java/org/apache/kafka/connect/runtime/distributed/ConnectProtocolCompatibility.java