modulepackage
0.0.0-20240214121328-969def769630
Repository: https://github.com/swarajkumarsingh/ziplink.git
Documentation: pkg.go.dev
# README
URL Shortener Service

A Scalable URL shortener service implemented in Golang with Redis and MongoDB for storage, and Docker for containerization.
Table of Contents
Features
- Shorten long URLs into easy-to-share links
- Store URL mappings in both Redis and MongoDB for performance and durability
- Retrieve original URLs by visiting the shortened link
- Dockerized for easy deployment
Prerequisites
Before you begin, ensure you have met the following requirements:
- Golang installed
- Redis server installed and running
- MongoDB server installed and running
- Docker installed (optional, for containerization)
Getting Started
Installation
-
Clone this repository:
git clone https://github.com/swarajkumarsingh/ziplink.git
-
Navigate to the project directory:
cd ziplink
-
Install the required Go packages:
go mod tidy
Benchmarks
- POST requests (Create Short-URL): Average 856.728106ms (shared cloud cluster)
- GET requests (REDIRECT URL): Average 5.33ms (Redis, MongoDB)
Configuration
- Mongodb client(local, atlas)
- Redis client(local, cloud)
Usage
- After installing docker, just run dev.bat(windows), linux and mac run make run(Note: Mongodb, and redis client should be running,) NOTE: Add configs as shown in run.example.sh
./run.sh
Contributing
Contributions are welcome! If you'd like to contribute to this project, please follow these guidelines:
- Fork the repository.
- Create a new branch for your feature or bug fix.
- Make your changes and test thoroughly.
- Commit your changes with clear commit messages.
- Create a pull request against the main branch.
License
This project is licensed under the MIT License. See the LICENSE file for details.
# Packages
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author