File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSF and the fly likes Help - JSF Tomcat Config Error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "Help - JSF Tomcat Config Error" Watch "Help - JSF Tomcat Config Error" New topic
Author

Help - JSF Tomcat Config Error

Raminder Singh
Ranch Hand

Joined: Mar 01, 2002
Posts: 72
Hi all,
I'm getting one error while starting tomcat to test my JSFApp.
Help me out..as i have no idea abt it.

WarFile: MyApp.war
Files in lib:
commons-beanutils.jar
commons-collections.jar
commons-digester.jar
commons-logging.jar
dt.jar
html_basic.tld
jsf_core.tld
jsf-api.jar
jsf-impl.jar
rt.jar
tools.jar
web-facesconfig_1_0.dtd
web-facesconfig_1_1.dtd



Error On tomcat start:

Dec 21, 2005 5:00:27 PM org.apache.catalina.core.StandardHostDeployer install
INFO: Installing web application at context path /MyApp from URL file:C:/jakarta
-tomcat-5.0.27/webapps/MyApp
Dec 21, 2005 5:01:14 PM com.sun.faces.config.ConfigureListener parse
SEVERE: Can't parse configuration file:jndi:/localhost/MyApp/WEB-INF/faces-confi
g.xml
java.net.NoRouteToHostException: No route to host: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:171)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
at java.net.Socket.connect(Socket.java:452)
at java.net.Socket.connect(Socket.java:402)
at sun.net.NetworkClient.doConnect(NetworkClient.java:139)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:402)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:618)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:306)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:267)
at sun.net.www.http.HttpClient.New(HttpClient.java:339)
at sun.net.www.http.HttpClient.New(HttpClient.java:320)
at sun.net.www.http.HttpClient.New(HttpClient.java:315)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConne
ction.java:512)
at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection
.java:489)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon
nection.java:617)
at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown So
urce)
at org.apache.xerces.impl.XMLEntityManager.startEntity(Unknown Source)
at org.apache.xerces.impl.XMLEntityManager.startDTDEntity(Unknown Source
)
at org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(Unknown Sourc
e)
at org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(
Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Un
known Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.commons.digester.Digester.parse(Digester.java:1548)
at com.sun.faces.config.ConfigureListener.parse(ConfigureListener.java:1
188)
at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureLi
stener.java:323)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContex
t.java:3827)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4
343)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase
.java:823)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:80
7)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:595)

at org.apache.catalina.core.StandardHostDeployer.install(StandardHostDep
loyer.java:277)
at org.apache.catalina.core.StandardHost.install(StandardHost.java:832)
at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:617
)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:431
)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:968)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java
:349)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl
eSupport.java:119)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1091)

at org.apache.catalina.core.StandardHost.start(StandardHost.java:789)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1083)

at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:478
)
at org.apache.catalina.core.StandardService.start(StandardService.java:4
80)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:231
3)
at org.apache.catalina.startup.Catalina.start(Catalina.java:556)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:284)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:422)
Dec 21, 2005 5:01:17 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Dec 21, 2005 5:01:17 PM org.apache.catalina.core.StandardContext start
SEVERE: Context startup failed due to previous errors




Error on starting application:

Dec 21, 2005 5:01:37 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 91358 ms
Dec 21, 2005 5:02:27 PM org.apache.catalina.core.StandardHostDeployer start
INFO: standardHost.start /MyApp
Dec 21, 2005 5:02:50 PM com.sun.faces.config.ConfigureListener parse
SEVERE: Can't parse configuration file:jndi:/localhost/MyApp/WEB-INF/faces-confi
g.xml
java.net.ConnectException: Connection timed out: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:171)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
at java.net.Socket.connect(Socket.java:452)
at java.net.Socket.connect(Socket.java:402)
at sun.net.NetworkClient.doConnect(NetworkClient.java:139)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:402)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:618)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:306)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:267)
at sun.net.www.http.HttpClient.New(HttpClient.java:339)
at sun.net.www.http.HttpClient.New(HttpClient.java:320)
at sun.net.www.http.HttpClient.New(HttpClient.java:315)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConne
ction.java:512)
at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection
.java:489)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon
nection.java:617)
at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown So
urce)
at org.apache.xerces.impl.XMLEntityManager.startEntity(Unknown Source)
at org.apache.xerces.impl.XMLEntityManager.startDTDEntity(Unknown Source
)
at org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(Unknown Sourc
e)
at org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(
Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Un
known Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.commons.digester.Digester.parse(Digester.java:1548)
at com.sun.faces.config.ConfigureListener.parse(ConfigureListener.java:1
188)
at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureLi
stener.java:323)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContex
t.java:3827)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4
343)
at org.apache.catalina.core.StandardHostDeployer.start(StandardHostDeplo
yer.java:830)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:991)
at org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:
1322)
at org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServl
et.java:530)
at org.apache.catalina.manager.HTMLManagerServlet.doGet(HTMLManagerServl
et.java:104)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:237)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:157)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:214)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:520)
at org.apache.catalina.core.StandardContextValve.invokeInternal(Standard
ContextValve.java:198)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:152)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:104)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica
torBase.java:540)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:520)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:137)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:104)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
ava:117)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:520)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:109)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)

at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:16
0)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
:799)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proce
ssConnection(Http11Protocol.java:705)
at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java
:577)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadP
ool.java:683)
at java.lang.Thread.run(Thread.java:534)
Dec 21, 2005 5:02:56 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Dec 21, 2005 5:02:56 PM org.apache.catalina.core.StandardContext start
SEVERE: Context startup failed due to previous errors


thanks
raminder.singh
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299
    
    6

SEVERE: Can't parse configuration file:jndi:/localhost/MyApp/WEB-INF/faces-config.xml


That's your problem. If you show us the faces-config.xml maybe we can help determine what the underlying problem is.


GenRocket - Experts at Building Test Data
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16065
    
  21

Originally posted by Gregg Bolinger:


That's your problem. If you show us the faces-config.xml maybe we can help determine what the underlying problem is.


Oops. First time through, I thought Gregg was being nasty (as in that's YOUR problem!).

THAT's your problem, alright. Your faces-config.xml file doesn't conform to the faces-config DTD.

But could you please change your display name to "Raminder Singh"? With the dot in the middle, it comes out as an offense against our naming rules (separate first and last names).


Customer surveys are for companies who didn't pay proper attention to begin with.
Raminder Singh
Ranch Hand

Joined: Mar 01, 2002
Posts: 72
Thanks Tom. Name changed as per rules.

faces-config.xml, web.xml and web-facesconfig_1_1.dtd are in TestJSF\MyApp\WEB-INF Folder.


Here is my faces-config file:

<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JSF Config 1.1//EN"
"web-facesconfig_1_1.dtd">
<faces-config>
<application>
<locale-config>
<default-locale>en</default-locale>
<supported-locale>de</supported-locale>
<supported-locale>fr</supported-locale>
<supported-locale>es</supported-locale>
</locale-config>
</application>
<navigation-rule>
<description>The decision rule used by the
NavigationHandler to determine which view must be displayed
after the current view, greeting.jsp is processed.
</description>
<from-view-id>/greeting.jsp</from-view-id>

<navigation-case>
<description>Indicates to the NavigationHandler that the response.jsp
view must be displayed if the Action referenced by a
UICommand component on the greeting.jsp view returns the outcome "success".
</description>
<from-outcome>success</from-outcome>
<to-view-id>/response.jsp</to-view-id>
</navigation-case>
</navigation-rule>

<navigation-rule>
<description> The decision rules used by the NavigationHandler to
determine which view must be displayed after the
current view, response.jsp is processed.
</description>
<from-view-id>/response.jsp</from-view-id>
<navigation-case>
<description>Indicates to the NavigationHandler that the greeting.jsp
view must be displayed if the Action referenced by a
UICommand component on the response.jsp view returns
the outcome "success".
</description>
<from-outcome>success</from-outcome>
<to-view-id>/greeting.jsp</to-view-id>
</navigation-case>
</navigation-rule>

<managed-bean>
<description> The "backing file" bean that backs up the guessNumber webapp </description>
<managed-bean-name>UserNumberBean</managed-bean-name>
<managed-bean-class>guessNumber.UserNumberBean</managed-bean-class>
<managed-bean-scope>session</managed-bean-scope>

<managed-property>
<property-name>minimum</property-name>
<property-class>int</property-class>
<value>0</value>
</managed-property>

<managed-property>
<property-name>maximum</property-name>
<property-class>int</property-class>
<value>10</value>
</managed-property>

</managed-bean>
</faces-config>
 
Don't get me started about those stupid light bulbs.
 
subject: Help - JSF Tomcat Config Error