1 package org.openecomp.dcae.dmaapbc.dbcapp.controller;
3 import java.text.DateFormat;
4 import java.text.SimpleDateFormat;
6 import org.springframework.stereotype.Controller;
7 import org.springframework.web.bind.annotation.RequestMapping;
8 import org.springframework.web.bind.annotation.RequestMethod;
9 import org.springframework.web.servlet.ModelAndView;
12 * This controller maps requests for the DMaaP-BC-App's landing page, which is
13 * an Angular single-page application.
17 public class DataBusHomeController extends DbcappRestrictedBaseController {
19 public static final String APP_NAME = "dmaap-bc-app";
20 public static final DateFormat logDateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSXXX");
23 * At one time I published the landing page as simply "/dbc", but it can
24 * also be accessed with a default suffix; e.g., "/dbc.htm".
26 * @return View name key, which is resolved to a file using an Apache tiles
27 * "definitions.xml" file.
29 @RequestMapping(value = { "/dbc" }, method = RequestMethod.GET)
30 public ModelAndView dbcDefaultController() {
31 // a model is only useful for JSP; this app is angular.
32 return new ModelAndView("dbc_home_tdkey");