GithubHelp home page GithubHelp logo

airport-microservice-app's Introduction

Airport-microservice-app

Design and implement a system for selling airline tickets in microservice architecture. Brief description of the system: The system consists of 3 services. These services include the customer, ticket and flight services.

User service:

  • Registration - name, surname, email, code, passport number (at the end of registration an email is sent to the user to verify the email address).
  • Login - the user forwards the email and password, if the login is successful he gets JWT token in response.
  • Edit profile - when the user logs in to the system it has the ability to change all its parameters.
  • Credit card - the user can add 1 or more credit cards to the system.
  • Ranks - Users are assigned a certain rank depending on the miles they are and assigned when buying tickets. The ranks are Gold (> 10000 mi), Silver (> 1000 mi), Bronze (<1000 mi).
  • Admin - In addition to the regular user, there is also an admin, his role is to add and deleting flights. The admin of the parameters has only a username and a password.
  • See service

Flight service:

  • Flight list - The flight list is displayed to the user. Flight parameters are airplane, starting destination, final destination, flight length, price. The user does not show flights whose passenger capacity is full.
  • Flight Search - The user can search for flights based on all parameters.
  • Adding and deleting airplanes - The administrator can add and delete airplanes. The aircraft of the parameters has the name and capacity of the passenger. However, it can be deleted an aircraft only if it is not added to any flight.
  • Add and delete flights - Administrator can add and delete flights, however when deleting if at least one ticket has been sold then for the given flight performs a refund.
  • See service

Ticket service:

  • Ticket purchase - The user can buy tickets for existing ones through this service flights. When making a purchase, the user chooses the credit card with which he wants to pay. If the capacity for a given flight full, the user will be shown an error when purchasing. Depending on the rank of the user, he gets a discount on the ticket price (gold-20%, silver-10%, bronze-0%). After a successful purchase, they are updated for the user miles. The information card contains user information, flight information and date of purchase.
  • Overview of purchased tickets - The user can see all the tickets he bought, sorted by date of purchase.
  • See service

Other features:

Example:

User selects a ticket to buy and after connecting to the ticket service the following actions occur:

  1. The ticket service sends a request to the flight service with the flight id to get the ticket information
  2. The ticket service sends a request to the user service with the user token to get the user information
  3. The ticket service saves the ticket into it's database
  4. The ticket service sends a message to the message broker to update user's miles
  5. The ticket service sends a message to the message broker to update the number of passengers on the flight
  6. When the service is available it updates user's miles
  7. When the service is available it updates the number of passengers on a flight

airport-microservice-app's People

Contributors

gojkovicmatija99 avatar

Stargazers

 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.