Code Monkey home page Code Monkey logo

backend-socialmedia's Introduction

Backend-SocialMedia

Tech used

  1. Spring Boot (version 2.7.1)
  2. Spring Data JPA
  3. Hibernate 5.5
  4. REST Repositories
  5. MySQL Database
  6. Maven (version 3.8.5)
  7. Log4j2
  8. Lombok (version 1.18.24)
  9. IDE : Spring Tool Suite 4 (Version: 4.15.1.RELEASE)
  10. Java version: 17.0.3
  11. Postman (version 9.4)

Architecture

  1. Controller layer
  2. Service layer
  3. Repository layer
  4. Model layer

STEPS (REST API)

  1. Created 4 controllers(user, post, status and comment)
  2. Created the get, post and delete mappings for the end points.
  3. From Controller the program flow goes to the service class.
  4. Created 4 services (userService, postService , statusService, commentService)
  5. Using micro-services architecture.
  6. Now the program flow goes to the repository class.
  7. Created 4 reposotories (user repo, status repo, comment repo, comment repo).
  8. These repositories extends the JpaRepositories
  9. JpaRepositories contains all the CRUD pre-defined functions with pagination functionality.
  10. Created the entity class(pojo) : user, status, comment, post.
  11. In entity class , I have used the hibernate and persistance annotations for mapping the tables(OneToMany) and creating the tables and the primary key.

Logging

  1. Injected the logging framework Log4j2 in this project.
  2. In resources, created Log4j2.properties file that contains all the information for the logging.
  3. The logging level is info.
  4. Destination is console and external log file in the drive.
  5. For all the endpoints, loggings will be done.

ER Diagram


backend-socialmedia's People

Contributors

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