Giter Site home page Giter Site logo

canberktimurlenk / movieapi Goto Github PK

View Code? Open in Web Editor NEW
5.0 1.0 0.0 170 KB

A TMDB (The Movie Database) API Clone with ASP.NET Core Web API

C# 100.00%
asp-net-core-web-api aspect-oriented-programming n-tier-architecture postgresql redis seq serilog dotnet restful-api sql-server

movieapi's Introduction

MovieAPI

MovieAPI is an API project developed for educational purposes and similar to the API used by TMDB. TMDB stands for "The Movie Database" which is built as a user-editable movie and TV database and also provides an API.


I have created a scenario to reinforce what I have learned in my software development education. It will work similarly to the API developed by TMDB. The API will provide information about movies, including the details about the movie's budget, information about the actors appearing in the movie, the genres in which the actors have played or vice versa, and even more data. The JSON data produced as a response is eligible to be consumed by various front end technologies such as mobile apps, Angular, Vue.js, React etc. and/or another API.


  • The project was written in C#
  • ASP.NET Web API framework was used to create a RESTful Api.
  • CLEAN Code Techniques and SOLID Principles were followed during development process.



Software Design

Architecture

N Tier Architecture has been impelemented.

Database

PostgreSQL was used as database. Triggers has been also added through migrations.

Global Exception Handler

Global exception handling middleware was added to centralize exception management. Custom Exceptions was created.

Aspect-Oriented Programming

To exceed seperation of cross cutting concerns from the existed service logic, Aspect-Oriented programming is a well-known technique. Interceptors was used to clearize service logic from the cross cutting concerns. Concerns was thought and applied as aspect attributes

Although Log Aspect and Cache Aspect were implemented initially, Other Aspect could be added easily into existed structure.

Pagination

PageSize and Index could be passed from the query string. The response will be include Page size, Count and Next/Previous Page flag in its header.

Sort By Query

Requested data could be sorted from the query string




Technologies & Tools

  • Serilog

    Serilog was used as Logger. The logger could be used alone or as an aspect both. Global Exception Handling also includes logging.

  • SEQ

    Logging is an effective way to manage the monitoring, troubleshooting, and debugging process. However, when it's used directly and single-handedly the management will be rough to overcome. SEQ is a self-hosted search, analysis, and alerting server built for structured log data.

    Exception Handler, Logger, and SEQ work in collaboration.

  • Redis

    Redis was used as a distributed cache for caching. Rate Limiting also configured to use Redis as store rates.

  • Rate Limiting

    AspNetCoreRateLimit package was used for IP Rate Limiting.

  • JSON Web Token & Refresh Token

    JWT was used for authentication, refresh token mechanism has also been implemented.

  • ASP.NET Identity

    ASP.NET Identity is an API which could manages users, passwords, roles, claims, tokens, email confirmation, and more.

  • Autofac DI Container

    Autofac works as IoC container and The Autofac.Extras.DynamicProxy integration package enables method calls on Autofac components to be intercepted by other components.

movieapi's People

Contributors

canberktimurlenk avatar

Stargazers

 avatar  avatar  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.