Announcement Announcement Module
Collapse
No announcement yet.
getting java.lang.IllegalStateException Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • getting java.lang.IllegalStateException

    Hi all

    I am new to spring.I am creating a login application.while i get the username and password matched i return SuccessView and page displayed successfully but when i return the same login page on getting password mismatched got the following exception


    Dec 7, 2011 11:38:53 AM org.apache.catalina.core.StandardWrapperValve invoke
    SEVERE: Servlet.service() for servlet [dispatcher] in context with path [/SimpleLogin] threw exception [java.lang.IllegalStateException: Neither BindingResult nor plain target object for bean name 'User' available as request attribute] with root cause
    java.lang.IllegalStateException: Neither BindingResult nor plain target object for bean name 'User' available as request attribute
    at org.springframework.web.servlet.support.BindStatus .<init>(BindStatus.java:141)
    at org.springframework.web.servlet.tags.form.Abstract DataBoundFormElementTag.getBindStatus(AbstractData BoundFormElementTag.java:174)
    at org.springframework.web.servlet.tags.form.Abstract DataBoundFormElementTag.getPropertyPath(AbstractDa taBoundFormElementTag.java:194)
    at org.springframework.web.servlet.tags.form.Abstract DataBoundFormElementTag.getName(AbstractDataBoundF ormElementTag.java:160)
    at org.springframework.web.servlet.tags.form.Abstract DataBoundFormElementTag.autogenerateId(AbstractDat aBoundFormElementTag.java:147)
    at org.springframework.web.servlet.tags.form.Abstract DataBoundFormElementTag.resolveId(AbstractDataBoun dFormElementTag.java:138)
    at org.springframework.web.servlet.tags.form.Abstract DataBoundFormElementTag.writeDefaultAttributes(Abs tractDataBoundFormElementTag.java:122)
    at org.springframework.web.servlet.tags.form.Abstract HtmlElementTag.writeDefaultAttributes(AbstractHtml ElementTag.java:408)
    at org.springframework.web.servlet.tags.form.InputTag .writeTagContent(InputTag.java:140)
    at org.springframework.web.servlet.tags.form.Abstract FormTag.doStartTagInternal(AbstractFormTag.java:10 2)
    at org.springframework.web.servlet.tags.RequestContex tAwareTag.doStartTag(RequestContextAwareTag.java:7 9)
    at org.apache.jsp.WEB_002dINF.jsp.login_jsp._jspx_met h_form_005finput_005f0(login_jsp.java:222)
    at org.apache.jsp.WEB_002dINF.jsp.login_jsp._jspServi ce(login_jsp.java:120)
    at org.apache.jasper.runtime.HttpJspBase.service(Http JspBase.java:70)
    at javax.servlet.http.HttpServlet.service(HttpServlet .java:722)
    at org.apache.jasper.servlet.JspServletWrapper.servic e(JspServletWrapper.java:432)
    at org.apache.jasper.servlet.JspServlet.serviceJspFil e(JspServlet.java:390)
    at org.apache.jasper.servlet.JspServlet.service(JspSe rvlet.java:334)
    at javax.servlet.http.HttpServlet.service(HttpServlet .java:722)
    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.ApplicationDispatcher.inv oke(ApplicationDispatcher.java:684)
    at org.apache.catalina.core.ApplicationDispatcher.pro cessRequest(ApplicationDispatcher.java:471)
    at org.apache.catalina.core.ApplicationDispatcher.doF orward(ApplicationDispatcher.java:402)
    at org.apache.catalina.core.ApplicationDispatcher.for ward(ApplicationDispatcher.java:329)
    at org.springframework.web.servlet.view.InternalResou rceView.renderMergedOutputModel(InternalResourceVi ew.java:238)
    at org.springframework.web.servlet.view.AbstractView. render(AbstractView.java:250)
    at org.springframework.web.servlet.DispatcherServlet. render(DispatcherServlet.java:1120)
    at org.springframework.web.servlet.DispatcherServlet. doDispatch(DispatcherServlet.java:890)
    at org.springframework.web.servlet.DispatcherServlet. doService(DispatcherServlet.java:792)
    at org.springframework.web.servlet.FrameworkServlet.p rocessRequest(FrameworkServlet.java:851)
    at org.springframework.web.servlet.FrameworkServlet.d oPost(FrameworkServlet.java:767)
    at javax.servlet.http.HttpServlet.service(HttpServlet .java:641)
    at javax.servlet.http.HttpServlet.service(HttpServlet .java:722)
    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:224)
    at org.apache.catalina.core.StandardContextValve.invo ke(StandardContextValve.java:169)
    at org.apache.catalina.authenticator.AuthenticatorBas e.invoke(AuthenticatorBase.java:472)
    at org.apache.catalina.core.StandardHostValve.invoke( StandardHostValve.java:168)
    at org.apache.catalina.valves.ErrorReportValve.invoke (ErrorReportValve.java:98)
    at org.apache.catalina.valves.AccessLogValve.invoke(A ccessLogValve.java:928)
    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:987)
    at org.apache.coyote.AbstractProtocol$AbstractConnect ionHandler.process(AbstractProtocol.java:539)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProce ssor.run(JIoEndpoint.java:300)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run Task(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run (Unknown Source)
    at java.lang.Thread.run(Unknown Source)[/CODE]

    I have tried a lot but couldn't succeed.Needed code are in attachment.
Working...
X