
Explore the architecture for a full-stack online device shopping app built with Spring Boot, Vue.js, and PostgreSQL, covering server and client sides, JWT security, and role-based CRUD operations.
Build a full stack device shop app with spring boot and vue js, featuring home page product listings, color options, user authentication, admin dashboard, role based access, payments, and purchases.
Install Java 11 as the course's chosen LTS, explain the six-month release cycle and current LTS (Java 17), download from Oracle after signing in, and install with default settings.
IntelliJ offers a learning curve and intuitive code completion for Java and Spring Boot, with a free community version and a licensed edition that adds TypeScript support and database tools.
Download and install PostgreSQL on your operating system. Use default configurations and set a password for the default user, then manage localhost servers with pgAdmin.
Download and install Git for your operating system by visiting the download page, choosing the right installer, and applying default configurations to begin your Go Java full stack workflow.
Install and configure Lumbergh in IntelliJ, enable annotation processing in settings to escape getter and setter methods for server-side code.
Download and install Postman to enable API testing, create API endpoints, and test them with Postman using various request methods and register to Postman to start using it.
Explore spring boot overview with annotations, beans, and configuration, and see how dependency injection creates loosely coupled, testable applications through constructor, setter, and field injection.
Explore REST controllers in spring boot, using http methods and mapping annotations like get mapping, post mapping, put mapping, and patch mapping to handle requests and responses via response entities.
Explore basic SQL concepts by creating databases and tables, defining primary keys, and performing insert, delete, and select operations on relational data.
Lombok basics for automatic getters, setters, equals, hashCode, and constructors, including data and value annotations, and how to create default and all-args constructors.
Learn git basics and GitHub collaboration, including version control, repositories, commits, staging, branches, pushing to remote, and pull requests for code reviews and merges.
Learn how to use @RequestParam annotation to extract query parameters, form parameters, and headers in REST APIs, set default values and required flags, and customize parameter names.
Learn how the PathVariable annotation extracts template variables from a rest API URI, maps them to method parameters, and uses required and optional settings to control their presence.
Learn how the @RequestBody annotation maps an HTTP request body to a domain object and leverages HTTP message converters to handle JSON and XML content types.
Outline backend architecture with database, core backend, and front end, enabling device CRUD, user auth via Spring Security and JWT, with Postgres, Hibernate, and JPA for ORM.
Create a spring boot project with spring initializer, choosing melon or gradle, Java's latest stable version, and dependencies: model, security, JPA, PostgreSQL, Lombok; import into intelligence and enable annotation processing.
Create and configure a PostgreSQL database with PgAdmin, set up a login role with admin privileges and a password, and prepare a database template and skimmer for deployment.
Configure application properties for a PostgreSQL data source in a Spring Boot project, including host, port, database name, credentials, and schema, and enable Hibernate auto-configuration with update for development.
Explore the entity diagram for a Go Java full stack app, modeling users, devices, and purchases with roles, device attributes, and purchase logs for an online shopping system.
Create a user model as a JPA entity mapped to the users table, with id, username, password, name, and a role enum (user or admin) for sign-in and sign-up.
Master id generation strategies in JPA and Hibernate, including default, auto, identity, sequence, and table generators. Learn through code examples and repository tests.
Create a device model as a JPA entity mapped to a database table, with name, description, price, create date, and a device type enum, using identity id generation and Lombok.
Explore Hibernate as an object-relational mapping tool, mapping classes to tables with entity and table annotations, and define one-to-one, one-to-many, many-to-one, and many-to-many relations with eager and lazy fetch strategies.
Create a purchase model as a JPA entity with user and device relations, including id, userId, deviceId, three time fields, price, color, and Lombok-generated accessors.
Create a user repository using Spring Data JPA's CRUD repository to automate basic operations and custom queries with @Query, @Modifying, and @Param.
Create a device repository class that extends JPA repository to enable automatic CRUD operations and query derivation from method names, with device as the model and long as the id.
Implement a purchase repository extending JPA repository to enable CRUD and custom join queries, returning purchase item projections with name, type, price, colour, and purchase time.
Implement a Spring user service with interface and implementation, handling save, delete, find by username, and change user role, using a password encoder and transactional updates.
Implement a device service class with its interface, wire in the device repository, and provide save, find by id, delete by id, and find all devices.
Implement the purchase service class in the business layer, wiring a purchase repository via dependency injection, and define save and find methods in the service interface and its implementation.
Explore how Spring Security authenticates users using HTTP filters and the basic authentication filter, decoding base64 credentials from the authorization header to verify with authentication providers and the provider manager.
Explore authorization architecture in spring security, where interceptors use access decision managers and voters—role, authenticated, remember-me—with default, consensus, and anonymous-based strategies to grant or deny access.
Explore how Spring Security handles authentication and authorization with default and custom configurations, including form login, basic headers, and role-based access. Understand sessions and CSRF protection in requests.
Explore implementing Spring Security authentication via filters and providers, customize the user details service, map roles to authorities, and build a user principal with a builder pattern and Lombok.
Configure spring security by implementing a custom authentication manager and user details service, and secure http requests with jwt, stateless sessions, cors, csrf protection, and endpoint authorization.
Install and configure JWT for authorization after authentication, replacing session IDs, and validate tokens on the server. Explore dependencies, algorithms (HMAC or RSA), and a one day token expiration.
Generate and validate JWT tokens for user authentication in a Spring Boot app, using a JWT provider, authorization header, and token expiration checks.
Implement a custom JWT authentication filter in a Spring Security setup, validating tokens per request, setting the security context, and ordering the filter before the username and password authentication filter.
Implements an authentication service using Spring Security to sign in users with username and password. Generates a JWT token and integrates an authentication manager with a custom user details service.
Learn to build Spring rest API methods with a rest controller and response entity, covering HTTP headers, status, body, and mappings for post, get, put, and delete.
Implement authentication by creating an authentication controller in Spring, exposing API endpoints for sign up and sign in, using an authentication service, validating unique usernames, and returning JWT tokens.
Implement a rest controller with endpoints to save, delete by id, and list devices under /api/device, injecting the device service and securing save/delete to admins.
Implement a purchase rest controller, expose /api/purchase endpoints, inject the purchase service, and create methods to save purchases and fetch the authenticated user's purchases.
Implement a REST controller for user operations by creating a controller class and mapping API endpoints. Inject the user service and access the session user via authentication principal.
In this course, we will create a new project like online-technology-shopping.
When I say online-technology-shopping application, we can think of it like that we will have a device-list page. Somehow users or customers will see these device-lists and they can buy one of them. Of course, at the end of it, this purchase will be stored and displayed later.
And we will implement this project using Spring Boot, VueJS, and PostgreSQL.
In our project, we will implement CRUD operations. These CRUD operations will be for users and devices. We will use users for user sign-in, sign-up and authorization operations. And we will use the devices for creating, editing, deleting device operations.
These CRUD operations will be requested from VueJS. So on the backend, we will create an infrastructure for these CRUD operations and on the frontend, we will serve them with the user interface.
Our project goes on with User and device operations.
Our main operations will be user login, register, book-list, create-device, delete-device etc.
Also, we will go on with the role based application. So we will use different roles like “Admin”, “User”. Then we will provide different authorizations to these users according to the role.
And this all things will be provided with a secure way in both Device and Spring Boot.
We will have two main components to implement our project.
These are server side and client side.
In Server Side:
Of course here, our main library will be Spring-boot. We will implement the whole infrastructure on the backend with the Spring boot. It will provide easy and fast configuration to us.
We will implement the Model view controller architecture on our project.
Spring-security will be one of the main topics in our application. Also, we will use JWT to provide security.
In Spring Boot, Data will be presented to the client as an API call so Spring Rest Controller will be used to handle it.
We will use PostgreSQL as Database. We can use other databases also but at the end of it we will deploy our codes to Heroku. Postgresql can be used on Heroku for free so we chose that.
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 the Lombok library to clear code.
You know that we don't want to implement getter, setter, equals and hashcode. So we can escape it using Lombok @Data or @Value annotation.
We will use Maven To handle all dependencies on the server side. Actually, here we can also use Gradle. Gradle provides better performance than maven but Maven is the most common one. So we'll go on with maven.
For our all services, we will create cloud deployment with Heroku. Heroku is an amazing free framework. We can deploy our spring-boot projects with some configuration over github easily. So At the end of the course, we will have an application on production and we will have a code on github that is accessible by everyone.
That's all about Server side.
Let's talk about Client Side.
We will create a vueJS application on the client side and it will provide a cool user-interface. So we will create some pages like home-page, admin dashboard, login page and register-page. Then we will assign the server apis to these pages and we will consume and produce the data from the user-interface easily and user friendly.
At the end of it, we will build it and we will serve it to heroku also. So at the end of the course, we will have a live application on production.
Last but not least, we will implement security and authorization on VueJS also. We will work with different roles and according to these roles, we will implement unauthorized and not-found pages on the user interface also.
We will see the details of them one by one.
For now, that’s all.
Thank you.