Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TSD-Restful-API

Setup Instructions

In Package Manager Console execute

Update-Database -StartupProject Orders.Api -Project Orders.Infrastructure

This will create a SQLite app.db in the Orders.Infrastructure folder.

Running the project will open the swagger ui page with the Order endpoints. Their is also a .http file in Orders.Api which can be used as well.

Assumptions

  1. Products are not stored in the database so multiple orderItems could contain the "same" product name
  2. Project is intending to be for a overall larger project so setup for that "future" with the way its structured compared to using a Minimal Api solution.
  3. No automated testing added due to time constraints
  4. No authentication to guard against performing update/delete actions eg by a Staff member
  5. No validation to make sure order status steps flow from pending -> processing -> shipped -> delivered

Architectural Decisions

  1. Utilised FluentResults and FluentValidations to implement the Result Pattern to improve clarity, consistency and separation of concerns.
  2. Use records for DTOs to maintain immutability
  3. Use of Controllers over Minimal APIs was done for better organisation, complexity handling and familiarity.
  4. Chose SQLite for the database just for ease of setup in development and sharing of the project.
  5. Chose EF Core as i'm familiar with it and its quick to get basic CRUD operations up and running. If more complex scenarios came up then custom SQL for performance.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages