Everything You Need to Learn About Java
From OOPs to GenAI - Your Shortcut to Java Mastery
Table of contents
- Roadmap you need to know:
- And that's a wrap! Phew! You've made it through all of it. Now, feel free to circle back to the top whenever you need a quick revision. After all, it's totally normal to not remember everything in one go. Don’t hesitate to hop back to where you’re stuck and pick up right from there!
Roadmap you need to know:
Object Oriented Programming in Java
Advanced Java and Java 8 Programming
JUnit and Enterprise Architecture
Java Persistence
Web Development - Servlet and JSP
Spring Core
Spring ORM
Spring MVC
Java with GenAI
Unit 1: OOPs in Java
Java Introduction: Java Architecture and Features, Java Keywords, Datatypes and Operators, Control Structures
Class and Objects: Class and Object, Getters and Setters, Access Modifiers, Garbage Collector and Methods
Arrays and Strings: Array, String, String Buffer and StringBuilder in Java
Class Relationship: Class Association, Inheritance and Method Overriding, Abstract Keyword
Binding and Interface: Static and Dynamic Binding, Static and Final keyword, Interface and Design Patterns
Unit 2: Advanced Java and Java8
→Advanced Java
Exception Handling : Exception Types and Exception Hierarchy, Catch and Handle exceptions, Design Custom Exceptions
Collection API: Part 1: Collections and use of collections, advantages of using collections and collection hierarchy, List and Set implementations
Collection API: Part 2: Map implementation, comparator and comparable interfaces
Multithreading: Multithreading/Concurrency, Thread: Creation, Life-cycle, Priorities, Stack Implementation, Methods, Synchronization, Inter-thread Communication
Java 8 Features: Interface, Annonymous Inner Classes Lambda Expressions, Stream API, Functional Interfaces, Date and Time API
→ Software Development Practices
SCM using Git: Intro to Version Control, Intro to Git, Common Git Terms, Working with Git and GitLab
Code Quality: Coding standards, Importance of Code Review, Type of code review, Automated Code Review tools, SonarQube usages, SonarLint as eclipse plugin for code analysis
Sonar Qube: Code Quality Automation and its benefits, Types of Code Quality, Static code analysis, Difference between Static Code Analysis and Dynamic Code Analysis, Tools available for Code Quality, State SonarQube features and its benefits
Sonar Qube Components: Architecture of SonarQube, Processes of SonarQube Server, Database of SonarQube, SonarQube Plugins, How to use code analysis using SonarQube Scanners, SonarQube Workflow, code analysis using SonarLint in Eclipse
Working with Sonar Qube: SonarQube dashboard overview, Manage projects using Project tab, Rules and its fields, Quality profiles, Quality gates and its types
Maven Introduction: Scope of Build Automation, Build Tool and its benefits, Life cycle of build tool and its phases
Maven Structure: Structure of Maven, pom.xml and its elements, super POM, minimal POM and effective POM, archetype and its types, Understand how to create a maven project based on the archetypes and executes with different goals
Maven Repositories and Dependencies: Describe the way to store set of artifacts as Maven repositories, Local Repository, Central Repository, Remote Repository, Maven Dependency and configuring the dependencies in pom.xml, Dependency hierarchy; transitive dependency; dependency management, Types of dependency scope, Process of dependency search sequence
Maven PlugIn: Categories and types of plugins, MOJO and to configure the same in pom file, configuration of plugin in pom file, Surefire plugin and its implementation
Input Output: Writing data to character & byte streams, chain of IO streams and serialization
Bravo! You've made it this far! 😉 Step ahead only if you're ready to master the road to greatness — yes, it's challenging, but you've already tackled the tough stuff. From here on, things will smoothen out a little (well, just a little). Let’s go!
Unit 3: JUnit and Enterprise Architecture
JUnit 5: Unit Testing Conceps using x-testing framework, JUnit 4 v/s JUnit 5, Architecture, Installation, JUnit5 Annotations
Enterprise Architecture & Patterns: Java EE Patterns, Architectural Patterns, Patterns of Enterprise Architecture (EA)
HTML, CSS & Javascript: Web based Application Programming, Tools, GUI, HTTP, Web page construction
XML & XSLT: XML features and purpose, rules for well-formed XML, Key features of the XML Schema, XML validation and transformation (XML and XSLT)
Unit 4: Java Persistence
JDBC: Role of JDBC Driver, JDBC API (Connection to DB), CRUD operations using Statement interface, CRUD operations using Prepared Statement interface
Introduction to ORMJPA: JPA and bootstrapping of JPA, CRUD operations on entities using JPA, entity life cycle
JPA Entity Relationships: OneToOne, ManyToOne, OneToMany, ManyToMany, multiplicities b/w entities
JPQL: Select Operation ,DML Operations, Named Queries, Join Queries, Aggregation Queries
Unit 5: Web Development - Servlet and JSP
Web Development - Servlet Programming: Servlet Life Cycle, Servlet Context and Servlet Config, Request Dispatcher, Session Management
Web Development - JSP: Dynamic web page using JSP, JSP lifecycle, JSP scripting, and directive elements to create web pages, implicit objects and action elements to create web pages
Web Development - JSTL: Dynamic web pages using: JSTL core tags and JSTL formatting tags
Unit 6: Spring Core
Spring Core: container component model, IOC using dependency injection and autowiring, spring core annotations, loosely coupled application using Spring IOC container witH XML and Java
Spring Test: JSR-330 Annotations, JSR-250 Annotations, Transactional and Rollback Annotations
Unit 7: Spring ORM
Spring ORM: Spring Core with JPA Integration**,** Spring Core with JPA Integration with Transaction Manager, Transaction Propagation, Transactional Attributes, Spring ORM Integration, Spring ORM Transaction Management
Spring JPA Data: Spring JPA Integration, Spring JPA Data, Spring JPA Data Repositories, Spring JPA Data Repositories, Spring JPA Data writing Queries
Unit 8: Spring MVC
Spring MVC Introduction: MVC - Model2 Architecture, Spring MVC and Front view Controller Configuration, Context Configuration, ContextHierarchy, ViewResolvers
Spring Form: Spring MVC application using Spring form and form elements, Spring Model v/s Request scope, validations, Exception Handlers
Spring MVC JPA Introduction: Session Attributes, Spring MVC with Spring JPA Integration, Spring MVC with Spring JPA Data Integration
Spring Rest: Services using Spring REST, Spring REST Integration with Spring JPA Data, RestTemplate
Spring Security Part 1: Customizing Access Denied Handler View, Customizing Login Page, Authencation Provider, Spring MVC application implementing Spring Security with JDBC authentication provider
Spring Security Part 2: Implement security in application using Spring Security Expression Language, applications to detect concurrent sessions, Implement security at Service layer of an application
Spring Boot: Spring Boot Application microservices, Configuring Jetty container as a default container, Content negotiation
Unit 9: Java with GenAI
Introduction to Generative AI: Basics of Generative Al, Use Cases of Generative Al, Large Language Models, Generative Al tools, Prompt engineering, Prompt design Strategies/ Techniques, Issues/ concerns and considerations
Generative AI in Java - Java with VertexAI
Steps to Integrate Java with Vertex AI
Set Up Google Cloud Environment:
Create a Google Cloud project.
Enable Vertex AI API.
Create a service account with Vertex AI User and Storage Object Viewer roles.
Download the service account JSON key.
Install and initialize Google Cloud SDK (
gcloud init
).
Set Up Java Development Environment:
Ensure Java 8+ is installed.
Install Apache Maven (if not already installed).
Add Dependencies to
pom.xml
<dependency>
<groupId>com.google.cloud</groupId>
<artifactId>google-cloud-vertex-ai</artifactId>
<version>1.0.0</version>
</dependency>
<dependency>
<groupId>com.google.cloud</groupId>
<artifactId>google-cloud-storage</artifactId>
<version>2.4.0</version>
</dependency>
<dependency>
<groupId>com.google.auth</groupId>
<artifactId>google-auth-library-oauth2-http</artifactId>
<version>0.28.0</version>
</dependency>
Authenticate Using Service Account:
Set the
GOOGLE_APPLICATION_CREDENTIALS
environment variable to your service account JSON key.On Linux/Mac:
export GOOGLE_APPLICATION_CREDENTIALS="/path/to/service-account-key.json"
- On Windows:
set GOOGLE_APPLICATION_CREDENTIALS=C:\path\to\service-account-key.json
- Java Code to Interact with Vertex AI:
GoogleCredentials credentials = GoogleCredentials.fromStream(new FileInputStream("path/to/service-account-key.json"));
try (PredictionServiceClient predictionServiceClient = PredictionServiceClient.create()) {
// Prepare the prediction request
PredictRequest predictRequest = PredictRequest.newBuilder()
.setModel("your-model-id")
.setInstances("{ \"instances\": [{ \"input\": \"Hello Vertex AI\" }]}") // Example input
.build();
// Get predictions
PredictResponse response = predictionServiceClient.predict(predictRequest);
System.out.println(response.getPredictionsList());
}
Run Your Java Application:
- Use Maven or your IDE to run the application:
mvn exec:java -Dexec.mainClass="VertexAIExample"