Skip to content

An implementation of the WebDav protocol backed by AWS S3 and DynamoDB.

License

Notifications You must be signed in to change notification settings

webdav-serverless/webdav-serverless

Repository files navigation

webdav-serverless

An implementation of the WebDav protocol backed by AWS S3 and DynamoDB.

About the Design of webdav-serverless

Diagram of webdav-serverless

Metadata Structure Overview

Metadata:

Metadata

Reference:

Reference

Note: In reality, the reference paths are hashed.

Defining MetadataStore tables using DynamoDB

Metadata:

Key Attributes Type Description
PK id string Unique ID (eg. UUID)
GSIPK1 parent_id string ID of the parent directory
name string Name (eg. report.pdf)
type string File system entry type (eg. File or Directory)
size number File size (eg. 512)
modify string File modify time (eg. ISO 8601)
version number Version number for optimistic lock (eg. 1)

Reference:

Key Attributes Type Description
PK id string Unique ID (eg. hashed path)
entries map key(hashed path): value(metadata id)
version number Version number for optimistic lock (eg. 1)

PhysicalStorage specifications using S3

# S3 Key (Metadata#id)
$bucket_name/$UUID

Development

Starting Docker Compose:

docker-compose up --force-recreate --build --abort-on-container-exit

Initialize DynamoDB(dynamodb-local):

docker-compose run dynamodb-init

Initialize S3(minio):

docker-compose run s3-init

Run Go Application:

env AWS_ACCESS_KEY_ID="AKIAIOSFODNN7EXAMPLE" AWS_SECRET_ACCESS_KEY="wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY" AWS_REGION="us-east-1" go run main.go --port=8080 --dynamodb-url=http://localhost:18070 --s3-url=http://localhost:19010

Authors

  • vvatanabe - Main contributor
  • safx - Main contributor
  • kunst1080 - Main contributor
  • Currently, there are no other contributors

License

This project is licensed under the MIT License. For detailed licensing information, refer to the LICENSE file included in the repository.

About

An implementation of the WebDav protocol backed by AWS S3 and DynamoDB.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages