Java 8

Java 8: What’s new?

Heard about Java 8? Excited about Java 8? Wanna know about Java 8? If so, then you can continue to read this article.

If you have heard about Java 8 then you might noticed people saying that it is going to change the world of Java community and it is going to have many new revolutionary features that Java was …

Spring

Beans Scopes in Spring

Bean scope in Spring are scope for a bean managed by Spring IOC container. As we know that Spring is a framework which is based on Dependency Injection(DI) and Inversion of Control (IoC) and provides bean management facilities to Java application. In Spring managed environment, bean are created and wired by Spring framework. Spring allows you to define how …

Oracle Java

Customized Exception Stack Trace in Java

As a programmer, you must be familiar with Java stack trace, isn’t it? If you’re not familiar with exception stack trace, you can learn on how to produce and read the stack trace before you continue to read this article.

Converting a stack trace into a String is done with Throwable.printStackTrace(). If desired, a customized stack trace String can …

Servlet

Tracking HTTP Session by using HttpSessionListener

In web application, sometimes we need to track existing sessions on server, for example we need to get actual HTTP session from session ID. Following I will show you simple HTTP session listener to keep existing sessions during creation time, then get stored session based on session ID. Below sample code will store valid sessions into memory for debugging and …

ssh

SSH Remote Login Without Password in Linux

By default, if you want to do remote console with SSH, server (A) will prompt you the password of user (a) in the server. Sometime you need to call ssh not in interactive mode, for example in shell script, then you may need to make the script secure without storing any password there. Basically Linux provide such way to remote …

Oracle Java

Make Your Oracle JDK 7 as Default JVM in Ubuntu

In some Linux distros, the vendor included OpenJDK as the default JVM, but sometime this not what you’re looking for. If you want to use Sun JDK instead, you can follow below instructions:

  1. Purge existing OpenJDK from your Ubuntu:
  2. Add a new repository and install Sun JDK: