Java Beginner
Hub › Java › Beginner
What you'll build
A single HTTP endpoint at GET /items served by a Spring Boot application. It returns a fixed list of three items as JSON, runs locally on port 8080, and answers a curl from a second terminal. No database, no auth, no front end — just a JVM process, an embedded Tomcat, and one controller. Building this is the point of every page in this tier.
The ladder
- 01 Install JDK 21 — get the JVM toolchain so every later page can run.
- 02 Install Maven — the build tool we use to compile and run the Spring app.
- 03 Classes and primitives — the minimum vocabulary to read Java code.
- 04 Methods — Java's reusable unit at this tier.
- 05 Records — modern data classes that will become our response shape.
- 06 Collections —
List.of(...)for the fixed data we return. - 07 What Spring Boot is — the framework that does the routing and the Tomcat plumbing.
- 08 Create a Spring Boot project — generate the project on Spring Initializr.
- 09 First controller — wire one path to one method with
@RestController. - 10 Returning JSON from a record list — return a
List<Record>and let Spring serialize it. - 11 GET /items — the tier exit artifact.
Start → 01 Install JDK 21