Skip to content

Restfull & GRPC APIs to manage Bowling scores, games and players data.

License

Notifications You must be signed in to change notification settings

JeremyTremblay2/bowling-scorer-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status Bugs Code Smells Coverage Duplicated Lines (%) Lines of Code Maintainability Rating Quality Gate Status Reliability Rating Security Hotspots Security Rating Technical Debt Vulnerabilities

🎳 Bowling Scorer API 🎳

The goal of this project is to develop a functionnal API to manage bowling scores, players, statistics and games.

This project will use and cover a Restful API for the player part, and use some websockets to ensure real time exchanges with the clients for the bowling part (games, scores, etc.).

✔️ Features

These features will be available in the future, when the API will be completely finished, so stay tuned to be notified when there will be available !

🕹️ Restful API

  • [✅] Request player's data (name, url of his profile picture, ID...)
  • [✅] Get the statistics of the players (best score, number of games (won, loose...), scores more generally).
  • [✅] Create players and change their names and profile pictures, and also their statistics.

🎙️ GRPC API

  • [✅] Get information about bowling players
  • [✅] Get informations about the scores
  • [✅] CRUD Methods on players
  • [✅] CRUD Methods on statistics

🧱 Structure of the project

To realize such a work, we have structured this project following a certain architecture, here is it Architecture Description

🖥️ Langages and technologies used

🧵 Prerequisities

⚙️ How to run the app ?

  • Start Visual Studio.
  • Open the solution in src/ named BowlingScorerAPI.

🔖 If you want to run the RestFul API

  • Open a terminal or a PowerShell instance and place you in the RestfulAPI project:
cd RestfulAPI
  • Create the database by using these commands:

If dotnet ef is not installed on your computer :

dotnet tool install dotnet-ef

If you are on one of the IUT's computer :

dotnet new tool-manifest
dotnet tool install dotnet-ef
  • Generate migrations and database:
dotnet ef migrations add bowlingMigration --project ../Entities --context BowlingDbContext
dotnet ef database update bowlingMigration --project ../Entities --context BowlingDbContext
  • You can't use directly the API, you need to start the Ocelot gateway to access it
    • Right click on solution
    • Select "Properties.."
    • Select "Starting Projects"
    • Check "Multiple Starting Projects"
      • Select Start on "RestfulAPI" and "ApiGateway"
  • Start the project.
  • You maybe would to have a graphical interface to explore the requests in the API. To do this, you can use Postman and import the solution that is in the "postman" folder at the root of the project

🔖 If you want to run the GRPC API

  • Open a terminal or a PowerShell instance and place you in the RestfulAPI project:
cd BowlingGrpcServer
  • Create the database by using these commands:

If dotnet ef is not installed on your computer :

dotnet tool install dotnet-ef

If you are on one of the IUT's computer :

dotnet new tool-manifest
dotnet tool install dotnet-ef
  • Generate migrations and database:
dotnet ef migrations add bowlingMigration --project ../Entities --context BowlingDbContext
dotnet ef database update bowlingMigration --project ../Entities --context BowlingDbContext
  • You can't use directly the GRPC API
    • Right click on solution
    • Select "Properties.."
    • Select "Starting Projects"
    • Check "Multiple Starting Projects"
      • Select Start on "BowlingGrpcServer", "BowlingGrpcClient" and "StatisticsGrpcClient"
  • Start the project.

📌 Documentation & developper guidance

API Choice description : here
API Gateway description : here
Architecture description : here

Also, look at the doc folder at the root of this repository!


👤 Authors

Jérémy TREMBLAY

Mickaël DUBOIS (omega2028)

📝 License

We want to leave the possibility to other people to work on this project, to improve it and to make it grow, that's why we decided to place it under MIT license.

Read more about the MIT licence.

Releases

No releases published

Packages

No packages published

Languages