You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/features-storage-files.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,6 +10,12 @@ Managing file storage presents challenges due to inconsistent APIs across storag
10
10
11
11
The `FileStorage` feature addresses these through the `IFileStorageProvider` interface for abstracting file operations, a fluent DI setup with `AddFileStorage`, and the `Result` pattern for error handling and messaging. It supports progress reporting via `IProgress<FileProgress>` and metadata management with `FileMetadata`. The feature is designed to be extensible, allowing developers to implement custom providers or extend functionality with behaviors. Additionally, it supports notifications for real-time monitoring (used by `FileMonitoring`) through the `SupportsNotifications` property. Besides the existing `WriteFileAsync` push model, the abstraction also supports `OpenWriteFileAsync` for scenarios where callers want to stream bytes directly into the destination.
12
12
13
+
Available providers included:
14
+
- Local Files (e.g., `C:\data\file.txt` or `/var/data/file.txt`)
15
+
- Network Shares (e.g., Windows UNC paths)
16
+
- Azure Files
17
+
- Azure Blob Storage
18
+
13
19
### Architecture
14
20
15
21
The `FileStorage` subsystem is built around the `IFileStorageProvider` interface, which defines core file operations. Providers like `LocalFileStorageProvider`, `InMemoryFileStorageProvider`, and others implement this interface. The `IFileStorageFactory` resolves providers by name, and extensions like `FileStorageProviderCompressionExtensions` and `FileStorageProviderCrossExtensions` add advanced functionality such as compression and cross-provider operations. Behaviors can be applied to providers to add cross-cutting concerns like logging or retry logic.
publicabstractclassAggregateRootId<TId>:EntityId<TId>// TODO: this is obsolete with the new codegen TypedIds, remove in future (DinnerFiesta depends on it for now)
0 commit comments