{"record":{"id":"d262436109b643dd","repo":"apache/hadoop","slug":"no-enough-valid-inputs-are-provided-not-recoverab-d26243","errorCode":null,"errorMessage":"No enough valid inputs are provided, not recoverable","messagePattern":"No enough valid inputs are provided, not recoverable","errorType":"exception","errorClass":"HadoopIllegalArgumentException","httpStatus":null,"severity":"error","filePath":"hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/erasurecode/rawcoder/ByteBufferDecodingState.java","lineNumber":119,"sourceCode":"    for (ByteBuffer buffer : buffers) {\n      if (buffer == null) {\n        continue;\n      }\n\n      if (buffer.remaining() != decodeLength) {\n        throw new HadoopIllegalArgumentException(\n            \"Invalid buffer, not of length \" + decodeLength);\n      }\n      if (buffer.isDirect() != usingDirectBuffer) {\n        throw new HadoopIllegalArgumentException(\n            \"Invalid buffer, isDirect should be \" + usingDirectBuffer);\n      }\n\n      validInputs++;\n    }\n\n    if (validInputs < decoder.getNumDataUnits()) {\n      throw new HadoopIllegalArgumentException(\n          \"No enough valid inputs are provided, not recoverable\");\n    }\n  }\n\n  /**\n   * Check and ensure the buffers are of the desired length and type, direct\n   * buffers or not.\n   * @param buffers the buffers to check\n   */\n  void checkOutputBuffers(ByteBuffer[] buffers) {\n    for (ByteBuffer buffer : buffers) {\n      if (buffer == null) {\n        throw new HadoopIllegalArgumentException(\n            \"Invalid buffer found, not allowing null\");\n      }\n\n      if (buffer.remaining() != decodeLength) {\n        throw new HadoopIllegalArgumentException(","sourceCodeStart":101,"sourceCodeEnd":137,"githubUrl":"https://github.com/apache/hadoop/blob/2add9630210752f88ceb1bb74eb65e37bf41da8e/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/erasurecode/rawcoder/ByteBufferDecodingState.java#L101-L137","documentation":"Error \"No enough valid inputs are provided, not recoverable\" thrown in apache/hadoop.","triggerScenarios":"Thrown at hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/erasurecode/rawcoder/ByteBufferDecodingState.java:119 when the library encounters an invalid state.","commonSituations":"Occurs when too many input blocks are erased or null for decoding to recover the data. Ensure the number of erased units does not exceed the number of parity units before decoding.","solutions":["Provide at least numDataUnits valid (non-erased) input blocks; with more erasures than parity units the data is unrecoverable.","Check erasedIndexes against available inputs before decoding and restore or re-read missing blocks."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2add9630210752f88ceb1bb74eb65e37bf41da8e","analyzedAt":"2026-08-22T19:55:07.957Z","schemaVersion":2},"datasetVersion":"2026-08-22T20:17:22.307Z"}