cmda-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xingwei...@apache.org
Subject [5/5] incubator-cmda git commit: Add KnowledgeGraph page and recommendationSummary page. Update backend models and create new APIs to support new features. Add KnowledgCard in Dataset search result page.
Date Thu, 29 Oct 2015 22:46:00 GMT
Add KnowledgeGraph page and recommendationSummary page. Update backend models and create new APIs to support new features. Add KnowledgCard in Dataset search result page.


Project: http://git-wip-us.apache.org/repos/asf/incubator-cmda/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cmda/commit/aa50efa2
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cmda/tree/aa50efa2
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cmda/diff/aa50efa2

Branch: refs/heads/master
Commit: aa50efa2b8ef25fb4abf3ada96bda0aa54ffaf87
Parents: a9a8367
Author: mingqi830 <mqi@andrew.cmu.edu>
Authored: Thu Oct 29 15:45:45 2015 -0700
Committer: mingqi830 <mqi@andrew.cmu.edu>
Committed: Thu Oct 29 15:45:45 2015 -0700

----------------------------------------------------------------------
 ApacheCMDA_Backend_1.0/DBDump/Dump20150414.sql  |    32 +
 .../app/controllers/AnalyticsController.java    |   128 +
 .../controllers/ClimateServiceController.java   |    19 +-
 .../app/controllers/DatasetController.java      |     2 -
 .../app/controllers/DatasetLogController.java   |     1 -
 .../ServiceExecutionLogController.java          |     4 +-
 .../app/models/ClimateServiceRepository.java    |     4 +-
 ApacheCMDA_Backend_1.0/app/models/Dataset.java  |     9 +
 .../app/models/DatasetAndUser.java              |    69 +
 .../app/models/DatasetAndUserRepository.java    |    12 +
 .../app/models/DatasetLogRepository.java        |     2 +-
 .../app/models/Instrument.java                  |     9 +
 .../app/models/ServiceExecutionLog.java         |    13 +-
 ApacheCMDA_Backend_1.0/conf/routes              |     4 +
 .../app/controllers/AnalyticsController.java    |    32 +-
 .../controllers/ClimateServiceController.java   |   482 +-
 .../app/controllers/DatasetController.java      |    68 +-
 .../app/controllers/DatasetLogController.java   |     4 +-
 .../ServiceExecutionLogController.java          |    14 +-
 ApacheCMDA_Frontend_1.0/app/models/Dataset.java |    32 +-
 .../app/models/Instrument.java                  |     9 +
 .../app/models/ServiceExecutionLog.java         |    13 +-
 .../app/utils/Constants.java                    |     5 +
 .../app/views/aboutUs.scala.html                |     6 +-
 .../app/views/allClimateServices.scala.html     |    17 +-
 .../app/views/allDatasets.scala.html            |     2 +-
 .../app/views/climateServiceList.scala.html     |    62 +
 .../app/views/dataSetList.scala.html            |    18 +-
 .../app/views/dataSetListPopular.scala.html     |    68 +
 .../app/views/header.scala.html                 |    18 +-
 .../app/views/knowledgeGraph.scala.html         |   320 +
 .../app/views/main.scala.html                   |     2 -
 .../app/views/recommendationSummary.scala.html  |   171 +
 .../app/views/searchClimateService.scala.html   |   117 +
 .../app/views/serviceLog.scala.html             |    19 +-
 ApacheCMDA_Frontend_1.0/conf/routes             |     8 +
 .../public/html/js2/.DS_Store                   |   Bin 0 -> 6148 bytes
 .../public/html/js2/common.css                  |    29 +
 .../public/html/js2/common.js                   |   548 +
 .../public/html/js2/dataList2.js                |    42 +
 .../public/html/js2/varList.js                  |    40 +
 .../public/html/serviceScatterPlot2Vars.html    |   672 +
 ApacheCMDA_Frontend_1.0/public/images/giphy.gif |   Bin 0 -> 998904 bytes
 .../public/javascripts/exampleUtil.js           |   126 +
 .../public/javascripts/googleAnalytics.js       |    12 +
 .../public/javascripts/vis.js                   | 43387 +++++++++++++++++
 .../public/stylesheets/vis.css                  |  1295 +
 47 files changed, 47686 insertions(+), 260 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/DBDump/Dump20150414.sql
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/DBDump/Dump20150414.sql b/ApacheCMDA_Backend_1.0/DBDump/Dump20150414.sql
index 48130c2..169081f 100644
--- a/ApacheCMDA_Backend_1.0/DBDump/Dump20150414.sql
+++ b/ApacheCMDA_Backend_1.0/DBDump/Dump20150414.sql
@@ -186,6 +186,7 @@ CREATE TABLE `Dataset` (
   `dataSourceNameinWebInterface` varchar(255) DEFAULT NULL,
   `startTime` datetime DEFAULT NULL,
   `endTime` datetime DEFAULT NULL,
+  `agencyURL` varchar(255) DEFAULT NULL,
   PRIMARY KEY (`id`),
   KEY `FK_9x29nf004vryd28iummv5l5r0` (`instrumentId`),
   CONSTRAINT `FK_9x29nf004vryd28iummv5l5r0` FOREIGN KEY (`instrumentId`) REFERENCES `Instrument` (`id`)
@@ -203,6 +204,35 @@ INSERT INTO `Dataset` VALUES (1,'ot','NOAA','NOAA_ARGO','3D','ARGO Ocean Tempera
 UNLOCK TABLES;
 
 --
+-- Table structure for table `DatasetAndUser`
+--
+
+DROP TABLE IF EXISTS `DatasetAndUser`;
+/*!40101 SET @saved_cs_client     = @@character_set_client */;
+/*!40101 SET character_set_client = utf8 */;
+CREATE TABLE `DatasetAndUser` (
+  `id` bigint(20) NOT NULL AUTO_INCREMENT,
+  `userId` bigint(20) NOT NULL,
+  `datasetId` bigint(20) NOT NULL,
+  `count` int(11) DEFAULT NULL,
+  PRIMARY KEY (`id`),
+  KEY `FK_User_DatasetAndUser` (`userId`),
+  KEY `FK_Dataset_DatasetAndUser` (`datasetId`),
+  CONSTRAINT `FK_User_DatasetAndUser` FOREIGN KEY (`userId`) REFERENCES `User` (`id`),
+  CONSTRAINT `FK_Dataset_DatasetAndUser` FOREIGN KEY (`datasetId`) REFERENCES `Dataset` (`id`)
+) ENGINE=InnoDB DEFAULT CHARSET=latin1;
+/*!40101 SET character_set_client = @saved_cs_client */;
+
+--
+-- Dumping data for table `DatasetAndUser`
+--
+
+LOCK TABLES `DatasetAndUser` WRITE;
+/*!40000 ALTER TABLE `DatasetAndUser` DISABLE KEYS */;
+/*!40000 ALTER TABLE `DatasetAndUser` ENABLE KEYS */;
+UNLOCK TABLES;
+
+--
 -- Table structure for table `DatasetAndService`
 --
 
@@ -285,6 +315,7 @@ CREATE TABLE `Instrument` (
   `description` varchar(255) DEFAULT NULL,
   `launchDate` datetime DEFAULT NULL,
   `name` varchar(255) DEFAULT NULL,
+  `instrumentURL` varchar(255) DEFAULT NULL,
   PRIMARY KEY (`id`)
 ) ENGINE=InnoDB AUTO_INCREMENT=16 DEFAULT CHARSET=latin1;
 /*!40101 SET character_set_client = @saved_cs_client */;
@@ -464,6 +495,7 @@ CREATE TABLE `ServiceExecutionLog` (
   `userId` bigint(20) NOT NULL,
   `datasetStudyStartTime` datetime DEFAULT NULL,
   `datasetStudyEndTime` datetime DEFAULT NULL,
+  `url` text DEFAULT NULL,
   PRIMARY KEY (`id`),
   KEY `FK_ly45hkuqs8yyw00iiuyx5hoj4` (`serviceId`),
   KEY `FK_g2n3b4rs0xys2r4r967uvi4jr` (`serviceConfigurationId`),

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/controllers/AnalyticsController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/controllers/AnalyticsController.java b/ApacheCMDA_Backend_1.0/app/controllers/AnalyticsController.java
new file mode 100644
index 0000000..feed694
--- /dev/null
+++ b/ApacheCMDA_Backend_1.0/app/controllers/AnalyticsController.java
@@ -0,0 +1,128 @@
+package controllers;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import javax.inject.Inject;
+import javax.inject.Named;
+import javax.inject.Singleton;
+
+import models.DatasetAndUser;
+import models.DatasetAndUserRepository;
+import play.mvc.Controller;
+import play.mvc.Result;
+
+import com.google.gson.Gson;
+
+@Named
+@Singleton
+public class AnalyticsController extends Controller{
+	private final DatasetAndUserRepository datasetAndUserRepository;
+	@Inject
+	public AnalyticsController(DatasetAndUserRepository datasetAndUserRepository) {
+		this.datasetAndUserRepository = datasetAndUserRepository;
+	}
+	
+	public Result getAllDatasetAndUserWithCount(String format) {
+
+		try {
+			Iterable<DatasetAndUser> datasetAndUsers = datasetAndUserRepository.findAll();
+
+			if (datasetAndUsers == null) {
+				System.out.println("User and Dataset: cannot be found!");
+				return notFound("User and Dataset: cannot be found!");
+			}  
+
+			Map<String, Object> map = jsonFormat(datasetAndUsers);
+
+			String result = new String();
+			if (format.equals("json")) {
+				result = new Gson().toJson(map);
+			}
+
+			return ok(result);
+		} catch (Exception e) {
+			return badRequest("DatasetLog not found");
+		}
+	}
+
+	private Map<String, Object> jsonFormat(Iterable<DatasetAndUser> userDatasets) {
+
+		List<Map<String, Object>> nodes = new ArrayList<Map<String, Object>>();
+		List<Map<String, Object>> rels = new ArrayList<Map<String, Object>>();
+
+		int i = 1;
+		for (DatasetAndUser userDataset : userDatasets) {
+			int source = 0;
+			int target = 0;
+			// Check whether the current user has already existed
+			for (int j = 0; j < nodes.size(); j++) {
+				if (nodes.get(j).get("title")
+						.equals(userDataset.getUser().getUserName())) {
+					source = (int) nodes.get(j).get("id");
+					break;
+				}
+			}
+			if (source == 0) {
+				nodes.add(map6("id", i, "title", userDataset.getUser()
+						.getUserName(), "label", "user", "cluster", "1",
+						"value", 1, "group", "user"));
+				source = i;
+				i++;
+			}
+			// Check whether the current dataset has already existed
+			for (int j = 0; j < nodes.size(); j++) {
+				if (nodes.get(j).get("title")
+						.equals(userDataset.getDataset().getName())) {
+					target = (int) nodes.get(j).get("id");
+					break;
+				}
+			}
+			if (target == 0) {
+				nodes.add(map6("id", i, "title", userDataset.getDataset()
+						.getName(), "label", "dataset", "cluster", "2",
+						"value", 2, "group", "dataset"));
+				target = i;
+				i++;
+			}
+
+			rels.add(map3("from", source, "to", target, "title", "USE"));
+
+		}
+
+		return map("nodes", nodes, "edges", rels);
+	}
+
+	private Map<String, Object> map(String key1, Object value1, String key2,
+			Object value2) {
+		Map<String, Object> result = new HashMap<String, Object>(2);
+		result.put(key1, value1);
+		result.put(key2, value2);
+		return result;
+	}
+
+	private Map<String, Object> map3(String key1, Object value1, String key2,
+			Object value2, String key3, Object value3) {
+		Map<String, Object> result = new HashMap<String, Object>(3);
+		result.put(key1, value1);
+		result.put(key2, value2);
+		result.put(key3, value3);
+		return result;
+	}
+
+	private Map<String, Object> map6(String key1, Object value1, String key2,
+			Object value2, String key3, Object value3, String key4,
+			Object value4, String key5, Object value5, String key6,
+			Object value6) {
+		Map<String, Object> result = new HashMap<String, Object>(6);
+		result.put(key1, value1);
+		result.put(key2, value2);
+		result.put(key3, value3);
+		result.put(key4, value4);
+		result.put(key5, value5);
+		result.put(key6, value6);
+		return result;
+	}
+}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/controllers/ClimateServiceController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/controllers/ClimateServiceController.java b/ApacheCMDA_Backend_1.0/app/controllers/ClimateServiceController.java
index 73722b3..700ad68 100644
--- a/ApacheCMDA_Backend_1.0/app/controllers/ClimateServiceController.java
+++ b/ApacheCMDA_Backend_1.0/app/controllers/ClimateServiceController.java
@@ -472,5 +472,22 @@ public class ClimateServiceController extends Controller {
         return ok(result);
 
     }
-
+    
+    public Result getTopKUsedClimateServicesByDatasetId(long id, String format) {
+    	if (id < 0) {
+			System.out.println("id is negative!");
+			return badRequest("id is negative!");
+		}
+    	String result = new String();
+    	try {
+    		//Parse JSON file
+    		List<ClimateService> climateService;
+    		climateService = climateServiceRepository.getClimateServiceByDatasetId(5, id);
+    		result = new Gson().toJson(climateService);
+    	} catch (Exception e) {
+    		System.out.println("ServiceExecutionLog cannot be queried, query is corrupt");
+    		return badRequest("ServiceExecutionLog cannot be queried, query is corrupt");
+    	}
+    	return ok(result);
+    }
 }

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/controllers/DatasetController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/controllers/DatasetController.java b/ApacheCMDA_Backend_1.0/app/controllers/DatasetController.java
index 295c0a2..23822b4 100644
--- a/ApacheCMDA_Backend_1.0/app/controllers/DatasetController.java
+++ b/ApacheCMDA_Backend_1.0/app/controllers/DatasetController.java
@@ -366,8 +366,6 @@ public class DatasetController extends Controller {
     		System.out.println("ServiceExecutionLog cannot be queried, query is corrupt");
     		return badRequest("ServiceExecutionLog cannot be queried, query is corrupt");
     	}
-    	System.out.println("************" + result);
-
     	return ok(result);
     }
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/controllers/DatasetLogController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/controllers/DatasetLogController.java b/ApacheCMDA_Backend_1.0/app/controllers/DatasetLogController.java
index 432cf16..f92b68e 100644
--- a/ApacheCMDA_Backend_1.0/app/controllers/DatasetLogController.java
+++ b/ApacheCMDA_Backend_1.0/app/controllers/DatasetLogController.java
@@ -3,7 +3,6 @@ package controllers;
 import java.text.ParseException;
 import java.text.SimpleDateFormat;
 import java.util.Date;
-
 import javax.inject.Inject;
 import javax.inject.Named;
 import javax.inject.Singleton;

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/controllers/ServiceExecutionLogController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/controllers/ServiceExecutionLogController.java b/ApacheCMDA_Backend_1.0/app/controllers/ServiceExecutionLogController.java
index 507d549..e4594a8 100644
--- a/ApacheCMDA_Backend_1.0/app/controllers/ServiceExecutionLogController.java
+++ b/ApacheCMDA_Backend_1.0/app/controllers/ServiceExecutionLogController.java
@@ -342,8 +342,8 @@ public class ServiceExecutionLogController extends Controller {
 		String purpose = json.findPath("purpose").asText();
 		String plotUrl = json.findPath("url").asText();
 		String dataUrl = json.findPath("dataUrl").asText();
+		String url = json.findPath("urlLink").asText();
 		JsonNode datasetArray = json.get("datasets");
-		System.out.println(datasetArray);
 
 		SimpleDateFormat formatter = new SimpleDateFormat(util.Common.DATE_PATTERN);
 		formatter.setTimeZone(TimeZone.getTimeZone("America/Los_Angeles"));
@@ -415,7 +415,7 @@ public class ServiceExecutionLogController extends Controller {
 			ServiceExecutionLog serviceExecutionLog = new ServiceExecutionLog(
 					climateService, user, serviceConfiguration, purpose,
 					executionStartTime, executionEndTime, dataUrl, plotUrl,
-					datasetStudyStartTime, datasetStudyEndTime);
+					datasetStudyStartTime, datasetStudyEndTime, url);
 			ServiceExecutionLog savedServiceExecutionLog = serviceExecutionLogRepository
 					.save(serviceExecutionLog);
 			ServiceConfiguration savedServiceConfiguration = savedServiceExecutionLog

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/models/ClimateServiceRepository.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/models/ClimateServiceRepository.java b/ApacheCMDA_Backend_1.0/app/models/ClimateServiceRepository.java
index 53a303f..2f70c53 100644
--- a/ApacheCMDA_Backend_1.0/app/models/ClimateServiceRepository.java
+++ b/ApacheCMDA_Backend_1.0/app/models/ClimateServiceRepository.java
@@ -21,5 +21,7 @@ public interface ClimateServiceRepository extends CrudRepository<ClimateService,
 
 	@Query(value = "select c.* from ClimateService c, ServiceEntry s where c.id=s.serviceId group by s.serviceId order by s.latestAccessTimeStamp desc", nativeQuery = true)
 	List<ClimateService> getClimateServiceOrderByLatestAccessTime();
-
+	
+	@Query(value = "select * from ClimateService where id in (select serviceId from ServiceEntry s where serviceId in (select climateServiceId from DatasetAndService where datasetId=?2) group by s.serviceId order by s.latestAccessTimeStamp desc) limit ?1", nativeQuery = true)
+	List<ClimateService> getClimateServiceByDatasetId(int k, long id);
 }

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/models/Dataset.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/models/Dataset.java b/ApacheCMDA_Backend_1.0/app/models/Dataset.java
index 884a957..0d4fc3c 100644
--- a/ApacheCMDA_Backend_1.0/app/models/Dataset.java
+++ b/ApacheCMDA_Backend_1.0/app/models/Dataset.java
@@ -45,6 +45,7 @@ public class Dataset {
 	private String comment;
 	private Date startTime;
 	private Date endTime;
+	private String agencyURL;
 	
 
 	public Dataset() {
@@ -82,6 +83,14 @@ public class Dataset {
 		this.endTime = endTime;
 	}
 
+	public String getAgencyURL() {
+		return agencyURL;
+	}
+
+	public void setAgencyURL(String agencyURL) {
+		this.agencyURL = agencyURL;
+	}
+
 	public long getId() {
 		return id;
 	}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/models/DatasetAndUser.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/models/DatasetAndUser.java b/ApacheCMDA_Backend_1.0/app/models/DatasetAndUser.java
new file mode 100644
index 0000000..53665b3
--- /dev/null
+++ b/ApacheCMDA_Backend_1.0/app/models/DatasetAndUser.java
@@ -0,0 +1,69 @@
+package models;
+
+import javax.persistence.Entity;
+import javax.persistence.GeneratedValue;
+import javax.persistence.GenerationType;
+import javax.persistence.Id;
+import javax.persistence.JoinColumn;
+import javax.persistence.ManyToOne;
+
+@Entity
+public class DatasetAndUser {
+
+	@Id
+	@GeneratedValue(strategy = GenerationType.AUTO)
+	private long id;
+	@ManyToOne(optional = false)
+	@JoinColumn(name = "userId", referencedColumnName = "id")
+	private User user;
+	@ManyToOne(optional = false)
+	@JoinColumn(name = "datasetId", referencedColumnName = "id")
+	private Dataset dataset;
+	private long count;
+	
+	public DatasetAndUser() {
+	}
+	
+	public DatasetAndUser(User user, Dataset dataset, long count) {
+		this.user = user;
+		this.dataset = dataset;
+		this.count = count;
+	}
+
+	public long getId() {
+		return id;
+	}
+
+	public void setId(long id) {
+		this.id = id;
+	}
+
+	public User getUser() {
+		return user;
+	}
+
+	public void setUser(User user) {
+		this.user = user;
+	}
+
+	public Dataset getDataset() {
+		return dataset;
+	}
+
+	public void setDataset(Dataset dataset) {
+		this.dataset = dataset;
+	}
+
+	public long getCount() {
+		return count;
+	}
+	public void setCount(long count) {
+		this.count = count;
+	}
+	
+	@Override
+	public String toString() {
+		return "DatasetAndUser[id=" + id + ", user=" + user.toString()
+				+ ", dataset=" + dataset.toString() + ", count=" + count + "]";
+	}
+}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/models/DatasetAndUserRepository.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/models/DatasetAndUserRepository.java b/ApacheCMDA_Backend_1.0/app/models/DatasetAndUserRepository.java
new file mode 100644
index 0000000..ce6b046
--- /dev/null
+++ b/ApacheCMDA_Backend_1.0/app/models/DatasetAndUserRepository.java
@@ -0,0 +1,12 @@
+package models;
+
+import org.springframework.data.repository.CrudRepository;
+
+import javax.inject.Named;
+import javax.inject.Singleton;
+
+@Named
+@Singleton
+public interface DatasetAndUserRepository extends CrudRepository<DatasetAndUser, Long> {
+		
+}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/models/DatasetLogRepository.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/models/DatasetLogRepository.java b/ApacheCMDA_Backend_1.0/app/models/DatasetLogRepository.java
index 3381b4e..de4ce6c 100644
--- a/ApacheCMDA_Backend_1.0/app/models/DatasetLogRepository.java
+++ b/ApacheCMDA_Backend_1.0/app/models/DatasetLogRepository.java
@@ -8,5 +8,5 @@ import javax.inject.Singleton;
 @Named
 @Singleton
 public interface DatasetLogRepository extends CrudRepository<DatasetLog, Long> {
-
+	
 }

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/models/Instrument.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/models/Instrument.java b/ApacheCMDA_Backend_1.0/app/models/Instrument.java
index 71a0094..45aed25 100644
--- a/ApacheCMDA_Backend_1.0/app/models/Instrument.java
+++ b/ApacheCMDA_Backend_1.0/app/models/Instrument.java
@@ -15,6 +15,7 @@ public class Instrument {
 	private String name;
 	private String description;
 	private Date launchDate;
+	private String instrumentURL;
 	
 	public Instrument() {
 	}
@@ -26,6 +27,14 @@ public class Instrument {
 		this.launchDate = launchDate;
 	}
 
+	public String getInstrumentURL() {
+		return instrumentURL;
+	}
+
+	public void setInstrumentURL(String instrumentURL) {
+		this.instrumentURL = instrumentURL;
+	}
+
 	public long getId() {
 		return id;
 	}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/app/models/ServiceExecutionLog.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/app/models/ServiceExecutionLog.java b/ApacheCMDA_Backend_1.0/app/models/ServiceExecutionLog.java
index c35c6c4..86351dc 100644
--- a/ApacheCMDA_Backend_1.0/app/models/ServiceExecutionLog.java
+++ b/ApacheCMDA_Backend_1.0/app/models/ServiceExecutionLog.java
@@ -40,6 +40,7 @@ public class ServiceExecutionLog {
 	private String dataUrl;
 	private Date datasetStudyStartTime;
 	private Date datasetStudyEndTime;
+	private String url;
 	
 
 	public ServiceExecutionLog(
@@ -47,7 +48,7 @@ public class ServiceExecutionLog {
 			ServiceConfiguration serviceConfiguration, // DatasetLog datasetLog,
 			String purpose, Date executionStartTime, Date executionEndTime,
 			String dataUrl, String plotUrl,
-			Date datasetStudyStartTime, Date datasetStudyEndTime) {
+			Date datasetStudyStartTime, Date datasetStudyEndTime, String url) {
 	this.climateService = climateService;
 		this.user = user;
 		this.serviceConfiguration = serviceConfiguration;
@@ -59,6 +60,7 @@ public class ServiceExecutionLog {
 		this.dataUrl = dataUrl;
 		this.datasetStudyStartTime = datasetStudyStartTime;
 		this.datasetStudyEndTime = datasetStudyEndTime;
+		this.url = url;
 	}
 	
 	public ServiceExecutionLog() {
@@ -111,6 +113,10 @@ public class ServiceExecutionLog {
 	
 	public Date getDatasetStudyEndTime() {
 		return datasetStudyEndTime;
+	}	
+
+	public String getUrl() {
+		return url;
 	}
 	
 	public void setId(long id) {
@@ -161,6 +167,10 @@ public class ServiceExecutionLog {
 		this.datasetStudyEndTime  = datasetStudyEndTime;
 	}
 
+	public void setUrl(String url) {
+		this.url = url;
+	}
+
 	@Override
 	public String toString() {
 		return "ServiceExecutionLog [id=" + id + ", climateService="
@@ -171,6 +181,7 @@ public class ServiceExecutionLog {
 				+ plotUrl + ", dataUrl=" + dataUrl 
 				+ ", datasetStudyStartTime=" + datasetStudyStartTime
 				+ ", datasetStudyEndTime=" + datasetStudyEndTime
+				+ ", url=" + url
 				+ "]";
 	}
 

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Backend_1.0/conf/routes
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Backend_1.0/conf/routes b/ApacheCMDA_Backend_1.0/conf/routes
index ff3d46c..b59bff7 100644
--- a/ApacheCMDA_Backend_1.0/conf/routes
+++ b/ApacheCMDA_Backend_1.0/conf/routes
@@ -13,6 +13,7 @@ GET           /climateService/getAllClimateServices/json
 GET           /climateService/getAllMostRecentClimateServicesByCreateTime/json                          @controllers.ClimateServiceController.getAllClimateServicesOrderByCreateTime(format: String="json")
 GET           /climateService/getAllMostRecentClimateServicesByLatestAccessTime/json                    @controllers.ClimateServiceController.getAllClimateServicesOrderByLatestAccessTime(format: String="json")
 GET           /climateService/getAllMostUsedClimateServices/json                                        @controllers.ClimateServiceController.getAllClimateServicesOrderByCount(format: String="json")
+GET			  /climateService/getTopKUsedClimateServicesByDatasetId/:id									@controllers.ClimateServiceController.getTopKUsedClimateServicesByDatasetId(id: Long, format: String="json")
 POST          /climateService/addClimateService                                                         @controllers.ClimateServiceController.addClimateService
 GET           /climateService/getAllServiceEntries/json                                                 @controllers.ClimateServiceController.getAllServiceEntries(format: String="json")
 POST          /climateService/addServiceEntry                                                           @controllers.ClimateServiceController.addServiceEntry
@@ -136,5 +137,8 @@ POST		  /users/isUserValid																		@controllers.UserController.isUserVa
 POST		  /users/isEmailExisted																		@controllers.UserController.isEmailExisted
 DELETE		  /users/delete/userName/:userName/password/:password										@controllers.UserController.deleteUserByUserNameandPassword(userName: String, password: String)
 
+# Analytics
+GET			  /analytics/getAllDatasetAndUserWithCount/json											@controllers.AnalyticsController.getAllDatasetAndUserWithCount(format: String="json")
+
 # Map static resources from the /public folder to the /assets URL path
 GET           /assets/*file                                                                             controllers.Assets.at(path="/public", file)

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/controllers/AnalyticsController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/controllers/AnalyticsController.java b/ApacheCMDA_Frontend_1.0/app/controllers/AnalyticsController.java
index 873ecfa..75d7881 100644
--- a/ApacheCMDA_Frontend_1.0/app/controllers/AnalyticsController.java
+++ b/ApacheCMDA_Frontend_1.0/app/controllers/AnalyticsController.java
@@ -1,39 +1,14 @@
 package controllers;
 
-import java.io.BufferedWriter;
-import java.io.File;
-import java.io.FileNotFoundException;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.text.DateFormat;
-import java.text.ParseException;
-import java.text.SimpleDateFormat;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map.Entry;
-
-import org.apache.commons.lang3.StringEscapeUtils;
-
-import models.ClimateService;
 import models.ServiceExecutionLog;
-import play.Logger;
-import play.data.DynamicForm;
 import play.data.Form;
-import play.libs.Json;
 import play.mvc.Controller;
 import play.mvc.Result;
 import utils.Constants;
 import utils.RESTfulCalls;
-import utils.RESTfulCalls.ResponseType;
 import views.html.*;
-import models.*;
-import views.*;
 
 import com.fasterxml.jackson.databind.JsonNode;
-import com.fasterxml.jackson.databind.node.ObjectNode;
 
 public class AnalyticsController extends Controller{
 
@@ -41,6 +16,13 @@ public class AnalyticsController extends Controller{
 			.form(ServiceExecutionLog.class);
 	
 	
+	public static Result getKnowledgeGraph() {
+		JsonNode response = RESTfulCalls.getAPI(Constants.URL_HOST
+				+ Constants.CMU_BACKEND_PORT + Constants.GET_DATASET_AND_USER);
+		String resStr = response.toString();
+		return ok(knowledgeGraph.render(resStr));
+	}
+	
 	public static Result getRecommend() {
 		JsonNode response = RESTfulCalls.getAPI("http://einstein.sv.cmu.edu:9026/api/sgraph");
 		String resStr = response.toString();

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/controllers/ClimateServiceController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/controllers/ClimateServiceController.java b/ApacheCMDA_Frontend_1.0/app/controllers/ClimateServiceController.java
index f103643..e0c0739 100644
--- a/ApacheCMDA_Frontend_1.0/app/controllers/ClimateServiceController.java
+++ b/ApacheCMDA_Frontend_1.0/app/controllers/ClimateServiceController.java
@@ -12,6 +12,7 @@ import java.nio.file.Files;
 import java.nio.file.Path;
 import java.nio.file.Paths;
 import java.text.DateFormat;
+import java.text.ParseException;
 import java.text.SimpleDateFormat;
 import java.util.ArrayList;
 import java.util.Date;
@@ -24,6 +25,7 @@ import static java.nio.file.StandardCopyOption.REPLACE_EXISTING;
 import org.apache.commons.lang3.StringEscapeUtils;
 
 import models.ClimateService;
+import models.Dataset;
 import models.ServiceConfigurationItem;
 import models.User;
 import play.Logger;
@@ -38,13 +40,14 @@ import utils.RESTfulCalls.ResponseType;
 import views.html.*;
 
 import com.fasterxml.jackson.databind.JsonNode;
+import com.fasterxml.jackson.databind.ObjectMapper;
 import com.fasterxml.jackson.databind.node.ObjectNode;
 
 public class ClimateServiceController extends Controller {
 
 	final static Form<ClimateService> climateServiceForm = Form
-			.form(ClimateService.class); 
-	
+			.form(ClimateService.class);
+
 	public static Result addAClimateService() {
 		return ok(registerAClimateService.render(climateServiceForm));
 	}
@@ -54,32 +57,17 @@ public class ClimateServiceController extends Controller {
 		JsonNode climateServicesNode = RESTfulCalls.getAPI(Constants.URL_HOST
 				+ Constants.CMU_BACKEND_PORT
 				+ Constants.GET_ALL_CLIMATE_SERVICES);
-		System.out.println("GET API: " + Constants.URL_HOST
-				+ Constants.CMU_BACKEND_PORT
-				+ Constants.GET_ALL_CLIMATE_SERVICES);
 		// if no value is returned or error or is not json array
 		if (climateServicesNode == null || climateServicesNode.has("error")
 				|| !climateServicesNode.isArray()) {
 			return ok(allClimateServices.render(climateServicesList,
-				climateServiceForm));
+					climateServiceForm));
 		}
-	
+
 		// parse the json string into object
 		for (int i = 0; i < climateServicesNode.size(); i++) {
 			JsonNode json = climateServicesNode.path(i);
-			ClimateService oneService = new ClimateService();
-			oneService.setName(json.path("name").asText());
-			System.out.println("****************"+json.path("name").asText());
-			oneService.setPurpose(json.path("purpose").asText());
-			// URL here is the dynamic page url
-			String name = json.path("name").asText();
-			String pageUrl = Constants.URL_SERVER + Constants.LOCAL_HOST_PORT + "/assets/html/service" + 
-					name.substring(0, 1).toUpperCase() + name.substring(1) + ".html";
-			oneService.setUrl(pageUrl);
-			// newService.setCreateTime(json.path("createTime").asText());
-			oneService.setScenario(json.path("scenario").asText());
-			oneService.setVersionNo(json.path("versionNo").asText());
-			oneService.setRootServiceId(json.path("rootServiceId").asLong());
+			ClimateService oneService = deserializeJsonToClimateService(json);
 			climateServicesList.add(oneService);
 		}
 
@@ -88,7 +76,7 @@ public class ClimateServiceController extends Controller {
 	}
 
 	public static Result addClimateService() {
-//		Form<ClimateService> cs = climateServiceForm.bindFromRequest();
+		// Form<ClimateService> cs = climateServiceForm.bindFromRequest();
 		JsonNode json = request().body().asJson();
 		String name = json.path("name").asText();
 		String purpose = json.path("purpose").asText();
@@ -96,7 +84,7 @@ public class ClimateServiceController extends Controller {
 		String scenario = json.path("scenario").asText();
 		String versionNo = json.path("version").asText();
 		String rootServiceId = json.path("rootServiceId").asText();
-		
+
 		JsonNode response = null;
 		ObjectNode jsonData = Json.newObject();
 		try {
@@ -115,21 +103,22 @@ public class ClimateServiceController extends Controller {
 											// default val
 			jsonData.put("purpose", purpose);
 			jsonData.put("url", url);
-			DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssz");
+			DateFormat dateFormat = new SimpleDateFormat(
+					"yyyy-MM-dd'T'HH:mm:ssz");
 			// get current date time with Date()
 			Date date = new Date();
 			jsonData.put("createTime", dateFormat.format(date));
 			jsonData.put("scenario", scenario);
 			jsonData.put("versionNo", versionNo);
 			jsonData.put("rootServiceId", rootServiceId);
-			
 
 			// POST Climate Service JSON data
-			response = RESTfulCalls.postAPI(Constants.URL_HOST + Constants.CMU_BACKEND_PORT 
+			response = RESTfulCalls.postAPI(Constants.URL_HOST
+					+ Constants.CMU_BACKEND_PORT
 					+ Constants.ADD_CLIMATE_SERVICE, jsonData);
 
 			// flash the response message
-			System.out.println("***************"+response);
+			System.out.println("***************" + response);
 			Application.flashMsg(response);
 		} catch (IllegalStateException e) {
 			e.printStackTrace();
@@ -148,7 +137,7 @@ public class ClimateServiceController extends Controller {
 		System.out.println("JSON data: " + jsonData);
 		String url = jsonData.get("climateServiceCallUrl").toString();
 		System.out.println("JPL climate service model call url: " + url);
-		
+
 		// transfer JsonNode to Object
 		ObjectNode object = (ObjectNode) jsonData;
 		object.remove("climateServiceCallUrl");
@@ -162,7 +151,8 @@ public class ClimateServiceController extends Controller {
 
 		// flash the response message
 		Application.flashMsg(response);
-		System.out	.println(ok("Climate Service model has been called successfully!"));
+		System.out
+				.println(ok("Climate Service model has been called successfully!"));
 		// return jsonData
 		return ok(response);
 	}
@@ -173,9 +163,11 @@ public class ClimateServiceController extends Controller {
 		String name = request().body().asJson().get("name").toString();
 		String purpose = request().body().asJson().get("purpose").toString();
 		String url = request().body().asJson().get("url").toString();
-		String outputButton = request().body().asJson().get("pageOutput").toString();
-		String dataListContent = request().body().asJson().get("dataListContent").toString();
-		
+		String outputButton = request().body().asJson().get("pageOutput")
+				.toString();
+		String dataListContent = request().body().asJson()
+				.get("dataListContent").toString();
+
 		System.out.println("page string: " + str);
 		System.out.println("climate service name: " + name);
 
@@ -187,8 +179,7 @@ public class ClimateServiceController extends Controller {
 		JsonNode response = RESTfulCalls.postAPI(Constants.URL_HOST
 				+ Constants.CMU_BACKEND_PORT
 				+ Constants.SAVE_CLIMATE_SERVICE_PAGE, jsonData);
-		
-		
+
 		System.out.println("WARNING!!!!!!");
 		// save page in front-end
 		savePage(str, name, purpose, url, outputButton, dataListContent);
@@ -200,32 +191,31 @@ public class ClimateServiceController extends Controller {
 
 	public static Result ruleEngineData() {
 		JsonNode result = request().body().asJson();
-		//System.out.println("ticking!");  
- 		System.out.println(result);		
-		
-		return ok("good");	
+		// System.out.println("ticking!");
+		System.out.println(result);
+
+		return ok("good");
 	}
-	
-	
+
 	public static Result addAllParameters() {
 		JsonNode result = request().body().asJson();
 		System.out.println(result);
 		System.out.println("--------------------------");
 		Iterator<JsonNode> ite = result.iterator();
-		
-		while(ite.hasNext()) {
-			
+
+		while (ite.hasNext()) {
+
 			JsonNode tmp = ite.next();
 			System.out.println(tmp);
-			JsonNode response = RESTfulCalls.postAPI(Constants.URL_HOST
-					+ Constants.CMU_BACKEND_PORT
-					+ Constants.ADD_ALL_PARAMETERS, tmp);
+			JsonNode response = RESTfulCalls.postAPI(
+					Constants.URL_HOST + Constants.CMU_BACKEND_PORT
+							+ Constants.ADD_ALL_PARAMETERS, tmp);
 			System.out.println("=========" + response);
 		}
-		
-		return ok("good");	
+
+		return ok("good");
 	}
-	
+
 	public static void savePage(String str, String name, String purpose,
 			String url, String outputButton, String dataListContent) {
 		System.out.println("output button test: " + outputButton);
@@ -234,24 +224,25 @@ public class ClimateServiceController extends Controller {
 				.replaceAll(
 						"<td><button type=\\\\\"button\\\\\" class=\\\\\"btn btn-danger\\\\\" onclick=\\\\\"Javascript:deleteRow\\(this,\\d+\\)\\\\\">delete</button></td>",
 						"");
-		
+
 		dataListContent = StringEscapeUtils.unescapeJava(dataListContent);
 		result = StringEscapeUtils.unescapeJava(result);
 		outputButton = StringEscapeUtils.unescapeJava(outputButton);
 		System.out.println("output button test: " + outputButton);
-		
+
 		// remove the first char " and the last char " of result, name and
 		// purpose
-		dataListContent = dataListContent.substring(1, dataListContent.length() - 1);
+		dataListContent = dataListContent.substring(1,
+				dataListContent.length() - 1);
 		result = result.substring(1, result.length() - 1);
 		outputButton = outputButton.substring(1, outputButton.length() - 1);
-		
+
 		name = name.substring(1, name.length() - 1);
 		purpose = purpose.substring(1, purpose.length() - 1);
-		
+
 		String putVarAndDataList = Constants.putVar + dataListContent;
 		System.out.println("putVarAndDataList: " + putVarAndDataList);
-		
+
 		String str11 = Constants.htmlHead1;
 		// System.out.println("head1: " + str11);
 		String str12 = Constants.htmlHead2;
@@ -264,8 +255,9 @@ public class ClimateServiceController extends Controller {
 		String str22 = Constants.htmlTail2;
 		String str23 = Constants.htmlTail3;
 
-		result = str11 +putVarAndDataList+ str12 + name + str13 + purpose + str14 + result + str21
-				+ url.substring(1, url.length() - 1) + str22 + outputButton + str23;
+		result = str11 + putVarAndDataList + str12 + name + str13 + purpose
+				+ str14 + result + str21 + url.substring(1, url.length() - 1)
+				+ str22 + outputButton + str23;
 
 		name = name.replace(" ", "");
 
@@ -275,7 +267,7 @@ public class ClimateServiceController extends Controller {
 				+ ".html";
 
 		File theDir = new File("public/html");
-		
+
 		// if the directory does not exist, create it
 		if (!theDir.exists()) {
 			System.out.println("creating directory: public/html");
@@ -305,6 +297,7 @@ public class ClimateServiceController extends Controller {
 			e.printStackTrace();
 		}
 	}
+
 	public static void flashMsg(JsonNode jsonNode) {
 		Iterator<Entry<String, JsonNode>> it = jsonNode.fields();
 		while (it.hasNext()) {
@@ -312,15 +305,14 @@ public class ClimateServiceController extends Controller {
 			flash(field.getKey(), field.getValue().asText());
 		}
 	}
-	
+
 	public static Result mostRecentlyAddedClimateServices() {
-		
+
 		List<ClimateService> climateServices = new ArrayList<ClimateService>();
 
-		JsonNode climateServicesNode = RESTfulCalls
-				.getAPI(Constants.URL_HOST
-						+ Constants.CMU_BACKEND_PORT
-						+ Constants.GET_MOST_RECENTLY_ADDED_CLIMATE_SERVICES_CALL);
+		JsonNode climateServicesNode = RESTfulCalls.getAPI(Constants.URL_HOST
+				+ Constants.CMU_BACKEND_PORT
+				+ Constants.GET_MOST_RECENTLY_ADDED_CLIMATE_SERVICES_CALL);
 
 		// if no value is returned or error or is not json array
 		if (climateServicesNode == null || climateServicesNode.has("error")
@@ -331,33 +323,19 @@ public class ClimateServiceController extends Controller {
 		// parse the json string into object
 		for (int i = 0; i < climateServicesNode.size(); i++) {
 			JsonNode json = climateServicesNode.path(i);
-			ClimateService newService = new ClimateService();
-			newService.setId(json.get("id").asLong());
-			newService.setName(json.get("name").asText());
-			newService.setPurpose(json.findPath("purpose").asText());
-			//newService.setUrl(json.findPath("url").asText());
-			String name = json.path("name").asText();
-			String pageUrl = Constants.URL_SERVER + Constants.LOCAL_HOST_PORT + "/assets/html/service" + 
-					name.substring(0, 1).toUpperCase() + name.substring(1) + ".html";
-			newService.setUrl(pageUrl);
-			//newService.setCreateTime(json.findPath("createTime").asText());
-			newService.setScenario(json.findPath("scenario").asText());
-			newService.setVersionNo(json.findPath("versionNo").asText());
-			newService.setRootServiceId(json.findPath("rootServiceId").asLong());
+			ClimateService newService = deserializeJsonToClimateService(json);
 			climateServices.add(newService);
 		}
-		
+
 		return ok(mostRecentlyAddedServices.render(climateServices));
 	}
-	
-	
-	
-	
+
 	public static Result mostPopularServices() {
 		List<ClimateService> climateServices = new ArrayList<ClimateService>();
 
-		JsonNode climateServicesNode = RESTfulCalls
-				.getAPI(Constants.URL_HOST + Constants.CMU_BACKEND_PORT + Constants.GET_MOST_POPULAR_CLIMATE_SERVICES_CALL);
+		JsonNode climateServicesNode = RESTfulCalls.getAPI(Constants.URL_HOST
+				+ Constants.CMU_BACKEND_PORT
+				+ Constants.GET_MOST_POPULAR_CLIMATE_SERVICES_CALL);
 
 		// if no value is returned or error or is not json array
 		if (climateServicesNode == null || climateServicesNode.has("error")
@@ -368,33 +346,101 @@ public class ClimateServiceController extends Controller {
 		// parse the json string into object
 		for (int i = 0; i < climateServicesNode.size(); i++) {
 			JsonNode json = climateServicesNode.path(i);
-			ClimateService newService = new ClimateService();
-			newService.setId(json.get("id").asLong());
-			newService.setName(json.get("name").asText());
-			newService.setPurpose(json.findPath("purpose").asText());
-			//newService.setUrl(json.findPath("url").asText());
-			String name = json.path("name").asText();
-			String pageUrl = Constants.URL_SERVER + Constants.LOCAL_HOST_PORT + "/assets/html/service" + 
-					name.substring(0, 1).toUpperCase() + name.substring(1) + ".html";
-			newService.setUrl(pageUrl);
-			//newService.setCreateTime(json.findPath("createTime").asText());
-			newService.setScenario(json.findPath("scenario").asText());
-			newService.setVersionNo(json.findPath("versionNo").asText());
-			newService.setRootServiceId(json.findPath("rootServiceId").asLong());
+			ClimateService newService = deserializeJsonToClimateService(json);
 			climateServices.add(newService);
 		}
-		
+
 		return ok(mostPopularServices.render(climateServices));
 	}
 	
-	public static Result mostRecentlyUsedClimateServices() {
+	public static Result recommendationSummary() {
+		List<ClimateService> climateServices = new ArrayList<ClimateService>();
 		
+		List<Dataset> dataSetsList = new ArrayList<Dataset>();
+		
+		List<User> usersList = new ArrayList<User>();
+		
+		JsonNode usersNode = RESTfulCalls.getAPI(Constants.URL_HOST
+				+ Constants.CMU_BACKEND_PORT
+				+ Constants.GET_ALL_USERS);
+		
+		// if no value is returned or error or is not json array
+		if (usersNode == null || usersNode.has("error")
+				|| !usersNode.isArray()) {
+			return ok(recommendationSummary.render(climateServices, dataSetsList, usersList));
+		}
+
+		
+//		JsonNode dataSetsNode = RESTfulCalls.getAPI(Constants.URL_HOST
+//				+ Constants.CMU_BACKEND_PORT
+//				+ Constants.GET_ALL_DATASETS);
+//		
+//		System.out.println("GET API: " + Constants.URL_HOST
+//				+ Constants.CMU_BACKEND_PORT
+//				+ Constants.GET_ALL_DATASETS);
+
+		JsonNode climateServicesNode = RESTfulCalls.getAPI(Constants.URL_HOST
+				+ Constants.CMU_BACKEND_PORT
+				+ Constants.GET_MOST_POPULAR_CLIMATE_SERVICES_CALL);
+
+		// if no value is returned or error or is not json array
+		if (climateServicesNode == null || climateServicesNode.has("error")
+				|| !climateServicesNode.isArray()) {
+			return ok(recommendationSummary.render(climateServices, dataSetsList, usersList));
+		}
+		
+//		// if no value is returned or error or is not json array
+//		if (dataSetsNode == null || dataSetsNode.has("error")
+//				|| !dataSetsNode.isArray()) {
+//			System.out.println("All oneDatasets format has error!");
+//			return ok(recommendationSummary.render(climateServices, dataSetsList));
+//		}
+
+		// parse the json string into object
+		for (int i = 0; i < climateServicesNode.size(); i++) {
+			JsonNode json = climateServicesNode.path(i);
+			ClimateService newService = deserializeJsonToClimateService(json);
+			climateServices.add(newService);
+		}		
+
+//		// parse the json string into object
+//		for (int i = 0; i < dataSetsNode.size(); i++) {
+//			JsonNode json = dataSetsNode.path(i);
+//			Dataset oneDataset = DatasetController.deserializeJsonToDataSet(json);
+//			dataSetsList.add(oneDataset);
+//		}
+		
+		
+		// parse the json string into object
+		for (int i = 0; i < usersNode.size(); i++) {
+			JsonNode json = usersNode.path(i);
+			User oneUser = new User();
+			oneUser.setId(json.findPath("id").asLong());
+			oneUser.setUserName(json.findPath("userName").asText());
+			oneUser.setPassword(json.findPath("password").asText());
+			oneUser.setFirstName(json.findPath("firstName").asText());
+			oneUser.setMiddleInitial(json.findPath("middleInitial").asText());
+			oneUser.setLastName(json.findPath("lastName").asText());
+			oneUser.setAffiliation(json.findPath("affiliation").asText());
+			oneUser.setEmail(json.findPath("email").asText());
+			oneUser.setResearchFields(json.findPath("researchFields").asText());
+			
+			usersList.add(oneUser);
+		}
+
+		int k = Integer.MAX_VALUE; // Set the first popular K datasets
+		dataSetsList = DatasetController.queryFirstKDatasetsWithoutClimateService("", "", "", "", "", new Date(0), new Date(), k);
+		return ok(recommendationSummary.render(climateServices, dataSetsList, usersList));
+	}
+
+	public static Result mostRecentlyUsedClimateServices() {
+
 		List<ClimateService> climateServices = new ArrayList<ClimateService>();
 
 		JsonNode climateServicesNode = RESTfulCalls.getAPI(Constants.URL_HOST
 				+ Constants.CMU_BACKEND_PORT
 				+ Constants.GET_MOST_RECENTLY_USED_CLIMATE_SERVICES_CALL);
-		
+
 		// if no value is returned or error or is not json array
 		if (climateServicesNode == null || climateServicesNode.has("error")
 				|| !climateServicesNode.isArray()) {
@@ -404,110 +450,182 @@ public class ClimateServiceController extends Controller {
 		// parse the json string into object
 		for (int i = 0; i < climateServicesNode.size(); i++) {
 			JsonNode json = climateServicesNode.path(i);
-			ClimateService newService = new ClimateService();
-			newService.setId(json.get("id").asLong());
-			newService.setName(json.get("name").asText());
-			newService.setPurpose(json.findPath("purpose").asText());
-			
-			String name = json.path("name").asText();
-			String pageUrl = Constants.URL_SERVER + Constants.LOCAL_HOST_PORT + "/assets/html/service" + 
-					name.substring(0, 1).toUpperCase() + name.substring(1) + ".html";
-			newService.setUrl(pageUrl);
-			
-			newService.setScenario(json.findPath("scenario").asText());
-			newService.setVersionNo(json.findPath("versionNo").asText());
-			newService.setRootServiceId(json.findPath("rootServiceId").asLong());
+			ClimateService newService = deserializeJsonToClimateService(json);
 			climateServices.add(newService);
 		}
-		
+
 		return ok(mostRecentlyUsedServices.render(climateServices));
 	}
-	
+
 	public static Result replaceFile() {
-	  	File result =  request().body().asRaw().asFile();
-	  	System.out.println("result: " + request().body().asRaw().asFile());
-	  	
-//	  	String content = readFile(result.getName(), StandardCharsets.UTF_8);
-	  	System.out.println("result body: "+result.toString());
-	  	
-	  	String line = "";
-	    try {
-	    	BufferedReader br = new BufferedReader(new FileReader(result.getAbsolutePath()));
-	        StringBuilder sb = new StringBuilder();
-	        line = br.readLine();
-	        int count = 0;
-	        while (line != null && count < 22) {
-	            sb.append(line);
-	            sb.append("\n");
-	            line = br.readLine();	          
-	            count++;
-	        }
-	        br.close();
-	    } catch (FileNotFoundException e) {
+		File result = request().body().asRaw().asFile();
+		System.out.println("result: " + request().body().asRaw().asFile());
+
+		// String content = readFile(result.getName(), StandardCharsets.UTF_8);
+		System.out.println("result body: " + result.toString());
+
+		String line = "";
+		try {
+			BufferedReader br = new BufferedReader(new FileReader(
+					result.getAbsolutePath()));
+			StringBuilder sb = new StringBuilder();
+			line = br.readLine();
+			int count = 0;
+			while (line != null && count < 22) {
+				sb.append(line);
+				sb.append("\n");
+				line = br.readLine();
+				count++;
+			}
+			br.close();
+		} catch (FileNotFoundException e) {
 			// TODO Auto-generated catch block
 			e.printStackTrace();
 		} catch (IOException e) {
 			// TODO Auto-generated catch block
 			e.printStackTrace();
-		} 
-	    
-	    //TEMPOARY SOLUTION : get the fileName from the html page
-	    String tempName = line.substring(24, line.length()-5);		  
-	    String fileName = "public/html/service" + tempName.substring(0, 1).toUpperCase() + tempName.substring(1)+ ".html";
-	    System.out.println("fileName: " + fileName);
-	  	
-	  	//replace the page in the frontend Server
-	  	try {		  		
-		  	Path newPath = Paths.get(fileName);
-		  	Files.move(result.toPath(), newPath, REPLACE_EXISTING);
-	  	} catch (FileNotFoundException e) {
+		}
+
+		// TEMPOARY SOLUTION : get the fileName from the html page
+		String tempName = line.substring(24, line.length() - 5);
+		String fileName = "public/html/service"
+				+ tempName.substring(0, 1).toUpperCase()
+				+ tempName.substring(1) + ".html";
+		System.out.println("fileName: " + fileName);
+
+		// replace the page in the frontend Server
+		try {
+			Path newPath = Paths.get(fileName);
+			Files.move(result.toPath(), newPath, REPLACE_EXISTING);
+		} catch (FileNotFoundException e) {
 			// TODO Auto-generated catch block
 			e.printStackTrace();
 		} catch (IOException e) {
 			// TODO Auto-generated catch block
 			e.printStackTrace();
-		} 
-	  	//executeReplace(result);		
-		
-	  	
-	  	return ok("File uploaded");
+		}
+		// executeReplace(result);
+
+		return ok("File uploaded");
 	}
 
-public static void executeReplace(String result) {
-	
-	try {
-		String path = "public/html/se.html";			
-		File theDir = new File("public/html");		
-		
-		// if the directory does not exist, create it
-		if (!theDir.exists()) {
-			System.out.println("creating directory: public/html");
-			boolean create = false;
+	public static void executeReplace(String result) {
 
-			try {
-				theDir.mkdir();
-				create = true;
-			} catch (SecurityException se) {
-				// handle it
-			}
-			if (create) {
-				System.out.println("DIR created");
+		try {
+			String path = "public/html/se.html";
+			File theDir = new File("public/html");
+
+			// if the directory does not exist, create it
+			if (!theDir.exists()) {
+				System.out.println("creating directory: public/html");
+				boolean create = false;
+
+				try {
+					theDir.mkdir();
+					create = true;
+				} catch (SecurityException se) {
+					// handle it
+				}
+				if (create) {
+					System.out.println("DIR created");
+				}
 			}
+
+			File file = new File(path);
+			BufferedWriter output = new BufferedWriter(new FileWriter(file));
+			output.write(result);
+			output.close();
+			System.out.println("Beeping!!!!!!!!!!!!!!!!!!!!!!!!!!!");
+		} catch (FileNotFoundException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
 		}
+	}
+	
+	public static ClimateService deserializeJsonToClimateService(JsonNode json) {
 		
+		ClimateService oneService = new ClimateService();
+		oneService.setName(json.path("name").asText());
+		oneService.setPurpose(json.path("purpose").asText());
+		// URL here is the dynamic page url
+		String name = json.path("name").asText();
+		String url = json.path("url").asText();
+		// Parse NASA URL
+		if (url.contains("/cmac/web")) {
+			oneService.setUrl(url);
+		} else {
+			String pageUrl = Constants.URL_SERVER
+					+ Constants.LOCAL_HOST_PORT + "/assets/html/service"
+					+ name.substring(0, 1).toUpperCase()
+					+ name.substring(1) + ".html";
+			oneService.setUrl(pageUrl);
+		}
+		// newService.setCreateTime(json.path("createTime").asText());
+		oneService.setScenario(json.path("scenario").asText());
+		oneService.setVersionNo(json.path("versionNo").asText());
+		oneService.setRootServiceId(json.path("rootServiceId").asLong());
 		
-		File file = new File(path);
-		BufferedWriter output = new BufferedWriter(new FileWriter(file));			
-		output.write(result);			
-		output.close();
-		System.out.println("Beeping!!!!!!!!!!!!!!!!!!!!!!!!!!!");
-	} catch (FileNotFoundException e) {
-		// TODO Auto-generated catch block
-		e.printStackTrace();
-	} catch (IOException e) {
-		// TODO Auto-generated catch block
-		e.printStackTrace();
-	} 
-}
+		return oneService;
+	}
 	
+	// Get all climate Services
+	public static Result searchClimateServices() {
+		return ok(searchClimateService.render(climateServiceForm));
+	}
+
+
+	public static Result getSearchResult(){
+		Form<ClimateService> cs = climateServiceForm.bindFromRequest();
+		ObjectNode jsonData = Json.newObject();
+		
+		String name = "";
+		String purpose = "";
+		String scenario = "";
+		String url = "";
+		String versionNo = "";
+		
+		try {
+			name = cs.field("Climate Service Name").value();
+			purpose = cs.field("Purpose").value();
+			url = cs.field("Url").value();
+			scenario = cs.field("Scenario").value();
+			versionNo = cs.field("Version Number").value();
+		
+		} catch (IllegalStateException e) {
+			e.printStackTrace();
+			Application.flashMsg(RESTfulCalls
+					.createResponse(ResponseType.CONVERSIONERROR));
+		} catch (Exception e) {
+			e.printStackTrace();
+			Application.flashMsg(RESTfulCalls.createResponse(ResponseType.UNKNOWN));
+		}
+
+		List<ClimateService> response = queryClimateService(name, purpose, url, scenario, versionNo);
+		return ok(climateServiceList.render(response));
+	}
+	
+public static List<ClimateService> queryClimateService(String name, String purpose, String url, String scenario, String versionNo) {
+		
+		List<ClimateService> climateService = new ArrayList<ClimateService>();
+		ObjectMapper mapper = new ObjectMapper();
+		ObjectNode queryJson = mapper.createObjectNode();
+		queryJson.put("name", name);
+		queryJson.put("purpose", purpose);
+		queryJson.put("url", url);
+		queryJson.put("scenario", scenario);
+		queryJson.put("versionNo", versionNo);
+		
+		JsonNode climateServiceNode = RESTfulCalls.postAPI(Constants.URL_HOST
+				+ Constants.CMU_BACKEND_PORT + Constants.QUERY_CLIMATE_SERVICE, queryJson);
+		// parse the json string into object
+		for (int i = 0; i < climateServiceNode.size(); i++) {
+			JsonNode json = climateServiceNode.path(i);
+			ClimateService newClimateService = deserializeJsonToClimateService(json);
+			climateService.add(newClimateService);
+		}
+		return climateService;
+	}
 }

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/controllers/DatasetController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/controllers/DatasetController.java b/ApacheCMDA_Frontend_1.0/app/controllers/DatasetController.java
index 6f9d711..9a0d6dd 100644
--- a/ApacheCMDA_Frontend_1.0/app/controllers/DatasetController.java
+++ b/ApacheCMDA_Frontend_1.0/app/controllers/DatasetController.java
@@ -7,6 +7,7 @@ import java.util.ArrayList;
 import java.util.Date;
 import java.util.List;
 
+import models.ClimateService;
 import models.Dataset;
 
 import org.joda.time.DateTime;
@@ -36,14 +37,16 @@ public class DatasetController extends Controller {
 		return ok(searchDataSet.render(dataSetForm));
 	}
 	
+	public static Result mostPopularDatasets() {
+		List<Dataset> datasets = queryFirstKDatasetsWithoutClimateService("", "", "", "", "", new Date(0), new Date(), Integer.MAX_VALUE);
+		return ok(dataSetListPopular.render(dataSetForm, datasets));
+	}
+	
 	public static Result showAllDatasets() {
 		List<Dataset> dataSetsList = new ArrayList<Dataset>();
 		JsonNode dataSetsNode = RESTfulCalls.getAPI(Constants.URL_HOST
 				+ Constants.CMU_BACKEND_PORT
 				+ Constants.GET_ALL_DATASETS);
-		System.out.println("GET API: " + Constants.URL_HOST
-				+ Constants.CMU_BACKEND_PORT
-				+ Constants.GET_ALL_DATASETS);
 		// if no value is returned or error or is not json array
 		if (dataSetsNode == null || dataSetsNode.has("error")
 				|| !dataSetsNode.isArray()) {
@@ -129,7 +132,7 @@ public class DatasetController extends Controller {
 		}
 
 		List<Dataset> response = queryDataSet(dataSetName, agency, instrument, physicalVariable, gridDimension, dataSetStartTime, dataSetEndTime);
-		int k = 5;
+		int k = 5; // Set the first popular K datasets
 		List<Dataset> datasetsTopK = queryFirstKDatasets(dataSetName, agency, instrument, physicalVariable, gridDimension, dataSetStartTime, dataSetEndTime, k);
 		return ok(dataSetList.render(response, dataSetForm, datasetsTopK));
 	}
@@ -194,12 +197,55 @@ public static List<Dataset> queryFirstKDatasets(String dataSetName, String agenc
 	for (int i = 0; i < dataSetNode.size(); i++) {
 		JsonNode json = dataSetNode.path(i);
 		Dataset newDataSet = deserializeJsonToDataSet(json);
+		long id = newDataSet.getId();
+		JsonNode climateSetNode = RESTfulCalls.getAPI(Constants.URL_HOST
+				+ Constants.CMU_BACKEND_PORT + Constants.GET_TOP_K_USED_CLIMATE_SERVICES_BY_DATASET_ID + "/" + id);
+		List<ClimateService> climateServices = new ArrayList<ClimateService>();
+		for (int j = 0; j < climateSetNode.size(); j++) {
+			JsonNode json1 = climateSetNode.path(j);
+			ClimateService oneService = ClimateServiceController.deserializeJsonToClimateService(json1);
+			climateServices.add(oneService);
+		}
+		newDataSet.setClimateServices(climateServices);
 		dataset.add(newDataSet);
 	}
 	return dataset;
 }
+	
+	public static List<Dataset> queryFirstKDatasetsWithoutClimateService(String dataSetName, String agency, String instrument, String physicalVariable, String gridDimension, Date dataSetStartTime, Date dataSetEndTime, int k) {
+		
+		List<Dataset> dataset = new ArrayList<Dataset>();
+		ObjectMapper mapper = new ObjectMapper();
+		ObjectNode queryJson = mapper.createObjectNode();
+		queryJson.put("name", dataSetName);
+		queryJson.put("agencyId", agency);
+		queryJson.put("instrument", instrument);
+		queryJson.put("physicalVariable", physicalVariable);
+		queryJson.put("gridDimension", gridDimension);
+		queryJson.put("k", k);
+		if (dataSetEndTime != null) {
+			queryJson.put("dataSetEndTime", dataSetEndTime.getTime());
+		}
+		if (dataSetStartTime != null) {
+			queryJson.put("dataSetStartTime", dataSetStartTime.getTime());
+		}
+		JsonNode dataSetNode = RESTfulCalls.postAPI(Constants.URL_HOST
+				+ Constants.CMU_BACKEND_PORT + Constants.GET_MOST_K_POPULAR_DATASETS_CALL, queryJson);
+		if (dataSetNode == null || dataSetNode.has("error")
+				|| !dataSetNode.isArray()) {
+			return dataset;
+		}
+	
+		// parse the json string into object
+		for (int i = 0; i < dataSetNode.size(); i++) {
+			JsonNode json = dataSetNode.path(i);
+			Dataset newDataSet = deserializeJsonToDataSet(json);
+			dataset.add(newDataSet);
+		}
+		return dataset;
+	}
 
-	private static Dataset deserializeJsonToDataSet(JsonNode json) {
+	public static Dataset deserializeJsonToDataSet(JsonNode json) {
 		Dataset newDataSet = new Dataset();
 		newDataSet.setId(json.get("id").asLong());
 		newDataSet.setName(json.get("name").asText());
@@ -212,14 +258,14 @@ public static List<Dataset> queryFirstKDatasets(String dataSetName, String agenc
 		newDataSet.setSource(json.get("source").asText());
 		newDataSet.setStatus(json.get("status").asText());
 		newDataSet.setResponsiblePerson(json.get("responsiblePerson").asText());
-	//	dataset.setComments(json.get(""));
 		newDataSet.setDataSourceNameinWebInterface(json.get("dataSourceNameinWebInterface").asText());
-	//	Console.print("aaa"+dataset.getDataSourceName());
 		newDataSet.setVariableNameInWebInterface(json.get("variableNameInWebInterface").asText());
 		newDataSet.setDataSourceInputParameterToCallScienceApplicationCode(json.get("dataSourceInputParameterToCallScienceApplicationCode").asText());
 		newDataSet.setVariableNameInputParameterToCallScienceApplicationCode(json.get("variableNameInputParameterToCallScienceApplicationCode").asText());
-		String startTime = json.findPath("startTime").asText();
-		String endTime = json.findPath("endTime").asText();
+		newDataSet.setAgencyURL(json.findPath("agencyURL").asText());
+		newDataSet.setInstrumentURL(json.findPath("instrument").findPath("instrumentURL").asText());
+		String startTime = json.get("startTime").asText();
+		String endTime = json.get("endTime").asText();
 		Date tmpStartTime = null;
 		Date tmpEndTime = null;
 		
@@ -230,6 +276,7 @@ public static List<Dataset> queryFirstKDatasets(String dataSetName, String agenc
 				newDataSet.setStartTime(new SimpleDateFormat("YYYY-MM").format(tmpStartTime));
 			}
 	    } catch (ParseException e){	    
+	    	System.out.println(e);
 	    }
 		
 		try {
@@ -239,7 +286,7 @@ public static List<Dataset> queryFirstKDatasets(String dataSetName, String agenc
 				newDataSet.setEndTime(new SimpleDateFormat("YYYY-MM").format(tmpEndTime));
 			}
 	    } catch (ParseException e){	    
-	    	
+	    	System.out.println(e);
 	    }
 		
 		DateTime dateTimeFrom = new DateTime(tmpStartTime);  
@@ -255,4 +302,5 @@ public static List<Dataset> queryFirstKDatasets(String dataSetName, String agenc
 		
 		return newDataSet;
 	}
+	
 }

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/controllers/DatasetLogController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/controllers/DatasetLogController.java b/ApacheCMDA_Frontend_1.0/app/controllers/DatasetLogController.java
index 7906d85..4839883 100644
--- a/ApacheCMDA_Frontend_1.0/app/controllers/DatasetLogController.java
+++ b/ApacheCMDA_Frontend_1.0/app/controllers/DatasetLogController.java
@@ -59,7 +59,7 @@ public class DatasetLogController extends Controller {
 			tmpTime = (new SimpleDateFormat("MMM dd, yyyy hh:mm:ss a")).parse(datasetStudyStartTime);
 			
 			if (tmpTime != null) {
-				newDatasetLog.setDatasetStudyStartTime(new SimpleDateFormat("YYYYMM").format(tmpTime));
+				newDatasetLog.setDatasetStudyStartTime(new SimpleDateFormat("YYYY-MM").format(tmpTime));
 			}
 	    } catch (ParseException e){	    
 //	    	e.printStackTrace();
@@ -69,7 +69,7 @@ public class DatasetLogController extends Controller {
 			tmpTime = (new SimpleDateFormat("MMM dd, yyyy hh:mm:ss a")).parse(datasetStudyEndTime);
 			
 			if (tmpTime != null) {
-				newDatasetLog.setDatasetStudyEndTime(new SimpleDateFormat("YYYYMM").format(tmpTime));
+				newDatasetLog.setDatasetStudyEndTime(new SimpleDateFormat("YYYY-MM").format(tmpTime));
 			}
 	    } catch (ParseException e){	    
 //	    	e.printStackTrace();

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/controllers/ServiceExecutionLogController.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/controllers/ServiceExecutionLogController.java b/ApacheCMDA_Frontend_1.0/app/controllers/ServiceExecutionLogController.java
index 847b0f9..163146f 100644
--- a/ApacheCMDA_Frontend_1.0/app/controllers/ServiceExecutionLogController.java
+++ b/ApacheCMDA_Frontend_1.0/app/controllers/ServiceExecutionLogController.java
@@ -374,7 +374,8 @@ public class ServiceExecutionLogController extends Controller {
 		ServiceExecutionLog newServiceLog = new ServiceExecutionLog();
 		newServiceLog.setId(json.get("id").asLong());
 		newServiceLog.setServiceId(json.get("climateService").get("id").asLong());
-		newServiceLog.setServiceName(json.get("climateService").get("name").asText());
+		String serviceName = json.get("climateService").get("name").asText();
+		newServiceLog.setServiceName(serviceName);
 		newServiceLog.setPurpose(json.get("purpose").asText());
 		newServiceLog.setUserName(json.get("user").get("firstName").asText()
 				+ " " + json.get("user").get("lastName").asText());
@@ -407,7 +408,7 @@ public class ServiceExecutionLogController extends Controller {
 			tmpTime = (new SimpleDateFormat("MMM dd, yyyy hh:mm:ss a")).parse(datasetStudyStartTime);
 			
 			if (tmpTime != null) {
-				newServiceLog.setDataSetStartTime(new SimpleDateFormat("YYYYMM").format(tmpTime));
+				newServiceLog.setDataSetStartTime(new SimpleDateFormat("YYYY-MM").format(tmpTime));
 			}
 	    } catch (ParseException e){	    
 //	    	e.printStackTrace();
@@ -417,13 +418,20 @@ public class ServiceExecutionLogController extends Controller {
 			tmpTime = (new SimpleDateFormat("MMM dd, yyyy hh:mm:ss a")).parse(datasetStudyEndTime);
 			
 			if (tmpTime != null) {
-				newServiceLog.setDataSetEndTime(new SimpleDateFormat("YYYYMM").format(tmpTime));
+				newServiceLog.setDataSetEndTime(new SimpleDateFormat("YYYY-MM").format(tmpTime));
 			}
 	    } catch (ParseException e){	    
 //	    	e.printStackTrace();
 	    }
 		
 		newServiceLog.setDatasetLogId(json.findPath("datasetLogId").asText());
+		if(json.get("url") != null) {
+			String pageUrl = Constants.URL_SERVER
+					+ Constants.LOCAL_HOST_PORT + "/assets/html/service"
+					+ serviceName.substring(0, 1).toUpperCase()
+					+ serviceName.substring(1) + ".html" + json.get("url").asText();
+			newServiceLog.setUrl(pageUrl);
+		}
 		
 		return newServiceLog;
 	}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/models/Dataset.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/models/Dataset.java b/ApacheCMDA_Frontend_1.0/app/models/Dataset.java
index f8f4482..d72cfc3 100644
--- a/ApacheCMDA_Frontend_1.0/app/models/Dataset.java
+++ b/ApacheCMDA_Frontend_1.0/app/models/Dataset.java
@@ -44,6 +44,9 @@ public class Dataset {
 	private String startTime;
 	private String endTime;
 	private String duration;
+	private String agencyURL;
+	private String instrumentURL;
+	private List<ClimateService> climateServices;
 
 	public Dataset() {
 	}
@@ -56,7 +59,7 @@ public class Dataset {
 			String responsiblePerson, String variableNameInWebInterface,
 			String dataSourceInputParameterToCallScienceApplicationCode,
 			String variableNameInputParameterToCallScienceApplicationCode,
-			String comment, String duration) {
+			String comment, String duration, String agencyURL, String instrumentURL, List<ClimateService> climateServices) {
 		super();
 		this.name = name;
 		this.dataSourceNameinWebInterface = dataSourceNameinWebInterface;
@@ -77,6 +80,33 @@ public class Dataset {
 		this.variableNameInputParameterToCallScienceApplicationCode = variableNameInputParameterToCallScienceApplicationCode;
 		this.comment = comment;
 		this.duration = duration;
+		this.agencyURL = agencyURL;
+		this.instrumentURL = instrumentURL;
+		this.climateServices = climateServices;
+	}
+
+	public List<ClimateService> getClimateServices() {
+		return climateServices;
+	}
+
+	public void setClimateServices(List<ClimateService> climateServices) {
+		this.climateServices = climateServices;
+	}
+
+	public String getInstrumentURL() {
+		return instrumentURL;
+	}
+
+	public void setInstrumentURL(String instrumentURL) {
+		this.instrumentURL = instrumentURL;
+	}
+
+	public String getAgencyURL() {
+		return agencyURL;
+	}
+
+	public void setAgencyURL(String agencyURL) {
+		this.agencyURL = agencyURL;
 	}
 
 	public String getDuration() {

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/models/Instrument.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/models/Instrument.java b/ApacheCMDA_Frontend_1.0/app/models/Instrument.java
index 71a0094..90ac4c1 100644
--- a/ApacheCMDA_Frontend_1.0/app/models/Instrument.java
+++ b/ApacheCMDA_Frontend_1.0/app/models/Instrument.java
@@ -15,6 +15,7 @@ public class Instrument {
 	private String name;
 	private String description;
 	private Date launchDate;
+	private String instrumentURL;
 	
 	public Instrument() {
 	}
@@ -25,6 +26,14 @@ public class Instrument {
 		this.description = description;
 		this.launchDate = launchDate;
 	}
+	
+	public String getInstrumentURL() {
+		return instrumentURL;
+	}
+
+	public void setInstrumentURL(String instrumentURL) {
+		this.instrumentURL = instrumentURL;
+	}
 
 	public long getId() {
 		return id;

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/models/ServiceExecutionLog.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/models/ServiceExecutionLog.java b/ApacheCMDA_Frontend_1.0/app/models/ServiceExecutionLog.java
index aff9e87..fa08477 100644
--- a/ApacheCMDA_Frontend_1.0/app/models/ServiceExecutionLog.java
+++ b/ApacheCMDA_Frontend_1.0/app/models/ServiceExecutionLog.java
@@ -15,6 +15,8 @@ public class ServiceExecutionLog {
 	private String serviceName;
 	private String dataSetStartTime;
 	private String dataSetEndTime;
+	private String url;
+
 
 	public long getId() {
 		return id;
@@ -55,6 +57,10 @@ public class ServiceExecutionLog {
 	public String getDataUrl() {
 		return dataUrl;
 	}
+	
+	public String getUrl() {
+		return url;
+	}
 
 	public void setId(long id) {
 		this.id = id;
@@ -120,6 +126,10 @@ public class ServiceExecutionLog {
 		this.dataSetEndTime = dataSetEndTime;
 	}
 	
+	public void setUrl(String url) {
+		this.url = url;
+	}
+	
 	@Override
 	public String toString() {
 		return "ServiceExecutionLog [id=" + id + ", serviceId="
@@ -127,6 +137,7 @@ public class ServiceExecutionLog {
 				+ serviceConfigurationId + ", purpose=" + purpose
 				+ ", executionStartTime=" + executionStartTime
 				+ ", executionEndTime=" + executionEndTime + ", plotUrl="
-				+ plotUrl + ", dataUrl=" + dataUrl + "]";
+				+ plotUrl + ", dataUrl=" + dataUrl + ", url=" + url 
+				+ "]";
 	}
 }

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/utils/Constants.java
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/utils/Constants.java b/ApacheCMDA_Frontend_1.0/app/utils/Constants.java
index 2ed9d92..2a36d81 100644
--- a/ApacheCMDA_Frontend_1.0/app/utils/Constants.java
+++ b/ApacheCMDA_Frontend_1.0/app/utils/Constants.java
@@ -25,9 +25,11 @@ public class Constants {
 	
 	public static final String GET_MOST_RECENTLY_USED_CLIMATE_SERVICES_CALL = "/climateService/getAllMostRecentClimateServicesByLatestAccessTime/json";
 	public static final String GET_CLIMATE_SERVICES_CALL = "/climateService/getAllClimateServices/json";
+	public static final String GET_TOP_K_USED_CLIMATE_SERVICES_BY_DATASET_ID = "/climateService/getTopKUsedClimateServicesByDatasetId";
 	
 	// climate service page
 	public static final String SAVE_CLIMATE_SERVICE_PAGE = "/climateService/savePage";
+	public static final String QUERY_CLIMATE_SERVICE = "/climateService/queryClimateService";
 	
 	// user
 	public static final String IS_USER_VALID = "/users/isUserValid";
@@ -79,5 +81,8 @@ public class Constants {
 	public static final String CONFIG_ITEM =	"/serviceConfigurationItem";
 	public static final String GET_CONFIG_ITEMS_BY_CONFIG= "/serviceConfigurationItemByServiceConfig";
 	
+	//Analytics
+	public static final String GET_DATASET_AND_USER = "/analytics/getAllDatasetAndUserWithCount/json";
+	
 	
 }

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/views/aboutUs.scala.html
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/views/aboutUs.scala.html b/ApacheCMDA_Frontend_1.0/app/views/aboutUs.scala.html
index ba88ee2..320844a 100644
--- a/ApacheCMDA_Frontend_1.0/app/views/aboutUs.scala.html
+++ b/ApacheCMDA_Frontend_1.0/app/views/aboutUs.scala.html
@@ -11,8 +11,11 @@
    <p>Seungwon Lee</p>
    <p>Lei Pan</p>
    <h3><strong>Current Contributors</strong></h3>
-   <p>Xing Wei</p>
    <p>Wei Wang</p>
+   <p>Qihao Bao</p>
+   <p>Ruoxiao Wang</p>
+   <p>Ming Qi</p>
+   <p>Xing Wei</p>
    <p>Chris Lee</p>
    <p>Rao Li</p>
    <p>Chenran Gong</p>
@@ -21,7 +24,6 @@
    <p>Yichen Liu</p>
    <p>Edward Huang</p>
    <p>Zhiyu Lin</p>
-   <p>Ming Qi</p>
    <p>Jian Jiao</p>
    <p>Juanchen Li</p>
    <h3><strong>Former Contributors</strong></h3>

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/views/allClimateServices.scala.html
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/views/allClimateServices.scala.html b/ApacheCMDA_Frontend_1.0/app/views/allClimateServices.scala.html
index 547e8d1..6dabf7f 100644
--- a/ApacheCMDA_Frontend_1.0/app/views/allClimateServices.scala.html
+++ b/ApacheCMDA_Frontend_1.0/app/views/allClimateServices.scala.html
@@ -11,10 +11,10 @@
 		<th style = "vertical-align: middle;" class="col-md-4">Purpose</th>
 		<th style = "vertical-align: middle;" class="col-md-4">URL</th>
 		<th style = "vertical-align: middle;" class="col-md-3">Scenario</th>
-		<th style = "vertical-align: middle;" class="col-md-3">Version_No</th>
+		<th style = "vertical-align: middle;" class="col-md-3">Version No</th>
 		<th style = "vertical-align: middle;" class="col-md-3">Root Service_Id</th>
 		 @if(true){
-			<th style = "vertical-align: middle;" class="col-md-3">Operation</th> 
+			<th style = "vertical-align: middle;" class="col-md-2">Operation</th> 
 	     } 
 	     <th style = "vertical-align: middle;" class="col-md-2">Operation</th>
 	</tr>
@@ -27,14 +27,21 @@
 		<td><span class="@climateService.getName() editable" data-name='purpose'>
 				@{
 					if (climateService.getPurpose().length > 5 ) {
-						climateService.getPurpose().substring(0,5);
+						climateService.getPurpose().substring(0,5) + "...";
 					}else {
 						climateService.getPurpose();
 					}
-				} ... </span></td>
+				}  </span></td>
 		
 		<td><span class="@climateService.getName() editable" id = "url" data-name='url'>
-				<a href = "@climateService.getUrl()">@climateService.getUrl()</a></span></td>
+				<a href = "@climateService.getUrl()">
+				@{
+					if (climateService.getUrl().length > 5 ) {
+						"..." + climateService.getUrl().substring(31);
+					}else {
+						climateService.getUrl();
+					}
+				}</a></span></td>
 				
 		<td><span class="@climateService.getName() editable" data-name='scenario'>
 				@climateService.getScenario() </span></td>

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/views/allDatasets.scala.html
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/views/allDatasets.scala.html b/ApacheCMDA_Frontend_1.0/app/views/allDatasets.scala.html
index 8976c6b..50649d4 100644
--- a/ApacheCMDA_Frontend_1.0/app/views/allDatasets.scala.html
+++ b/ApacheCMDA_Frontend_1.0/app/views/allDatasets.scala.html
@@ -12,7 +12,7 @@
 		-->
 		<th style = "vertical-align: top;" class="col-md-2">Dataset Name</th>
 		<th style = "vertical-align: top;" class="col-md-1">Agency</th>
-		<th style = "vertical-align: top;" class="col-md-1">Instrument</th>
+		<th style = "vertical-align: top;" class="col-md-1">Instrument/Model Experiment</th>
 		<th style = "vertical-align: top;" class="col-md-2">Physical variable</th>
 		<th style = "vertical-align: top;" class="col-md-1">Variable short name</th>
 		<th style = "vertical-align: top;" class="col-md-1">Units</th>

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/views/climateServiceList.scala.html
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/views/climateServiceList.scala.html b/ApacheCMDA_Frontend_1.0/app/views/climateServiceList.scala.html
new file mode 100644
index 0000000..f871090
--- /dev/null
+++ b/ApacheCMDA_Frontend_1.0/app/views/climateServiceList.scala.html
@@ -0,0 +1,62 @@
+@(climateServices: List[ClimateService])
+@import helper._
+
+@main("All Climate Services") {
+
+    <h1>@climateServices.size() Climate Services</h1>
+		<table class="table table-striped table-bordered table-condensed ex2 tablesorter" id = "csTable">
+	<thead>
+	<tr class="text-center">
+		<th style = "vertical-align: middle;" class="col-md-2">Climate Service Name</th>
+		<th style = "vertical-align: middle;" class="col-md-4">Purpose</th>
+		<th style = "vertical-align: middle;" class="col-md-4">URL</th>
+		<th style = "vertical-align: middle;" class="col-md-3">Scenario</th>
+		<th style = "vertical-align: middle;" class="col-md-3">Version No</th>
+		<th style = "vertical-align: middle;" class="col-md-3">Root Service_Id</th>
+		 @if(true){
+			<th style = "vertical-align: middle;" class="col-md-2">Operation</th> 
+	     } 
+	     <th style = "vertical-align: middle;" class="col-md-2">Operation</th>
+	</tr>
+	</thead>
+	<tbody>
+	@for(climateService <- climateServices) {
+	<tr>
+		<td><a href = "@climateService.getUrl()">@climateService.getName()</a></td>
+
+		<td><span class="@climateService.getName() editable" data-name='purpose'>
+				@{
+					if (climateService.getPurpose().length > 5 ) {
+						climateService.getPurpose().substring(0,5) + "...";
+					}else {
+						climateService.getPurpose();
+					}
+				}  </span></td>
+		
+		<td><span class="@climateService.getName() editable" id = "url" data-name='url'>
+				<a href = "@climateService.getUrl()">
+				@{
+					if (climateService.getUrl().length > 5 ) {
+						"..." + climateService.getUrl().substring(31);
+					}else {
+						climateService.getUrl();
+					}
+				}</a></span></td>
+				
+		<td><span class="@climateService.getName() editable" data-name='scenario'>
+				@climateService.getScenario() </span></td>
+				
+		<td><span class="@climateService.getName() editable" data-name='versionNo'>
+				@climateService.getVersionNo() </span></td>
+				
+		<td><span class="@climateService.getName() editable" data-name='rootServiceId'>
+				@climateService.getRootServiceId() </span></td>
+				
+		<td><input type="file" class="btn btn-info" id ="upload @climateService.getName()" ></button></td>
+		<td><button type="button" class="btn btn-danger" id ="doReplace"  onclick="Javascript:replaceFile('upload '+'@climateService.getName()')" >Execute</button></td>
+	
+	</tr>
+	}
+	</tbody>
+    </table>
+}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/views/dataSetList.scala.html
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/views/dataSetList.scala.html b/ApacheCMDA_Frontend_1.0/app/views/dataSetList.scala.html
index 83aeb18..078c6c8 100644
--- a/ApacheCMDA_Frontend_1.0/app/views/dataSetList.scala.html
+++ b/ApacheCMDA_Frontend_1.0/app/views/dataSetList.scala.html
@@ -72,15 +72,15 @@
 								<div class="well col-lg-offset-4 col-lg-4 col-sm-offset-3 col-sm-6">
 									<div class="text-center">
 										<img class="card-img-top" style=" width:60%;"
-											src='@routes.Assets.at("images/data.png")' >
+											src='@routes.Assets.at("images/giphy.gif")' >
 									</div>
 									<div class="card-block text-center">
 										<h4 class="card-title">@dataSet.getName()</h4>
 										<p class="card-text text-muted">A data set (or dataset) is a collection of data.</p>
 									</div>
 									<ul class="list-group list-group-flush">
-										<li class="list-group-item"><strong>Agency:</strong> <code>@dataSet.getAgencyId()</code></li>
-										<li class="list-group-item"><strong>Instrument:</strong> <code>@dataSet.getInstrument()</code></li>
+										<li class="list-group-item"><strong>Agency:</strong> <a href="@dataSet.getAgencyURL()" target="_blank"><code><u>@dataSet.getAgencyId()</u></code></a></li>
+										<li class="list-group-item"><strong>Instrument/Model Experiment:</strong> <a href="@dataSet.getInstrumentURL()" target="_blank"><code><u>@dataSet.getInstrument()</u></code></a></li>
 										<li class="list-group-item"><strong>Units:</strong> <code>@dataSet.getUnits()</code></li>
 										<li class="list-group-item"><strong>Start Time:</strong> <code>@dataSet.getStartTime()</code></li>
 										<li class="list-group-item"><strong>End Time:</strong> <code>@dataSet.getEndTime()</code></li>
@@ -102,15 +102,20 @@
 									</div>
 									
 									<div class="row">
+									@for(climateService <- dataSet.getClimateServices()) {
 									  <div class="col-md-6">
 									    <div class="thumbnail">
+									    <a href="@climateService.getUrl()">
 									      <img src='@routes.Assets.at("images/github.png")' >
+								      	</a>
 									      <div class="caption">
-									        <h5>NASA</h5>				        
-									        <p><a href="#" class="btn btn-primary" role="button">Go</a> <a href="#" class="btn btn-default" role="button">Ignore</a></p>
+									        <h5>@climateService.getName()</h5>				        
+									        
 									      </div>				      
 									    </div>
 									  </div>
+									  }
+									  <!--  
 									  <div class="col-md-6">
 									    <div class="thumbnail">
 									      <img src='@routes.Assets.at("images/bug.png")' >
@@ -120,6 +125,7 @@
 									      </div>				      
 									    </div>
 									  </div>
+									  -->
 									</div>
 									
 								</div>
@@ -162,7 +168,7 @@
 		-->
 		<th style = "vertical-align: top;" class="col-md-2">Dataset Name</th>
 		<th style = "vertical-align: top;" class="col-md-1">Agency</th>
-		<th style = "vertical-align: top;" class="col-md-1">Instrument</th>
+		<th style = "vertical-align: top;" class="col-md-1">Instrument/Model Experiment</th>
 		<th style = "vertical-align: top;" class="col-md-2">Physical variable</th>
 		<th style = "vertical-align: top;" class="col-md-1">Variable short name</th>
 		<th style = "vertical-align: top;" class="col-md-1">Units</th>

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/views/dataSetListPopular.scala.html
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/views/dataSetListPopular.scala.html b/ApacheCMDA_Frontend_1.0/app/views/dataSetListPopular.scala.html
new file mode 100644
index 0000000..9df2a3d
--- /dev/null
+++ b/ApacheCMDA_Frontend_1.0/app/views/dataSetListPopular.scala.html
@@ -0,0 +1,68 @@
+@(dataSetForm: play.data.Form[Dataset], dataSets: List[Dataset])
+
+@import helper._
+@import java.math.BigInteger;var k=1;var n = 0;
+
+@scripts = {
+	<script src='@routes.Assets.at("javascripts/edit_button.js")'></script>
+	<script type="text/javascript">
+	$(document).ready(function(){
+		//alert($("#url").text());
+	});
+	</script>
+}
+
+@main("Dataset List", scripts) { 
+	 
+    <h1>Datasets List</h1>
+    <h2>@dataSets.size() Datasets Found</h2>
+<div style="overflow-y:scroll">
+		<table class="table table-striped table-bordered table-condensed tablesorter" id ="myTable">
+		<thead>
+	<tr >
+		<!-- 
+		<th style = "vertical-align: top;" class="col-md-1 header">Id</th>
+		-->
+		<th style = "vertical-align: top;" class="col-md-2">Dataset Name</th>
+		<th style = "vertical-align: top;" class="col-md-1">Agency</th>
+		<th style = "vertical-align: top;" class="col-md-1">Instrument/Model Experiment</th>
+		<th style = "vertical-align: top;" class="col-md-2">Physical variable</th>
+		<th style = "vertical-align: top;" class="col-md-1">Variable short name</th>
+		<th style = "vertical-align: top;" class="col-md-1">Units</th>
+		<th style = "vertical-align: top;" class="col-md-1">Grid Dimension</th>
+		
+		<th style = "vertical-align: top;" class="col-md-2">Variable Name in Web Interface</th>
+		<th style = "vertical-align: top;" class="col-md-1">Data Source Input Parameter</th>
+		
+		<th style = "vertical-align: top;" class="col-md-1">Dataset Start Time</th>
+		<th style = "vertical-align: top;"class="col-md-1">Dataset End Time</th>
+		<th style = "vertical-align: top;"class="col-md-1">Duration</th>
+
+	</tr>
+	</thead>
+	<tbody>
+@for(dataSet <- dataSets){
+							<tr>
+								<!-- 
+								<td><font size="2">@dataSet.getId()</font></td>
+								-->
+								<td><font size="2">@dataSet.getName()</font></td>
+								<td><font size="2">@dataSet.getAgencyId()</font></td>
+								<td><font size="2">@dataSet.getInstrument()</font></td>
+								<td><font size="2">@dataSet.getPhysicalVariable()</font></td>
+								<td><font size="2">@dataSet.getCMIP5VarName()</font></td>
+								<td><font size="2">@dataSet.getUnits()</font></td>
+								<td><font size="2">@dataSet.getGridDimension()</font></td>
+								<td><font size="2">@dataSet.getVariableNameInWebInterface()</font></td>
+								<td><font size="2">@dataSet.getDataSourceInputParameterToCallScienceApplicationCode()</font></td>
+								<td><font size="2">@dataSet.getStartTime()</font></td>
+								<td><font size="2">@dataSet.getEndTime()</font></td>
+								<td><font size="2">@dataSet.getDuration()</font></td>
+							</tr>
+							}
+
+	
+	</tbody>
+    </table>
+    </div>
+}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/aa50efa2/ApacheCMDA_Frontend_1.0/app/views/header.scala.html
----------------------------------------------------------------------
diff --git a/ApacheCMDA_Frontend_1.0/app/views/header.scala.html b/ApacheCMDA_Frontend_1.0/app/views/header.scala.html
index c67371d..3446fdd 100644
--- a/ApacheCMDA_Frontend_1.0/app/views/header.scala.html
+++ b/ApacheCMDA_Frontend_1.0/app/views/header.scala.html
@@ -10,8 +10,8 @@
 				</button>
 				<a class="navbar-brand" style="padding-bottom: 0;" href="/">
 					<div>
-					<img src='@routes.Assets.at("images/NASA_JPL_logo.png")' style="height: 30px; width: 180px;">&nbsp&nbsp
-					<img src='@routes.Assets.at("images/logo.png")' style="height: 15px; width: 200px;">
+					<img src='@routes.Assets.at("images/NASA_JPL_logo.png")' style="height: 24px; width: 144px;">
+					<img src='@routes.Assets.at("images/logo.png")' style="height: 12px; width: 160px;">
 					</div>
 				</a>
 			</div>
@@ -19,6 +19,14 @@
 				<ul class="nav navbar-nav navbar-right">
 					
 					<li class="dropdown">
+						<a href="#" class="dropdown-toggle" data-toggle="dropdown"><span class="text-danger">Recommendation</span><b class="caret"></b></a>
+						<ul class="dropdown-menu">
+							<li><a href="@routes.ClimateServiceController.recommendationSummary()">Summary</a></li>
+							
+						</ul>				
+					</li>
+					
+					<li class="dropdown">
 						<a href="#" class="dropdown-toggle" data-toggle="dropdown">Web Service<b class="caret"></b></a>
 						<ul class="dropdown-menu">
 							<li><a href="@routes.ClimateServiceController.mostRecentlyAddedClimateServices()">Most Recently Added</a></li>
@@ -28,14 +36,14 @@
 							@if(true) {
 								<li><a href="@routes.ClimateServiceController.addAClimateService()">Register A Service</a></li>
 							}
-							<li><a>Search Service</a></li>
+							<li><a href="@routes.ClimateServiceController.searchClimateServices()">Search Service</a></li>
 						</ul>				
 					</li>
 					
 					<li class="dropdown">
 						<a href="#" class="dropdown-toggle" data-toggle="dropdown">Dataset<b class="caret"></b></a>
 						<ul class="dropdown-menu">
-							<li><a>Most Popular</a></li>
+							<li><a href="@routes.DatasetController.mostPopularDatasets()">Most Popular</a></li>
 							<li><a href="@routes.DatasetController.showAllDatasets()">Dataset List</a></li>
 							@if(true) {
 								<li><a href="#">Register A Dataset</a></li>
@@ -50,7 +58,7 @@
 							<li><a href="@routes.ServiceExecutionLogController.getServiceLog">Service Execution Log</a></li>
 							<li><a href="@routes.ServiceExecutionLogController.searchServiceLog">Search Service Log</a></li>
 							<li><a href="@routes.DatasetLogController.getAllDatasetLogs">Dataset Log</a></li>
-							<li><a href="@routes.AnalyticsController.getRecommend">Semantic Service Analytics</a></li>
+							<li><a href="@routes.AnalyticsController.getKnowledgeGraph">Knowledge Graph</a></li>
 							<li><a href="@routes.AnalyticsController.getDatasetRecommend">Semantic Dataset Analytics</a></li>
 							<li><a href="@routes.AnalyticsController.getScientistRecommend">User Analytics</a></li>
 							<li><a href="@routes.AnalyticsController.getLogGraph">Service Execution Log Analytics</a></li>



Mime
View raw message