Home | JSP | EJB | JDBC | Java Servlets | WAP  | Free JSP Hosting  | Spring Framework | Web Services | BioInformatics | Java Server Faces | Jboss 3.0 tutorial | Hibernate 3.0 | XML

Tutorial Categories: Ajax | Articles | JSP | Bioinformatics | Database | Free Books | Hibernate | J2EE | J2ME | Java | JavaScript | JDBC | JMS | Linux | MS Technology | PHP | RMI | Web-Services | Servlets | Struts | UML


 

Java Tutorials


 

 

Struts Tutorials

Struts Resources

Visit Forum! Post Questions!
Jobs At RoseIndia.net!

Spring Springpart2

User Comments
Add This Tutorial To:
  Del.icio.us   Digg   Google   Spurl
  Blink   Furl   Simpy   Y! MyWeb 

Add This Tutorial To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 

Current Comments

11 comments so far (post your own) View All Comments Latest 10 Comments:

f:\springdemo>set path=c:\windows\command;g:\jdk1.5\bin
(* Set path for jdk1.5 or jdk1.4.2 only. )
f:\springdemo>set classpath=f:\springdemo;
f:\springdemo\spring.jar;

f:\springdemo\commons-logging.jar

I am having trouble with these things. I could not able to run the first spring program. Could be plz explain what I can do to make it run?

Posted by AG on Monday, 10.12.09 @ 11:51am | #91683

Hi There,
Its not able to hello.xml in classpath , hence its giving IOException. In eclipse just point classpath to the folder in which the hello.xml is placed and it will work fine

Posted by angelina on Monday, 11.17.08 @ 11:52am | #81752

javac helloclient.java -cp /home/user/Desktop/springdemo/spring.jar:/home/user/Desktop/springdemo/commons-logging.jar

helloclient.java:14: cannot find symbol
symbol : class hello
location: class helloclient
hello bean1=(hello)factory.getBean("hello1");
^
helloclient.java:14: cannot find symbol
symbol : class hello
location: class helloclient
hello bean1=(hello)factory.getBean("hello1");
^
2 errors

I tried export CLASSPATH=$CLASSPATH:/home/user/Desktop/springdemo but still not able to compile without above (-cp) method. Please help me on Ubuntu. This is for 1st example

Posted by needshelp on Thursday, 10.16.08 @ 01:36am | #81108

Hi,
I don't know why, But in Line: BeanFactory factory = new XmlBeanFactory(res); I get time out error and exception.
this is the exception:
org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML document from class path resource [hello.xml]; nested exception is java.net.ConnectException: Connection timed out.

I think it is not able to parse "hello.xml".
can you help me with that.

Posted by hossein on Monday, 10.13.08 @ 17:07pm | #81045

Here's the web.xml you need:

<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE web-app
PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd">

<web-app>
<servlet>
<servlet-name>servletclient</servlet-name>
<servlet-class>servletclient</servlet-class>
</servlet>

<servlet-mapping>
<servlet-name>servletclient</servlet-name>
<url-pattern>/servlet/servletclient</url-pattern>
</servlet-mapping>
</web-app>

Posted by LJS on Monday, 10.6.08 @ 16:06pm | #80926

Where should I place the hello.xml if I am developing a web application using eclipse IDE?

Posted by Murali on Saturday, 09.27.08 @ 01:50am | #80731

After I click on the Submit Query button, I get this error message:
HTTP Status 404 - /servlet/servletclient
The requested resource (/servlet/servletclient) is not available.

I'm guessing it can't find the file servletclient.class under the c:\Tomcat 6.0\webapps\ROOT\WEB-INF\classes

Could it be that it doesn't like the space in "Tomcat 6.0"?

Thanks,
Patrick

Posted by Patrick on Wednesday, 08.6.08 @ 09:38am | #71249

Could you please tell me how to add an entry in the web.xml file in this example......

Posted by Shobhana Katukuri on Wednesday, 07.30.08 @ 01:29am | #69850

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/lo
gging/LogFactory
at org.springframework.util.ClassUtils.<clinit>(ClassUtils.java:73)
at org.springframework.core.io.ClassPathResource.<init>(ClassPathResourc
e.java:82)
at org.springframework.core.io.ClassPathResource.<init>(ClassPathResourc
e.java:64)
at helloclient.main(helloclient.java:19)

i am getting this exception, when iam running hello. java program with setting all the path and class paths..why..what is the problem

Posted by sivakumar on Thursday, 07.3.08 @ 20:01pm | #65537

Hi,
Just wanted to say how well this works. Very quick demo apps. Esp delighted getting the servlet running in tomcat.
Thanks, its been a great help.
Des

Posted by JavaRocket on Wednesday, 07.2.08 @ 15:10pm | #65327

I've copied everything verbatim. The only questionable part may be the "Add entry to web.xml file".

Can you please provide me with how the web.xml file should look like? I have it as:

...
<servlet>
<servlet-name>servletclient</servlet-name>
<servlet-class>servletclient</servlet-class>
<servlet-name>org.apache.jsp.index_jsp</servlet-name>
<servlet-class>org.apache.jsp.index_jsp</servlet-class>
</servlet>
...

but it does work.

Thanks for your assistance.

Posted by Robinson on Wednesday, 04.30.08 @ 01:58am | #58150

Ask programming questions?

 

 

Back to Tutorial

 

  JDO Tutorials
  EAI Articles
  Struts Tutorials
  Java Tutorials
  Java Certification

Tell A Friend
Your Friend Name

 

 
Browse all Java Tutorials
Java JSP Struts Servlets Hibernate XML
Ajax JDBC EJB MySQL JavaScript JSF
Maven2 Tutorial JEE5 Tutorial Java Threading Tutorial Photoshop Tutorials Linux Technology
Technology Revolutions Eclipse Spring Tutorial Bioinformatics Tutorials Tools SQL
 

Home | JSP | EJB | JDBC | Java Servlets | WAP  | Free JSP Hosting  | Search Engine | News Archive | Jboss 3.0 tutorial | Free Linux CD's | Forum | Blogs

About Us | Advertising On RoseIndia.net  | Site Map

India News

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright 2007. All rights reserved.