/**
  * Site HitCounter value
  *
  * @param locale
  * @param model
  * @param key
  * @return
  */
 @RequestMapping(value = "hitcounter", method = RequestMethod.GET)
 public @ResponseBody String getSiteHitCount(
     Locale locale, Model model, @RequestParam(value = "passcode", required = true) String key) {
   if (key.equals("Ameya")) {
     model.addAttribute("counterValue", CountOneUtilities.getCounter());
     return String.valueOf(CountOneUtilities.getCounter());
   } else {
     return "Invalid Request";
   }
 }
 /** Return the selected service page. */
 @RequestMapping(value = "/services", method = RequestMethod.GET)
 public String dashBoardtemmp(
     @RequestParam(value = "serviceName", required = true) String serviceName,
     Locale locale,
     Model model) {
   CountOneUtilities.hitCounter();
   System.out.println("Service Name Requested-> " + serviceName);
   for (Services service : Services.values()) {
     if (serviceName.equals(service.toString())) {
       model.addAttribute(
           "serviceName", CountOneUtilities.getServiceName(service.toString()) + "|");
       return "/services/" + service.toString();
     }
   }
   return "services";
 }
 /** Simply selects the home view to render by returning its name. */
 @RequestMapping(value = "/", method = RequestMethod.GET)
 public String home(Locale locale, Model model, HttpServletRequest request) {
   logger.info("Welcome home! the client locale is " + request.getRemoteAddr());
   CountOneUtilities.hitCounter();
   DateFormat dateFormat =
       DateFormat.getDateTimeInstance(DateFormat.LONG, DateFormat.LONG, locale);
   Runnable pageAccessMonitor = new PageAccessMonitorThread(request, "home", siteAppDao);
   Thread currentthread = new Thread(pageAccessMonitor);
   currentthread.start();
   return "index";
 }
 /** Return the selected service page. */
 @RequestMapping(value = "/Services", method = RequestMethod.GET)
 public String dashBoard(Locale locale, Model model, HttpServletRequest request) {
   String serviceName = request.getParameter("serviceName");
   if (serviceName != null) {
     for (Services service : Services.values()) {
       if (serviceName.equals(service.toString())) {
         String servicedesc = CountOneUtilities.getServiceName(service.toString());
         Runnable pageAccessMonitor =
             new PageAccessMonitorThread(request, servicedesc, siteAppDao);
         Thread currentthread = new Thread(pageAccessMonitor);
         currentthread.start();
         model.addAttribute("serviceName", servicedesc + "|");
         return "/services/" + service.toString();
       }
     }
   }
   return "services";
 }