public boolean failed() {
            return error != NO_ERROR;
        }
Check if this assignment failed.

@return true if this assignment failed; false otherwise
connect/runtime/src/main/java/org/apache/kafka/connect/runtime/distributed/ConnectProtocol.java