{"record":{"id":"22a93b2619fa143a","repo":"apache/hadoop","slug":"remote-iterator-issupported-for-snapshotdiffreport","errorCode":null,"errorMessage":"Remote Iterator issupported for snapshotDiffReport between two snapshots","messagePattern":"Remote Iterator issupported for snapshotDiffReport between two snapshots","errorType":"exception","errorClass":"UnsupportedOperationException","httpStatus":null,"severity":"error","filePath":"hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/DistributedFileSystem.java","lineNumber":2474,"sourceCode":"   *          tree\n   * @param toSnapshot\n   *          snapshot name of the to point. Null indicates the current\n   *          tree.\n   * @return Remote iterator\n   */\n  public RemoteIterator\n      <SnapshotDiffReportListing> snapshotDiffReportListingRemoteIterator(\n      final Path snapshotDir, final String fromSnapshot,\n      final String toSnapshot) throws IOException {\n    Path absF = fixRelativePart(snapshotDir);\n    return new FileSystemLinkResolver\n        <RemoteIterator<SnapshotDiffReportListing>>() {\n      @Override\n      public RemoteIterator<SnapshotDiffReportListing> doCall(final Path p)\n          throws IOException {\n        if (!DFSUtilClient.isValidSnapshotName(fromSnapshot) ||\n            !DFSUtilClient.isValidSnapshotName(toSnapshot)) {\n          throw new UnsupportedOperationException(\"Remote Iterator is\"\n              + \"supported for snapshotDiffReport between two snapshots\");\n        }\n        return new SnapshotDiffReportListingIterator(getPathName(p),\n            fromSnapshot, toSnapshot);\n      }\n\n      @Override\n      public RemoteIterator<SnapshotDiffReportListing> next(final FileSystem fs,\n          final Path p) throws IOException {\n        return ((DistributedFileSystem) fs)\n            .snapshotDiffReportListingRemoteIterator(p, fromSnapshot,\n                toSnapshot);\n      }\n    }.resolve(this, absF);\n\n  }\n\n  /**","sourceCodeStart":2456,"sourceCodeEnd":2492,"githubUrl":"https://github.com/apache/hadoop/blob/2add9630210752f88ceb1bb74eb65e37bf41da8e/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/DistributedFileSystem.java#L2456-L2492","documentation":"Error \"Remote Iterator issupported for snapshotDiffReport between two snapshots\" thrown in apache/hadoop.","triggerScenarios":"snapshotDiffReport is requested with an iterator, but the FileSystem or path does not support the remote-iterator variant for diff reports between two snapshots.","commonSituations":"See trigger scenarios.","solutions":["Call snapshotDiffReport with both fromSnapshot and toSnapshot specified when using the remote iterator API.","Use the non-iterator snapshotDiffReport for comparisons that omit one snapshot."],"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"}