Skip to main content

Professional Service Framework - Revolutionary modular microservice framework with zero-config API

Project description

๐Ÿš€ ProServe - Modern Microservices Framework

Build production-ready microservices with minimal code - Python decorators or YAML manifests!

๐ŸŽฏ 98% Less Boilerplate โ€ข 5-Minute Start โ€ข Production Ready

ProServe is a revolutionary microservices framework that combines the simplicity of Flask with the power of modern architecture. Create APIs, static sites, real-time chat, and more with just a few lines of code.

๐Ÿš€ Fully Modular Architecture: All components are now modular, testable, and follow SOLID principles
๐Ÿงช Comprehensive E2E Testing: 8+ test suites covering real-world scenarios, security, performance, and integrations

โšก Quick Start (3 Lines of Code!)

# app.py
from proserve import Service

app = Service("my-api")

@app.endpoint("/", method="GET")
async def hello(request):
    return {"message": "Hello World! ๐Ÿš€"}

if __name__ == "__main__":
    app.run(port=8080)
python app.py
# Open: http://localhost:8080

That's it! You have a production-ready API running.

๐ŸŽ“ New to microservices? Check out our Junior Quick Start Guide - "ProServe in 5 minutes"

๐Ÿ—๏ธ Architecture

ProServe Ecosystem Integration

graph TB
    subgraph "Modular Ecosystem"
        ProServe[ProServe Framework<br/>Core Microservices]
        Servos[Servos<br/>Environment Isolation]
        EDPMT[EDPMT Framework<br/>Hardware Control]
        wmlog[wmlog<br/>Centralized Logging]
    end
    
    ProServe --> Servos
    ProServe --> wmlog
    EDPMT --> ProServe
    Servos --> Docker[Docker Containers]
    wmlog --> Monitoring[Real-time Monitoring]
    
    subgraph "ProServe Core Architecture"
        ServiceAPI[Service API<br/>Zero-Config Decorators]
        ManifestEngine[Manifest Engine<br/>YAML-Driven Config]
        ServiceRunner[Service Runner<br/>Multi-Environment]
        Discovery[Discovery & Migration<br/>Auto-Detection]
    end
    
    ProServe --> ServiceAPI
    ProServe --> ManifestEngine
    ProServe --> ServiceRunner
    ProServe --> Discovery
    
    subgraph "Deployment Targets"
        Cloud[Cloud Native<br/>Docker/K8s]
        Embedded[Embedded Systems<br/>MicroPython/Arduino]
        Edge[Edge Computing<br/>RP2040/ESP32]
        Local[Local Development<br/>Process Isolation]
    end
    
    ServiceRunner --> Cloud
    ServiceRunner --> Embedded
    ServiceRunner --> Edge
    ServiceRunner --> Local
    
    subgraph "Service Features"
        HTTP[HTTP Endpoints]
        WebSocket[WebSocket Handlers]
        Background[Background Tasks]
        Monitoring[Health & Metrics]
        StaticFiles[Static File Serving]
        CORS[CORS & Security]
    end
    
    ServiceAPI --> HTTP
    ServiceAPI --> WebSocket
    ServiceAPI --> Background
    ServiceAPI --> Monitoring
    ServiceAPI --> StaticFiles
    ServiceAPI --> CORS

Detailed ProServe Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                            ProServe Framework                               โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚                                                                             โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”‚
โ”‚  โ”‚                      Developer Interface                            โ”‚     โ”‚
โ”‚  โ”‚                                                                     โ”‚     โ”‚
โ”‚  โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”        โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚  Zero-Config   โ”‚        โ”‚      Manifest-Based                โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚   Decorators   โ”‚        โ”‚      Configuration                  โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚                โ”‚        โ”‚                                     โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚ @service.      โ”‚        โ”‚  name: my-service                   โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚  endpoint()    โ”‚        โ”‚  version: 1.0.0                     โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚ @service.      โ”‚        โ”‚  type: http                         โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚  websocket()   โ”‚        โ”‚  port: 8080                         โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚ @service.      โ”‚        โ”‚  isolation:                         โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ”‚  background()  โ”‚        โ”‚    mode: docker                     โ”‚   โ”‚     โ”‚
โ”‚  โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜        โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜   โ”‚     โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ”‚
โ”‚                                โ”‚                                             โ”‚
โ”‚                                โ–ผ                                             โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”‚
โ”‚  โ”‚                      Core Framework                                โ”‚     โ”‚
โ”‚  โ”‚                                                                     โ”‚     โ”‚
โ”‚  โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚   Service   โ”‚ โ”‚  Manifest   โ”‚ โ”‚   Runner    โ”‚ โ”‚    Discovery    โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚     API     โ”‚ โ”‚   Engine    โ”‚ โ”‚             โ”‚ โ”‚   & Migration   โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚             โ”‚ โ”‚             โ”‚ โ”‚             โ”‚ โ”‚                 โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Endpoints  โ”‚ โ”‚โ€ข YAML Parse โ”‚ โ”‚โ€ข Multi-Env  โ”‚ โ”‚โ€ข Auto-Detect    โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข WebSocket  โ”‚ โ”‚โ€ข Validation โ”‚ โ”‚โ€ข Process    โ”‚ โ”‚โ€ข Blue-Green     โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Background โ”‚ โ”‚โ€ข Env Vars   โ”‚ โ”‚โ€ข Docker     โ”‚ โ”‚โ€ข Gradual        โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Health     โ”‚ โ”‚โ€ข Templates  โ”‚ โ”‚โ€ข K8s        โ”‚ โ”‚  Migration      โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Metrics    โ”‚ โ”‚โ€ข Inheritanceโ”‚ โ”‚โ€ข MicroPy    โ”‚ โ”‚โ€ข Rollback       โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข CORS       โ”‚ โ”‚โ€ข Includes   โ”‚ โ”‚โ€ข Arduino    โ”‚ โ”‚โ€ข Monitor        โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚     โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ”‚
โ”‚                                โ”‚                                             โ”‚
โ”‚                                โ–ผ                                             โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”‚
โ”‚  โ”‚                   Integration Layer                                โ”‚     โ”‚
โ”‚  โ”‚                                                                     โ”‚     โ”‚
โ”‚  โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚   Servos    โ”‚ โ”‚   wmlog     โ”‚ โ”‚   aiohttp   โ”‚ โ”‚      EDPMT      โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚ Isolation   โ”‚ โ”‚  Logging    โ”‚ โ”‚   Server    โ”‚ โ”‚   Framework     โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚             โ”‚ โ”‚             โ”‚ โ”‚             โ”‚ โ”‚                 โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Process    โ”‚ โ”‚โ€ข Structured โ”‚ โ”‚โ€ข Async      โ”‚ โ”‚โ€ข Hardware       โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Docker     โ”‚ โ”‚โ€ข Real-time  โ”‚ โ”‚โ€ข HTTP/WS    โ”‚ โ”‚โ€ข Manifest       โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Platform   โ”‚ โ”‚โ€ข Broadcastingโ”‚ โ”‚โ€ข CORS       โ”‚ โ”‚โ€ข Service        โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚  Detection  โ”‚ โ”‚โ€ข Context    โ”‚ โ”‚โ€ข Static     โ”‚ โ”‚  Templates      โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Resource   โ”‚ โ”‚  Enrichment โ”‚ โ”‚  Files      โ”‚ โ”‚โ€ข Device         โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚  Limits     โ”‚ โ”‚โ€ข Multi-dest โ”‚ โ”‚โ€ข Middleware โ”‚ โ”‚  Management     โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚     โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ”‚
โ”‚                                โ”‚                                             โ”‚
โ”‚                                โ–ผ                                             โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”‚
โ”‚  โ”‚                  Deployment Environments                           โ”‚     โ”‚
โ”‚  โ”‚                                                                     โ”‚     โ”‚
โ”‚  โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚    Cloud    โ”‚ โ”‚  Embedded   โ”‚ โ”‚    Edge     โ”‚ โ”‚      Local      โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚   Native    โ”‚ โ”‚   Systems   โ”‚ โ”‚  Computing  โ”‚ โ”‚  Development    โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚             โ”‚ โ”‚             โ”‚ โ”‚             โ”‚ โ”‚                 โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Docker     โ”‚ โ”‚โ€ข MicroPythonโ”‚ โ”‚โ€ข RP2040     โ”‚ โ”‚โ€ข Process        โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Kubernetes โ”‚ โ”‚โ€ข CircuitPy  โ”‚ โ”‚โ€ข ESP32      โ”‚ โ”‚โ€ข Thread         โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Compose    โ”‚ โ”‚โ€ข Arduino    โ”‚ โ”‚โ€ข STM32      โ”‚ โ”‚โ€ข Debug          โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Swarm      โ”‚ โ”‚โ€ข PlatformIO โ”‚ โ”‚โ€ข Bare Metal โ”‚ โ”‚โ€ข Hot Reload     โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Scaling    โ”‚ โ”‚โ€ข RTOS       โ”‚ โ”‚โ€ข Real-time  โ”‚ โ”‚โ€ข Live Logs      โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ”‚โ€ข Load Bal   โ”‚ โ”‚โ€ข Low Power  โ”‚ โ”‚โ€ข IoT        โ”‚ โ”‚โ€ข Rich Console   โ”‚  โ”‚     โ”‚
โ”‚  โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚     โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

โœจ Features

๐ŸŽฏ Core Framework

  • Manifest-Driven Architecture: Declarative YAML-based service configuration
  • Multi-Environment Isolation: Process, Docker, Kubernetes, MicroPython, Arduino, RP2040
  • Auto-Discovery & Migration: Automatic service detection and seamless migration tools
  • Zero Vendor Lock-in: Export generated code and run independently

๐Ÿ”ง Advanced Capabilities

  • Structured Logging: Rich console output with JSON export and WebSocket broadcasting
  • Health & Metrics: Built-in monitoring endpoints with Prometheus integration
  • Dynamic Handlers: Hot-reload Python scripts with isolation sandboxing
  • Background Tasks: Async periodic tasks with optional WebSocket broadcasting
  • CORS & Security: Configurable CORS, authentication, and request validation

๐ŸŒ Multi-Platform Support

  • Cloud Native: Docker, Kubernetes, Docker Compose orchestration
  • Embedded Systems: MicroPython, CircuitPython, Arduino IDE integration
  • Hardware Platforms: Raspberry Pi Pico (RP2040), ESP32, STM32, Arduino boards
  • Development Tools: PlatformIO, Arduino CLI, esptool integration

๐Ÿš€ DevOps & Deployment

  • Blue-Green Migration: Gradual traffic shifting with automatic rollback
  • Service Discovery: Automatic manifest generation from existing code
  • Monitoring Stack: Grafana dashboards, Prometheus metrics, Alertmanager
  • CI/CD Ready: GitHub Actions, Docker builds, PyPI publishing

๐Ÿ“ฆ Installation

Basic Installation

pip install proserve

With All Features

pip install proserve[all]

Specific Feature Sets

# Docker & Kubernetes support
pip install proserve[docker,kubernetes]

# MicroPython & Embedded development
pip install proserve[micropython,arduino,rp2040]

# Monitoring & observability
pip install proserve[monitoring]

# Development tools
pip install proserve[development,testing]

๐Ÿš€ Quick Start

๐ŸŽฏ NEW: Simplified Decorator API (No Manifest Required!)

# app.py - Zero configuration needed!
from proserve import Service

service = Service(name="my-service")

@service.endpoint("/api/hello", method="GET")
async def hello(request):
    return {"message": "Hello, ProServe!"}

@service.websocket("/ws")
async def websocket_handler(ws):
    async for message in ws:
        await ws.send(f"Echo: {message}")

@service.background_task(interval=60)
async def cleanup():
    print("Running cleanup...")

# Start the service
if __name__ == "__main__":
    service.run(port=8080)

Run it:

python app.py
# ๐Ÿš€ Service running at http://localhost:8080
# ๐Ÿ“Š Health check: http://localhost:8080/health
# ๐Ÿ“ˆ Metrics: http://localhost:8080/metrics

๐Ÿ“‹ Traditional: Manifest-Based Configuration

# my-service.yaml
name: my-awesome-service
version: 1.0.0
type: http
port: 8080
host: 0.0.0.0

# Features
requires_edpmt: false
enable_cors: true
enable_health: true
enable_metrics: true

# Endpoints
endpoints:
  - path: /api/hello
    method: GET
    script: handlers/hello.py

# WebSocket handlers
websocket_handlers:
  - path: /ws
    script: handlers/websocket.py

# Background tasks
background_tasks:
  - script: handlers/background.py
    interval: 60
    broadcast: true

# Environment isolation
isolation:
  mode: process  # none, process, docker, kubernetes, micropython, arduino
  timeout: 30
  auto_environment: true

# Environment variables
env_vars:
  - API_KEY
  - DATABASE_URL
  - DEBUG

# Static file serving
static_dirs:
  "/static": "./static"
  "/assets": "./assets"

2. Create Handler Scripts

# handlers/hello.py
async def handle_request(request, service):
    return {"message": "Hello from ProServe!", "service": service.manifest.name}

# handlers/websocket.py  
async def handle_websocket(ws, data, service):
    if data.get('action') == 'ping':
        return {'action': 'pong', 'timestamp': time.time()}

# handlers/background.py
async def background_task(service):
    service.logger.info("Background task executed")
    return {"status": "completed"}

3. Run Your Service

# Using CLI
proserve run --manifest my-service.yaml

# Using Python
python -c "
from proserve import ServiceRunner
runner = ServiceRunner('my-service.yaml')
runner.run()
"

๐ŸŒ Multi-Environment Deployment

Cloud Native (Docker/Kubernetes)

isolation:
  mode: docker
  image: python:3.11-slim
  resources:
    memory: "512Mi"
    cpu: "0.5"

MicroPython (RP2040/ESP32)

isolation:
  mode: micropython
  platform: rp2040  # or esp32, esp8266
  firmware_version: "1.19.1"
  memory_limit: 256KB

Arduino

isolation:
  mode: arduino
  board: esp32dev  # or nano33iot, uno_r4_wifi
  libraries:
    - WiFi
    - ArduinoJson
    - PubSubClient

๐Ÿ”ง Service Discovery & Migration

Discover Existing Services

# Automatic service discovery
proserve-discover --project-root . --output manifests/

# Generate manifests from existing code
proserve convert legacy-service.py --output service.yaml

Migrate to Manifest-Based

# Start migration with blue-green deployment  
proserve-migrate migrate --service my-service --strategy blue-green

# Monitor migration progress
proserve-migrate status --service my-service

# Complete migration
proserve-migrate complete --service my-service

๐Ÿณ Docker & Orchestration

Docker Compose

# docker-compose.yml
version: '3.8'
services:
  my-service:
    image: proserve:latest
    environment:
      - PROSERVE_MANIFEST=/app/my-service.yaml
    ports:
      - "8080:8080"
    volumes:
      - ./manifests:/app/manifests:ro

Multiple Architectures

# Build for different platforms
make build-docker  # Builds arm64, x86_64, micropython, arduino

# Deploy to specific environment
proserve-deploy --environment production --platform kubernetes

๐Ÿ“Š Monitoring & Observability

Built-in Endpoints

  • GET /health - Health check with service status
  • GET /metrics - Prometheus metrics endpoint
  • GET /status - Detailed service information
  • WS /logs - Real-time log streaming

Prometheus Integration

# Automatic metrics collection
monitoring:
  prometheus: true
  metrics_port: 9090
  custom_metrics:
    - request_duration_seconds
    - background_task_duration
    - websocket_connections_total

Grafana Dashboards

# Setup monitoring stack
docker-compose -f docker-compose.manifest.yml --profile monitoring up
# Access Grafana at http://localhost:3000 (admin/admin123)

๐Ÿงช Testing & Development

Run Tests

make test              # All tests
make test-unit         # Unit tests only  
make test-integration  # Integration tests
make test-environments # Multi-environment tests

Development Setup

make dev-setup         # Complete dev environment
make format           # Code formatting
make lint             # Code linting
make check            # All quality checks

๐Ÿ“š Examples

Simple HTTP Service

from proserve import ProServeService, Manifest

manifest = Manifest.from_yaml("service.yaml")
service = ProServeService(manifest)

@service.endpoint("/api/users", methods=["GET"])
async def get_users(request):
    return {"users": ["alice", "bob"]}

service.run()

MicroPython IoT Service

# For RP2040/ESP32
from proserve.embedded import MicroPythonService

service = MicroPythonService("iot-sensor.yaml")

@service.background_task(interval=30)
async def read_sensors():
    temperature = sensor.read_temperature()
    service.broadcast({"temperature": temperature})

service.run()

๐Ÿ“š Learning Path & Examples

๐ŸŽ“ NEW: Progressive Learning Examples

We've created a complete learning path from absolute beginner to production deployment:

Level Example Time Skills
๐Ÿ‘ถ Junior 01-hello-world 5 min First API (3 lines!)
02-static-website 10 min Static files + manifest
03-simple-api 15 min REST endpoints
04-manifest-driven 20 min YAML-only API
๐Ÿง‘โ€๐Ÿ’ป Mid 05-database-api 30 min SQLite + ORM patterns
06-auth-middleware 45 min JWT + RBAC
07-file-upload 30 min File handling + security
08-websocket-chat 45 min Real-time WebSocket chat

๐Ÿš€ Quick Start Paths

Complete Beginner (never built APIs):

cd examples/01-hello-world && python app.py

Know Docker/Flask (familiar with web development):

cd examples/03-simple-api && python app.py  

Prefer Configuration (like docker-compose users):

cd examples/04-manifest-driven && proserve run

๐Ÿ“– Documentation

๐Ÿค Contributing

We welcome contributions! Please see our Contributing Guide for details.

Development Workflow

git clone https://github.com/proserve/proserve.git
cd proserve
make dev-setup
make test

๐Ÿ“„ License

This project is licensed under the Apache License 2.0 - see LICENSE file for details.

๐Ÿ‘จโ€๐Ÿ’ป Author

Tom Sapletta

๐Ÿ† Credits

ProServe is built on top of excellent open-source libraries:


Made with โค๏ธ by the ProServe Team

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

proserve-2.0.1.tar.gz (251.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

proserve-2.0.1-py3-none-any.whl (234.9 kB view details)

Uploaded Python 3

File details

Details for the file proserve-2.0.1.tar.gz.

File metadata

  • Download URL: proserve-2.0.1.tar.gz
  • Upload date:
  • Size: 251.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.0

File hashes

Hashes for proserve-2.0.1.tar.gz
Algorithm Hash digest
SHA256 6ccbe1be8ff101d4cad892e54035b1765f1a735ce157f6762da2b101875005fe
MD5 9159fc4d93fe3123bb83264aaec8b1b3
BLAKE2b-256 65aee3e9a52c8efa093636cb1806ae9ce374a05c23f3f5ba70aec99356b882cf

See more details on using hashes here.

File details

Details for the file proserve-2.0.1-py3-none-any.whl.

File metadata

  • Download URL: proserve-2.0.1-py3-none-any.whl
  • Upload date:
  • Size: 234.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.0

File hashes

Hashes for proserve-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e3d7d115b6c6c07b795c1d560a12c49b15f243859455c230e979d372d70d8754
MD5 dd458c8d561fe34812427009c8f1434a
BLAKE2b-256 c875891898dc0d1458c3bb94a15afa01eb66c5dead03785c9f656bbd4a3e489f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page