Sparkdo.BlobStoring 1.0.3

There is a newer prerelease version of this package available.
See the version list below for details.
dotnet add package Sparkdo.BlobStoring --version 1.0.3
                    
NuGet\Install-Package Sparkdo.BlobStoring -Version 1.0.3
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Sparkdo.BlobStoring" Version="1.0.3" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Sparkdo.BlobStoring" Version="1.0.3" />
                    
Directory.Packages.props
<PackageReference Include="Sparkdo.BlobStoring" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Sparkdo.BlobStoring --version 1.0.3
                    
#r "nuget: Sparkdo.BlobStoring, 1.0.3"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Sparkdo.BlobStoring@1.0.3
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Sparkdo.BlobStoring&version=1.0.3
                    
Install as a Cake Addin
#tool nuget:?package=Sparkdo.BlobStoring&version=1.0.3
                    
Install as a Cake Tool

Sparkdo.BlobStoring

Sparkdo BLOB 存储库,提供统一的二进制大对象存储接口和多种存储提供程序实现。

功能特性

  • 统一的 BLOB 存储接口:提供一致的 API 来操作各种存储后端
  • 多种存储提供程序:支持文件系统、数据库等多种存储方式
  • 容器化管理:通过容器概念组织和管理 BLOB 对象
  • 多租户支持:为多租户应用提供隔离的存储空间
  • 配置灵活:支持基于容器的个性化配置
  • 与 Sparkdo 框架无缝集成

安装

<PackageReference Include="Sparkdo.BlobStoring" Version="x.x.x" />

核心组件

IBlobContainer

BLOB 容器接口,定义了基本的 BLOB 操作方法:

  • SaveAsync(): 保存 BLOB 对象
  • DeleteAsync(): 删除 BLOB 对象
  • ExistsAsync(): 检查 BLOB 对象是否存在
  • GetAsync(): 获取 BLOB 对象
  • GetOrNullAsync(): 获取 BLOB 对象(不存在时返回 null)

BlobContainer

BLOB 容器实现,提供基本的 BLOB 操作功能:

  • 支持多租户隔离
  • 与具体存储提供程序解耦
  • 统一的异常处理机制

IBlobProvider

BLOB 存储提供程序接口,定义了底层存储操作:

  • SaveAsync(): 保存 BLOB 数据
  • DeleteAsync(): 删除 BLOB 数据
  • ExistsAsync(): 检查 BLOB 是否存在
  • GetOrNullAsync(): 获取 BLOB 数据

BlobProviderBase

BLOB 存储提供程序基类,提供通用实现:

  • 统一的参数验证
  • 标准化的异常处理
  • 可扩展的存储逻辑

配置相关

  • BlobContainerConfiguration: 容器配置信息
  • IBlobContainerConfigurationProvider: 容器配置提供程序
  • DefaultBlobContainerConfigurationProvider: 默认配置提供程序

命名服务

  • IBlobNormalizeNamingService: BLOB 命名规范化服务
  • BlobNormalizeNamingService: 默认命名规范化实现

工厂模式

  • IBlobContainerFactory: BLOB 容器工厂接口
  • BlobContainerFactory: BLOB 容器工厂实现

扩展性

该库提供了完整的 BLOB 存储功能实现,可以通过以下方式扩展:

  1. 实现自定义的 IBlobProvider 来支持新的存储后端
  2. 通过 IBlobContainerConfigurationProvider 自定义容器配置
  3. 实现 IBlobNormalizeNamingService 来改变命名规则
  4. 创建特定的容器类来封装业务逻辑

代码结构说明

本项目包含以下主要组件:

核心接口

  • IBlobContainer<TContainer>: 泛型 BLOB 容器接口
  • IBlobContainer: BLOB 容器接口
  • IBlobProvider: BLOB 存储提供程序接口

核心实现

  • BlobContainer<TContainer>: 泛型 BLOB 容器实现
  • BlobContainer: BLOB 容器实现
  • BlobProviderBase: BLOB 存储提供程序基类

配置

  • BlobContainerConfiguration: 容器配置信息
  • IBlobContainerConfigurationProvider: 容器配置提供程序接口
  • DefaultBlobContainerConfigurationProvider: 默认配置提供程序实现

命名服务

  • IBlobNormalizeNamingService: BLOB 命名规范化服务接口
  • BlobNormalizeNamingService: 默认命名规范化实现

工厂

  • IBlobContainerFactory: BLOB 容器工厂接口
  • BlobContainerFactory: BLOB 容器工厂实现

模块配置

  • SparkdoBlobStoringModule: 模块配置类

所有公共接口和类都添加了详细的 XML 文档注释,便于开发者理解和使用。

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (5)

Showing the top 5 NuGet packages that depend on Sparkdo.BlobStoring:

Package Downloads
Sparkdo.BlobStoring.Minio

Sparkdo BlobStoring 的 MinIO provider。

Sparkdo.BlobStoring.Aliyun

Sparkdo BlobStoring 的阿里云 OSS provider。

Sparkdo.BlobStoring.FileSystem

Sparkdo BlobStoring 的本地文件系统 provider。

Sparkdo.BlobStoring.Tencent

Sparkdo BlobStoring 的腾讯云 COS provider。

Sparkdo.BlobStoring.Aws

Sparkdo BlobStoring 的 AWS S3 provider。

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.0.0-preview.2 67 7/20/2026
1.0.4-preview.3 87 6/8/2026
1.0.4-preview.2 80 6/7/2026
1.0.4-preview.1 94 6/7/2026
1.0.3 169 6/6/2026
1.0.3-preview.1 85 5/17/2026
1.0.2 161 4/27/2026
1.0.2-preview.5 78 4/15/2026
1.0.2-preview.4 105 2/8/2026
1.0.2-preview.3 95 2/1/2026
1.0.2-preview.2 92 1/31/2026
1.0.2-preview.1 199 12/4/2025
1.0.1 443 11/27/2025
1.0.0 439 11/25/2025
1.0.0-preview.5 167 10/24/2025