Giter Club home page Giter Club logo

ktor-yoga-backend's Introduction

Yoga Ktor Backend

Backend for booking Yoga Classes built on Ktor-Server

Approach

  • Built HTTP POST end points for the login, signup and register features with corresponding models for the Response request and Body.
  • Implemented the HTTP GET end point for authentication, which contains the JWT Auth token in header and unique user id in the query param.
  • Used Kotlin Coroutines for multithreading
  • Used salting and hashing techniques and algorithms like SHA256 & HMAC signature, to protect the user data and privacy.
  • Used a clean architecture and basic design patterns for scalability.

Tools & Technologies Used -

  • Backend: Kotlin Ktor-Server
  • Database: KMongo Atlas
  • Container: Docker
  • IDE: IntelliJ Idea
  • API Testing: Postman

Database Schema and ER Diagram

Schema for the NoSQL collection -

db-schema

ER Diagram -

er-diagram

Note: In case the image does not load, follow this link

API Reference

Refer this url for the postman documentation -

Deployment

  • The app contains a Dockerfile which can be used to containerize the application and is thus Cloud Native.

  • The app is currently deployed on renderer & the database is hosted on AWS.

    Refer to this url for steps to containerize this app using docker -

  • ktor-docker

Troubleshooting

  • Note: Since the app is hosted using a free plan of render, the server stops after being idle for some time.
  • Desi Jugaad: Make sure to hit the base end point a couple of times before using the app until you see this message - "Welcome to the Yoga App!" to wake the server up from sleep and make it up and running!

My Learnings

  • Learnt the complete backend development using Kotlin Ktor Server and KMongo Atlas NoSQL database.
  • Explored Docker to make the app cloud native and for ease of deployment.
  • Learnt to host the app on a hosting service like renderer.
  • Learnt how to use postman for making API calls and to build an attractive API documentation.
  • Learnt about Database Schema and ER Diagram.
  • Concepts like routing, serialization, hashing, salting

Author

ktor-yoga-backend's People

Contributors

lord-lava avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.