Skip to content

vishnuys/cloudloadbalancer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cloud Computing Project: Scalable Distributed Object Storage with Consitent Hashing

Load balancer for Object Storage that provides REST API to Create/Delete Buckets and Create/Update/Delete Files.

Implementation of the characterstics of Amazon Dynamo Paper like Consistent Hashing, Sloppy Quorum and Hinted Handoff as REST based Object storage service.

Requirements:

Installation:

  1. Create a virtualenv LoadBalancer and activate it. If you do not have virtualenv installed, install it. (Installation: Windows, Linux & MAC OS)
  2. Clone the Load Balancer repo into the desired directory.
  3. In the project home folder, Install the necessary packages using the command pip install -r requirements .
  4. Create conf.py in clouder folder.
  5. Add the following code to conf.py
    NODE_LIST = [<List of the Storage Nodes>]
    NODE_ADDRESS = {<Each node in NODE_LIST as key and its corresponding address as its value>}
    REPLICATION_FACTOR = <Minimum number of replications needed for each read/write>
  6. Execute the following command to apply migrations: python manage.py migrate.
  7. To run the server on local IP assigned with default port, execute the command python manage.py runserver 0.0.0.0:8000.

Usage:

This REST API doesn't have any authentication. To access this API, send a POST request using any request managers like Postman to specified address given below.

  • Create Bucket: - URL: /create/bucket/ - Request Body: 'name' = - Result: {status: <Success/Failure>, node: <Node at which the bucket was created>}
  • Delete Bucket: - URL: /delete/bucket/ - Request Body: 'name' = - Result: {status: <Success/Failure>, node: <Node at which the bucket was deleted>}
  • Create File: - URL: /create/file/ - Request Body: 'name' = , 'bucket' = , 'file' = - Result: {status: <Success/Failure>, node: <Node at which the file was created>, vector_clocks: {<Vector Clock of each node after file creation>}}
  • Update File: - URL: /update/file/ - Request Body: 'name' = , 'bucket' = , 'file' = - Result: {status: <Success/Failure>, node: <Node at which the file was updated>, vector_clocks: {<Vector Clock of each node after file updation>}}
  • Delete File: - URL: /delete/file/ - Request Body: 'name' = , 'bucket' = - Result: {status: <Success/Failure>, node: <Node at which the file was deleted>}

You can learn more about APIs and how to use them here.

Releases

No releases published

Packages

No packages published

Languages