title: Spring MVC Homepage Controller
body: <p>I have generated some pages using Spring Roo, and I need to show some items from database on the homepage of the application.
  So how can I pass model with data to homepage, Roo has added following lines which I have commented out</p>
  
  <pre><code>    &lt;mvc:view-controller path="/" view-name="index"/&gt;
  </code></pre>
  
  <p>I created a new controller using Roo called Home like this</p>
  
  <pre><code>    @RequestMapping("/")
      @Controller
      public class Home {
              @RequestMapping(method = RequestMethod.GET)
              public String index() {
                  return "index";
              }
      }
  </code></pre>
  
  <p>Now all the pages show Index view, even /login .</p>
  
  <p>Regards and thanks.</p>