Java Architecture Interview Questions

Java interview questions

Java releases and major features introduced

  • Version
  • Released year
  • Code Name
  • Important features
  • 1995
  • Oak
  •    JDBC (Java Database Connectivity
  •  Inner Classes
  •      Java Beans
  •  RMI (Remote Method Invocation)
  • Reflection (introspection only)
  • Playground
  •    * Collections framework.
  • * Java String memory map for constants.
  •  Just In Time (JIT) compiler.
  • Jar Signer for signing Java ARchive (JAR) files.
  • Policy Tool for granting access to system resources.
  • Java Foundation Classes (JFC) which consists of Swing 1.0, Drag and Drop, and Java 2D class libraries
  • Java Plug-in
  • Scrollable result sets, BLOB, CLOB, batch update, user-defined types in JDBC.
  •  Audio support in Applets.
  • Kestrel
  • Java Sound
  •  Jar Indexing
  • A huge list of enhancements in almost all the java area.
  • Merlin
  •    XML Processing
  • Java Print Service
  • Logging API
  •  Java Web Start
  •  JDBC 3.0 API
  •  Assertions
  •  Preferences API
  • Chained Exception
  • IPv6 Support
  • Regular Expressions
  •  Image I/O API
  • September 30, 2004
  • Tiger
  •     Generics
  •  Enhanced for Loop
  • Autoboxing/Unboxing
  • Typesafe Enums
  •  Varargs
  •  Static Import
  • Metadata (Annotations)
  • Instrumentation
  • December 11, 2006
  • Mustang
  • Scripting Language Support
  •  JDBC 4.0 API
  •  Java Compiler API
  •  Pluggable Annotations
  •  Native PKI
  • Java GSS
  • Kerberos and LDAP support.
  •  Integrated Web Services.
  •  Lot more enhancements.
  • July 28, 2011
  • Dolphin
  •   Strings in switch Statement
  • Type Inference for Generic Instance Creation
  •  Multiple Exception Handling
  • Support for Dynamic Languages
  •  Try with Resources
  •  Java nio Package
  • Binary Literals, underscore in literals
  •  Diamond Syntax
  •  Automatic null Handling

Design related questions

1. Tell me about the projects, technologies used and challenges faced.

2. Tell me about X problem (from answer to previous question) and how did you solve it.

3.  Can you build a ORM framework, what are the things that a ORM framework solves.

4. Why spring is so popular and when is it recommended.

5. How spring annotations work.

6. If you have to build spring like framework with annotations, how do you do it?

7. How connection pooling works in hibernate

8. Can you design a MVC framework, what are the aspects/concerns we need to take care of.

9. Explain me the X project (from your profile) and how contribution.

10. First level cache, 2nd level cache how does it work.

11. What is the difference between hibernate and Mybatis

12. How can we manage transactions with spring framework.

13. Can you design data model for X problem (problem definition will be given).

14. If you have to build spring batch kind of framework, how do you go about it?

15. Multi threading questions

16. What are the important aspects you need to take care of, when it comes to performance, while designing an application

17. How do you scale your application (application tuning/horizintal scaling by adding new servers, vertical scaling by adding extra hardware to the server(s))

18. How do you balance the load across the servers and how do you manage user sessions?

19. If a server goes down  and user is in the middle of a  particular transaction, how do you mitigate the risk?

20. How do you monitor a production system? (Tools/process/access)

21. How do you analyze a production issue and provide fix to it?

22. Performance tuning (profiling, optimizing code for memory leaks and simplifying logic etc).

23. How does garbage collection work in java?

24. Can you explain the heap and stack and different generations of memory in heap?

25. Explain decorator design pattern.

26. What are the design patterns you have used ?

27. Based on the answer to 25, you may be asked to explain 1 o 2 design patterns.

28. Difference between struts 2 and spring mvc (struts actions is model itself (has data within), spring mvc controllers have data as a model object(another java object)).

 Database related questions:

1.DB optimization

2.use warehouse db for reporting

3. aggregate data to warehouse for reporting

4. if transactional queries need to process bigger chunks. Look at the query plan  look at the order of queries and figure out if some table is being queried on broader criteria (you don’t need that many rows but you are quering and an outer query might trim those results to few with additional filter).

5.Partition Pruning. Most common partitioning is on DATE. Make sure you always specify the date filters so that full table scan  can be avoided and only particular partition gets scanned.

Trim data, if you don’t need data to be in production tables, then push them to back up db on nightly basis and trim that data from production db. Less data  then less time to query.


1. Arul java interview questions (He has written a book as well)

2. Struts vs spring MVC.

3. Spring MVC architecture

Framework comparisons

Garbage collection

DB queries

Top 10 interview questions



3. Database pruning

Leave a Reply