For further reference, please consider the following sections:
- Official Apache Maven documentation
- Spring Boot Maven Plugin Reference Guide
- Create an OCI image
- Deploying SpringBoot apps
- Spring Web
- Spring Data Redis (Access+Driver)
- Spring Data JPA
- Spring Configuration Processor
- Spring Session
- Spring Security
- OAuth2 Client
- Validation
The following guides illustrate how to use some features concretely:
- Building a RESTful Web Service
- Serving Web Content with Spring MVC
- Building REST services with Spring
- Messaging with Redis
- Accessing Data with JPA
- Accessing data with MySQL
- Securing a Web Application
- Spring Boot and OAuth2
- Validation
- Braintree Payments
- JPA Buddy - ✨ useful extension for IntelliJ Ultimate IDE, when working with JPA + Hibernate
This is the primary database. All DateTimes are stored and queried in UTC only. (Hint: USE java.time.Instant
as Type
for all Datetime fields). Handle timezone conversion on your Frontend! For your convenience, I have included a
mysqldump file which contains sample data for testing.
-
CREATE new schema called
wedemy
(any name is OK), with charsetutf8mb4
. -
Springboot will create all tables and indexes automatically on the Very First launch.
-
To maintain consistent time-zone (UTC) with your Java server, ensure your JDBC connection URL has parameter
connectionTimeZone=UTC
. See example below. For native @Query's, use UTC_TIMESTAMP() or UTC_DATE().spring.datasource.url=jdbc:mysql://localhost:3306/wedemy?connectionTimeZone=UTC # OR, set this spring.jpa.properties.hibernate.jdbc.time_zone=UTC
Here is the ERD Diagram for MySQL Db used in the project:
This project uses Redis for 2 main tasks: Caching, and Storing login sessions. You can download latest Redis (macOS & Linux) from https://redis.io/download. Windows users may download the latest native installer (.msi) from this GitHub repo. Alternatively, you could pull its official Docker image. Another option you could try is Redis Cloud at: https://redis.com/try-free/. Remember to replace Redis credentials inside application.yml (or in your ENV variables).
Tip 💡 | Redis now has an OFFICIAL cross-platform desktop GUI client: RedisInsight. Download it free here |
---|