Different Types of Spring Containers


There are two distinct types of spring containers as mentioned below:

1. BeanFactory Container:

This is the simplest container providing basic support for Dependency Injection and defined by the org.springframework.beans.factory.BeanFactory interface. The BeanFactory and related interfaces, such as BeanFactoryAware, InitializingBean, DisposableBean, are still present in Spring for the purposes of backward compatibility with the large number of third-party frameworks that integrate with Spring.

2. ApplicationContext Container:

This container adds more enterprise-specific functionality such as the ability to resolve textual messages from a properties file and the ability to publish application events to interested event listeners. This container is defined by the org.springframework.context.ApplicationContext interface.

The ApplicationContext container includes all functionality of the BeanFactory container, so it is generally recommended over the BeanFactory. BeanFactory can still be used for light weight applications like mobile devices or applet based applications where data volume and speed is significant.

Advertisements
Tagged with: , , , ,
Posted in Spring

Is it mandatory to have the “id” property in Bean/ApplicationContext Xml


Typical Bean xml file looks like below:

<?xml version=”1.0″ encoding=”UTF-8″?>
<beans xmlns=”http://www.springframework.org/schema/beans&#8221;
xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance&#8221;
xsi:schemaLocation=”http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd&#8221; >

<bean class=”in.malliktalksjava.service.MyServiceImpl”>

<property name=”repository” ref=”someDAO”/>
</bean>

<bean id=”someDAO” class=”in.malliktalksjava.dao.SomeDao”/>

</beans>

MyServiceImpl Bean is anonymous because no id is supplied explicitly. Thus Spring container generates a unique id for that bean. It uses the fully qualified class name and appends a number to them. However, if you want to refer to that bean by name, through the use of the ref element you must provide a name (see Naming Beans section of the Spring reference manual). To be correct, the 2nd bean has to declare a someDAO id attribute in order to be reference by the repository property of the first bean

Tagged with: , , , ,
Posted in Spring

Spring Core – Hello World Example


Pre Requisite :

Download and install the Spring STS into your machine. This will provide all the default spring configurations whenever you create the project

Application Creation Steps:

Step 1: Spring Maven project in your STS. This gives the project folder structure and one pom.xml file in root folder. Below is the Sample pom Xml.

<project xmlns=”http://maven.apache.org/POM/4.0.0&#8243; xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance&#8221; xsi:schemaLocation=”http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd”&gt;
<modelVersion>4.0.0</modelVersion>
<groupId>org.springframework.samples</groupId>
<artifactId>Spring-Project</artifactId>
<version>0.0.1-SNAPSHOT</version>

<properties>

<!– Generic properties –>
<java.version>1.6</java.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

<!– Spring –>
<spring-framework.version>3.2.3.RELEASE</spring-framework.version>

<!– Hibernate / JPA –>
<hibernate.version>4.2.1.Final</hibernate.version>

<!– Logging –>
<logback.version>1.0.13</logback.version>
<slf4j.version>1.7.5</slf4j.version>

<!– Test –>
<junit.version>4.11</junit.version>

</properties>

<dependencies>
<!– Spring and Transactions –>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<version>${spring-framework.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-tx</artifactId>
<version>${spring-framework.version}</version>
</dependency>

<!– Logging with SLF4J & LogBack –>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${slf4j.version}</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>${logback.version}</version>
<scope>runtime</scope>
</dependency>

<!– Hibernate –>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-entitymanager</artifactId>
<version>${hibernate.version}</version>
</dependency>
<!– Test Artifacts –>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
<version>${spring-framework.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>

</dependencies>
</project>

Step 2: Create the bean class HelloWorldBean.java as below

package in.malliktalksjava.spring.examples;

public class HelloWorldBean {

private String message;

public void setMessage(String message){
this.message = message;
}

public void printMessage(){
System.out.println(“You are in Print Message : “+message);
}
}

Step 3: Create Beans Xml file and configure the HellowWorldBean into that file to make use of dependency injection.

<?xml version=”1.0″ encoding=”UTF-8″?>
<beans xmlns=”http://www.springframework.org/schema/beans&#8221;
xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance&#8221;
xsi:schemaLocation=”http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd”&gt;
<bean id=”helloWorldBean” class=”in.malliktalksjava.spring.examples.HelloWorldBean”>
<property name=”message” value=”Hello World”></property>
</bean>

</beans>

Step 4: Create the Main Application class SpringCoreBeansXmlExample.java and load the beans xml

package in.malliktalksjava.spring.examples;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
* @author mallikarjungunda
*
*/
public class SpringCoreBeansXmlExample {

/**
* @param args
*/
public static void main(String[] args) {

//Load the beans.xml into Application Context
ApplicationContext context = new ClassPathXmlApplicationContext(“beans.xml”);

//Inject the object whenever required
HelloWorldBean helloWorldBean = (HelloWorldBean)context.getBean(“helloWorldBean”);

helloWorldBean.printMessage();
}
}

Below is the out put that prints whenever you run the class.

You are in Print Message : Hello World

 

Thank you for going through the this example. Refer to Menu bar for other tutorials.

Tagged with: , , , , , , ,
Posted in Spring

Difference between ClassNotFoundException and NoClassDefFoundError


1. java.lang.ClassNotFoundException :  This exception indicates that the class was not found on the classpath. This indicates that we were trying to load the class definition, and the class did not exist on the classpath.

2. java.lang.NoClassDefFoundError :  This exception indicates that the JVM looked in its internal class definition data structure for the definition of a class and did not find it. This is different than saying that it could not be loaded from the classpath. Usually this indicates that we previously attempted to load a class from the classpath, but it failed for some reason – now we’re trying to use the class again (and thus need to load it, since it failed last time), but we’re not even going to try to load it, because we failed loading it earlier (and reasonably suspect that we would fail again). The earlier failure could be a ClassNotFoundException or an ExceptionInInitializerError (indicating a failure in the static initialization block) or any number of other problems. The point is, a NoClassDefFoundError is not necessarily a classpath problem.

Tagged with: , ,
Posted in JAVA

Difference between HttpSession’s getSession(), getSession(true) and getSession(false) methods


getSession() : Returns the current session associated with this request, or if the request does not have a session, creates one.

getSession(true) : Returns the current HttpSession associated with this request, if there is no current session, returns a new session

getSession(false) : Returns the current HttpSession associated with this request, if there is no current session, returns null.

Tagged with: , , , ,
Posted in JAVA, Servlet, Servlets

org.springframework.beans.NotReadablePropertyException: Invalid property


Exception:

ERROR: org.springframework.web.servlet.tags.form.RadioButtonTag – Invalid property ‘newUser’ of bean class [com.malliktalksjava.bean.UserBean]: Bean property ‘newUser’ is not readable or has an invalid getter method: Does the return type of the getter match the parameter type of the setter?
org.springframework.beans.NotReadablePropertyException: Invalid property ‘newUser’ of bean class [com.malliktalksjava.bean.UserBean]: Bean property ‘newUser’ is not readable or has an invalid getter method: Does the return type of the getter match the parameter type of the setter?
at org.springframework.beans.BeanWrapperImpl.getPropertyValue(BeanWrapperImpl.java:725)
at org.springframework.beans.BeanWrapperImpl.getPropertyValue(BeanWrapperImpl.java:716)
at org.springframework.validation.AbstractPropertyBindingResult.getActualFieldValue(AbstractPropertyBindingResult.java:99)
at org.springframework.validation.AbstractBindingResult.getFieldValue(AbstractBindingResult.java:229)
at org.springframework.web.servlet.support.BindStatus.<init>(BindStatus.java:120)
at org.springframework.web.servlet.tags.form.AbstractDataBoundFormElementTag.getBindStatus(AbstractDataBoundFormElementTag.java:168)
at org.springframework.web.servlet.tags.form.AbstractDataBoundFormElementTag.getPropertyPath(AbstractDataBoundFormElementTag.java:188)
at org.springframework.web.servlet.tags.form.AbstractDataBoundFormElementTag.getName(AbstractDataBoundFormElementTag.java:154)
at org.springframework.web.servlet.tags.form.AbstractDataBoundFormElementTag.autogenerateId(AbstractDataBoundFormElementTag.java:141)
at org.springframework.web.servlet.tags.form.AbstractCheckedElementTag.autogenerateId(AbstractCheckedElementTag.java:81)

Solution:

Ensure all the properties configured in the form are available in the FormBean object. In the above case the radio button property have not been configured in my UserBean class.

Tagged with: , , , ,
Posted in Spring

Features of Spring Web MVC


Spring’s web module includes many unique web support features:

  • Clear separation of roles. Each role — controller, validator, command object, form object, model object, DispatcherServlet, handler mapping, view resolver, and so on — can be fulfilled by a specialized object.
  • Powerful and straightforward configuration of both framework and application classes as JavaBeans. This configuration capability includes easy referencing across contexts, such as from web controllers to business objects and validators.
  • Adaptability, non-intrusiveness, and flexibility. Define any controller method signature you need, possibly using one of the parameter annotations (such as @RequestParam, @RequestHeader, @PathVariable, and more) for a given scenario.
  • Reusable business code, no need for duplication. Use existing business objects as command or form objects instead of mirroring them to extend a particular framework base class.
  • Customizable binding and validation. Type mismatches as application-level validation errors that keep the offending value, localized date and number binding, and so on instead of String-only form objects with manual parsing and conversion to business objects.
  • Customizable handler mapping and view resolution. Handler mapping and view resolution strategies range from simple URL-based configuration, to sophisticated, purpose-built resolution strategies. Spring is more flexible than web MVC frameworks that mandate a particular technique.
  • Flexible model transfer. Model transfer with a name/value Map supports easy integration with any view technology. Customizable locale, time zone and theme resolution, support for JSPs with or without Spring tag library, support for JSTL, support for Velocity without the need for extra bridges, and so on.
  • A simple yet powerful JSP tag library known as the Spring tag library that provides support for features such as data binding and themes. The custom tags allow for maximum flexibility in terms of markup code. For information on the tag library descriptor, see the appendix entitled Chapter 36, spring.tld
  • A JSP form tag library, introduced in Spring 2.0, that makes writing forms in JSP pages much easier.
  • Beans whose lifecycle is scoped to the current HTTP request or HTTP Session. This is not a specific feature of Spring MVC itself, but rather of the WebApplicationContext container(s) that Spring MVC uses. These bean scopes are described in the section called “Request, session, and global session scopes”

Source:

http://docs.spring.io/spring/docs/current/spring-framework-reference/pdf/spring-framework-reference.pdf

Tagged with: , , , , , , , , ,
Posted in Spring

javax.servlet.ServletException: Could not resolve view with name ‘home’ in servlet with name ‘springDispatcher’


Exception:

javax.servlet.ServletException: Could not resolve view with name 'home' in servlet with name 'springDispatcher'
	org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1200)
	org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:1005)
	org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:952)
	org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:870)
	org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:961)
	org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:852)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:734)
	org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:837)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:847)

Solution:

If it is a tiles framework integrated application, verify the Tiles definition is defined in tiles-defs.xml file.

If it is not a tiles application, verify the corresponding view is available in application or not.

 

Tagged with: , , ,
Posted in Spring

Context initialization failed: org.springframework.beans.factory.BeanCreationException: Error creating bean with name ’tilesConfigurer’ defined in ServletContext resource


Below is the exception that I have received when I am integrating the tiles 3.0 framework with Spring 4.0 web mvc application. Using the solution below I have rectified the issue my self. Hope this is useful to all.

21:02:06,311 ERROR [org.springframework.web.servlet.DispatcherServlet] (ServerService Thread Pool — 74) Context initialization failed: org.springframework.beans.factory.BeanCreationException: Error creating bean with name ’tilesConfigurer’ defined in ServletContext resource [/config/spring-context.xml]: Invocation of init method failed; nested exception is java.lang.NoSuchMethodError: org.apache.tiles.access.TilesAccess.setContainer(Lorg/apache/tiles/request/ApplicationContext;Lorg/apache/tiles/TilesContainer;Ljava/lang/String;)V
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1553) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:539) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:304) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:300) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:195) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:703) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:760) [spring-context-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:482) [spring-context-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.configureAndRefreshWebApplicationContext(FrameworkServlet.java:658) [spring-webmvc-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:624) [spring-webmvc-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:672) [spring-webmvc-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext(FrameworkServlet.java:543) [spring-webmvc-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.initServletBean(FrameworkServlet.java:484) [spring-webmvc-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.web.servlet.HttpServletBean.init(HttpServletBean.java:136) [spring-webmvc-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at javax.servlet.GenericServlet.init(GenericServlet.java:242) [jboss-servlet-api_3.0_spec-1.0.2.Final-redhat-1.jar:1.0.2.Final-redhat-1]
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1194) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1100) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3591) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardContext.start(StandardContext.java:3798) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.jboss.as.web.deployment.WebDeploymentService.doStart(WebDeploymentService.java:156) [jboss-as-web-7.3.0.Final-redhat-14.jar:7.3.0.Final-redhat-14]
at org.jboss.as.web.deployment.WebDeploymentService.access$000(WebDeploymentService.java:60) [jboss-as-web-7.3.0.Final-redhat-14.jar:7.3.0.Final-redhat-14]
at org.jboss.as.web.deployment.WebDeploymentService$1.run(WebDeploymentService.java:93) [jboss-as-web-7.3.0.Final-redhat-14.jar:7.3.0.Final-redhat-14]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [rt.jar:1.8.0]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [rt.jar:1.8.0]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0]
at java.lang.Thread.run(Thread.java:744) [rt.jar:1.8.0]
at org.jboss.threads.JBossThread.run(JBossThread.java:122)
Caused by: java.lang.NoSuchMethodError: org.apache.tiles.access.TilesAccess.setContainer(Lorg/apache/tiles/request/ApplicationContext;Lorg/apache/tiles/TilesContainer;Ljava/lang/String;)V
at org.apache.tiles.startup.AbstractTilesInitializer.initialize(AbstractTilesInitializer.java:65) [tiles-core-3.0.4.jar:3.0.4]
at org.springframework.web.servlet.view.tiles3.TilesConfigurer.afterPropertiesSet(TilesConfigurer.java:270) [spring-webmvc-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1612) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1549) [spring-beans-4.0.3.RELEASE.jar:4.0.3.RELEASE]
… 29 more

 

Solution:

step 1: Check the spring tiles configuration: DTD should match with the version of jars added into application

<?xml version=”1.0″ encoding=”UTF-8″ ?>
<!DOCTYPE tiles-definitions PUBLIC
-//Apache Software Foundation//DTD Tiles Configuration 3.0//EN”
http://tiles.apache.org/dtds/tiles-config_3_0.dtd”&gt;

<tiles-definitions>
<definition name=”base.definition” template=”/jsp/layout.jsp”>
<put-attribute name=”title” value=”” />
<put-attribute name=”header” value=”/jsp/header.jsp” />
<put-attribute name=”menu” value=”/jsp/menu.jsp” />
<put-attribute name=”body” value=”” />
<put-attribute name=”footer” value=”/jsp/footer.jsp” />
</definition>

<definition name=”contact” extends=”base.definition”>
<put-attribute name=”title”
value=”Sample Spring MVC With Tiles Appliacation” />
<put-attribute name=”body” value=”/jsp/contact.jsp” />
</definition>

</tiles-definitions>

Step 2: Check the spring configuration files: DTD should match to the jars added into application

<?xml version=”1.0″ encoding=”UTF-8″?>
<beans xmlns=”http://www.springframework.org/schema/beans&#8221;
xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance&#8221; xmlns:mvc=”http://www.springframework.org/schema/mvc&#8221;
xmlns:context=”http://www.springframework.org/schema/context&#8221;
xsi:schemaLocation=”
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-4.0.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd“>

<context:component-scan base-package=”in.javatutorials.spring.controller” />
<mvc:annotation-driven />
<bean id=”viewResolver” class=”org.springframework.web.servlet.view.UrlBasedViewResolver“>
<property name=”viewClass” value=”org.springframework.web.servlet.view.tiles3.TilesView“/>
</bean>

<bean id=”tilesConfigurer” class=“org.springframework.web.servlet.view.tiles3.TilesConfigurer“>
<property name=”definitions”>
<list>
<value>/config/tiles.xml</value>
</list>
</property>
</bean>

</beans>

Step 3: Check the jar versions with the above DTD versions:

Spring4 and Tiles 3 Integration Jars

Tagged with: , , , ,
Posted in Spring

How to read a URL using JAVA


package in.malliktalksjava;

import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLConnection;

/**
* @author malliktalksjava
*
*/
public class URLConnectionReader {

public static void main(String[] args) throws Exception {

URL oracle = new URL(“https://malliktalksjava.in/&#8221;);
URLConnection yc = oracle.openConnection();
BufferedReader in = new BufferedReader(new InputStreamReader(
yc.getInputStream()));
String inputLine;
while ((inputLine = in.readLine()) != null)
System.out.println(inputLine);
in.close();
}
}

Tagged with: , , , , , , , ,
Posted in JAVA

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 680 other followers

Calendar
June 2017
M T W T F S S
« Dec    
 1234
567891011
12131415161718
19202122232425
2627282930  
Mallikarjun Gunda

This is Mallikarjun Gunda, I am working as a software professional. Blogging is my Passion. This blog contains the posts on Java related technologies and programming languages. I am happy to share my knowledge through the blogs.

Blog Stats
  • 219,545 hits
IndiBlogger
malliktalksjava.wordpress.c...
70/100
All tags
Apache Cassandra Arrays in Java Cassandra Cassandra Database Cassandra examples client stubs creating a java web service creating a web service using java difference between interface and abstract class Differences between SOAP and RESTfull webservices Display div as Overlay using JQuery download the spring basic application File directory Generating webservice client stubs Hibernate hibernate exceptions How to display over using JQuery how to generated web service client stubs in STS How to implement Spring basic application how to write singleton design pattern in java interface in java Java Java Arrays Java Example Programs Java examples Java interview questions java programs java project Java sample Programs JavaScript Java Script JavaServer Faces Java Sorting alogorithms Java Tutorials javatutorials Java Web services JDBC open shift openshift Overlay implementation using JQuery Overlay in JQuery POI API POI Examples public class public static void main Redhat OpenShift representational state transfer Restfull webservices Sample Overlay html with JQuery sample programs in java Service-oriented architecture Singleton design pattern in java SOAP SOAP Webservices software Spring Framework Spring Interview Questions Spring MVC Spring MVC Example program Spring MVC sample Program Spring Sample Programs Spring Tutorials Struts technology Top Java Interview questions w3c dom Web service web service client Web Service Description Language Web services webservices writing singleton design pattern in Java WSDL Xml xml parsers