Skip to content

Commit 3b6ebf9

Browse files
morningmanCopilot
andcommitted
[refactor](fe) Phase 0: Prerequisite decoupling for filesystem SPI (#61862)
## Summary This PR completes **Phase 0** of the [FE filesystem SPI refactoring](#61860) — removing compile-time couplings that would otherwise prevent splitting filesystem implementations into independent Maven modules in later phases. ## Changes ### P0.1 — FsStorageType enum migration - Introduce `FsStorageType` enum in `fe-foundation` (zero-dependency module) to replace Thrift-generated `StorageBackend.StorageType` in `PersistentFileSystem` - Add `FsStorageTypeAdapter` in `fe-core` for bidirectional Thrift↔FsStorageType conversion - Update all subclasses and callers: `Repository`, `BackupJob`, `RestoreJob`, `CloudRestoreJob` ### P0.2 — ObjStorage IOException bridge - Add `IOException`-based `default` bridge methods to `ObjStorage` interface - Add `ObjStorageStatusAdapter` for `Status→IOException` conversion ### P0.3 — SwitchingFileSystem decoupling - Introduce `FileSystemLookup` functional interface - Decouple `SwitchingFileSystem` from `ExternalMetaCacheMgr` ### P0.4 — MultipartUploadCapable interface - Extract `MultipartUploadCapable` interface from `ObjFileSystem` - `S3FileSystem` and `AzureFileSystem` implement it; `HMSTransaction` uses `instanceof` check ### P0.5 — GsonUtils compile-time decoupling - Introduce `FileSystemDescriptor` POJO for `Repository` metadata serialization - `GsonUtils` removes 7 compile-time concrete class imports, uses `Class.forName()` reflection ### P0.6 — FileSystemSpiProvider skeleton - Add `FileSystemSpiProvider` interface in `fs/spi/` ### Build - Fix Maven build cache incorrectly skipping `checkstyle:check` - Fix checkstyle violations (unused import, import order) ## Testing - FE build: ✅ Checkstyle: 0 violations ✅ Closes part of #61860 --------- Co-authored-by: Copilot <[email protected]>
1 parent 86c3fee commit 3b6ebf9

0 file changed

File tree

    0 commit comments

    Comments
     (0)