{"record":{"id":"d1a9cc859c769a32","repo":"apache/pulsar","slug":"paramname-cannot-be-greater-than-maxvalue","errorCode":null,"errorMessage":"${paramName} cannot be greater than ${maxValue}!","messagePattern":"(.+?) cannot be greater than (.+?)!","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"pulsar-client-tools/src/main/java/org/apache/pulsar/admin/cli/utils/CmdUtils.java","lineNumber":68,"sourceCode":"                        invalidFormatException.getLocation().getColumnNr());\n\n                throw new IllegalArgumentException(exceptionMessage);\n            } else {\n                throw new IllegalArgumentException(ex.getMessage());\n            }\n        }\n    }\n\n    public static boolean positiveCheck(String paramName, long value) {\n        if (value <= 0) {\n            throw new IllegalArgumentException(paramName + \" cannot be less than or equal to 0!\");\n        }\n        return true;\n    }\n\n    public static boolean maxValueCheck(String paramName, long value, long maxValue) {\n        if (value > maxValue) {\n            throw new IllegalArgumentException(paramName + \" cannot be greater than \" + maxValue + \"!\");\n        }\n        return true;\n    }\n}\n","sourceCodeStart":50,"sourceCodeEnd":73,"githubUrl":"https://github.com/apache/pulsar/blob/820761864ed8e2a7d2e52dd9763ad2ae117c1395/pulsar-client-tools/src/main/java/org/apache/pulsar/admin/cli/utils/CmdUtils.java#L50-L73","documentation":"Upper-bound check in CmdUtils.maxValueCheck: a CLI parameter exceeded its permitted maximum (maxValue), commonly a percentage or limit capped by the tool; paramName and the option value are the faulty inputs.","triggerScenarios":"Thrown at pulsar-client-tools/src/main/java/org/apache/pulsar/admin/cli/utils/CmdUtils.java:68 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Lower the parameter value to at most the stated maximum"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"820761864ed8e2a7d2e52dd9763ad2ae117c1395","analyzedAt":"2026-09-06T00:14:20.138Z","contentChangedAt":"2026-09-06T00:14:20.138Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}