Portal Community
What is InfraHub Storage? InfraHub Storage is the shared file storage foundation for the entire BizFirst AI platform. Any workflow node, agent, or service calls IObjectStorageProvider.StoreAsync() and receives a Content ID (CID) back. Files are stored once, tenant-isolated, automatically deduplicated, and protected against disk overflow. The same CID can be passed across nodes and retrieved by any service in the platform.

Key Capabilities

CapabilityWhat it does
Content-Addressable StorageFiles are stored by SHA-256 hash (CID). Uploading the same file twice stores it once — zero duplication cost.
Tenant IsolationEvery file key is prefixed with tenant_{tenantID}/. One bucket, fully isolated per tenant at the key level.
Capacity GuardWrites are blocked before disk reaches 90% (configurable). Alert thresholds at 70% / 85% / 95% via Prometheus.
Backend FlexibilitySingle configuration switch selects MinIO (self-hosted), AWS S3, Cloudflare R2, or Backblaze B2 — no code changes.
Automated BackupDaily encrypted incremental backups via restic to Backblaze B2. Retention: 7 daily, 4 weekly, 12 monthly, 2 annual.
Lifecycle ArchivalObjects automatically tiered to cold storage at Day 30, expired at Day 365 via MinIO lifecycle policies.
Point-in-Time RestoreRecover any snapshot to any point within the retention window using restic restore commands.

How It Works

Caller
Node / Agent
IObjectStorage
Provider
Capacity
Guard
CID
Compute
Dedup
Check
MinIO / S3
Upload
The deduplication check ensures files stored multiple times are only uploaded once, saving bandwidth and storage space.

Documentation Guides

Overview

Architecture, design decisions, project structure, SRP decomposition, and dependency graph.

Getting Started

Register the service, store your first file, retrieve it, and verify deduplication in under 10 minutes.

Setup & Configuration

Docker Compose for MinIO, environment variables, appsettings, and multi-environment configuration patterns.

Use Cases & Scenarios

8 real business scenarios — invoice archival, HR documents, AI artefacts, workflow attachments, audit trails, and more.

Storing Files

Complete developer integration guide: StoreAsync, GetStreamAsync, ExistsAsync, StoreOptions, and error handling.

Backup

Automated encrypted daily backups with restic + Backblaze B2, retention policy, monitoring, and manual procedures.

Archival & Lifecycle

MinIO lifecycle rules — hot → cold at Day 30, expiry at Day 365, compliance holds, and storage class transitions.

Resiliency & Monitoring

Prometheus metrics, Grafana dashboards, disk threshold alerts (70%/85%/95%), and incident response runbooks.

Maintenance

Day-to-day operations — capacity checks, backup verification, log review, MinIO console, and health endpoints.

Point-in-Time Restore

Recover files from any snapshot — full restore, selective restore, disaster recovery procedures, and RTO targets.

Configuration Reference

Complete reference for all FileStorage settings, environment variables, defaults, and per-environment examples.

Project Map

ProjectTypeResponsibility
BizFirst.Integration.S3.DomainDomainS3Credential, request/result records, MinIO path style support
BizFirst.Integration.S3.ServicesServicesS3ClientFactory, IS3ObjectService, bucket and folder services
BizFirst.Ai.InfraHub.Storage.DomainDomainIObjectStorageProvider, StoreOptions, StorageCapacityException
BizFirst.Ai.InfraHub.Storage.S3.ServicesServicesICidProvider, IStorageCapacityGuard, S3ObjectStorageProvider, DI registration

Compatible Backends

BackendEndpoint settingForcePathStyleNotes
MinIO (self-hosted)http://minio:9000trueDefault for BizFirst deployments
AWS S3Leave blankfalseUses RegionEndpoint routing
Cloudflare R2https://<account>.r2.cloudflarestorage.comtrueS3-compatible, no egress fees
Backblaze B2https://s3.<region>.backblazeb2.comtrueLow-cost backup target