• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hi Gregg!

 
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for providing that nice tutorial!

Ok i created that WAR file and put that in the webapps directory and i'm getting a SEVERE error which looks like the typcial scenarios, ie classpath or version problem maybe?

SEVERE: Exception sending context initialized event to listener instance of class com.sun.faces.config.ConfigureListener
java.lang.NoClassDefFoundError: org/apache/commons/collections/ArrayStack

I also got warning when creating the WAR file, but the warning didn't seem like it would cause this sort of problem?

C:\JSFLogin>ant
Buildfile: build.xml
init:
[copy] Copying 1 file to C:\JSFLogin\classes
compile:
deploy:
[war] Building war: C:\JSFLogin\deploy\jsflogin.war
[war] Warning: selected war files include a WEB-INF/web.xml which will be
ignored (please use webxml attribute to war task)
BUILD SUCCESSFUL
Total time: 8 seconds
C:\JSFLogin>

Thanks Gregg for any ideas!

LISTING from the TCOMCAT startup: (see SEVERE)

Apr 11, 2005 1:17:48 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
Apr 11, 2005 1:17:48 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 3065 ms
Apr 11, 2005 1:17:49 AM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Apr 11, 2005 1:17:49 AM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/5.5.8
Apr 11, 2005 1:17:49 AM org.apache.catalina.core.StandardHost start
INFO: XML validation disabled
Apr 11, 2005 1:17:51 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive jsflogin.war
Apr 11, 2005 1:17:53 AM org.apache.catalina.core.ApplicationContext log

SEVERE: Exception sending context initialized event to listener instance of class com.sun.faces.config.ConfigureListener

java.lang.NoClassDefFoundError: org/apache/commons/collections/ArrayStack

at org.apache.commons.digester.Digester.<init>(Digester.java:185)
at com.sun.faces.config.ConfigureListener.digester(ConfigureListener.jav
a:964)
at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureLi
stener.java:270)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContex
t.java:3659)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4
097)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase
.java:759)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:73
9)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)

at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:812)

at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:701
)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:473
)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1126)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java
:311)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl
eSupport.java:119)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1020)

at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1012)

at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442
)
at org.apache.catalina.core.StandardService.start(StandardService.java:4
50)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:683
)
at org.apache.catalina.startup.Catalina.start(Catalina.java:537)
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:585)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:271)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:409)
Apr 11, 2005 1:17:53 AM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Apr 11, 2005 1:17:53 AM org.apache.catalina.core.StandardContext start
SEVERE: Context startup failed due to previous errors
Apr 11, 2005 1:17:54 AM org.apache.catalina.core.ApplicationContext log
INFO: org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.
webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule:
Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.bal
ancer.rules.RequestParameterRule: Target param name: paramName / Target param va
lue: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balanc
er.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]]
Apr 11, 2005 1:17:54 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
Apr 11, 2005 1:17:54 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
Apr 11, 2005 1:17:55 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
Apr 11, 2005 1:17:55 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
Apr 11, 2005 1:17:56 AM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
Apr 11, 2005 1:17:57 AM org.apache.jk.common.ChannelSocket init
INFO: JK2: ajp13 listening on /0.0.0.0:8009
Apr 11, 2005 1:17:57 AM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/240 config=null
Apr 11, 2005 1:17:57 AM org.apache.catalina.storeconfig.StoreLoader load
INFO: Find registry server-registry.xml at classpath resource
Apr 11, 2005 1:17:58 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 9513 ms :roll:
 
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Looks like you are missing the commons-collection.jar.

As far as the ant warning, yes, you can just ignore that.
 
bob connolly
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Gregg!

Gee maybe i'll actually get a JSF app. going this weekend, thanks for getting back to me on this today!

Have a great what's left of it Gregg!

bc
 
bob connolly
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Gregg!

Well i'm making progress as the jsfLogin seemed to register correctly with Tomcat, yeeehaaa!

So now it looks like i'm in the door and dealing with a minor issue regarding the property file!

And i put this in the class directory and the resource directory just be sure!

And i didn't put anything special in the file, just those lines of parameter text:

C:\TOMCAT\jakarta-tomcat-5.5.8\webapps\jsflogin\WEB-INF\classes\Message.properties
greeting_text=Welcome
username_label=Username
password_label=Password
login_button=Login

Appreciate any ideas here too!

Thanks Gregg!

ERROR:

The server encountered an internal error () that prevented it from fulfilling this request.

exception

org.apache.jasper.JasperException: Can't find bundle for base name bundle.Messages, locale en_US
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)


root cause

java.util.MissingResourceException: Can't find bundle for base name bundle.Messages, locale en_US
java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:837)
java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:806)
java.util.ResourceBundle.getBundle(ResourceBundle.java:700)
com.sun.faces.taglib.jsf_core.LoadBundleTag.doStartTag(LoadBundleTag.java:96)
org.apache.jsp.login_jsp._jspx_meth_f_loadBundle_0(org.apache.jsp.login_jsp:114)
org.apache.jsp.login_jsp._jspService(org.apache.jsp.login_jsp:78)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:99)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:325)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)


note The full stack trace of the root cause is available in the Apache Tomcat/5.5.8 logs.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Not sure if there is a problem with my tutorial or a typo on your part but look at this:

C:\TOMCAT\jakarta-tomcat-5.5.8\webapps\jsflogin\WEB-INF\classes\Message.properties

Can't find bundle for base name bundle.Messages, locale en_US

Notice anything different between the 2 bold words? If my tutorial is wrong, let me know.
[ April 10, 2005: Message edited by: Gregg Bolinger ]
 
clojure forum advocate
Posts: 3479
Mac Objective C Clojure
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You have to create a dir called bunlde under classes dir and put your properties file under it.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by John Todd:
You have to create a dir called bunlde under classes dir and put your properties file under it.



Yes, that is true. I missed that on your post. Thanks John.
 
bob connolly
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks all, got it, yabadoo!

Put that properties file under the "bunde" dir in classes and changed the name to Messages from Message!

Appreciate all the help all, really wanted to get something going this weekend, spent a few weekends trying to get other examples going, but this one worked, so hats off!

Have a great what's left of the weekend!

bc
 
Oh the stink of it! Smell my tiny ad!
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic