0% found this document useful (0 votes)
3 views29 pages

Product Java Qtns Part2

The document contains a comprehensive list of interview questions covering various topics in software development, particularly focusing on Spring, Spring Boot, microservices, cloud technologies, and Java features. It includes questions about design patterns, RESTful web services, dependency injection, and practical coding challenges. The questions are aimed at assessing both theoretical knowledge and practical skills in programming and system design.

Uploaded by

shivthilak1994
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views29 pages

Product Java Qtns Part2

The document contains a comprehensive list of interview questions covering various topics in software development, particularly focusing on Spring, Spring Boot, microservices, cloud technologies, and Java features. It includes questions about design patterns, RESTful web services, dependency injection, and practical coding challenges. The questions are aimed at assessing both theoretical knowledge and practical skills in programming and system design.

Uploaded by

shivthilak1994
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

Interview Questions

Difference between spring vs spring boot?

What is inside starter package?

Explain the Maven lifecycle

How spring creates beans?

What is microservice?

What is different between SOA vs microservice?

Which cloud technology have you worked?

Azure related questions as I worked on azure

Design patterns

Explain SOLID with examples

What is docker?

What is

kubernetes?

Have you created dockerfile?

have you configured kubernetes?

Have you worked on linux commands?

Difference between REST vs http?

What is CAP theorem?

previous project architecture

questions on java 8 stream API

Java 8 features

Why default method has been added in Java 8 ?

how to remove duplicate element from an array ?

reverse a string and remove white spaces

CI CD pipeline flow

Docker file

Main components of Kubernetes cluster

Design pattern used in Spring

Design Pattern used in your projects

Advantages and disadvantages of Microservices


How to deploy microservices?

What is API gateway

Why we use Reactive streams ?

Previous Project complete flow (front end to backend)

What is docker container?

What

is Streams in java?

Calculate the average of all the elements in below code snippet using streams:-

List<List<Integer>> marksByStudents = [Link] (

[Link] (60, 70, 80),

[Link](50, 70, 85),

[Link](65, 70, 75)

);

write a program to reverse the linked list.

Singleton, Factory, Proxy Pattern, etc

Microservices advantages

Spring s ="energy" ->

print first non repeating character

Spring s ="energy";

String s1 = "enemy"; -> print uncommon characters

query to print 3rd largest salary

query to print no. of employees in each department.

design patterns used.

communication between microservices

spring profiles

How to read multiple properties files


Autowiring annotation

JPA annotations

@Query Annotation

RestTemplate methods.

Reading HTTP headers and cookies in spring

excluding auto configuration of some classes in

springboot

Exception Handling in Spring

Microservices advantages

2. Spring s ="energy" -> print first

non repeating character

3. Spring s ="energy"; -> print uncommon characters

String s1 = "enemy";

4. query to print 3rd largest salary

5. query to print no. of employees in each department.

6. design patterns used.

7. communication between microservices

8. spring profiles

9. How to read multiple properties files

10.

Autowiring annotation

11. JPA annotations

12. @Query Annotation

13.

RestTemplate methods.

14. Reading HTTP headers and cookies in spring

15. excluding auto configuration of some classes in

springboot

16. Exception Handling in Spring

Questions for Raju


Have you implemented Restful webservices in your previous projects? If so, how did you implement?

What are microservices and any projects implemented so far?

How does Restful webservices communicate?

How is transaction management handled in spring?

What is Dependency Injection?

Constructor injection vs Setter Injection? Which is preferred and why?

List vs set differences?

How to transform a list of objects in java?

Java 8 features

How do you configure environment specific properties?

Reactor streams and

RestTemplate

Annotations in JPA

design patterns

How do you keep up with latest technologies?

How to create immutable classes

How do you handle JSON response in webservices

How to ignore certain values of JSON response

Relationships in Hibernate - How do you configure

one to one mapping - what happens if there is a bidirectional dependency

Project Architecture

Employee list given - filter employees with salary more than 30k

Check whether two strings are Anagram or not

Steps for creating Restful webservice

Equals &

Hashcode , what hashcode does and what is hash collision

Java 8 features and what features are used in your project

Exceptional Handling in spring

explain functional programming


use cases of API-Gateway Design pattern

oops concept and example

functional interface and example

loose coupling and example and implementation

thread safe

arraylist

concurrent

hashmap

collections in java

caching and its techniques (examples)

least frequency used cache

async vs sync transactions

system design question (appointment and

updation-whole technical flow and implementation)

Explain last project

Explain Design patterns by category

write the code to create a singleton class. Explain how object is created

Which line in singleton class code can give error if 2 requests access the same code

write the code to create an immutable class in java, create other mutable

class and use its object in immutable class maintaining immutability

Implement linked list data structure in java . Write code to insert and display elements in a linked list

How

hashmap works internally. How distinct key implementation is done

what is Docker

Write a code to create a rest

api and return a string with response status 200

Explain Spring MVC

Difference between synchronous and asynchronous calls

H2 database

JPA/Hibernate

create restful webservices & how restful


ws communicate

explain

jwt

how to fetch data from

appliction properties file

Java 8 features

Given a

studentList, add the student data in map with key as

StudentId, value Student data.

LinkedList- program to check if loop in

Linkedlist

SQL Joins

put vs patch mapping diff

Ehcache in hibernate

Composite primary key in hibernate

Serialization

Collections : LinkedList &

Arraylist difference

Cache - annotations

Builder design pattern

Explain project architecture

nosql & relational

db diff and why relational was being used in project

Challenges for Microservices

DB -

sql queries:

1. id, name, salary, email,

current_city --> employee table,

emp_id, designation --> designation

find no of
employees wit salary more than 20000

find no of employees in

each with salary more than 20000

find no of managers in each city

BY S N

PrasadRao

Challenges

print list item with index using streams

print unique character using streams

arr[1,2,3,4,5,6], target=4, required

output=[1,3]

Print the count of minimum duplicate number in array [1,2,2,2,3,3,4,4,4,4] output= 2

int a[] = {1,2,2,3,3,4,4,5};

Map<Integer,Integer> hm = new HashMap<Integer,Integer>();

for(Integer in:a) {

[Link](in,

[Link](in)?[Link](in)+1:1);

[Link](
[Link]().stream().sorted([Link]([Link]())).filter(k->

[Link]()>1).findFirst().get().getKey());

functional interface in java 8

what is

hashset?

What is

final,Finally,Finilizer ?

how

ioc works internally?

status codes

annotations you worked in spring boot

how many microservices you created.

make an architecture of your microservice

write pseudo code to fine employee list by dept id

if you

have to create a microservice then which technology & DB will choose & why?

how to set traffic level?

Solid

princples.

How to create docker image

How you are implementing security in microservices.

Thread life cycle

wait & join difference

two diff array merge it in diff array and sort it with your logic
Interview Questions

Difference between spring vs spring boot?

What is inside starter package?

Explain the Maven lifecycle

How spring creates beans?

What is microservice?

What is different between SOA vs microservice?

Which cloud technology have you worked?

Azure related questions as I worked on azure

Design patterns

Explain SOLID with examples

What is docker?

What is kubernetes?

Have you created dockerfile?

have you configured kubernetes?


Have you worked on linux commands?

Difference between REST vs http?

What is CAP theorem?

previous project architecture

questions on java 8 stream API

Java 8 features

Why default method has been added in Java 8 ?

how to remove duplicate element from an array ?

reverse a string and remove white spaces

CI CD pipeline flow

Docker file

Main components of Kubernetes cluster

Design pattern used in Spring

Design Pattern used in your projects

Advantages and disadvantages of Microservices

How to deploy microservices?


What is API gateway

Why we use Reactive streams ?

Previous Project complete flow (front end to backend)

What is docker container?

What is Streams in java?

Calculate the average of all the elements in below code snippet using streams:- List>
marksByStudents = [Link] (

[Link] (60, 70, 80),

[Link](50, 70, 85),

[Link](65, 70, 75)

);

write a program to reverse the linked list.

Singleton, Factory, Proxy Pattern, etc

Microservices advantages

Spring s ="energy" -> print first non repeating character

Spring s ="energy"; String s1 = "enemy"; -> print uncommon characters

query to print 3rd largest salary

query to print no. of employees in each department.


design patterns used.

communication between microservices

spring profiles

How to read multiple properties files

Autowiring annotation

JPA annotations

@Query Annotation

RestTemplate methods.

Reading HTTP headers and cookies in spring

excluding auto configuration of some classes in springboot

Exception Handling in Spring

Microservices advantages

2. Spring s ="energy" -> print first non repeating character

3. Spring s ="energy"; -> print uncommon characters

String s1 = "enemy";
4. query to print 3rd largest salary

5. query to print no. of employees in each department.

6. design patterns used.

7. communication between microservices

8. spring profiles

9. How to read multiple properties files

10. Autowiring annotation

11. JPA annotations

12. @Query Annotation

13. RestTemplate methods.

14. Reading HTTP headers and cookies in spring

15. excluding auto configuration of some classes in springboot

16. Exception Handling in Spring

Questions for Raju

Have you implemented Restful webservices in your previous projects? If so, how did you implement?

What are microservices and any projects implemented so far?


How does Restful webservices communicate?

How is transaction management handled in spring?

What is Dependency Injection?

Constructor injection vs Setter Injection? Which is preferred and why?

List vs set differences?

How to transform a list of objects in java?

Java 8 features

How do you configure environment specific properties?

Reactor streams and RestTemplate

Annotations in JPA

design patterns

How do you keep up with latest technologies?

How to create immutable classes

How do you handle JSON response in webservices

How to ignore certain values of JSON response


Relationships in Hibernate - How do you configure

one to one mapping - what happens if there is a bidirectional dependency

Project Architecture

Employee list given - filter employees with salary more than 30k

Check whether two strings are Anagram or not

Steps for creating Restful webservice

Equals & Hashcode , what hashcode does and what is hash collision

Java 8 features and what features are used in your project

Exceptional Handling in spring

explain functional programming

use cases of API-Gateway Design pattern

oops concept and example

functional interface and example

loose coupling and example and implementation

thread safe arraylist

concurrent hashmap
collections in java

caching and its techniques (examples)

least frequency used cache

async vs sync transactions

system design question (appointment and updation-whole technical flow and implementation)

Explain last project

Explain Design patterns by category

write the code to create a singleton class. Explain how object is created

Which line in singleton class code can give error if 2 requests access the same code

write the code to create an immutable class in java, create other mutable class and use its object in
immutable class maintaining immutability

Implement linked list data structure in java . Write code to insert and display elements in a linked list

How hashmap works internally. How distinct key implementation is done

what is Docker

Write a code to create a rest api and return a string with response status 200

Explain Spring MVC


Difference between synchronous and asynchronous calls

H2 database

JPA/Hibernate

create restful webservices & how restful ws communicate

explain jwt

how to fetch data from appliction properties file

Java 8 features

Given a studentList, add the student data in map with key as StudentId, value Student data.

LinkedList- program to check if loop in Linkedlist

SQL Joins

put vs patch mapping diff

Ehcache in hibernate

Composite primary key in hibernate

Serialization

Collections : LinkedList & Arraylist difference


Cache - annotations

Builder design pattern

Explain project architecture

nosql & relational db diff and why relational was being used in project

Challenges for Microservices

DB - sql queries:

1. id, name, salary, email, current_city --> employee table, emp_id, designation --> designation

find no of employees wit salary more than 20000

find no of employees in each with salary more than 20000

find no of managers in each city

BY S N PrasadRao

Challenges

print list item with index using streams

print unique character using streams

arr[1,2,3,4,5,6], target=4, required output=[1,3]

Print the count of minimum duplicate number in array [1,2,2,2,3,3,4,4,4,4] output= 2


int a[] = {1,2,2,3,3,4,4,5};

Map hm = new HashMap();

for(Integer in:a) {

[Link](in, [Link](in)?[Link](in)+1:1);

[Link](

[Link]().stream().sorted([Link]([Link]())).filter(k->
[Link]()>1).findFirst().get().getKey());

functional interface in java 8

what is hashset?

What is final,Finally,Finilizer ?

how ioc works internally?

status codes

annotations you worked in spring boot

how many microservices you created.

make an architecture of your microservice


write pseudo code to fine employee list by dept id

if you have to create a microservice then which technology & DB will choose & why?

how to set traffic level?

Solid princples.

How to create docker image

How you are implementing security in microservices.

Thread life cycle

wait & join difference

two diff array merge it in diff array and sort it with your logic

Interview Questions

Difference between spring vs spring boot?

What is inside starter package?

Explain the Maven lifecycle

How spring creates beans?

What is microservice?
What is different between SOA vs microservice?

Which cloud technology have you worked?

Azure related questions as I worked on azure

Design patterns

Explain SOLID with examples

What is docker?

What is kubernetes?

Have you created dockerfile?

have you configured kubernetes?

Have you worked on linux commands?

Difference between REST vs http?

What is CAP theorem?

previous project architecture

questions on java 8 stream API

Java 8 features
Why default method has been added in Java 8 ?

how to remove duplicate element from an array ?

reverse a string and remove white spaces

CI CD pipeline flow

Docker file

Main components of Kubernetes cluster

Design pattern used in Spring

Design Pattern used in your projects

Advantages and disadvantages of Microservices

How to deploy microservices?

What is API gateway

Why we use Reactive streams ?

Previous Project complete flow (front end to backend)

What is docker container?

What is Streams in java?


Calculate the average of all the elements in below code snippet using streams:- List>
marksByStudents = [Link] (

[Link] (60, 70, 80),

[Link](50, 70, 85),

[Link](65, 70, 75)

);

write a program to reverse the linked list.

Singleton, Factory, Proxy Pattern, etc

Microservices advantages

Spring s ="energy" -> print first non repeating character

Spring s ="energy"; String s1 = "enemy"; -> print uncommon characters

query to print 3rd largest salary

query to print no. of employees in each department.

design patterns used.

communication between microservices

spring profiles

How to read multiple properties files

Autowiring annotation
JPA annotations

@Query Annotation

RestTemplate methods.

Reading HTTP headers and cookies in spring

excluding auto configuration of some classes in springboot

Exception Handling in Spring

Microservices advantages

2. Spring s ="energy" -> print first non repeating character

3. Spring s ="energy"; -> print uncommon characters

String s1 = "enemy";

4. query to print 3rd largest salary

5. query to print no. of employees in each department.

6. design patterns used.

7. communication between microservices

8. spring profiles

9. How to read multiple properties files


10. Autowiring annotation

11. JPA annotations

12. @Query Annotation

13. RestTemplate methods.

14. Reading HTTP headers and cookies in spring

15. excluding auto configuration of some classes in springboot

16. Exception Handling in Spring

Questions for Raju

Have you implemented Restful webservices in your previous projects? If so, how did you implement?

What are microservices and any projects implemented so far?

How does Restful webservices communicate?

How is transaction management handled in spring?

What is Dependency Injection?

Constructor injection vs Setter Injection? Which is preferred and why?

List vs set differences?


How to transform a list of objects in java?

Java 8 features

How do you configure environment specific properties?

Reactor streams and RestTemplate

Annotations in JPA

design patterns

How do you keep up with latest technologies?

How to create immutable classes

How do you handle JSON response in webservices

How to ignore certain values of JSON response

Relationships in Hibernate - How do you configure

one to one mapping - what happens if there is a bidirectional dependency

Project Architecture

Employee list given - filter employees with salary more than 30k

Check whether two strings are Anagram or not

Steps for creating Restful webservice


Equals & Hashcode , what hashcode does and what is hash collision

Java 8 features and what features are used in your project

Exceptional Handling in spring

explain functional programming

use cases of API-Gateway Design pattern

oops concept and example

functional interface and example

loose coupling and example and implementation

thread safe arraylist

concurrent hashmap

collections in java

caching and its techniques (examples)

least frequency used cache

async vs sync transactions

system design question (appointment and updation-whole technical flow and implementation)
Explain last project

Explain Design patterns by category

write the code to create a singleton class. Explain how object is created

Which line in singleton class code can give error if 2 requests access the same code

write the code to create an immutable class in java, create other mutable class and use its object in
immutable class maintaining immutability

Implement linked list data structure in java . Write code to insert and display elements in a linked list

How hashmap works internally. How distinct key implementation is done

what is Docker

Write a code to create a rest api and return a string with response status 200

Explain Spring MVC

Difference between synchronous and asynchronous calls

H2 database

JPA/Hibernate

create restful webservices & how restful ws communicate

explain jwt
how to fetch data from appliction properties file

Java 8 features

Given a studentList, add the student data in map with key as StudentId, value Student data.

LinkedList- program to check if loop in Linkedlist

SQL Joins

You might also like