eagle-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From h..@apache.org
Subject [1/3] incubator-eagle git commit: EAGLE-190 JBDC metadata storage extension and support derby embedded database as default storage
Date Wed, 16 Mar 2016 05:18:59 GMT
Repository: incubator-eagle
Updated Branches:
  refs/heads/master 4c1831aa1 -> ffd84fa0e


http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/criteria/TestQueryCriteriaBuilder.java
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/criteria/TestQueryCriteriaBuilder.java b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/criteria/TestQueryCriteriaBuilder.java
index a5cb399..4fe119d 100644
--- a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/criteria/TestQueryCriteriaBuilder.java
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/criteria/TestQueryCriteriaBuilder.java
@@ -16,9 +16,12 @@
  */
 package org.apache.eagle.storage.jdbc.criteria;
 
+import org.apache.eagle.log.entity.test.TestTimeSeriesAPIEntity;
 import org.apache.eagle.storage.exception.QueryCompileException;
 import org.apache.eagle.storage.jdbc.conn.ConnectionManagerFactory;
 import org.apache.eagle.storage.jdbc.criteria.impl.QueryCriteriaBuilder;
+import org.apache.eagle.storage.jdbc.schema.JdbcEntityDefinition;
+import org.apache.eagle.storage.jdbc.schema.JdbcEntityDefinitionManager;
 import org.apache.eagle.storage.operation.CompiledQuery;
 import org.apache.eagle.storage.operation.RawQuery;
 import org.apache.torque.criteria.Criteria;
@@ -32,13 +35,15 @@ import org.slf4j.LoggerFactory;
  */
 public class TestQueryCriteriaBuilder {
     private final static Logger LOG = LoggerFactory.getLogger(TestQueryCriteriaBuilder.class);
+    private JdbcEntityDefinition jdbcEntityDefinition;
 
     @Before
     public void setUp() throws Exception {
         ConnectionManagerFactory.getInstance();
+        jdbcEntityDefinition = JdbcEntityDefinitionManager.getJdbcEntityDefinition(TestTimeSeriesAPIEntity.class);
     }
 
-    //@Test
+    @Test
     public void testSimpleQueryBuilder() throws QueryCompileException {
         RawQuery rawQuery = new RawQuery();
         rawQuery.setQuery("TestTimeSeriesAPIEntity[@cluster=\"thecluster\" AND @field4 > 1000 ]{@field1,@field2, EXP{@field3/2}}");
@@ -47,7 +52,7 @@ public class TestQueryCriteriaBuilder {
         rawQuery.setPageSize(1000);
         CompiledQuery query = new CompiledQuery(rawQuery);
 
-        QueryCriteriaBuilder criteriaBuilder = new QueryCriteriaBuilder(query,"test");
+        QueryCriteriaBuilder criteriaBuilder = new QueryCriteriaBuilder(query,jdbcEntityDefinition);
         Criteria criteria = criteriaBuilder.build();
         LOG.info(criteria.toString());
     }
@@ -61,7 +66,7 @@ public class TestQueryCriteriaBuilder {
         rawQuery.setPageSize(1000);
         CompiledQuery query = new CompiledQuery(rawQuery);
 
-        QueryCriteriaBuilder criteriaBuilder = new QueryCriteriaBuilder(query,"test");
+        QueryCriteriaBuilder criteriaBuilder = new QueryCriteriaBuilder(query,jdbcEntityDefinition);
         Criteria criteria = criteriaBuilder.build();
         LOG.info(criteria.toString());
     }
@@ -76,7 +81,7 @@ public class TestQueryCriteriaBuilder {
         rawQuery.setPageSize(1000);
         CompiledQuery query = new CompiledQuery(rawQuery);
 
-        QueryCriteriaBuilder criteriaBuilder = new QueryCriteriaBuilder(query,"test");
+        QueryCriteriaBuilder criteriaBuilder = new QueryCriteriaBuilder(query,jdbcEntityDefinition);
         Criteria criteria = criteriaBuilder.build();
         LOG.info(criteria.toString());
     }

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/schema/TestJdbcEntityDefinition.java
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/schema/TestJdbcEntityDefinition.java b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/schema/TestJdbcEntityDefinition.java
new file mode 100644
index 0000000..ddbde0e
--- /dev/null
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/schema/TestJdbcEntityDefinition.java
@@ -0,0 +1,33 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ * <p/>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p/>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.eagle.storage.jdbc.schema;
+
+import org.apache.eagle.log.entity.test.TestTimeSeriesAPIEntity;
+import org.junit.Assert;
+import org.junit.Test;
+
+
+public class TestJdbcEntityDefinition {
+    @Test
+    public void testColumnClassType(){
+        try {
+            Assert.assertEquals(Integer.class,TestTimeSeriesAPIEntity.class.getDeclaredField("field2").getType());
+        } catch (NoSuchFieldException e) {
+            Assert.fail(e.getMessage());
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/schema/TestJdbcEntitySchemaManager.java
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/schema/TestJdbcEntitySchemaManager.java b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/schema/TestJdbcEntitySchemaManager.java
new file mode 100644
index 0000000..c906b6c
--- /dev/null
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/java/org/apache/eagle/storage/jdbc/schema/TestJdbcEntitySchemaManager.java
@@ -0,0 +1,27 @@
+package org.apache.eagle.storage.jdbc.schema;
+
+import org.junit.Test;
+
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ * <p/>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p/>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+public class TestJdbcEntitySchemaManager {
+    @Test
+    public void testSetup(){
+        JdbcEntitySchemaManager.getInstance().init();
+        JdbcEntitySchemaManager.getInstance().init();
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application-derby.conf
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application-derby.conf b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application-derby.conf
new file mode 100644
index 0000000..689dc91
--- /dev/null
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application-derby.conf
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+eagle {
+	service {
+		storage-type="jdbc"
+		storage-adapter="derby"
+		storage-username="eagle"
+		storage-password=eagle
+		storage-database=eagle
+		storage-connection-url="jdbc:derby:memory:eagle;create=true"
+		storage-connection-props="encoding=UTF-8"
+		storage-driver-class="org.apache.derby.jdbc.EmbeddedDriver"
+		storage-connection-max=8
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application-mysql.conf
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application-mysql.conf b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application-mysql.conf
new file mode 100644
index 0000000..61a899f
--- /dev/null
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application-mysql.conf
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+eagle {
+	service {
+		storage-type="jdbc"
+		storage-adapter="mysql"
+		storage-username="eagle"
+		storage-password=eagle
+		storage-database=eagle
+		storage-connection-url="jdbc:mysql://localhost:3306/eagle"
+		storage-connection-props="encoding=UTF-8"
+		storage-driver-class="com.mysql.jdbc.Driver"
+		storage-connection-max=8
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application.conf
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application.conf b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application.conf
index 61a899f..689dc91 100644
--- a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application.conf
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/application.conf
@@ -16,13 +16,13 @@
 eagle {
 	service {
 		storage-type="jdbc"
-		storage-adapter="mysql"
+		storage-adapter="derby"
 		storage-username="eagle"
 		storage-password=eagle
 		storage-database=eagle
-		storage-connection-url="jdbc:mysql://localhost:3306/eagle"
+		storage-connection-url="jdbc:derby:memory:eagle;create=true"
 		storage-connection-props="encoding=UTF-8"
-		storage-driver-class="com.mysql.jdbc.Driver"
+		storage-driver-class="org.apache.derby.jdbc.EmbeddedDriver"
 		storage-connection-max=8
 	}
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/ddl/unittest_testtsentity.sql
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/ddl/unittest_testtsentity.sql b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/ddl/unittest_testtsentity.sql
deleted file mode 100644
index 48bc367..0000000
--- a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/ddl/unittest_testtsentity.sql
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- */
-
-SET NAMES utf8;
-SET FOREIGN_KEY_CHECKS = 0;
-
--- ----------------------------
---  Table structure for `unittest_testtsentity`
--- ----------------------------
-DROP TABLE IF EXISTS `unittest_testtsentity`;
-CREATE TABLE `unittest_testtsentity` (
-  `uuid` varchar(255) NOT NULL,
-  `field1` int(11) DEFAULT NULL,
-  `field2` int(11) DEFAULT NULL,
-  `field3` bigint(20) DEFAULT NULL,
-  `field4` bigint(20) DEFAULT NULL,
-  `field5` double DEFAULT NULL,
-  `field6` double DEFAULT NULL,
-  `field7` varchar(255) DEFAULT NULL,
-  `cluster` varchar(255) DEFAULT NULL,
-  `datacenter` varchar(255) DEFAULT NULL,
-  `timestamp` bigint(20) DEFAULT NULL,
-  `jobid` varchar(255) DEFAULT NULL,
-  PRIMARY KEY (`uuid`),
-  KEY `partition` (`cluster`,`datacenter`) USING BTREE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-
-SET FOREIGN_KEY_CHECKS = 1;

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/log4j.properties
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/log4j.properties b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/log4j.properties
index d59ded6..fb13ad5 100644
--- a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/log4j.properties
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/log4j.properties
@@ -13,7 +13,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-log4j.rootLogger=INFO, stdout
+log4j.rootLogger=DEBUG, stdout
 
 # standard output
 log4j.appender.stdout=org.apache.log4j.ConsoleAppender

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest.application.conf
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest.application.conf b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest.application.conf
new file mode 100644
index 0000000..846d2c3
--- /dev/null
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest.application.conf
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+eagle {
+	service {
+		storage-type="jdbc"
+		storage-adapter="h2"
+		storage-username="eagle"
+		storage-password=eagle
+		storage-database=eagle
+		storage-connection-url="jdbc:h2:tcp//localhost/eagle"
+		storage-connection-props="encoding=UTF-8"
+		storage-driver-class="org.h2.Driver"
+		storage-connection-max=8
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest_ddl.derby.sql
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest_ddl.derby.sql b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest_ddl.derby.sql
new file mode 100644
index 0000000..61cb948
--- /dev/null
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest_ddl.derby.sql
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+CREATE TABLE UNITTEST_TESTTSENTITY (
+  uuid varchar(255) NOT NULL,
+  field1 int DEFAULT NULL,
+  field2 int DEFAULT NULL,
+  field3 BIGINT DEFAULT NULL,
+  field4 BIGINT DEFAULT NULL,
+  field5 double DEFAULT NULL,
+  field6 double DEFAULT NULL,
+  field7 varchar(255) DEFAULT NULL,
+  cluster varchar(255) DEFAULT NULL,
+  datacenter varchar(255) DEFAULT NULL,
+  random_tag VARCHAR(255) DEFAULT NULL,
+  timestamp BIGINT DEFAULT NULL,
+  jobid varchar(255) DEFAULT NULL,
+  PRIMARY KEY (uuid)
+)
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest_ddl.mysql.sql
----------------------------------------------------------------------
diff --git a/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest_ddl.mysql.sql b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest_ddl.mysql.sql
new file mode 100644
index 0000000..6791a74
--- /dev/null
+++ b/eagle-core/eagle-query/eagle-storage-jdbc/src/test/resources/unittest_ddl.mysql.sql
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+-- SET NAMES utf8;
+-- SET FOREIGN_KEY_CHECKS = 0;
+
+-- ----------------------------
+--  Table structure for `unittest_testtsentity`
+-- ----------------------------
+DROP TABLE IF EXISTS `unittest_testtsentity`;
+CREATE TABLE `unittest_testtsentity` (
+  `uuid` varchar(255) NOT NULL,
+  `field1` int(11) DEFAULT NULL,
+  `field2` int(11) DEFAULT NULL,
+  `field3` bigint(20) DEFAULT NULL,
+  `field4` bigint(20) DEFAULT NULL,
+  `field5` double DEFAULT NULL,
+  `field6` double DEFAULT NULL,
+  `field7` varchar(255) DEFAULT NULL,
+  `cluster` varchar(255) DEFAULT NULL,
+  `random_tag` VARCHAR(255) DEFAULT NULL,
+  `datacenter` varchar(255) DEFAULT NULL,
+  `timestamp` bigint(20) DEFAULT NULL,
+  `jobid` varchar(255) DEFAULT NULL,
+  PRIMARY KEY (`uuid`),
+  KEY `partition` (`cluster`,`datacenter`) USING BTREE
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+SET FOREIGN_KEY_CHECKS = 1;

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-hadoop-metric/src/main/resources/hadoop-metric-init.sh
----------------------------------------------------------------------
diff --git a/eagle-hadoop-metric/src/main/resources/hadoop-metric-init.sh b/eagle-hadoop-metric/src/main/resources/hadoop-metric-init.sh
index 6ba119c..dbcb9b8 100755
--- a/eagle-hadoop-metric/src/main/resources/hadoop-metric-init.sh
+++ b/eagle-hadoop-metric/src/main/resources/hadoop-metric-init.sh
@@ -47,9 +47,9 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
         "tags":{
            "application":"hadoopJmxMetricDataSource"
         },
-        "desc":"hadoop jmx metric monitoring",
+        "description":"hadoop jmx metric monitoring",
         "alias":"JmxMetricMonitor",
-        "group":"METRIC",
+        "groupName":"METRIC",
         "config":"{}",
         "features":["common","metadata"]
      }
@@ -66,10 +66,10 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
     {
        "prefix":"alertStream",
        "tags":{
-          "dataSource":"hadoopJmxMetricDataSource",
+          "application":"hadoopJmxMetricDataSource",
           "streamName":"hadoopJmxMetricEventStream"
        },
-       "desc":"hadoop"
+       "description":"hadoop"
     }
  ]
  '
@@ -84,11 +84,11 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
     {
        "prefix":"alertExecutor",
        "tags":{
-          "dataSource":"hadoopJmxMetricDataSource",
+          "application":"hadoopJmxMetricDataSource",
           "alertExecutorId":"hadoopJmxMetricAlertExecutor",
           "streamName":"hadoopJmxMetricEventStream"
        },
-       "desc":"aggregate executor for hadoop jmx metric event stream"
+       "description":"aggregate executor for hadoop jmx metric event stream"
     }
  ]
  '
@@ -103,7 +103,7 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
     {
        "prefix": "alertStreamSchema",
        "tags": {
-          "dataSource": "hadoopJmxMetricDataSource",
+          "application": "hadoopJmxMetricDataSource",
           "streamName": "hadoopJmxMetricEventStream",
           "attrName": "host"
        },
@@ -115,7 +115,7 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
     {
        "prefix": "alertStreamSchema",
        "tags": {
-          "dataSource": "hadoopJmxMetricDataSource",
+          "application": "hadoopJmxMetricDataSource",
           "streamName": "hadoopJmxMetricEventStream",
           "attrName": "timestamp"
        },
@@ -127,7 +127,7 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
     {
        "prefix": "alertStreamSchema",
        "tags": {
-          "dataSource": "hadoopJmxMetricDataSource",
+          "application": "hadoopJmxMetricDataSource",
           "streamName": "hadoopJmxMetricEventStream",
           "attrName": "metric"
        },
@@ -139,7 +139,7 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
     {
        "prefix": "alertStreamSchema",
        "tags": {
-          "dataSource": "hadoopJmxMetricDataSource",
+          "application": "hadoopJmxMetricDataSource",
           "streamName": "hadoopJmxMetricEventStream",
           "attrName": "component"
        },
@@ -151,7 +151,7 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
     {
        "prefix": "alertStreamSchema",
        "tags": {
-          "dataSource": "hadoopJmxMetricDataSource",
+          "application": "hadoopJmxMetricDataSource",
           "streamName": "hadoopJmxMetricEventStream",
           "attrName": "site"
        },
@@ -163,7 +163,7 @@ curl -u ${EAGLE_SERVICE_USER}:${EAGLE_SERVICE_PASSWD} -X POST -H 'Content-Type:a
     {
        "prefix": "alertStreamSchema",
        "tags": {
-          "dataSource": "hadoopJmxMetricDataSource",
+          "application": "hadoopJmxMetricDataSource",
           "streamName": "hadoopJmxMetricEventStream",
           "attrName": "value"
        },

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-security/eagle-security-hbase-web/src/main/java/org/apache/eagle/service/security/hbase/HbaseSensitivityResourceService.java
----------------------------------------------------------------------
diff --git a/eagle-security/eagle-security-hbase-web/src/main/java/org/apache/eagle/service/security/hbase/HbaseSensitivityResourceService.java b/eagle-security/eagle-security-hbase-web/src/main/java/org/apache/eagle/service/security/hbase/HbaseSensitivityResourceService.java
index f707bb1..bc4d42b 100644
--- a/eagle-security/eagle-security-hbase-web/src/main/java/org/apache/eagle/service/security/hbase/HbaseSensitivityResourceService.java
+++ b/eagle-security/eagle-security-hbase-web/src/main/java/org/apache/eagle/service/security/hbase/HbaseSensitivityResourceService.java
@@ -18,9 +18,9 @@
 package org.apache.eagle.service.security.hbase;
 
 
-import org.apache.eagle.log.entity.ListQueryAPIResponseEntity;
+import org.apache.eagle.log.entity.GenericServiceAPIResponseEntity;
 import org.apache.eagle.security.entity.HbaseResourceSensitivityAPIEntity;
-import org.apache.eagle.service.generic.ListQueryResource;
+import org.apache.eagle.service.generic.GenericEntityServiceResource;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -33,11 +33,11 @@ public class HbaseSensitivityResourceService {
     private static Logger LOG = LoggerFactory.getLogger(HbaseSensitivityResourceService.class);
 
     public Map<String, Map<String, String>> getAllHbaseSensitivityMap(){
-        ListQueryResource resource = new ListQueryResource();
+        GenericEntityServiceResource resource = new GenericEntityServiceResource();
         /* parameters are: query, startTime, endTime, pageSzie, startRowkey, treeAgg, timeSeries, intervalmin, top, filterIfMissing,
         * parallel, metricName*/
-        ListQueryAPIResponseEntity ret = resource.listQuery("HbaseResourceSensitivityService[]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
-                0, null);
+        GenericServiceAPIResponseEntity ret = resource.search("HbaseResourceSensitivityService[]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
+                0, null, false);
         List<HbaseResourceSensitivityAPIEntity> list = (List<HbaseResourceSensitivityAPIEntity>) ret.getObj();
         if( list == null )
             return Collections.emptyMap();
@@ -62,10 +62,10 @@ public class HbaseSensitivityResourceService {
     }
 
     public Map<String, String> getHbaseSensitivityMap(String site){
-        ListQueryResource resource = new ListQueryResource();
+        GenericEntityServiceResource resource = new GenericEntityServiceResource();
         String queryFormat = "HbaseResourceSensitivityService[@site=\"%s\"]{*}";
-        ListQueryAPIResponseEntity ret = resource.listQuery(String.format(queryFormat, site), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
-                0, null);
+        GenericServiceAPIResponseEntity ret = resource.search(String.format(queryFormat, site), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
+                0, null, false);
         List<HbaseResourceSensitivityAPIEntity> list = (List<HbaseResourceSensitivityAPIEntity>) ret.getObj();
         if( list == null )
             return Collections.emptyMap();

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-security/eagle-security-hdfs-web/src/main/java/org/apache/eagle/service/security/hdfs/HDFSResourceSensitivityService.java
----------------------------------------------------------------------
diff --git a/eagle-security/eagle-security-hdfs-web/src/main/java/org/apache/eagle/service/security/hdfs/HDFSResourceSensitivityService.java b/eagle-security/eagle-security-hdfs-web/src/main/java/org/apache/eagle/service/security/hdfs/HDFSResourceSensitivityService.java
index 283e25a..050fe10 100644
--- a/eagle-security/eagle-security-hdfs-web/src/main/java/org/apache/eagle/service/security/hdfs/HDFSResourceSensitivityService.java
+++ b/eagle-security/eagle-security-hdfs-web/src/main/java/org/apache/eagle/service/security/hdfs/HDFSResourceSensitivityService.java
@@ -21,7 +21,9 @@ import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
+import org.apache.eagle.log.entity.GenericServiceAPIResponseEntity;
 import org.apache.eagle.log.entity.ListQueryAPIResponseEntity;
+import org.apache.eagle.service.generic.GenericEntityServiceResource;
 import org.apache.eagle.service.generic.ListQueryResource;
 import org.apache.eagle.security.entity.FileSensitivityAPIEntity;
 import org.slf4j.Logger;
@@ -40,8 +42,8 @@ public class HDFSResourceSensitivityService {
 	@SuppressWarnings("unchecked")
 	public Map<String, Map<String, String>>  getAllFileSensitivityMap()
 	{
-		  ListQueryResource resource = new ListQueryResource();
-		  ListQueryAPIResponseEntity ret = resource.listQuery("FileSensitivityService[]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,0, null);
+		  GenericEntityServiceResource resource = new GenericEntityServiceResource();
+		  GenericServiceAPIResponseEntity ret = resource.search("FileSensitivityService[]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,0, null, false);
 	      List<FileSensitivityAPIEntity> list = (List<FileSensitivityAPIEntity>) ret.getObj();
 	      if( list == null )
 	        	return Collections.emptyMap();
@@ -69,9 +71,9 @@ public class HDFSResourceSensitivityService {
 	@SuppressWarnings("unchecked")
 	public Map<String, String> getFileSensitivityMapBySite ( String site )
 	{
-		ListQueryResource resource = new ListQueryResource();
-		ListQueryAPIResponseEntity ret = resource.listQuery(String.format("FileSensitivityService[@site=\"%s\"]{*}", site ), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,0, null);
-	    List<FileSensitivityAPIEntity> list = (List<FileSensitivityAPIEntity>) ret.getObj();	    
+		GenericEntityServiceResource resource = new GenericEntityServiceResource();
+		GenericServiceAPIResponseEntity ret = resource.search(String.format("FileSensitivityService[@site=\"%s\"]{*}", site ), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,0, null, false);
+	    List<FileSensitivityAPIEntity> list = (List<FileSensitivityAPIEntity>) ret.getObj();
 	    if( list == null )
         	return Collections.emptyMap();
 	    Map<String, String>  fileSensitivityMap = new HashMap <String, String> ();	
@@ -91,8 +93,8 @@ public class HDFSResourceSensitivityService {
 	@SuppressWarnings("unchecked")
 	public List<FileSensitivityAPIEntity>  filterSensitivity ( String site , String resourceFilter )
 	{
-		ListQueryResource resource = new ListQueryResource();
-		ListQueryAPIResponseEntity ret = resource.listQuery(String.format("FileSensitivityService[@site=\"%s\"]{@filedir="+resourceFilter+".*}", site ), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,0, null);
+		GenericEntityServiceResource resource = new GenericEntityServiceResource();
+		GenericServiceAPIResponseEntity ret = resource.search(String.format("FileSensitivityService[@site=\"%s\"]{@filedir="+resourceFilter+".*}", site ), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,0, null, false);
 	    List<FileSensitivityAPIEntity> list = (List<FileSensitivityAPIEntity>) ret.getObj();
 	    if( list == null )
         	return Collections.emptyList();	    

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveMetadataAccessConfigDAOImpl.java
----------------------------------------------------------------------
diff --git a/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveMetadataAccessConfigDAOImpl.java b/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveMetadataAccessConfigDAOImpl.java
index d0c18ed..b4d3f9e 100644
--- a/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveMetadataAccessConfigDAOImpl.java
+++ b/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveMetadataAccessConfigDAOImpl.java
@@ -16,9 +16,10 @@
  */
 package org.apache.eagle.service.security.hive.dao;
 
-import org.apache.eagle.alert.entity.SiteApplicationServiceEntity;
+import org.apache.eagle.alert.entity.AlertDataSourceEntity;
+import org.apache.eagle.log.entity.GenericServiceAPIResponseEntity;
 import org.apache.eagle.log.entity.ListQueryAPIResponseEntity;
-import org.apache.eagle.policy.common.Constants;
+import org.apache.eagle.service.generic.GenericEntityServiceResource;
 import org.apache.eagle.service.generic.ListQueryResource;
 import com.fasterxml.jackson.databind.ObjectMapper;
 import org.slf4j.Logger;
@@ -32,21 +33,39 @@ public class HiveMetadataAccessConfigDAOImpl implements HiveMetadataAccessConfig
     private static Logger LOG = LoggerFactory.getLogger(HiveMetadataAccessConfigDAOImpl.class);
 
     // site to HiveMetadataAccessConfig
+//    @Override
+//    public Map<String, HiveMetadataAccessConfig> getAllConfigs() throws Exception{
+//        ListQueryResource resource = new ListQueryResource();
+//        /* parameters are: query, startTime, endTime, pageSzie, startRowkey, treeAgg, timeSeries, intervalmin, top, filterIfMissing,
+//        * parallel, metricName*/
+//        ListQueryAPIResponseEntity ret = resource.listQuery("AlertDataSourceService[@dataSource=\"hiveQueryLog\"]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
+//                0, null);
+//        List<AlertDataSourceEntity> list = (List<AlertDataSourceEntity>) ret.getObj();
+//        Map<String, HiveMetadataAccessConfig> siteHiveConfigs = new HashMap<String, HiveMetadataAccessConfig>();
+//        for(AlertDataSourceEntity hiveDataSource : list){
+//            siteHiveConfigs.put(hiveDataSource.getTags().get("site"), convert(hiveDataSource.getConfig()));
+//        }
+//        return siteHiveConfigs;
+//    }
+
+    // site to HiveMetadataAccessConfig
     @Override
     public Map<String, HiveMetadataAccessConfig> getAllConfigs() throws Exception{
-        ListQueryResource resource = new ListQueryResource();
+        GenericEntityServiceResource resource = new GenericEntityServiceResource();
+
         /* parameters are: query, startTime, endTime, pageSzie, startRowkey, treeAgg, timeSeries, intervalmin, top, filterIfMissing,
         * parallel, metricName*/
-        ListQueryAPIResponseEntity ret = resource.listQuery(Constants.SITE_APPLICATION_SERVICE_ENDPOINT_NAME+"[@application=\"hiveQueryLog\"]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
-                0, null);
-        List<SiteApplicationServiceEntity> list = (List<SiteApplicationServiceEntity>) ret.getObj();
-        Map<String, HiveMetadataAccessConfig> siteHiveConfigs = new HashMap<>();
-        for(SiteApplicationServiceEntity hiveDataSource : list){
+        GenericServiceAPIResponseEntity ret = resource.search("AlertDataSourceService[@dataSource=\"hiveQueryLog\"]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
+                0, null, false);
+        List<AlertDataSourceEntity> list = (List<AlertDataSourceEntity>) ret.getObj();
+        Map<String, HiveMetadataAccessConfig> siteHiveConfigs = new HashMap<String, HiveMetadataAccessConfig>();
+        for(AlertDataSourceEntity hiveDataSource : list){
             siteHiveConfigs.put(hiveDataSource.getTags().get("site"), convert(hiveDataSource.getConfig()));
         }
         return siteHiveConfigs;
     }
 
+
     private HiveMetadataAccessConfig convert(String config){
         ObjectMapper mapper = new ObjectMapper();
         HiveMetadataAccessConfig c;
@@ -62,13 +81,13 @@ public class HiveMetadataAccessConfigDAOImpl implements HiveMetadataAccessConfig
     // HiveMetadataAccessConfig for one site
     @Override
     public HiveMetadataAccessConfig getConfig(String site) throws Exception{
-        ListQueryResource resource = new ListQueryResource();
+        GenericEntityServiceResource resource = new GenericEntityServiceResource();
         /* parameters are: query, startTime, endTime, pageSzie, startRowkey, treeAgg, timeSeries, intervalmin, top, filterIfMissing,
         * parallel, metricName*/
-        String queryFormat = Constants.SITE_APPLICATION_SERVICE_ENDPOINT_NAME+"[@application=\"hiveQueryLog\" AND @site=\"%s\"]{*}";
-        ListQueryAPIResponseEntity ret = resource.listQuery(String.format(queryFormat, site), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
-                0, null);
-        List<SiteApplicationServiceEntity> list = (List<SiteApplicationServiceEntity>) ret.getObj();
+        String queryFormat = "AlertDataSourceService[@dataSource=\"hiveQueryLog\" AND @site=\"%s\"]{*}";
+        GenericServiceAPIResponseEntity ret = resource.search(String.format(queryFormat, site), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
+                0, null, false);
+        List<AlertDataSourceEntity> list = (List<AlertDataSourceEntity>) ret.getObj();
         if(list == null || list.size() ==0)
             throw new BadHiveMetadataAccessConfigException("config is empty for site " + site);
         return convert(list.get(0).getConfig());

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveSensitivityMetadataDAOImpl.java
----------------------------------------------------------------------
diff --git a/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveSensitivityMetadataDAOImpl.java b/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveSensitivityMetadataDAOImpl.java
index e948e31..90ee845 100644
--- a/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveSensitivityMetadataDAOImpl.java
+++ b/eagle-security/eagle-security-hive-web/src/main/java/org/apache/eagle/service/security/hive/dao/HiveSensitivityMetadataDAOImpl.java
@@ -16,7 +16,9 @@
  */
 package org.apache.eagle.service.security.hive.dao;
 
+import org.apache.eagle.log.entity.GenericServiceAPIResponseEntity;
 import org.apache.eagle.log.entity.ListQueryAPIResponseEntity;
+import org.apache.eagle.service.generic.GenericEntityServiceResource;
 import org.apache.eagle.service.generic.ListQueryResource;
 import org.apache.eagle.security.entity.HiveResourceSensitivityAPIEntity;
 import org.slf4j.Logger;
@@ -32,11 +34,11 @@ public class HiveSensitivityMetadataDAOImpl implements HiveSensitivityMetadataDA
 
     @Override
     public Map<String, Map<String, String>> getAllHiveSensitivityMap(){
-        ListQueryResource resource = new ListQueryResource();
+        GenericEntityServiceResource resource = new GenericEntityServiceResource();
         /* parameters are: query, startTime, endTime, pageSzie, startRowkey, treeAgg, timeSeries, intervalmin, top, filterIfMissing,
         * parallel, metricName*/
-        ListQueryAPIResponseEntity ret = resource.listQuery("HiveResourceSensitivityService[]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
-                0, null);
+        GenericServiceAPIResponseEntity ret = resource.search("HiveResourceSensitivityService[]{*}", null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
+                0, null, false);
         List<HiveResourceSensitivityAPIEntity> list = (List<HiveResourceSensitivityAPIEntity>) ret.getObj();
         if( list == null )
         	return Collections.emptyMap();
@@ -62,10 +64,10 @@ public class HiveSensitivityMetadataDAOImpl implements HiveSensitivityMetadataDA
 
     @Override
     public Map<String, String> getHiveSensitivityMap(String site){
-        ListQueryResource resource = new ListQueryResource();
+        GenericEntityServiceResource resource = new GenericEntityServiceResource();
         String queryFormat = "HiveResourceSensitivityService[@site=\"%s\"]{*}";
-        ListQueryAPIResponseEntity ret = resource.listQuery(String.format(queryFormat, site), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
-                0, null);
+        GenericServiceAPIResponseEntity ret = resource.search(String.format(queryFormat, site), null, null, Integer.MAX_VALUE, null, false, false, 0L, 0, false,
+                0, null, false);
         List<HiveResourceSensitivityAPIEntity> list = (List<HiveResourceSensitivityAPIEntity>) ret.getObj();
         if( list == null )
         	return Collections.emptyMap();

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/pom.xml
----------------------------------------------------------------------
diff --git a/eagle-webservice/pom.xml b/eagle-webservice/pom.xml
index bdd682a..abddd91 100644
--- a/eagle-webservice/pom.xml
+++ b/eagle-webservice/pom.xml
@@ -65,6 +65,12 @@
 			</exclusions>
 		</dependency>
 
+        <dependency>
+            <groupId>org.apache.eagle</groupId>
+            <artifactId>eagle-storage-jdbc</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+
 		<!-- jersey needs asm3, so use extcos 0.3b -->
 		<dependency>
 			<groupId>net.sf.extcos</groupId>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/resources/application.conf
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/resources/application.conf b/eagle-webservice/src/main/resources/application.conf
index c67ea3c..23a7067 100644
--- a/eagle-webservice/src/main/resources/application.conf
+++ b/eagle-webservice/src/main/resources/application.conf
@@ -13,13 +13,17 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-eagle{
-	service{
-		storage-type="hbase"
-		hbase-zookeeper-quorum="sandbox.hortonworks.com"
-		hbase-zookeeper-property-clientPort=2181
-		zookeeper-znode-parent="/hbase-unsecure",
-		springActiveProfile="sandbox"
-		audit-enabled=true
+eagle {
+	service {
+		storage-type="jdbc"
+		storage-adapter="derby"
+		storage-username="eagle"
+		storage-password=eagle
+		storage-database=eagle
+		# Derby database location: $TOMCAT_HOME/data/eagle
+		storage-connection-url="jdbc:derby:../data/eagle;create=true"
+		storage-connection-props="encoding=UTF-8"
+		storage-driver-class="org.apache.derby.jdbc.EmbeddedDriver"
+		storage-connection-max=8
 	}
-}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/resources/application.conf.bak
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/resources/application.conf.bak b/eagle-webservice/src/main/resources/application.conf.bak
new file mode 100644
index 0000000..680be0e
--- /dev/null
+++ b/eagle-webservice/src/main/resources/application.conf.bak
@@ -0,0 +1,25 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+eagle{
+	service{
+		storage-type="hbase"
+		hbase-zookeeper-quorum="localhost"
+		hbase-zookeeper-property-clientPort=2181
+		zookeeper-znode-parent="/hbase",
+		springActiveProfile="sandbox"
+		audit-enabled=true
+	}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/META-INF/context.xml
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/META-INF/context.xml b/eagle-webservice/src/main/webapp/META-INF/context.xml
new file mode 100644
index 0000000..9b0b5d0
--- /dev/null
+++ b/eagle-webservice/src/main/webapp/META-INF/context.xml
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Context path="/">
+</Context>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/WEB-INF/web.xml
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/WEB-INF/web.xml b/eagle-webservice/src/main/webapp/WEB-INF/web.xml
index 21850de..ed56a73 100644
--- a/eagle-webservice/src/main/webapp/WEB-INF/web.xml
+++ b/eagle-webservice/src/main/webapp/WEB-INF/web.xml
@@ -102,4 +102,8 @@
     <listener>
         <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
     </listener>
-</web-app>
+    <session-config>
+        <!-- in minutes -->
+        <session-timeout>60</session-timeout>
+    </session-config>
+</web-app>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/index.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/index.html b/eagle-webservice/src/main/webapp/app/index.html
index c5e9e34..c096b21 100644
--- a/eagle-webservice/src/main/webapp/app/index.html
+++ b/eagle-webservice/src/main/webapp/app/index.html
@@ -145,7 +145,7 @@
 						<div class="collapse navbar-collapse" id="moduleMenu">
 							<ul class="nav navbar-nav">
 								<li ng-repeat="_grp in Site.current().applicationGroupList" ng-if="_grp.enabledList.length"
-									class="dropdown" ng-class="{active: Application.current().groupName === _grp.name}">
+									class="dropdown" ng-class="{active: Application.current().group === _grp.name}">
 									<a class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
 										{{_grp.name}}
 									</a>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/partials/config/application.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/partials/config/application.html b/eagle-webservice/src/main/webapp/app/partials/config/application.html
index 5c5b09e..8f05703 100644
--- a/eagle-webservice/src/main/webapp/app/partials/config/application.html
+++ b/eagle-webservice/src/main/webapp/app/partials/config/application.html
@@ -48,11 +48,11 @@
 				</div>
 				<div class="form-group">
 					<label for="applicationGroup">Group</label>
-					<input type="text" class="form-control" id="applicationGroup" placeholder="(Optional) Group name" ng-model="applications[application.tags.application].group">
+					<input type="text" class="form-control" id="applicationGroup" placeholder="(Optional) Group name" ng-model="applications[application.tags.application].groupName">
 				</div>
 				<div class="form-group">
 					<label for="applicationDescription">Description</label>
-					<textarea id="applicationDescription" class="form-control" placeholder="(Optional) Application description" rows="2" ng-model="applications[application.tags.application].desc"></textarea>
+					<textarea id="applicationDescription" class="form-control" placeholder="(Optional) Application description" rows="2" ng-model="applications[application.tags.application].description"></textarea>
 				</div>
 				<div class="form-group">
 					<label for="applicationConfiguration">Configuration</label>
@@ -74,7 +74,7 @@
 								<div class="product-info">
 									<a class="fa fa-times pull-right" ng-click="removeFeature(feature, applications[application.tags.application])"></a>
 									<span class="product-title">{{feature}}</span>
-									<span class="product-description">{{Application.featureList.set[feature].desc}}</span>
+									<span class="product-description">{{Application.featureList.set[feature].description}}</span>
 								</div>
 							</li>
 						</ul>
@@ -87,7 +87,7 @@
 								</button>
 								<div class="product-info">
 									<span class="product-title">{{feature}}</span>
-									<span class="product-description">{{Application.featureList.set[feature].desc}}</span>
+									<span class="product-description">{{Application.featureList.set[feature].description}}</span>
 								</div>
 							</li>
 						</ul>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/partials/config/feature.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/partials/config/feature.html b/eagle-webservice/src/main/webapp/app/partials/config/feature.html
index 3088883..6e13c0f 100644
--- a/eagle-webservice/src/main/webapp/app/partials/config/feature.html
+++ b/eagle-webservice/src/main/webapp/app/partials/config/feature.html
@@ -52,7 +52,7 @@
 				</div>
 				<div class="form-group">
 					<label for="featureDescription">Description</label>
-					<textarea id="featureDescription" class="form-control" placeholder="(Optional) Feature description." rows="10" ng-model="features[feature.tags.feature].desc"></textarea>
+					<textarea id="featureDescription" class="form-control" placeholder="(Optional) Feature description." rows="10" ng-model="features[feature.tags.feature].description"></textarea>
 				</div>
 			</div>
 		</div>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/partials/config/site.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/partials/config/site.html b/eagle-webservice/src/main/webapp/app/partials/config/site.html
index 1d792d9..e9ed1bf 100644
--- a/eagle-webservice/src/main/webapp/app/partials/config/site.html
+++ b/eagle-webservice/src/main/webapp/app/partials/config/site.html
@@ -65,7 +65,7 @@
 										<a class="fa fa-cog" ng-click="setApplication(application)"></a>
 										{{application.tags.application}}
 									</span>
-									<span class="product-description">{{Application.list.set[application.tags.application].desc}}</span>
+									<span class="product-description">{{Application.list.set[application.tags.application].description}}</span>
 								</div>
 							</li>
 						</ul>
@@ -78,7 +78,7 @@
 								</button>
 								<div class="product-info">
 									<span class="product-title">{{application.tags.application}}</span>
-									<span class="product-description">{{Application.list.set[application.tags.application].desc}}</span>
+									<span class="product-description">{{Application.list.set[application.tags.application].description}}</span>
 								</div>
 							</li>
 						</ul>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/feature/classification/page/sensitivity/folder.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/feature/classification/page/sensitivity/folder.html b/eagle-webservice/src/main/webapp/app/public/feature/classification/page/sensitivity/folder.html
index e7abd4f..cfefffa 100644
--- a/eagle-webservice/src/main/webapp/app/public/feature/classification/page/sensitivity/folder.html
+++ b/eagle-webservice/src/main/webapp/app/public/feature/classification/page/sensitivity/folder.html
@@ -62,7 +62,7 @@
 					</span>
 				</td>
 				<td>{{item.owner}}</td>
-				<td>{{item.group}}</td>
+				<td>{{item.groupName}}</td>
 				<td>{{item.sensitiveType}}</td>
 				<td ng-show="Auth.isRole('ROLE_ADMIN')">
 					<button class="fa fa-eye btn btn-primary btn-xs" ng-click="markSensitivity(item)" ng-show="!item.sensitiveType"

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/feature/common/controller.js
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/feature/common/controller.js b/eagle-webservice/src/main/webapp/app/public/feature/common/controller.js
index 9cbef65..d87ec6d 100644
--- a/eagle-webservice/src/main/webapp/app/public/feature/common/controller.js
+++ b/eagle-webservice/src/main/webapp/app/public/feature/common/controller.js
@@ -96,7 +96,7 @@
 				var _value = common.getValueByPath(item, path, "").toLowerCase();
 				return _value.indexOf(_key) !== -1;
 			}
-			return _hasKey(item, "tags.policyId") || _hasKey(item, "__expression") || _hasKey(item, "desc") || _hasKey(item, "owner") || _hasKey(item, "__mailStr");
+			return _hasKey(item, "tags.policyId") || _hasKey(item, "__expression") || _hasKey(item, "description") || _hasKey(item, "owner") || _hasKey(item, "__mailStr");
 		};
 
 		$scope.updatePolicyStatus = Policy.updatePolicyStatus;
@@ -490,7 +490,7 @@
 							groupCondOp: ">=",
 							groupCondVal: "2"
 						},
-						desc: "",
+						description: "",
 						enabled: true,
 						prefix: "alertdef",
 						remediationDef: "",

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyDetail.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyDetail.html b/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyDetail.html
index 506aeab..17f5bf5 100644
--- a/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyDetail.html
+++ b/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyDetail.html
@@ -35,7 +35,7 @@
 					</dd></dl>
 				</div>
 				<div class="inline-group">
-					<dl><dt>Description</dt><dd>{{policy.desc}}</dd></dl>
+					<dl><dt>Description</dt><dd>{{policy.description}}</dd></dl>
 				</div>
 				<div class="inline-group">
 					<dl><dt>Alert</dt><dd>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyEdit.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyEdit.html b/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyEdit.html
index 8fe2eb4..b3ad0a2 100644
--- a/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyEdit.html
+++ b/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyEdit.html
@@ -316,7 +316,7 @@
 				</div>
 				<div class="form-group">
 					<label>Description</label>
-					<textarea class="form-control" placeholder="Policy description" ng-model="policy.desc"></textarea>
+					<textarea class="form-control" placeholder="Policy description" ng-model="policy.description"></textarea>
 				</div>
 
 				<a data-toggle="collapse" href="[data-id='policyQuery']">

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyList.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyList.html b/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyList.html
index 6081636..20a38dd 100644
--- a/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyList.html
+++ b/eagle-webservice/src/main/webapp/app/public/feature/common/page/policyList.html
@@ -55,7 +55,7 @@
 					<tr>
 						<th width="30" sortpath="enabled"> </th>
 						<th width="200" sortpath="tags.policyId">Policy Name</th>
-						<th sortpath="desc">Description</th>
+						<th sortpath="description">Description</th>
 						<th width="150" sortpath="owner">Owner</th>
 						<th width="170" sortpath="lastModifiedDate">Last Modified</th>
 						<th width="95" ng-show="_parent.Auth.isRole('ROLE_ADMIN')">Action</th>
@@ -65,7 +65,7 @@
 					<tr>
 						<td><span class='fa fa-square' ng-class="item.enabled ? 'text-green' : 'text-muted'"> </span></td>
 						<td><a href="#/common/policyDetail/{{item.encodedRowkey}}" style="width: 200px;" class="text-breakall">{{item.tags.policyId}}</a></td>
-						<td>{{item.desc}}</td>
+						<td>{{item.description}}</td>
 						<td>{{item.owner}}</td>
 						<td>{{common.format.date(item.lastModifiedDate) || "-"}}</td>
 						<td ng-show="_parent.Auth.isRole('ROLE_ADMIN')">

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/feature/metadata/page/streamList.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/feature/metadata/page/streamList.html b/eagle-webservice/src/main/webapp/app/public/feature/metadata/page/streamList.html
index 806a234..2b73300 100644
--- a/eagle-webservice/src/main/webapp/app/public/feature/metadata/page/streamList.html
+++ b/eagle-webservice/src/main/webapp/app/public/feature/metadata/page/streamList.html
@@ -49,7 +49,7 @@
 					Description
 				</dt>
 				<dd>
-					{{stream.desc}}
+					{{stream.description}}
 				</dd>
 			</dl>
 		</div>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/js/app.config.js
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/js/app.config.js b/eagle-webservice/src/main/webapp/app/public/js/app.config.js
index 1e6fd79..876114f 100644
--- a/eagle-webservice/src/main/webapp/app/public/js/app.config.js
+++ b/eagle-webservice/src/main/webapp/app/public/js/app.config.js
@@ -28,7 +28,7 @@
 
 			updateEntity: 'rest/entities?serviceName=${serviceName}',
 			queryEntity: 'rest/entities/rowkey?serviceName=${serviceName}&value=${encodedRowkey}',
-			queryEntities: 'rest/list?query=${serviceName}[${condition}]{${values}}&pageSize=100000',
+			queryEntities: 'rest/entities?query=${serviceName}[${condition}]{${values}}&pageSize=100000',
 			deleteEntity: 'rest/entities/delete?serviceName=${serviceName}&byId=true',
 			deleteEntities: 'rest/entities?query=${serviceName}[${condition}]{*}&pageSize=100000',
 

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/js/srv/applicationSrv.js
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/js/srv/applicationSrv.js b/eagle-webservice/src/main/webapp/app/public/js/srv/applicationSrv.js
index 2c9e0b6..d911194 100644
--- a/eagle-webservice/src/main/webapp/app/public/js/srv/applicationSrv.js
+++ b/eagle-webservice/src/main/webapp/app/public/js/srv/applicationSrv.js
@@ -123,9 +123,9 @@
 								}
 							},
 							// Get format group name. Will mark as 'Others' if no group defined
-							groupName: {
+							group: {
 								get: function () {
-									return this.group || "Others";
+									return this.groupName || "Others";
 								}
 							},
 							configObj: {

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/app/public/js/srv/siteSrv.js
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/app/public/js/srv/siteSrv.js b/eagle-webservice/src/main/webapp/app/public/js/srv/siteSrv.js
index 907915d..c97e9a1 100644
--- a/eagle-webservice/src/main/webapp/app/public/js/srv/siteSrv.js
+++ b/eagle-webservice/src/main/webapp/app/public/js/srv/siteSrv.js
@@ -142,7 +142,7 @@
 						_site.applicationList.push(siteApplication);
 						_site.applicationList.set[siteApplication.tags.application] = siteApplication;
 
-						_appGroup = _site.applicationGroup[_application.groupName] = _site.applicationGroup[_application.groupName] || [];
+						_appGroup = _site.applicationGroup[_application.group] = _site.applicationGroup[_application.group] || [];
 						_appGroup.push(_application);
 					}
 				});

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/eagle-webservice/src/main/webapp/index.html
----------------------------------------------------------------------
diff --git a/eagle-webservice/src/main/webapp/index.html b/eagle-webservice/src/main/webapp/index.html
index a67650b..831f3f0 100755
--- a/eagle-webservice/src/main/webapp/index.html
+++ b/eagle-webservice/src/main/webapp/index.html
@@ -25,4 +25,4 @@
 	</head>
 	<body>
 	</body>
-</html>
\ No newline at end of file
+</html>

http://git-wip-us.apache.org/repos/asf/incubator-eagle/blob/ffd84fa0/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 6d77413..89fd0d8 100755
--- a/pom.xml
+++ b/pom.xml
@@ -229,6 +229,8 @@
         <mysql-connector-java.version>5.1.34</mysql-connector-java.version>
         <ddlutils.version>1.0</ddlutils.version>
         <torque.version>4.0</torque.version>
+        <!--<derby.version>10.1.3.1</derby.version>-->
+        <derby.version>10.10.2.0</derby.version>
 
         <!-- REST Service-->
         <jersey.version>1.8</jersey.version>
@@ -689,6 +691,11 @@
                 <version>${torque.version}</version>
             </dependency>
             <dependency>
+                <groupId>org.apache.derby</groupId>
+                <artifactId>derby</artifactId>
+                <version>${derby.version}</version>
+            </dependency>
+            <dependency>
                 <groupId>org.apache.tomcat.embed</groupId>
                 <artifactId>tomcat-embed-core</artifactId>
                 <version>${tomcat.embed.version}</version>


Mime
View raw message