title: BeanUtils.populate throwing NullPointerException in struts after migrating to Tomcat7
body: <p>I am migrating a Struts 1 application from Tomcat 6 to Tomcat 7. most of the application is working fine but at a point while a form submit the following error is occurring.</p>
  
  <pre><code>javax.servlet.ServletException: BeanUtils.populate
      org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1254)
      org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.java:821)
      org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:254)
      org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
      org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:646)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
      org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
  
  root cause
  
  java.lang.NullPointerException
      org.apache.commons.beanutils.PropertyUtilsBean.getIndexedProperty(PropertyUtilsBean.java:543)
      org.apache.commons.beanutils.PropertyUtilsBean.getIndexedProperty(PropertyUtilsBean.java:446)
      org.apache.commons.beanutils.PropertyUtilsBean.getNestedProperty(PropertyUtilsBean.java:806)
      org.apache.commons.beanutils.PropertyUtilsBean.getProperty(PropertyUtilsBean.java:884)
      org.apache.commons.beanutils.BeanUtilsBean.setProperty(BeanUtilsBean.java:894)
      org.apache.commons.beanutils.BeanUtilsBean.populate(BeanUtilsBean.java:821)
      org.apache.commons.beanutils.BeanUtils.populate(BeanUtils.java:431)
      org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1252)
      org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.java:821)
      org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:254)
      org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
      org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:646)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
      org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
  
  note The full stack trace of the root cause is available in the Apache Tomcat/7.0.55 logs.
  </code></pre>
  
  <p>Does any one have an idea why this is occurring?</p>
  
  <p>The full stack trace is </p>
  
  <pre><code>java.lang.NullPointerException
      at org.apache.commons.beanutils.PropertyUtilsBean.getIndexedProperty(PropertyUtilsBean.java:543)
      at org.apache.commons.beanutils.PropertyUtilsBean.getIndexedProperty(PropertyUtilsBean.java:446)
      at org.apache.commons.beanutils.PropertyUtilsBean.getNestedProperty(PropertyUtilsBean.java:806)
      at org.apache.commons.beanutils.PropertyUtilsBean.getProperty(PropertyUtilsBean.java:884)
      at org.apache.commons.beanutils.BeanUtilsBean.setProperty(BeanUtilsBean.java:894)
      at org.apache.commons.beanutils.BeanUtilsBean.populate(BeanUtilsBean.java:821)
      at org.apache.commons.beanutils.BeanUtils.populate(BeanUtils.java:431)
      at org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1252)
      at org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.java:821)
      at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:254)
      at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
      at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:646)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
      at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
      at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:610)
      at com.homedepot.ta.aa.catalina.realm.THDFormAuthenticator.invoke(Unknown Source)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
      at com.homedepot.ta.aa.dao.catalina.THDDAOValve.invoke(Unknown Source)
      at com.homedepot.ta.aa.catalina.realm.THDSingleSignOn.invoke(Unknown Source)
      at com.homedepot.ta.aa.catalina.valves.HDAccessLogValve.invoke(Unknown Source)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)
      at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1070)
      at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
      at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:314)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
      at java.lang.Thread.run(Thread.java:745)
  </code></pre>
  
  <p>This is occurring even before it is going to the particular class. the application is working as expected in tomcat 6.</p>