{"record":{"id":"f7a39cd211f4924c","repo":"apache/beam","slug":"support-for-move-options-is-not-yet-implemented-f7a39c","errorCode":null,"errorMessage":"Support for move options is not yet implemented.","messagePattern":"Support for move options is not yet implemented\\.","errorType":"exception","errorClass":"UnsupportedOperationException","httpStatus":null,"severity":"error","filePath":"sdks/java/io/azure/src/main/java/org/apache/beam/sdk/io/azure/blobstore/AzureBlobStoreFileSystem.java","lineNumber":401,"sourceCode":"          \"Copying blobs requires that a SAS token, connection string, or account key be provided.\");\n    }\n\n    try {\n      CloudStorageAccount storageAccount = CloudStorageAccount.parse(storageConnectionString);\n      return \"?\" + storageAccount.generateSharedAccessSignature(sharedAccessAccountPolicy);\n    } catch (Exception e) {\n      throw (IOException) e.getCause();\n    }\n  }\n\n  @Override\n  protected void rename(\n      List<AzfsResourceId> srcResourceIds,\n      List<AzfsResourceId> destResourceIds,\n      MoveOptions... moveOptions)\n      throws IOException {\n    if (moveOptions.length > 0) {\n      throw new UnsupportedOperationException(\"Support for move options is not yet implemented.\");\n    }\n    copy(srcResourceIds, destResourceIds);\n    delete(srcResourceIds);\n  }\n\n  /** This method will delete a virtual folder or a blob, not a container. */\n  @Override\n  protected void delete(Collection<AzfsResourceId> resourceIds) throws IOException {\n    for (AzfsResourceId resourceId : resourceIds) {\n      if (resourceId.getBlob() == null) {\n        throw new IOException(\"delete does not delete containers.\");\n      }\n\n      BlobContainerClient container =\n          client.get().getBlobContainerClient(resourceId.getContainer());\n\n      // deleting a blob that is not a directory\n      if (!resourceId.isDirectory()) {","sourceCodeStart":383,"sourceCodeEnd":419,"githubUrl":"https://github.com/apache/beam/blob/12126d8942aaf848030c478b4c6a28c6af861c66/sdks/java/io/azure/src/main/java/org/apache/beam/sdk/io/azure/blobstore/AzureBlobStoreFileSystem.java#L383-L419","documentation":"AzureBlobStoreFileSystem.rename() implements move as copy-then-delete and explicitly rejects any MoveOptions arguments with an UnsupportedOperationException. Beam's filesystem contract allows callers to pass move options, but this implementation has not implemented them. The rename itself still works when moveOptions is empty.","triggerScenarios":"Calling FileSystems.rename(src, dest, SomeMoveOptions...) — or any API that forwards move options (e.g. rename with ignore-missing-subdirs style options) — against an azfs filesystem.","commonSituations":"Generic Beam pipeline code that passes MoveOptions regardless of the underlying filesystem; newer Beam code using MoveOptions.IgnoreMissingSubscriptions / standard cleanup options being pointed at Azure storage.","solutions":["Call rename/copy+delete without any MoveOptions arguments.","If you need option semantics (e.g. ignore missing sources), pre-check existence yourself and filter the path list before calling rename.","Implement the move with explicit copy() then delete() calls in your own code.","Track/patch the Beam connector to add MoveOptions support if it is a hard requirement."],"exampleFix":"// before\nFileSystems.rename(srcList, dstList, MoveOptions.IgnoreMissingSubscriptions); // throws\n// after\nFileSystems.rename(srcList, dstList); // no move options","handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n  FileSystems.rename(srcIds, dstIds, moveOptions);\n} catch (UnsupportedOperationException e) {\n  // azfs backend: fall back to rename without options\n  FileSystems.rename(srcIds, dstIds);\n}","preventionTips":["Never pass MoveOptions to azfs-backed rename.","Implement 'ignore missing sources' semantics yourself by pre-filtering paths.","Document backend-specific capability differences in filesystem-abstraction code."],"tags":["azure","unsupported-operation","rename","beam-filesystem","move-options"],"backgroundTag":"unsupported-operation","analyzedSha":"12126d8942aaf848030c478b4c6a28c6af861c66","analyzedAt":"2026-09-13T01:50:10.254Z","contentChangedAt":"2026-09-13T01:50:10.254Z","schemaVersion":2},"datasetVersion":"2026-09-20T03:17:13.778Z"}