title: Spring MVC: Bean property is not readable or has an invalid getter method Does the return type of the getter match the parameter type of the setter
body: <p>I am new to Spring MVC and I am having a problem in my application, I have been trying to populate a dropdown box with information from my database but I keep getting an error in the JSP, I get all the information in the controller but I cannot show it in the view, I have found similar cases in the site but none has an answer that I can use.</p>
  
  <p>I keep getting the same error no matter what I try, the exception is the following:</p>
  
  <pre><code>org.springframework.beans.NotReadablePropertyException: Invalid property 'nombreEstado' of bean class [java.util.ArrayList]: Bean property 'nombreEstado' is not readable or has an invalid getter method: Does the return type of the getter match the parameter type of the setter?
  org.springframework.beans.BeanWrapperImpl.getPropertyValue(BeanWrapperImpl.java:725)
  org.springframework.beans.BeanWrapperImpl.getPropertyValue(BeanWrapperImpl.java:716)
  org.springframework.web.servlet.support.BindStatus.&lt;init&gt;(BindStatus.java:149)
  org.springframework.web.servlet.tags.form.AbstractDataBoundFormElementTag.getBindStatus(AbstractDataBoundFormElementTag.java:168)
  org.springframework.web.servlet.tags.form.AbstractDataBoundFormElementTag.getPropertyPath(AbstractDataBoundFormElementTag.java:188)
  org.springframework.web.servlet.tags.form.AbstractDataBoundFormElementTag.getName(AbstractDataBoundFormElementTag.java:154)
  org.springframework.web.servlet.tags.form.AbstractDataBoundFormElementTag.writeDefaultAttributes(AbstractDataBoundFormElementTag.java:117)
  org.springframework.web.servlet.tags.form.AbstractHtmlElementTag.writeDefaultAttributes(AbstractHtmlElementTag.java:422)
  org.springframework.web.servlet.tags.form.SelectTag.writeTagContent(SelectTag.java:194)
  org.springframework.web.servlet.tags.form.AbstractFormTag.doStartTagInternal(AbstractFormTag.java:84)
  org.springframework.web.servlet.tags.RequestContextAwareTag.doStartTag(RequestContextAwareTag.java:80)
  org.apache.jsp.WEB_002dINF.views.home_jsp._jspService(home_jsp.java:141)
  org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
  org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
  org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
  org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
  org.springframework.web.servlet.view.InternalResourceView.renderMergedOutputModel(InternalResourceView.java:209)
  org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:267)
  org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1225)
  org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:1012)
  org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:959)
  org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:876)
  org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:961)
  org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:852)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
  org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:837)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
  org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52
  </code></pre>
  
  <p>Right now I have this method in my controller: </p>
  
  <pre><code>@ModelAttribute("estados")
  public List&lt;Estado&gt; obtenerEstados(){
      logger.debug("buscando todos los estados");
  
      for (int i = 0; i &lt; this.estadoBo.obtenerEstados().size(); i++) {
          System.out.println(this.estadoBo.obtenerEstados().get(i).getNombreEstado());
      }
  
      return this.estadoBo.obtenerEstados();
  }
  </code></pre>
  
  <p>I used the cycle just to see if the values were coming right from the database</p>
  
  <p>And the JSP</p>
  
  <pre><code>&lt;form:form modelAttribute="estados"&gt;
      &lt;form:select path="nombreEstado" id="nombreEstado"&gt;
          &lt;form:option value=""&gt;Estado: &lt;/form:option&gt;
          &lt;c:forEach items="${estados.getNombreEstado}" var="estado"&gt;
              &lt;form:option value="${estado}"&gt;${estado}&lt;/form:option&gt;
          &lt;/c:forEach&gt;
      &lt;/form:select&gt;
  </code></pre>
  
  <p>I get the error in the line of the select path = "nombreEstado"</p>
  
  <p>I don't know what I am doing wrong, any help will be welcomed</p>
  
  <p>Thanks in Advance </p>