Results 1 to 2 of 2
  1. #1
    carolwind is offline Member
    Join Date
    Mar 2013
    Posts
    5
    Rep Power
    0

    Question What's the problem with this?

    SEVERE: Servlet.service() for servlet [Faces Servlet] in context with path [/SecondHandHouse] threw exception [null] with root cause
    java.lang.IllegalArgumentException
    at com.sun.faces.renderkit.SelectItemsIterator.initia lizeItems(SelectItemsIterator.java:216)
    at com.sun.faces.renderkit.SelectItemsIterator.hasNex t(SelectItemsIterator.java:135)
    at com.sun.faces.renderkit.html_basic.MenuRenderer.re nderOptions(MenuRenderer.java:762)
    at com.sun.faces.renderkit.html_basic.MenuRenderer.re nderSelect(MenuRenderer.java:844)
    at com.sun.faces.renderkit.html_basic.MenuRenderer.en codeEnd(MenuRenderer.java:298)
    at javax.faces.component.UIComponentBase.encodeEnd(UI ComponentBase.java:875)
    at javax.faces.component.UIComponent.encodeAll(UIComp onent.java:1786)
    at javax.faces.render.Renderer.encodeChildren(Rendere r.java:168)
    at javax.faces.component.UIComponentBase.encodeChildr en(UIComponentBase.java:845)
    at javax.faces.component.UIComponent.encodeAll(UIComp onent.java:1779)
    at javax.faces.component.UIComponent.encodeAll(UIComp onent.java:1782)
    at com.sun.faces.application.view.JspViewHandlingStra tegy.doRenderView(JspViewHandlingStrategy.java:431 )
    at com.sun.faces.application.view.JspViewHandlingStra tegy.renderView(JspViewHandlingStrategy.java:232)
    at com.sun.faces.application.view.MultiViewHandler.re nderView(MultiViewHandler.java:124)
    at com.sun.faces.lifecycle.RenderResponsePhase.execut e(RenderResponsePhase.java:121)
    at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:1 01)
    at com.sun.faces.lifecycle.LifecycleImpl.render(Lifec ycleImpl.java:139)
    at javax.faces.webapp.FacesServlet.service(FacesServl et.java:594)
    at org.apache.catalina.core.ApplicationFilterChain.in ternalDoFilter(ApplicationFilterChain.java:305)
    at org.apache.catalina.core.ApplicationFilterChain.do Filter(ApplicationFilterChain.java:210)
    at org.apache.catalina.core.StandardWrapperValve.invo ke(StandardWrapperValve.java:222)
    at org.apache.catalina.core.StandardContextValve.invo ke(StandardContextValve.java:123)
    at org.apache.catalina.authenticator.AuthenticatorBas e.invoke(AuthenticatorBase.java:472)
    at org.apache.catalina.core.StandardHostValve.invoke( StandardHostValve.java:171)
    at org.apache.catalina.valves.ErrorReportValve.invoke (ErrorReportValve.java:99)
    at org.apache.catalina.valves.AccessLogValve.invoke(A ccessLogValve.java:936)
    at org.apache.catalina.core.StandardEngineValve.invok e(StandardEngineValve.java:118)
    at org.apache.catalina.connector.CoyoteAdapter.servic e(CoyoteAdapter.java:407)
    at org.apache.coyote.http11.AbstractHttp11Processor.p rocess(AbstractHttp11Processor.java:1004)
    at org.apache.coyote.AbstractProtocol$AbstractConnect ionHandler.process(AbstractProtocol.java:589)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProce ssor.run(JIoEndpoint.java:312)
    at java.util.concurrent.ThreadPoolExecutor.runWorker( Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run (Unknown Source)
    at java.lang.Thread.run(Unknown Source)

    The page can't open:

    HTTP Status 500 -

    type Exception report

    message

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

    exception

    javax.servlet.ServletException
    javax.faces.webapp.FacesServlet.service(FacesServl et.java:606)
    root cause

    java.lang.IllegalArgumentException
    com.sun.faces.renderkit.SelectItemsIterator.initia lizeItems(SelectItemsIterator.java:216)
    com.sun.faces.renderkit.SelectItemsIterator.hasNex t(SelectItemsIterator.java:135)
    com.sun.faces.renderkit.html_basic.MenuRenderer.re nderOptions(MenuRenderer.java:762)
    com.sun.faces.renderkit.html_basic.MenuRenderer.re nderSelect(MenuRenderer.java:844)
    com.sun.faces.renderkit.html_basic.MenuRenderer.en codeEnd(MenuRenderer.java:298)
    javax.faces.component.UIComponentBase.encodeEnd(UI ComponentBase.java:875)
    javax.faces.component.UIComponent.encodeAll(UIComp onent.java:1786)
    javax.faces.render.Renderer.encodeChildren(Rendere r.java:168)
    javax.faces.component.UIComponentBase.encodeChildr en(UIComponentBase.java:845)
    javax.faces.component.UIComponent.encodeAll(UIComp onent.java:1779)
    javax.faces.component.UIComponent.encodeAll(UIComp onent.java:1782)
    com.sun.faces.application.view.JspViewHandlingStra tegy.doRenderView(JspViewHandlingStrategy.java:431 )
    com.sun.faces.application.view.JspViewHandlingStra tegy.renderView(JspViewHandlingStrategy.java:232)
    com.sun.faces.application.view.MultiViewHandler.re nderView(MultiViewHandler.java:124)
    com.sun.faces.lifecycle.RenderResponsePhase.execut e(RenderResponsePhase.java:121)
    com.sun.faces.lifecycle.Phase.doPhase(Phase.java:1 01)
    com.sun.faces.lifecycle.LifecycleImpl.render(Lifec ycleImpl.java:139)
    javax.faces.webapp.FacesServlet.service(FacesServl et.java:594)
    note The full stack trace of the root cause is available in the Apache Tomcat/7.0.34 logs.

    My web.xml:

    <?xml version="1.0" encoding="ISO-8859-1"?>
    <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">

    <resource-ref>
    <description>DB Connection</description>
    <res-ref-name>jdbc/secondHandHouse</res-ref-name>
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>Container</res-auth>
    </resource-ref>

    <context-param>
    <param-name>contextConfigLocation</param-name>
    <param-value>/WEB-INF/appcontext.xml</param-value>
    </context-param>
    <listener>
    <listener-class>org.springframework.web.context.ContextLoade rListener</listener-class>
    </listener>


    <servlet>
    <servlet-name>Faces Servlet</servlet-name>
    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
    <servlet-name>Faces Servlet</servlet-name>
    <url-pattern>/faces/*</url-pattern>
    </servlet-mapping>
    <welcome-file-list>
    <welcome-file>Nav.jsp</welcome-file>
    </welcome-file-list>
    </web-app>


    My Tomcat7.0 server.xml:

    ..........
    <Context path="/SecondHandHouse" docBase="D:\Users\wind\workspace\SecondHandHouse"
    reloadable="true" crossContext="true" workDir="D:\Users\wind\workspace\SecondHandHouse\w ork">
    <Resource name="jdbc/secondHandHouse"
    auth="Container"
    type="javax.sql.DataSource"
    maxActive="100" maxIdle="30" maxWait="10000"
    username="root" password="123456"
    driverClassName="org.gjt.mm.mysql.Driver"
    url="jdbc:mysql://localhost/test"/>
    </Context>
    ...........

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,197
    Rep Power
    19

    Default Re: What's the problem with this?

    Please go through the Forum Rules, particularly the second and third paragraphs.

    I'm closing two of the three threads you started.

    db

    THREAD CLOSED
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Similar Threads

  1. Replies: 0
    Last Post: 11-07-2012, 12:44 PM
  2. Small problem with problem with Java, C++ parse program.
    By dragstang86 in forum New To Java
    Replies: 4
    Last Post: 10-30-2011, 03:43 AM
  3. Replies: 9
    Last Post: 09-21-2010, 04:15 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •