Skip to main content

Crate mockforge_registry_server

Crate mockforge_registry_server 

Source
Expand description

Pillars: [Cloud]

MockForge Plugin Registry Server — library crate.

This is the multi-tenant SaaS binary crate. The reusable, OSS-friendly pieces — domain models, the RegistryStore trait + SQLite/Postgres backends, auth, and TOTP/2FA helpers — live in mockforge-registry-core and are consumed directly by single-tenant builds such as mockforge-ui (mockforge-registry-core with default-features = false, features = ["sqlite"]). This crate re-exports a few of them for path stability but is not itself intended to be consumed as a slimmed-down library; that role belongs to mockforge-registry-core.

Consequently this crate requires its full integration set. The SaaS-only integrations (stripe, email, storage-s3, cache-redis) are referenced unconditionally throughout the crate, so the only supported build is the saas rollup (the default). A slimmed-down build such as --no-default-features --features postgres is not supported — see #644. The guard below turns that into one actionable message instead of 30+ “unresolved crate” errors. If OSS consumers ever need a smaller surface of this crate, the right move is to extend mockforge-registry-core, not to feature-gate the SaaS server.

Modules§

ai
Cloud AI Studio surface.
auth
JWT/password auth helpers moved to mockforge-registry-core. Authentication and JWT handling
cache
Redis caching utilities for frequently accessed data
circuit_breaker
Circuit breaker pattern for external service resilience
config
Server configuration
database
Database connection and models
deployment
Deployment orchestrator for hosted mocks
email
Email notification service for user communications
error
Error types for the registry server.
fly_logs
Fly.io runtime log client for hosted-mock deployments.
fly_metrics
Fly Managed Prometheus client for hosted-mock runtime metrics.
fly_nats
Real-time Fly.io runtime-log subscription over NATS (#556).
handlers
API handlers
metrics
Metrics instrumentation helpers for marketplace operations
middleware
HTTP middleware
models
Domain models now live in mockforge-registry-core. Re-exported here so existing crate::models::X paths continue to resolve during the cloud-core extraction. Database models
otlp_grpc
OTLP gRPC trace receiver (#548).
pillar_tracking_init
Initialize pillar tracking with analytics database adapter
platform_signing
HSM-backed platform signing-root rotation (Issue #550, RFC §8.2 / §9). Audit-aware wrapper around mockforge_platform_signing. Glue between mockforge_platform_signing and the registry’s audit-log machinery (Issue #550, RFC §8.2 / §9), plus the [PlatformSigningController] surface the HTTP handlers and the one-shot operator binary call into (Issue #568).
redis
Redis connection and utilities for rate limiting and caching
routes
API routes
run_queue
Helpers for pushing test_run jobs onto the Redis queue that the mockforge-test-runner worker consumes.
sso_domain
SSO domain-ownership verification and issuer SSRF guard (Issue #833, #746, #778).
storage
Plugin binary storage (S3-compatible with local filesystem fallback)
store
Storage trait + backends now live in mockforge-registry-core. Re-exported so existing crate::store::* paths keep working. Unified storage layer for the registry domain.
two_factor
TOTP/2FA helpers moved to mockforge-registry-core. Two-Factor Authentication (2FA) utilities
validation
Validation helpers moved to mockforge-registry-core. Marketplace upload validation
workers
Background workers for periodic tasks

Structs§

AppState