Posts

Showing posts with the label interviews

Topics to Prepare for Java Interview

Companies looking for Java developers who have experience in following topics 1. Core Java 2. Java 8 3. Multithreading (must) 4. Spring 5. Spring Boot (Micro Services) 6. Hibernate 7. XML 8. Concurrency 9. Algorithms 10. Data structures 11. Design patterns 12. Object-Oriented Design 13. Architecture patterns 14. MVC Design 15. RESTful web services 16. Maven 17. MongoDB 18. Git 19. JUnit & Mockito 20. System Design Links to refer: Design patterns https://www.youtube.com/watch?v=EYOKqb2Mf7k&list=PLmCsXDGbJHdjZiLC2HjXrgw8-E4O3MXdN Singleton Implement Singleton using Eager Initialisation Implement Singleton using Lazy Initialisation What is the Double-Checked Locking? When Double-Checked Locking fails? How can you fix Double-Checked Locking fail? Ans: use Volatile Factory  Abstract Factory - Factory of Factories Spring Spring core Spring transactions Spring JDBC Spring MVC CoreJava & Java8 OOP...

How to set proxy settings for JVM

You can configure proxy settings in JVM using 2 VM arguments. Those are Dhttp.proxyPort Dhttp.proxyHost As these are proxy arguments, while running a Java program from command line or from eclipse, you need to provide these arguments to Java. The sample code is given below. "C:\Program Files\Java\jrockit-jdk1.6.0_45-R28.2.7-4.1.0\bin\java" -Dhttp.proxyPort=80 -Dhttp.proxyHost=www-proxy.us.xxxx.com -jar "C:\Program Files\Java\jrockit-jdk1.6.0_45-R28.2.7-4.1.0\missioncontrol\mc.jar" Here i am trying to run mc.jar by setting proxy port and proxy host arguments. If you want to set proxy settings in eclipse, you can refer below screenshot. for running HttpURLConnectionExample, i am setting proxy vm arguments.