private static boolean isValidMethod(String method) {
        List<String> allowedMethods =
                Arrays.asList(TubeConst.ADD, TubeConst.DELETE, TubeConst.MODIFY, TubeConst.SWITCH);
        return allowedMethods.contains(method);
    }
Validates if the provided method is one of the allowed methods.

@param method The method to validate
@return True if the method is valid, otherwise false
inlong-tubemq/tubemq-manager/src/main/java/org/apache/inlong/tubemq/manager/controller/cluster/ClusterController.java