Skip to content

HHrisHikesHH/InstagramPost

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Project : Instagram Application

Frameworks/Tools and languages used

➡️ SpringBoot
➡️ Java
➡️ PostMan
➡️ MySQL DataBase

Data flow in the project

0. Model : We have Two models here namely User & Post:

Followings are the Glimse of the Models:

0.1 USER ⬇️

Screenshot 2023-03-06 at 9 08 55 PM

0.2 POST ⬇️

Screenshot 2023-03-06 at 9 10 13 PM

To see Models

https://github.com/HHrisHikesHH/SpringBoot/tree/main/FEB/Instagram/src/main/java/com/hrishikesh/Instagram/model


1. Controller : In Controller package the UserController is the gateWay to the API endpoints, Here we have provided many APIs perfrorm basic CRUD Operations on ToDo

Followings are the Glimse of the some of EndPoints of the Controller:

1.1 USER ⬇️

Screenshot 2023-03-06 at 9 18 40 PM

1.2 POST ⬇️

Screenshot 2023-03-06 at 9 18 03 PM

To see Entire controller

https://github.com/HHrisHikesHH/SpringBoot/edit/main/FEB/todo/src/main/java/com/hrishikesh/todo/controller/ToDoController.java


2. Services : All the operations linked with controller is been implemented with additional logics in service layer, service layer also interact with repository layer.

Followings are the Glimse of the some of BussinessLogic Implemented in the Service:

2.1 USER ⬇️

Screenshot 2023-03-06 at 9 34 13 PM

2.2 POST ⬇️

Screenshot 2023-03-06 at 9 31 51 PM

To see Entire Service

[ https://github.com/HHrisHikesHH/SpringBoot/tree/main/FEB/todo/src/main/java/com/hrishikesh/todo/service](https://github.com/HHrisHikesHH/SpringBoot/tree/main/FEB/Instagram/src/main/java/com/hrishikesh/Instagram/service)


3. Repository : Repository layer interacts with Database(MySQL) and persist the changes requested, We extend the JPA repository to get the predefined function.Here inside JPARespository Interface we have another Interface called CRUDRepo with provides us some of the preDefined methods

Followings are the Glimse of the some of Custom methods Implemented in the Repository:

3.1 USER ⬇️

Screenshot 2023-03-06 at 9 37 02 PM

3.2 POST ⬇️

Screenshot 2023-03-06 at 9 37 18 PM

To see Entire Repository

https://github.com/HHrisHikesHH/SpringBoot/blob/main/FEB/todo/src/main/java/com/hrishikesh/todo/repository/ITodoRepository.java


4. DataBase : Here i have used mySQL : This database persist data even when the program is re-run.

Table of User contents

Screenshot 2023-03-06 at 10 31 23 PM

Table of Post contents

Screenshot 2023-03-06 at 10 32 30 PM

5. Util : Here i have done StringToJSONObjectTo{requiredObject} :

Followings are the Glimse of the util:

Screenshot 2023-03-07 at 3 34 24 PM

To see Entire util

https://github.com/HHrisHikesHH/SpringBoot/blob/main/FEB/Instagram/src/main/java/com/hrishikesh/Instagram/util/Util.java

Data Structure Used in Project

  • ArrayList
  • JSONArray
  • JSONObject

Project Summary

Project Result

➡️ : FindAll Users : localhost:8080/api/v1/user/get

Screenshot 2023-03-06 at 9 03 14 PM

➡️ : FindAll Active Users : localhost:8080/api/v1/user/get?password=pass

Screenshot 2023-03-06 at 10 35 26 PM

➡️ : FindById User : localhost:8080/api/v1/user/get?userId=10

Screenshot 2023-03-06 at 10 37 40 PM

➡️ : Create User : localhost:8080/api/v1/user/save

Screenshot 2023-03-06 at 9 02 33 PM

➡️ : Update User : localhost:8080/api/v1/user/update?userId=14

Screenshot 2023-03-06 at 9 02 42 PM

➡️ : Delete User : localhost:8080/api/v1/user/delete?userId=14

Screenshot 2023-03-06 at 9 03 09 PM

➡️ : FindAll Posts : localhost:8080/api/v1/post/get

Screenshot 2023-03-06 at 10 42 20 PM

➡️ : FindById Posts : localhost:8080/api/v1/post/get?postId=4

Screenshot 2023-03-06 at 10 42 41 PM

➡️ : Create Post : localhost:8080/api/v1/post/save

Screenshot 2023-03-06 at 10 52 37 PM

➡️ : Update Post : localhost:8080/api/v1/post/update?postId=11

Screenshot 2023-03-06 at 10 54 15 PM

➡️ : Delete Post : localhost:8080/api/v1/post/delete?postId=10

Screenshot 2023-03-06 at 10 52 18 PM

About

Instagram Post feature using RestApi in springBoot

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages