Interview questions

JAVA interview questions – page 23

2,804 questions. Tap “Show answer” to check yourself.

  1. Does import make my class bigger? Does it actually compile the imported class or package into my code?

  2. What is Clonnable Interface in java? IS it implemented by the ProtoType Design Pattern?

  3. How to Access Session Variables in Servlets & JSp

  4. What are the various transaction attributes and differences between them

  5. What is Message Driven Bean

  6. How to make jdbc connection a protable without specific drivers

  7. What is the difference b/w sendRedirect() and <jsp: forward>?

  8. What happens if you try to run an executable JAR, and the end-user doesn't have java installed?

  9. Can we make construtor STATIC?

  10. Which method is more advantageous doGET() or doPOST()? in which situation does we use doGET() then?

  11. When can an object reference be cast to an interface reference?

  12. Consider a scenario in which 4 users are accessing a servlet instance. Among which one user called destroy() method. What happens to the rest 3 users?

  13. What are the types of refrences available in java. How they work

  14. Will class level variables are garbage collected?

  15. I can do every thing using jsp itself,then what is the need of using servlet?in which situation ,we must use servlet with jsp?

  16. What is the difference between queue and topic

  17. Plz give me detail difference between Tomcat & Weblogic server

  18. What is callback function?

  19. What is difault http method in http servlet?

  20. What are the three components of a Message ?

  21. What kind of information found in the header of a Message ?

  22. How can we invoke private method using refleciotn API(AccessibileObject class)?

  23. Can there ever be more than one program running on a single port? In other words, can two applications on the same server have the same port number?

  24. What is clustering. What are the different algorithms used for clustering

  25. What is difference between sendRedirect() and forward()..? Which one is faster then other and which works on server?

  26. What is the difference betweem getRequestDispatcher() available as part of ServletContext and ServletRequest

  27. What is the difference between ejbCreate() and ejbPostCreate()

  28. How to create a durable subsriber ?

  29. Are there any practical limits on the levels of subclassing? How deep can you go?

  30. What is the difference between hiding & overriding ?

Companies that ask JAVA questions