|
所在平台: Udemy |
课程主页: https://www.udemy.com/course/restfull-api-web-services-with-spring-boot-and-react-js/
课程评论:没有评论
**课程名称:** Restful API with Spring Boot and React (Redux, Router, Hooks) **课程概述:** 本课程将指导学员从零开始构建一个完整的项目,该项目将集成Spring Boot、React和MySQL技术栈。核心内容将围绕用户操作的CRUD(创建、读取、更新、删除)功能实现。 **项目详情:** * **后端(Server Side - Spring Boot):** * 采用Spring Boot构建,遵循Model-View-Controller (MVC) 架构模式。 * **Model:** 创建实体类,用于表示数据库模型。 * **Repository:** 为实体类创建持久化Repository,利用JPA Repository和Crud Repository处理常见的数据库操作(如保存、更新、查找、删除)。 * **Services:** 在Service层调用Repository,封装业务逻辑。 * **Controllers:** 使用Spring Rest Controller处理来自客户端的API请求,并将数据以API形式返回。 * **数据库:** 使用MySQL作为数据存储。 * **ORM:** 结合Java Persistence API (JPA) 和Hibernate实现对象关系映射,将数据库表映射到Java对象。 * **代码优化:** 使用Lombok库(如@Data, @Value注解)简化Java代码,避免编写重复的getter, setter, equals和hashCode方法。 * **构建工具:** 使用Gradle管理后端项目依赖。 * **前端(Client Side - React):** * 利用React构建用户界面,React运行在Node.js环境中。 * **API 调用:** 创建Service类,负责通过HTTP与后端API进行通信,发送请求并接收响应。 * **组件渲染:** 在React组件中调用Service层获取数据,并进行渲染。 * **用户界面功能:** * **用户操作:** * 展示商品列表(可购买)。 * 实现用户注册、登录和个人资料页面。 * **管理员操作:** * 实现用户CRUD操作。 * 实现管理员的身份验证(Authentication)和授权(Authorization)。 * **状态管理与路由:** 集成Redux进行状态管理,并使用React Router实现页面路由。 * **Hooks:** 利用React Hooks优化组件逻辑。 **核心技术栈:** * **后端:** Spring Boot, Spring Rest, JPA, Hibernate, MySQL, Lombok, Gradle * **前端:** React, Redux, React Router, Hooks, Node.js **项目重点:** * 实现基于Spring Boot和React的端到端应用开发。 * 熟练掌握RESTful API的设计与实现。 * 用户认证与授权的安全性保障。 * 角色基础的应用。 * CRUD操作的完整流程。
We will create a new project in this course.And we will implement this project with using Spring Boot, React, and MYSQL.In our project, we will implement CRUD operations. And these CRUD operations will be requested from React.Then This requests will be handled from Spring Boot.Our project goes on User operations. Our main operations will be user login, register, profile and user list.Also, we will go on with role based application.And this all things will be provided with secure way in both React and Spring Boot side.We will have two main components to implement our project.These are server side and client side.In Server Side:Spring Boot will be main thing.Model View Controller structure will be implemented with using Spring Boot.Our MVC structure will work like that:First of all, the entity classes will be created under model package.Later, if model class is permanent, we will create a repository for it.Then we will call repository from services.Finally, we will call services from from controllers. In Spring Boot, Data will be presented to client as API call so Spring Rest Controller will be used to handle it.We will use MySQL as Database.We will also use Object Relational Mapping with Java Persistence API and Hibernate.You know, We can map our database tables to objects with hibernate.We will use JPA Repository and Crud Repository in Spring Boot. So these repository templates will handle common database operations like save, update, find, delete.With Spring Boot, we will also use Lombok library to clear code.You know that we don't want to implement getter, setter, equals and hash code. So we can escape it using Lombok @Data or @Value annotation.We will use Gradle To handle all dependencies on server side.That's all about Server side.Let's talk about Client Side.React will be the main client controller.React works on nodeJS.In react, we will consume server side data with api calls.To do it, we will create service classes.In service: We can connect to server side and we can send requests or we can get responses from server side with http.Then, we will call service data from components and we will render them.Our User interface panel is contructed from admin operations and user operations.In user operations:, First of all, we will display test product data on home page. And these products can be purchased by users.Secondly, we will implement login, register and profile pages for users.In admin operations:,We will implement user CRUD operations.And of course, we will implement authentication and authorization for admin operations.