Skip to content

a benchmarking tool to evaluate microservices’ performance across different cloud providers.

License

Notifications You must be signed in to change notification settings

harshilshah2501/cross-cloud-benchmark

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cross-Cloud Microservices Performance Benchmarking Tool

Overview

The Cross-Cloud Microservices Performance Benchmarking Tool is a comprehensive framework to benchmark the performance of microservices across different cloud providers (CSPs) such as AWS, GCP, and OpenStack. It leverages Terraform for vendor-agnostic infrastructure provisioning, HashiCorp Vault for secure secret management, and tools like Prometheus and Grafana for metrics collection and visualization.

Key Features

  • Vendor-Agnostic Infrastructure Management: Automate resource provisioning on AWS, GCP, and OpenStack using Terraform.
  • Secure Secrets Management: Use HashiCorp Vault to securely manage CSP credentials and other sensitive data.
  • Microservices Deployment: Deploy identical gRPC-based microservices on different cloud platforms using Docker.
  • Benchmarking and Metrics: Measure key metrics like latency, throughput, scalability, and cost-performance using Prometheus and Grafana.
  • Actionable Insights: Generate comparative analyses of cloud providers to identify the optimal environment for specific workloads.

Architecture

+---------------------------------------------------+
|            Cross-Cloud Benchmark Tool            |
|---------------------------------------------------|
| Orchestration: Terraform                         |
| Secret Management: HashiCorp Vault               |
| Benchmarking: Load Testing, Metrics Collection   |
| Visualization: Grafana                           |
+---------------------------------------------------+
                      |
                      v
+---------------------------------------------------+
|             Cloud Providers (CSPs)               |
|---------------------------------------------------|
| AWS                 GCP                 OpenStack |
| - EC2 Instances     - VM Instances      - VMs     |
| - Load Balancers    - Load Balancers    - Network |
| - Networking        - Networking        - Storage |
+---------------------------------------------------+
                      |
                      v
+---------------------------------------------------+
|       Microservices Deployed on CSPs             |
|---------------------------------------------------|
| gRPC Microservice                                 |
| - Containerized via Docker                       |
| - Identical deployment across CSPs               |
+---------------------------------------------------+
                      |
                      v
+---------------------------------------------------+
|         Benchmarking and Metrics Collection      |
|---------------------------------------------------|
| Load Testing Tools:                              |
| - k6, wrk, ghz (simulate load)                   |
| Metrics Exporters:                               |
| - Prometheus (collect latency, throughput, etc.) |
+---------------------------------------------------+
                      |
                      v
+---------------------------------------------------+
|                Visualization Layer               |
|---------------------------------------------------|
| Grafana Dashboards:                              |
| - Latency Comparison (AWS vs GCP vs OpenStack)   |
| - Resource Usage (CPU, Memory, etc.)            |
| - Cost Analysis                                  |
+---------------------------------------------------+

Getting Started

Prerequisites

  1. Terraform: Install Terraform here.
  2. HashiCorp Vault: Install Vault here.
  3. Docker: Install Docker here.
  4. Prometheus and Grafana:
    • Prometheus installation guide.
    • Grafana installation guide.

Repository Structure

├── terraform-modules/           # Terraform modules for CSPs
│   ├── aws/                     # AWS-specific Terraform configuration
│   ├── gcp/                     # GCP-specific Terraform configuration
│   ├── openstack/               # OpenStack-specific Terraform configuration
├── microservices/               # gRPC-based microservices
│   └── Dockerfile               # Dockerfile for microservice deployment
├── benchmarks/                  # Load testing scripts and tools
├── grafana/                     # Grafana configuration and dashboards
├── docs/                        # Documentation and resources
├── scripts/                     # Helper scripts (e.g., setup, cleanup)
└── README.md                    # Project documentation

Setup

Step 1: Clone the Repository

git clone https://github.com/harshilshah2501/cross-cloud-benchmark-.git
cd cross-cloud-benchmark

Step 2: Configure Terraform

1. Initialize Terraform:

terraform init

2. Apply configurations for AWS, GCP, or OpenStack:

terraform apply -var="region=<your-region>"

Step 3: Configure HashiCorp Vault

1. Start Vault:

vault server -dev

2. Store CSP credentials securely:

vault write aws/creds/benchmark access_key=<AWS_ACCESS_KEY> secret_key=<AWS_SECRET_KEY>

Step 4: Deploy Microservices

1. Build and deploy the Docker container:

docker build -t grpc-microservice ./microservices
docker run -d -p 50051:50051 grpc-microservice

Step 5: Setup Prometheus and Grafana

1. Start Prometheus and Grafana using Docker:

docker-compose up -d

2. Configure Grafana to use Prometheus as a data source.

Usage

  1. Run Load Tests: - Use benchmarking tools like k6, wrk, or ghz to simulate traffic and measure performance:
k6 run benchmarks/load_test.js
  1. Monitor Metrics:
  2. Analyze Results:
    • Compare latency, throughput, and resource usage across CSPs.
    • Generate cost-performance insights.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Acknowledgments

  • Terraform
  • HashiCorp Vault
  • Prometheus
  • Grafana
  • Docker

About

a benchmarking tool to evaluate microservices’ performance across different cloud providers.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published