Architecture
Uzumibi’s architecture consists of several key components:
Core Components
┌─────────────────────────────────────────┐
│ Edge Platform │
│ (Cloudflare Workers, Fastly, Spin) │
└─────────────┬───────────────────────────┘
│
│ HTTP Request
▼
┌─────────────────────────────────────────┐
│ Platform-Specific Runtime │
│ (WASM Host Environment) │
└─────────────┬───────────────────────────┘
│
▼
┌─────────────────────────────────────────┐
│ Uzumibi WASM Module │
│ ┌───────────────────────────────────┐ │
│ │ mruby/edge Runtime │ │
│ │ ┌─────────────────────────────┐ │ │
│ │ │ Your Ruby Application │ │ │
│ │ │ (Uzumibi::Router) │ │ │
│ │ └─────────────────────────────┘ │ │
│ └───────────────────────────────────┘ │
└─────────────┬───────────────────────────┘
│
│ HTTP Response
▼
Component Layers
- uzumibi-cli: Command-line tool for generating project scaffolds
- uzumibi-gem: Core framework providing the Router class and request/response handling
- uzumibi-art-router: Lightweight router library for path matching and parameter extraction
- mruby/edge: Ruby runtime optimized for edge computing
- Platform Adapters: Platform-specific code for each edge provider
Request Flow
- HTTP request arrives at the edge platform
- Platform routes to WASM module
- Request data is serialized and passed to mruby/edge
- Your Router class processes the request
- Response is generated and serialized
- Platform sends HTTP response to client