Skip to content

Mr-Charvaka/CloudPool

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

253 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

CloudPool

Developer Infrastructure Orchestration & Decentralized BaaS Platform

License Java Rust Spring Boot GraphQL PostgreSQL Weaviate


CloudPool Hero Dashboard

Figure 1: CloudPool Developer Console Dashboard (Metrics, Storage, and Infrastructure State)


🌩️ Overview

CloudPool is an open-source Developer Infrastructure Orchestration & Decentralized BaaS Platform designed to unify backend services into a single programmable infrastructure layer.

Rather than replacing existing cloud providers, CloudPool orchestrates and abstracts infrastructure components through a centralized control plane capable of database provisioning, hybrid storage pooling, vector search indexing, state auditing, and native JNI-accelerated computations.


πŸ“Έ Quick Platform Demo

If you want to view a walkthrough of the system running, check out the walkthrough GIF below: (For instructions on capturing your own, refer to the Screenshot Capture Guide)

CloudPool Platform Walkthrough

✨ Core Features

  • Infrastructure Orchestration: Dynamic PostgreSQL schema generation, Redis cache management, and multi-tenant database partitions.
  • Hybrid Storage Pooling: Unifies Local Directories, AWS S3, and Google Drive behind a single zero-copy file controller.
  • Native Rust Performance Layer: High-speed compression, hashing, and vector math operations bridged to the JVM via JNI.
  • Dynamic Provisioning Engine: Exposes raw table creation, live updates, and live schema rollbacks via REST and GraphQL.
  • Embedded Vector Search: Embedded Weaviate engine with native fallback capabilities for semantic and hybrid similarity search.
  • API Key Management: Granular developer keys with token-scoped security configurations, expiration times, and live revocation.

πŸ›οΈ Platform Architecture & Flows

CloudPool separates high-level orchestration logic (JVM/Spring Boot) from performance-critical compute tasks (Rust via FFI).

1. System Topology

CloudPool System Topology
flowchart TD
    A[Developer Console / Vanilla JS SPA] --> B[Spring Boot Gateway :8080]
    
    subgraph Microservices Orchestration
        B --> C[cloudpool-auth :8082]
        B --> D[cloudpool-data :8083]
        B --> E[cloudpool-compute :8084]
        B --> F[cloudpool-network :8085]
    end

    subgraph Native Compute Acceleration
        D --> G[JNI Bridge]
        G --> H[Rust Native Runtime]
        H --> H1[zstd / gzip Compression]
        H --> H2[SHA-256 Hashes]
        H --> H3[Cosine Similarity Search]
    end

    subgraph Data & Storage Layer
        D --> I[(PostgreSQL DB)]
        D --> J[(Redis Cache)]
        D --> K[(Weaviate Vector DB)]
        D --> L[Storage Pool Orchestrator]
        L --> L1[Local Directory]
        L --> L2[AWS S3 Bucket]
        L --> L3[Google Drive API]
    end
Loading

2. Multi-Tenant Isolation Flow

This diagram details the logical segmentation that ensures Tenant A, Tenant B, and Tenant C remain isolated across credentials, schemas, and backing storage.

flowchart TD
    subgraph Clients
        T1[Tenant A Client]
        T2[Tenant B Client]
        T3[Tenant C Client]
    end

    subgraph Control Plane
        Gateway[CloudPool API Gateway]
        Auth[Multi-Tenant Auth Filter]
    end

    subgraph Metadata Isolation
        DB[(PostgreSQL Database)]
        TSA[(Tenant A Schema)]
        TSB[(Tenant B Schema)]
        TSC[(Tenant C Schema)]
    end

    subgraph Storage Isolation
        Pools[Storage Orchestrator]
        SA[Bucket A - AWS S3]
        SB[Bucket B - Google Drive]
        SC[Bucket C - Local Disk]
    end

    T1 & T2 & T3 --> Gateway
    Gateway --> Auth
    
    Auth -->|Tenant A Key| TSA
    Auth -->|Tenant B Key| TSB
    Auth -->|Tenant C Key| TSC
    
    TSA --> Pools
    TSB --> Pools
    TSC --> Pools
    
    Pools --> SA
    Pools --> SB
    Pools --> SC

    classDef tenantA fill:#0d1b2a,stroke:#415a77,stroke-width:2px,color:#fff;
    classDef tenantB fill:#1b4332,stroke:#40916c,stroke-width:2px,color:#fff;
    classDef tenantC fill:#2d112c,stroke:#7209b7,stroke-width:2px,color:#fff;
    
    class T1,TSA,SA tenantA;
    class T2,TSB,SB tenantB;
    class T3,TSC,SC tenantC;
Loading

3. File Upload Flow Diagram

Detailed request lifecycle tracing validation, metadata cataloging, and physical file stream dispatch to the target storage adapter.

sequenceDiagram
    autonumber
    participant Client as Client Application
    participant Gateway as CloudPool Gateway (:8080)
    participant Auth as Auth Service (:8082)
    participant Data as Data Service (:8083)
    participant DB as PostgreSQL / Cache
    participant Provider as Storage Pool (S3 / Local / Drive)

    Client->>Gateway: POST /api/files/upload (Form File, Bucket)
    Gateway->>Auth: Validate JWT / API Key
    alt Invalid Credentials
        Auth-->>Gateway: 401 Unauthorized
        Gateway-->>Client: HTTP 401 Response
    else Valid Authorization
        Auth-->>Gateway: User Metadata & Scopes
        Gateway->>Data: Delegate File Stream
        Data->>DB: Insert FileMetadata (UUID, Size, MIME, Path)
        DB-->>Data: Record Created
        Data->>Provider: Stream Binary Payload (Zero-copy)
        Provider-->>Data: Stream Complete (Storage Identifier)
        Data-->>Gateway: FileMetadata Payload
        Gateway-->>Client: 200 OK (JSON Upload Response)
    end
Loading

πŸ–ΌοΈ Developer Console screenshots

The interface consists of specialized pages for storage configuration, metrics visualization, database management, and authentication controls.

Tip

To reproduce the application dashboard configurations and capture screenshots locally, see the detailed instructions inside Screenshot Capture Guide.

1. File Explorer UI

File Explorer

2. GraphQL Playground

GraphQL Playground

3. Swagger / OpenAPI

Swagger UI

4. Storage Configuration

Storage Providers

5. API Key Management

API Keys

6. Docker Compose Running

Docker Compose State

7. Monitoring Dashboard

Grafana Monitoring

8. Performance Benchmark Graphs

Benchmark Performance

πŸ› οΈ Technology Stack

Architecture Layer Technologies
Backend Orchestration Java 21 (Spring Boot 3.1, Spring Cloud Gateway)
Native Compute core Rust 1.70+ (Bridged via JNI / FFI)
APIs GraphQL, REST (OpenAPI 3 / Swagger)
Databases PostgreSQL 15, H2 (Local development fallback)
Caching / PubSub Redis 7, RabbitMQ 3
Vector Engine Weaviate Vector Database
Client Interface Vanilla Javascript (SPA Developer Console)

πŸ“Š Performance Benchmarks Summary

Here is a summary of CloudPool Gateway performance under incremental concurrency. For full scenario data (database, vectors, storage comparison), read the System Performance Benchmarks page.

Concurrent Users Requests/sec Avg Latency P95 Latency P99 Latency
1 User 1,584 RPS 0.61 ms 1.28 ms 2.57 ms
10 Users 8,244 RPS 1.17 ms 2.45 ms 4.90 ms
100 Users 14,850 RPS 6.72 ms 14.12 ms 28.23 ms
500 Users 12,456 RPS 40.11 ms 84.23 ms 168.47 ms
1000 Users 8,622 RPS 115.83 ms 243.25 ms 486.50 ms

πŸ’» API Code Examples

1. REST API Examples

Authenticate & Generate token

curl -X POST http://localhost:8080/api/auth/login \
  -H "Content-Type: application/json" \
  -d '{"email": "developer@cloudpool.com", "password": "SecurePassword123!"}'

Upload File to Storage Pool

curl -X POST http://localhost:8080/api/files/upload \
  -H "Authorization: Bearer <your_jwt_token>" \
  -F "file=@/path/to/my-file.pdf" \
  -F "bucket=my-custom-pool"

Generate scoping API Key

curl -X POST http://localhost:8080/api/auth/keys \
  -H "Authorization: Bearer <your_jwt_token>" \
  -H "Content-Type: application/json" \
  -d '{"name": "production-key", "description": "Key for automated backups", "daysToLive": 30}'

2. GraphQL Examples

Query buckets and list metadata files

query GetStorageCatalog {
  buckets {
    name
    description
  }
  files(page: 0, size: 10) {
    id
    originalName
    size
    mimeType
  }
}

Mutation to index text embeddings

mutation IndexVectorDocument {
  indexDocument(
    collectionId: "ae45b128-4e12-4211-9a99-b1d56f78a011"
    docId: "doc_091"
    content: "Deploying cloud applications using decentralized storage backends."
    metadata: [
      { key: "category", value: "cloud-storage" },
      { key: "security", value: "public" }
    ]
  ) {
    id
    content
    status
  }
}

πŸ“‚ Folder Structure

CloudPool/
β”œβ”€β”€ backend/
β”‚   β”œβ”€β”€ spring-boot/          # Multi-module Spring Boot application
β”‚   β”‚   β”œβ”€β”€ cloudpool-auth/   # Identity and API Key validation
β”‚   β”‚   β”œβ”€β”€ cloudpool-data/   # Core File Metadata & Weaviate indexing
β”‚   β”‚   β”œβ”€β”€ cloudpool-compute/# Dynamic jobs & workers engine
β”‚   β”‚   └── cloudpool-gateway/# REST and GraphQL routing filter
β”‚   └── rust/                 # JNI-exposed Native Rust core
β”œβ”€β”€ frontend/
β”‚   └── dashboard/            # SPA Console interface (Vanilla JS)
β”œβ”€β”€ docker/                   # Docker Compose environment setups
β”œβ”€β”€ kubernetes/               # Deployment manifests (deploy/service pods)
β”œβ”€β”€ scripts/                  # Automation execution, deployment, & benchmarks
└── docs/                     # Architecture, metrics, & developer setup guides

πŸš€ Getting Started

Option A β€” Docker Compose (Recommended)

This starts all backend microservices, DBs, and the native Rust build compilation stage automatically.

# Clone the repository
git clone https://github.com/Mr-Charvaka/CloudPool.git
cd CloudPool

# Run multi-container stack
docker compose -f docker/docker-compose.yml up --build

Once the containers report healthy, open the UI at http://localhost:8080/index.html.

Option B β€” Local Manual Compilation

Prerequisites

  • Java JDK 17 or 21
  • Rust 1.70+ and Cargo
  • Maven 3.9+
  • Running local instances of: PostgreSQL (port 5432), Redis (6379), RabbitMQ (5672), Weaviate (8090)

Steps

  1. Compile Native Module:
    cd backend/rust
    cargo build --release
  2. Launch Java Stack:
    cd ../spring-boot
    mvn clean install
    ./launch-local.ps1

⚑ Running Automated Benchmark tests

You can verify and reproduce these performance tables locally:

# Execute local test suite
python scripts/benchmark_suite.py

This output can be used to populate performance charts and generate your benchmark_graphs.png file.


πŸ—ΊοΈ Roadmap

  • Kubernetes Dynamic Storage Class Orchestrator
  • WebAssembly (WASM) plugin injection interface for dynamic runtime compute
  • Multi-region bucket replication adapter
  • Live Grafana dashboard templates checked in to source code

🀝 Contributing

Contributions are welcome! Please follow the workflow instructions detailed inside our Contribution Guidelines.


πŸ“„ License

CloudPool is distributed under the Apache License 2.0. See LICENSE for details.

About

CloudPool is a high-performance developer Backend-as-a-Service (BaaS) and orchestration platform.

Resources

License

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors