[1/2] phoenix git commit: PHOENIX-2901 If namespaces are enabled, check for existence of schema when sequence created

2016-06-10 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 df65b174d -> 3c205ac49


PHOENIX-2901 If namespaces are enabled, check for existence of schema when 
sequence created


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/45e4af51
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/45e4af51
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/45e4af51

Branch: refs/heads/4.x-HBase-0.98
Commit: 45e4af519ff90a7969ba0ef690c3a9c5fe178229
Parents: df65b17
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Jun 10 16:49:54 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Jun 10 16:49:54 2016 +0530

--
 .../org/apache/phoenix/end2end/SequenceIT.java  |  58 -
 .../end2end/TenantSpecificViewIndexIT.java  | 211 +--
 .../org/apache/phoenix/end2end/UpgradeIT.java   |  41 +++-
 .../phoenix/end2end/index/ViewIndexIT.java  |  22 +-
 .../apache/phoenix/compile/FromCompiler.java|   4 +
 .../phoenix/query/ConnectionQueryServices.java  |   1 -
 .../query/ConnectionQueryServicesImpl.java  |  26 ++-
 .../apache/phoenix/schema/MetaDataClient.java   |  21 +-
 .../org/apache/phoenix/util/MetaDataUtil.java   |  35 +--
 .../org/apache/phoenix/util/PhoenixRuntime.java |   6 +-
 .../org/apache/phoenix/util/UpgradeUtil.java|  55 -
 11 files changed, 367 insertions(+), 113 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/45e4af51/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java
index 3e7ec31..3ed4fd7 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java
@@ -37,6 +37,7 @@ import java.util.Properties;
 import org.apache.phoenix.exception.SQLExceptionCode;
 import org.apache.phoenix.jdbc.PhoenixStatement;
 import org.apache.phoenix.query.QueryServices;
+import org.apache.phoenix.schema.SchemaNotFoundException;
 import org.apache.phoenix.schema.SequenceAlreadyExistsException;
 import org.apache.phoenix.schema.SequenceNotFoundException;
 import org.apache.phoenix.util.PhoenixRuntime;
@@ -110,6 +111,49 @@ public class SequenceIT extends BaseClientManagedTimeIT {
}
}

+@Test
+public void testCreateSequenceWhenNamespaceEnabled() throws Exception {
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+props.setProperty(QueryServices.IS_NAMESPACE_MAPPING_ENABLED, 
Boolean.toString(true));
+String sequenceSchemaName = "ALPHA";
+String sequenceName = sequenceSchemaName + ".M_OMEGA";
+
+nextConnection(props);
+try {
+conn.createStatement().execute("CREATE SEQUENCE " + sequenceName + 
" START WITH 2 INCREMENT BY 4");
+fail();
+} catch (SchemaNotFoundException e) {
+// expected
+}
+
+conn.createStatement().execute("CREATE SCHEMA " + sequenceSchemaName);
+nextConnection(props);
+conn.createStatement().execute("CREATE SEQUENCE " + sequenceName + " 
START WITH 2 INCREMENT BY 4");
+sequenceSchemaName = "TEST_SEQ_SCHEMA";
+sequenceName = "M_SEQ";
+conn.createStatement().execute("CREATE SCHEMA " + sequenceSchemaName);
+nextConnection(props);
+conn.createStatement().execute("USE " + sequenceSchemaName);
+conn.createStatement().execute("CREATE SEQUENCE " + sequenceName + " 
START WITH 2 INCREMENT BY 4");
+nextConnection(props);
+String query = "SELECT sequence_schema, sequence_name, current_value, 
increment_by FROM SYSTEM.\"SEQUENCE\" WHERE sequence_name='"
++ sequenceName + "'";
+ResultSet rs = conn.prepareStatement(query).executeQuery();
+assertTrue(rs.next());
+assertEquals(sequenceSchemaName, rs.getString("sequence_schema"));
+assertEquals(sequenceName, rs.getString("sequence_name"));
+assertEquals(2, rs.getInt("current_value"));
+assertEquals(4, rs.getInt("increment_by"));
+assertFalse(rs.next());
+try {
+conn.createStatement().execute(
+"CREATE SEQUENCE " + sequenceSchemaName + "." + 
sequenceName + " START WITH 2 INCREMENT BY 4");
+fail();
+} catch (SequenceAlreadyExistsExcep

[1/2] phoenix git commit: PHOENIX-2901 If namespaces are enabled, check for existence of schema when sequence created

2016-06-10 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 891131c78 -> 5fc6fa184


PHOENIX-2901 If namespaces are enabled, check for existence of schema when 
sequence created


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

Branch: refs/heads/4.x-HBase-1.1
Commit: a50bee213269e249c8f4bbae0242aa5a3a3b8341
Parents: 891131c
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Jun 10 16:09:13 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Jun 10 16:09:13 2016 +0530

--
 .../org/apache/phoenix/end2end/SequenceIT.java  |  58 -
 .../end2end/TenantSpecificViewIndexIT.java  | 211 +--
 .../org/apache/phoenix/end2end/UpgradeIT.java   |  41 +++-
 .../phoenix/end2end/index/ViewIndexIT.java  |  22 +-
 .../apache/phoenix/compile/FromCompiler.java|   4 +
 .../phoenix/query/ConnectionQueryServices.java  |   1 -
 .../query/ConnectionQueryServicesImpl.java  |  26 ++-
 .../apache/phoenix/schema/MetaDataClient.java   |  21 +-
 .../org/apache/phoenix/util/MetaDataUtil.java   |  36 ++--
 .../org/apache/phoenix/util/PhoenixRuntime.java |   6 +-
 .../org/apache/phoenix/util/UpgradeUtil.java|  55 -
 11 files changed, 367 insertions(+), 114 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/a50bee21/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java
index 3e7ec31..3ed4fd7 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/SequenceIT.java
@@ -37,6 +37,7 @@ import java.util.Properties;
 import org.apache.phoenix.exception.SQLExceptionCode;
 import org.apache.phoenix.jdbc.PhoenixStatement;
 import org.apache.phoenix.query.QueryServices;
+import org.apache.phoenix.schema.SchemaNotFoundException;
 import org.apache.phoenix.schema.SequenceAlreadyExistsException;
 import org.apache.phoenix.schema.SequenceNotFoundException;
 import org.apache.phoenix.util.PhoenixRuntime;
@@ -110,6 +111,49 @@ public class SequenceIT extends BaseClientManagedTimeIT {
}
}

+@Test
+public void testCreateSequenceWhenNamespaceEnabled() throws Exception {
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+props.setProperty(QueryServices.IS_NAMESPACE_MAPPING_ENABLED, 
Boolean.toString(true));
+String sequenceSchemaName = "ALPHA";
+String sequenceName = sequenceSchemaName + ".M_OMEGA";
+
+nextConnection(props);
+try {
+conn.createStatement().execute("CREATE SEQUENCE " + sequenceName + 
" START WITH 2 INCREMENT BY 4");
+fail();
+} catch (SchemaNotFoundException e) {
+// expected
+}
+
+conn.createStatement().execute("CREATE SCHEMA " + sequenceSchemaName);
+nextConnection(props);
+conn.createStatement().execute("CREATE SEQUENCE " + sequenceName + " 
START WITH 2 INCREMENT BY 4");
+sequenceSchemaName = "TEST_SEQ_SCHEMA";
+sequenceName = "M_SEQ";
+conn.createStatement().execute("CREATE SCHEMA " + sequenceSchemaName);
+nextConnection(props);
+conn.createStatement().execute("USE " + sequenceSchemaName);
+conn.createStatement().execute("CREATE SEQUENCE " + sequenceName + " 
START WITH 2 INCREMENT BY 4");
+nextConnection(props);
+String query = "SELECT sequence_schema, sequence_name, current_value, 
increment_by FROM SYSTEM.\"SEQUENCE\" WHERE sequence_name='"
++ sequenceName + "'";
+ResultSet rs = conn.prepareStatement(query).executeQuery();
+assertTrue(rs.next());
+assertEquals(sequenceSchemaName, rs.getString("sequence_schema"));
+assertEquals(sequenceName, rs.getString("sequence_name"));
+assertEquals(2, rs.getInt("current_value"));
+assertEquals(4, rs.getInt("increment_by"));
+assertFalse(rs.next());
+try {
+conn.createStatement().execute(
+"CREATE SEQUENCE " + sequenceSchemaName + "." + 
sequenceName + " START WITH 2 INCREMENT BY 4");
+fail();
+} catch (SequenceAlreadyExistsExcep

[2/2] phoenix git commit: PHOENIX-2915 Dropping of Index can still leave some non-replayed writes in WAL

2016-06-10 Thread ankit
PHOENIX-2915 Dropping of Index can still leave some non-replayed writes in WAL


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/3c205ac4
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/3c205ac4
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/3c205ac4

Branch: refs/heads/4.x-HBase-0.98
Commit: 3c205ac498e5873541bfcf26dea781a58cc22d3a
Parents: 45e4af5
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Jun 10 16:50:46 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Jun 10 16:50:46 2016 +0530

--
 .../query/ConnectionQueryServicesImpl.java  | 58 +---
 1 file changed, 39 insertions(+), 19 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/3c205ac4/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
index fad79b8..b086113 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
@@ -1531,7 +1531,8 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 }
 
 @Override
-public MetaDataMutationResult dropTable(final List 
tableMetaData, final PTableType tableType, final boolean cascade) throws 
SQLException {
+public MetaDataMutationResult dropTable(final List 
tableMetaData, final PTableType tableType,
+final boolean cascade) throws SQLException {
 byte[][] rowKeyMetadata = new byte[3][];
 SchemaUtil.getVarChars(tableMetaData.get(0).getRow(), rowKeyMetadata);
 byte[] tenantIdBytes = 
rowKeyMetadata[PhoenixDatabaseMetaData.TENANT_ID_INDEX];
@@ -1566,18 +1567,14 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 case TABLE_ALREADY_EXISTS:
 ReadOnlyProps props = this.getProps();
 boolean dropMetadata = props.getBoolean(DROP_METADATA_ATTRIB, 
DEFAULT_DROP_METADATA);
+PTable table = result.getTable();
 if (dropMetadata) {
+flushParentPhysicalTable(table);
 dropTables(result.getTableNamesToDelete());
 }
 invalidateTables(result.getTableNamesToDelete());
 if (tableType == PTableType.TABLE) {
-boolean isNamespaceMapped = 
result.getTable().isNamespaceMapped();
-byte[] physicalName;
-if (!isNamespaceMapped) {
-physicalName = SchemaUtil.getTableNameAsBytes(schemaBytes, 
tableBytes);
-} else {
-physicalName = TableName.valueOf(schemaBytes, 
tableBytes).getName();
-}
+byte[] physicalName = table.getPhysicalName().getBytes();
 long timestamp = 
MetaDataUtil.getClientTimeStamp(tableMetaData);
 ensureViewIndexTableDropped(physicalName, timestamp);
 ensureLocalIndexTableDropped(physicalName, timestamp);
@@ -1590,6 +1587,25 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
   return result;
 }
 
+/*
+ * PHOENIX-2915 while dropping index, flush data table to avoid stale WAL 
edits of indexes 1. Flush parent table if
+ * dropping view has indexes 2. Dropping table indexes 3. Dropping view 
indexes
+ */
+private void flushParentPhysicalTable(PTable table) throws SQLException {
+byte[] parentPhysicalTableName = null;
+if (PTableType.VIEW == table.getType()) {
+if (!table.getIndexes().isEmpty()) {
+parentPhysicalTableName = table.getPhysicalName().getBytes();
+}
+} else if (PTableType.INDEX == table.getType()) {
+PTable parentTable = getTable(null, 
table.getParentName().getString(), HConstants.LATEST_TIMESTAMP);
+parentPhysicalTableName = parentTable.getPhysicalName().getBytes();
+}
+if (parentPhysicalTableName != null) {
+flushTable(parentPhysicalTableName);
+}
+}
+
 @Override
 public MetaDataMutationResult dropFunction(final List 
functionData, final boolean ifExists) throws SQLException {
 byte[][] rowKeyMetadata = new byte[2][];
@@ -1661,31 +1677,35 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 
 private void ensureViewIndexTableCreated(PName tenantId, byte[] 
physicalIndexTableName, long timestamp,
 boolean isNam

[2/2] phoenix git commit: PHOENIX-2915 Dropping of Index can still leave some non-replayed writes in WAL

2016-06-10 Thread ankit
PHOENIX-2915 Dropping of Index can still leave some non-replayed writes in WAL


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/49618c83
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/49618c83
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/49618c83

Branch: refs/heads/master
Commit: 49618c835bf053d7e3846c809b2fba22418c4b26
Parents: 8eba8e2
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Jun 10 16:00:32 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Jun 10 16:00:32 2016 +0530

--
 .../query/ConnectionQueryServicesImpl.java  | 58 +---
 1 file changed, 39 insertions(+), 19 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/49618c83/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
index 03ed549..56bd50c 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
@@ -1488,7 +1488,8 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 }
 
 @Override
-public MetaDataMutationResult dropTable(final List 
tableMetaData, final PTableType tableType, final boolean cascade) throws 
SQLException {
+public MetaDataMutationResult dropTable(final List 
tableMetaData, final PTableType tableType,
+final boolean cascade) throws SQLException {
 byte[][] rowKeyMetadata = new byte[3][];
 SchemaUtil.getVarChars(tableMetaData.get(0).getRow(), rowKeyMetadata);
 byte[] tenantIdBytes = 
rowKeyMetadata[PhoenixDatabaseMetaData.TENANT_ID_INDEX];
@@ -1523,19 +1524,15 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 case TABLE_ALREADY_EXISTS:
 ReadOnlyProps props = this.getProps();
 boolean dropMetadata = props.getBoolean(DROP_METADATA_ATTRIB, 
DEFAULT_DROP_METADATA);
+PTable table = result.getTable();
 if (dropMetadata) {
+flushParentPhysicalTable(table);
 dropTables(result.getTableNamesToDelete());
 }
 invalidateTables(result.getTableNamesToDelete());
 long timestamp = MetaDataUtil.getClientTimeStamp(tableMetaData);
 if (tableType == PTableType.TABLE) {
-boolean isNamespaceMapped = 
result.getTable().isNamespaceMapped();
-byte[] physicalName;
-if (!isNamespaceMapped) {
-physicalName = SchemaUtil.getTableNameAsBytes(schemaBytes, 
tableBytes);
-} else {
-physicalName = TableName.valueOf(schemaBytes, 
tableBytes).getName();
-}
+byte[] physicalName = table.getPhysicalName().getBytes();
 ensureViewIndexTableDropped(physicalName, timestamp);
 ensureLocalIndexTableDropped(physicalName, timestamp);
 tableStatsCache.invalidate(new 
ImmutableBytesPtr(physicalName));
@@ -1547,6 +1544,25 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
   return result;
 }
 
+/*
+ * PHOENIX-2915 while dropping index, flush data table to avoid stale WAL 
edits of indexes 1. Flush parent table if
+ * dropping view has indexes 2. Dropping table indexes 3. Dropping view 
indexes
+ */
+private void flushParentPhysicalTable(PTable table) throws SQLException {
+byte[] parentPhysicalTableName = null;
+if (PTableType.VIEW == table.getType()) {
+if (!table.getIndexes().isEmpty()) {
+parentPhysicalTableName = table.getPhysicalName().getBytes();
+}
+} else if (PTableType.INDEX == table.getType()) {
+PTable parentTable = getTable(null, 
table.getParentName().getString(), HConstants.LATEST_TIMESTAMP);
+parentPhysicalTableName = parentTable.getPhysicalName().getBytes();
+}
+if (parentPhysicalTableName != null) {
+flushTable(parentPhysicalTableName);
+}
+}
+
 @Override
 public MetaDataMutationResult dropFunction(final List 
functionData, final boolean ifExists) throws SQLException {
 byte[][] rowKeyMetadata = new byte[2][];
@@ -1623,31 +1639,35 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 
 private void ensureViewIndexTableCreated(PName te

[2/2] phoenix git commit: PHOENIX-2915 Dropping of Index can still leave some non-replayed writes in WAL

2016-06-10 Thread ankit
PHOENIX-2915 Dropping of Index can still leave some non-replayed writes in WAL


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

Branch: refs/heads/4.x-HBase-1.0
Commit: a747b459a15ed271f536b1b08fab416eb5f03fb7
Parents: 5a5da14
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Jun 10 16:26:08 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Jun 10 16:26:08 2016 +0530

--
 .../query/ConnectionQueryServicesImpl.java  | 58 +---
 1 file changed, 39 insertions(+), 19 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/a747b459/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
index c6d8683..b51be5d 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
@@ -1530,7 +1530,8 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 }
 
 @Override
-public MetaDataMutationResult dropTable(final List 
tableMetaData, final PTableType tableType, final boolean cascade) throws 
SQLException {
+public MetaDataMutationResult dropTable(final List 
tableMetaData, final PTableType tableType,
+final boolean cascade) throws SQLException {
 byte[][] rowKeyMetadata = new byte[3][];
 SchemaUtil.getVarChars(tableMetaData.get(0).getRow(), rowKeyMetadata);
 byte[] tenantIdBytes = 
rowKeyMetadata[PhoenixDatabaseMetaData.TENANT_ID_INDEX];
@@ -1565,18 +1566,14 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 case TABLE_ALREADY_EXISTS:
 ReadOnlyProps props = this.getProps();
 boolean dropMetadata = props.getBoolean(DROP_METADATA_ATTRIB, 
DEFAULT_DROP_METADATA);
+PTable table = result.getTable();
 if (dropMetadata) {
+flushParentPhysicalTable(table);
 dropTables(result.getTableNamesToDelete());
 }
 invalidateTables(result.getTableNamesToDelete());
 if (tableType == PTableType.TABLE) {
-boolean isNamespaceMapped = 
result.getTable().isNamespaceMapped();
-byte[] physicalName;
-if (!isNamespaceMapped) {
-physicalName = SchemaUtil.getTableNameAsBytes(schemaBytes, 
tableBytes);
-} else {
-physicalName = TableName.valueOf(schemaBytes, 
tableBytes).getName();
-}
+byte[] physicalName = table.getPhysicalName().getBytes();
 long timestamp = 
MetaDataUtil.getClientTimeStamp(tableMetaData);
 ensureViewIndexTableDropped(physicalName, timestamp);
 ensureLocalIndexTableDropped(physicalName, timestamp);
@@ -1589,6 +1586,25 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
   return result;
 }
 
+/*
+ * PHOENIX-2915 while dropping index, flush data table to avoid stale WAL 
edits of indexes 1. Flush parent table if
+ * dropping view has indexes 2. Dropping table indexes 3. Dropping view 
indexes
+ */
+private void flushParentPhysicalTable(PTable table) throws SQLException {
+byte[] parentPhysicalTableName = null;
+if (PTableType.VIEW == table.getType()) {
+if (!table.getIndexes().isEmpty()) {
+parentPhysicalTableName = table.getPhysicalName().getBytes();
+}
+} else if (PTableType.INDEX == table.getType()) {
+PTable parentTable = getTable(null, 
table.getParentName().getString(), HConstants.LATEST_TIMESTAMP);
+parentPhysicalTableName = parentTable.getPhysicalName().getBytes();
+}
+if (parentPhysicalTableName != null) {
+flushTable(parentPhysicalTableName);
+}
+}
+
 @Override
 public MetaDataMutationResult dropFunction(final List 
functionData, final boolean ifExists) throws SQLException {
 byte[][] rowKeyMetadata = new byte[2][];
@@ -1660,31 +1676,35 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 
 private void ensureViewIndexTableCreated(PName tenantId, byte[] 
physicalIndexTableName, long timestamp,
 boolean isNam

phoenix git commit: PHOENIX-2901 If namespaces are enabled, check for existence of schema when sequence created(Addendum)

2016-06-10 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 5fc6fa184 -> 79bd03e08


PHOENIX-2901 If namespaces are enabled, check for existence of schema when 
sequence created(Addendum)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/79bd03e0
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/79bd03e0
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/79bd03e0

Branch: refs/heads/4.x-HBase-1.1
Commit: 79bd03e08547e0180eac4177105c50aa148ecfc3
Parents: 5fc6fa1
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Jun 10 16:33:34 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Jun 10 16:33:34 2016 +0530

--
 .../org/apache/phoenix/end2end/TenantSpecificViewIndexIT.java   | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/79bd03e0/phoenix-core/src/it/java/org/apache/phoenix/end2end/TenantSpecificViewIndexIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/TenantSpecificViewIndexIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/TenantSpecificViewIndexIT.java
index 69d9140..9f95a77 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/TenantSpecificViewIndexIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/TenantSpecificViewIndexIT.java
@@ -199,8 +199,9 @@ public class TenantSpecificViewIndexIT extends 
BaseTenantSpecificViewIndexIT {
 rs = conn.createStatement().executeQuery("explain select pk2,col1 from 
" + viewName + " where col1='f'");
 if (localIndex) {
 assertEquals("CLIENT PARALLEL 1-WAY RANGE SCAN OVER "
-+ SchemaUtil.getPhysicalHBaseTableName(tableName, 
isNamespaceMapped, PTableType.TABLE) + " ['"
-+ tenantId + "',1,'f']\n" + "SERVER FILTER BY FIRST 
KEY ONLY\n" + "CLIENT MERGE SORT",
++ 
Bytes.toString(MetaDataUtil.getLocalIndexPhysicalName(SchemaUtil
+.getPhysicalHBaseTableName(tableName, 
isNamespaceMapped, PTableType.TABLE).getBytes())) + " ['"
++ tenantId + "',-32768,'f']\n" + "SERVER FILTER BY 
FIRST KEY ONLY\n" + "CLIENT MERGE SORT",
 QueryUtil.getExplainPlan(rs));
 } else {
 assertEquals("CLIENT PARALLEL 1-WAY RANGE SCAN OVER "



phoenix git commit: PHOENIX-3008 Prevent upgrade of existing multi-tenant table to map to namespace until we support it correctly

2016-06-20 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 817764456 -> 257960b05


PHOENIX-3008 Prevent upgrade of existing multi-tenant table to map to namespace 
until we support it correctly


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/257960b0
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/257960b0
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/257960b0

Branch: refs/heads/4.x-HBase-1.1
Commit: 257960b056401602e48dd21089a14a637e11cd94
Parents: 8177644
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon Jun 20 11:42:01 2016 -0700
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon Jun 20 11:42:01 2016 -0700

--
 .../src/main/java/org/apache/phoenix/util/UpgradeUtil.java | 2 ++
 1 file changed, 2 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/257960b0/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
index 5b81a6c..3c07d95 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
@@ -1512,6 +1512,8 @@ public class UpgradeUtil {
 String schemaName = 
SchemaUtil.getSchemaNameFromFullName(tableName);
 // Confirm table is not already upgraded
 PTable table = PhoenixRuntime.getTable(conn, tableName);
+if (table.isMultiTenant()) { throw new IllegalArgumentException(
+"Sorry!! currently support for upgrading multi-tenant 
table to map to namespace is not supported!!"); }
 // Upgrade is not required if schemaName is not present.
 if (schemaName.equals("") && !PTableType.VIEW
 .equals(table.getType())) { throw new 
IllegalArgumentException("Table doesn't have schema name"); }



phoenix git commit: PHOENIX-3008 Prevent upgrade of existing multi-tenant table to map to namespace until we support it correctly

2016-06-20 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 584a08578 -> 881246531


PHOENIX-3008 Prevent upgrade of existing multi-tenant table to map to namespace 
until we support it correctly


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

Branch: refs/heads/4.x-HBase-0.98
Commit: 881246531f126fc7c2e24f531933865f745e7947
Parents: 584a085
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon Jun 20 11:43:23 2016 -0700
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon Jun 20 11:43:23 2016 -0700

--
 .../src/main/java/org/apache/phoenix/util/UpgradeUtil.java | 2 ++
 1 file changed, 2 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/88124653/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
index f13334d..ce7c3db 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
@@ -1512,6 +1512,8 @@ public class UpgradeUtil {
 String schemaName = 
SchemaUtil.getSchemaNameFromFullName(tableName);
 // Confirm table is not already upgraded
 PTable table = PhoenixRuntime.getTable(conn, tableName);
+if (table.isMultiTenant()) { throw new IllegalArgumentException(
+"Sorry!! currently support for upgrading multi-tenant 
table to map to namespace is not supported!!"); }
 // Upgrade is not required if schemaName is not present.
 if (schemaName.equals("") && !PTableType.VIEW
 .equals(table.getType())) { throw new 
IllegalArgumentException("Table doesn't have schema name"); }



phoenix git commit: PHOENIX-3008 Prevent upgrade of existing multi-tenant table to map to namespace until we support it correctly

2016-06-20 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master e53e3bbb6 -> b78d5b0c1


PHOENIX-3008 Prevent upgrade of existing multi-tenant table to map to namespace 
until we support it correctly


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

Branch: refs/heads/master
Commit: b78d5b0c16911a3925ea5113a325eb5b4f938e2d
Parents: e53e3bb
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon Jun 20 11:41:18 2016 -0700
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon Jun 20 11:41:18 2016 -0700

--
 .../src/main/java/org/apache/phoenix/util/UpgradeUtil.java | 2 ++
 1 file changed, 2 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/b78d5b0c/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
index 5b81a6c..3c07d95 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/UpgradeUtil.java
@@ -1512,6 +1512,8 @@ public class UpgradeUtil {
 String schemaName = 
SchemaUtil.getSchemaNameFromFullName(tableName);
 // Confirm table is not already upgraded
 PTable table = PhoenixRuntime.getTable(conn, tableName);
+if (table.isMultiTenant()) { throw new IllegalArgumentException(
+"Sorry!! currently support for upgrading multi-tenant 
table to map to namespace is not supported!!"); }
 // Upgrade is not required if schemaName is not present.
 if (schemaName.equals("") && !PTableType.VIEW
 .equals(table.getType())) { throw new 
IllegalArgumentException("Table doesn't have schema name"); }



phoenix git commit: PHOENIX-2949 Fix estimated region size when checking for serial query

2016-06-23 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 88c380925 -> 4de25dea4


PHOENIX-2949 Fix estimated region size when checking for serial query


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/4de25dea
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/4de25dea
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/4de25dea

Branch: refs/heads/4.x-HBase-1.0
Commit: 4de25dea48c95c0abc810b2678dbdbea0d86e1ab
Parents: 88c3809
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu Jun 23 13:56:21 2016 -0700
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu Jun 23 13:56:21 2016 -0700

--
 .../org/apache/phoenix/execute/ScanPlan.java| 46 ++--
 .../org/apache/phoenix/query/QueryServices.java |  2 +-
 2 files changed, 25 insertions(+), 23 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/4de25dea/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java 
b/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
index c55a1cc..0975b3f 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
@@ -25,7 +25,7 @@ import java.sql.SQLException;
 import java.util.Collections;
 import java.util.List;
 
-import org.apache.hadoop.hbase.HTableDescriptor;
+import org.apache.hadoop.hbase.HConstants;
 import org.apache.hadoop.hbase.client.Scan;
 import org.apache.phoenix.compile.GroupByCompiler.GroupBy;
 import org.apache.phoenix.compile.OrderByCompiler.OrderBy;
@@ -62,7 +62,6 @@ import org.apache.phoenix.schema.SaltingUtil;
 import org.apache.phoenix.schema.TableRef;
 import org.apache.phoenix.schema.stats.GuidePostsInfo;
 import org.apache.phoenix.schema.stats.PTableStats;
-import org.apache.phoenix.schema.stats.StatisticsUtil;
 import org.apache.phoenix.util.LogUtil;
 import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ScanUtil;
@@ -118,7 +117,7 @@ public class ScanPlan extends BaseQueryPlan {
 Scan scan = context.getScan();
 /*
  * If a limit is provided and we have no filter, run the scan serially 
when we estimate that
- * the limit's worth of data will fit into a single region.
+ * the limit's worth of data is less than the threshold bytes provided 
in QueryServices.QUERY_PARALLEL_LIMIT_THRESHOLD
  */
 Integer perScanLimit = !allowPageFilter ? null : limit;
 if (perScanLimit == null || scan.getFilter() != null) {
@@ -127,32 +126,35 @@ public class ScanPlan extends BaseQueryPlan {
 long scn = context.getConnection().getSCN() == null ? Long.MAX_VALUE : 
context.getConnection().getSCN();
 PTableStats tableStats = 
context.getConnection().getQueryServices().getTableStats(table.getName().getBytes(),
 scn);
 GuidePostsInfo gpsInfo = 
tableStats.getGuidePosts().get(SchemaUtil.getEmptyColumnFamily(table));
-long estRowSize = SchemaUtil.estimateRowSize(table);
-long estRegionSize;
+ConnectionQueryServices services = 
context.getConnection().getQueryServices();
+long estRowSize;
+long estimatedParallelThresholdBytes;
 if (gpsInfo == null) {
-// Use guidepost depth as minimum size
-ConnectionQueryServices services = 
context.getConnection().getQueryServices();
-HTableDescriptor desc = 
services.getTableDescriptor(table.getPhysicalName().getBytes());
-int guidepostPerRegion = 
services.getProps().getInt(QueryServices.STATS_GUIDEPOST_PER_REGION_ATTRIB,
-QueryServicesOptions.DEFAULT_STATS_GUIDEPOST_PER_REGION);
-long guidepostWidth = 
services.getProps().getLong(QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB,
-QueryServicesOptions.DEFAULT_STATS_GUIDEPOST_WIDTH_BYTES);
-estRegionSize = 
StatisticsUtil.getGuidePostDepth(guidepostPerRegion, guidepostWidth, desc);
+estRowSize = SchemaUtil.estimateRowSize(table);
+estimatedParallelThresholdBytes = 
services.getProps().getLong(HConstants.HREGION_MAX_FILESIZE,
+HConstants.DEFAULT_MAX_FILE_SIZE);
 } else {
-// Region size estimated based on total number of bytes divided by 
number of regions
 long totByteSize = 0;
+long totRowCount = 0;
 for (long byteCount : gpsInfo.getByteCounts()) {
 totByteSize += byteCount;
 }
-estRegionSize = totByteSize / (gpsInfo.getGuidePostsCount()+1);
+for

phoenix git commit: PHOENIX-2949 Fix estimated region size when checking for serial query

2016-06-23 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 18a47b051 -> 2f10476a8


PHOENIX-2949 Fix estimated region size when checking for serial query


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/2f10476a
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/2f10476a
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/2f10476a

Branch: refs/heads/4.x-HBase-1.1
Commit: 2f10476a8e75fe1c831729ef1ce18f0dbbddeb2c
Parents: 18a47b0
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu Jun 23 13:54:55 2016 -0700
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu Jun 23 13:54:55 2016 -0700

--
 .../org/apache/phoenix/execute/ScanPlan.java| 46 ++--
 .../org/apache/phoenix/query/QueryServices.java |  2 +-
 2 files changed, 25 insertions(+), 23 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/2f10476a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java 
b/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
index c55a1cc..0975b3f 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
@@ -25,7 +25,7 @@ import java.sql.SQLException;
 import java.util.Collections;
 import java.util.List;
 
-import org.apache.hadoop.hbase.HTableDescriptor;
+import org.apache.hadoop.hbase.HConstants;
 import org.apache.hadoop.hbase.client.Scan;
 import org.apache.phoenix.compile.GroupByCompiler.GroupBy;
 import org.apache.phoenix.compile.OrderByCompiler.OrderBy;
@@ -62,7 +62,6 @@ import org.apache.phoenix.schema.SaltingUtil;
 import org.apache.phoenix.schema.TableRef;
 import org.apache.phoenix.schema.stats.GuidePostsInfo;
 import org.apache.phoenix.schema.stats.PTableStats;
-import org.apache.phoenix.schema.stats.StatisticsUtil;
 import org.apache.phoenix.util.LogUtil;
 import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ScanUtil;
@@ -118,7 +117,7 @@ public class ScanPlan extends BaseQueryPlan {
 Scan scan = context.getScan();
 /*
  * If a limit is provided and we have no filter, run the scan serially 
when we estimate that
- * the limit's worth of data will fit into a single region.
+ * the limit's worth of data is less than the threshold bytes provided 
in QueryServices.QUERY_PARALLEL_LIMIT_THRESHOLD
  */
 Integer perScanLimit = !allowPageFilter ? null : limit;
 if (perScanLimit == null || scan.getFilter() != null) {
@@ -127,32 +126,35 @@ public class ScanPlan extends BaseQueryPlan {
 long scn = context.getConnection().getSCN() == null ? Long.MAX_VALUE : 
context.getConnection().getSCN();
 PTableStats tableStats = 
context.getConnection().getQueryServices().getTableStats(table.getName().getBytes(),
 scn);
 GuidePostsInfo gpsInfo = 
tableStats.getGuidePosts().get(SchemaUtil.getEmptyColumnFamily(table));
-long estRowSize = SchemaUtil.estimateRowSize(table);
-long estRegionSize;
+ConnectionQueryServices services = 
context.getConnection().getQueryServices();
+long estRowSize;
+long estimatedParallelThresholdBytes;
 if (gpsInfo == null) {
-// Use guidepost depth as minimum size
-ConnectionQueryServices services = 
context.getConnection().getQueryServices();
-HTableDescriptor desc = 
services.getTableDescriptor(table.getPhysicalName().getBytes());
-int guidepostPerRegion = 
services.getProps().getInt(QueryServices.STATS_GUIDEPOST_PER_REGION_ATTRIB,
-QueryServicesOptions.DEFAULT_STATS_GUIDEPOST_PER_REGION);
-long guidepostWidth = 
services.getProps().getLong(QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB,
-QueryServicesOptions.DEFAULT_STATS_GUIDEPOST_WIDTH_BYTES);
-estRegionSize = 
StatisticsUtil.getGuidePostDepth(guidepostPerRegion, guidepostWidth, desc);
+estRowSize = SchemaUtil.estimateRowSize(table);
+estimatedParallelThresholdBytes = 
services.getProps().getLong(HConstants.HREGION_MAX_FILESIZE,
+HConstants.DEFAULT_MAX_FILE_SIZE);
 } else {
-// Region size estimated based on total number of bytes divided by 
number of regions
 long totByteSize = 0;
+long totRowCount = 0;
 for (long byteCount : gpsInfo.getByteCounts()) {
 totByteSize += byteCount;
 }
-estRegionSize = totByteSize / (gpsInfo.getGuidePostsCount()+1);
+for

phoenix git commit: PHOENIX-2949 Fix estimated region size when checking for serial query

2016-06-23 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master 8a72032e2 -> a44387358


PHOENIX-2949 Fix estimated region size when checking for serial query


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

Branch: refs/heads/master
Commit: a44387358d6b58b77358a42f38c5baac9e2ab527
Parents: 8a72032
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu Jun 23 13:54:33 2016 -0700
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu Jun 23 13:54:33 2016 -0700

--
 .../org/apache/phoenix/execute/ScanPlan.java| 46 ++--
 .../org/apache/phoenix/query/QueryServices.java |  2 +-
 2 files changed, 25 insertions(+), 23 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/a4438735/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java 
b/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
index c55a1cc..0975b3f 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
@@ -25,7 +25,7 @@ import java.sql.SQLException;
 import java.util.Collections;
 import java.util.List;
 
-import org.apache.hadoop.hbase.HTableDescriptor;
+import org.apache.hadoop.hbase.HConstants;
 import org.apache.hadoop.hbase.client.Scan;
 import org.apache.phoenix.compile.GroupByCompiler.GroupBy;
 import org.apache.phoenix.compile.OrderByCompiler.OrderBy;
@@ -62,7 +62,6 @@ import org.apache.phoenix.schema.SaltingUtil;
 import org.apache.phoenix.schema.TableRef;
 import org.apache.phoenix.schema.stats.GuidePostsInfo;
 import org.apache.phoenix.schema.stats.PTableStats;
-import org.apache.phoenix.schema.stats.StatisticsUtil;
 import org.apache.phoenix.util.LogUtil;
 import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ScanUtil;
@@ -118,7 +117,7 @@ public class ScanPlan extends BaseQueryPlan {
 Scan scan = context.getScan();
 /*
  * If a limit is provided and we have no filter, run the scan serially 
when we estimate that
- * the limit's worth of data will fit into a single region.
+ * the limit's worth of data is less than the threshold bytes provided 
in QueryServices.QUERY_PARALLEL_LIMIT_THRESHOLD
  */
 Integer perScanLimit = !allowPageFilter ? null : limit;
 if (perScanLimit == null || scan.getFilter() != null) {
@@ -127,32 +126,35 @@ public class ScanPlan extends BaseQueryPlan {
 long scn = context.getConnection().getSCN() == null ? Long.MAX_VALUE : 
context.getConnection().getSCN();
 PTableStats tableStats = 
context.getConnection().getQueryServices().getTableStats(table.getName().getBytes(),
 scn);
 GuidePostsInfo gpsInfo = 
tableStats.getGuidePosts().get(SchemaUtil.getEmptyColumnFamily(table));
-long estRowSize = SchemaUtil.estimateRowSize(table);
-long estRegionSize;
+ConnectionQueryServices services = 
context.getConnection().getQueryServices();
+long estRowSize;
+long estimatedParallelThresholdBytes;
 if (gpsInfo == null) {
-// Use guidepost depth as minimum size
-ConnectionQueryServices services = 
context.getConnection().getQueryServices();
-HTableDescriptor desc = 
services.getTableDescriptor(table.getPhysicalName().getBytes());
-int guidepostPerRegion = 
services.getProps().getInt(QueryServices.STATS_GUIDEPOST_PER_REGION_ATTRIB,
-QueryServicesOptions.DEFAULT_STATS_GUIDEPOST_PER_REGION);
-long guidepostWidth = 
services.getProps().getLong(QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB,
-QueryServicesOptions.DEFAULT_STATS_GUIDEPOST_WIDTH_BYTES);
-estRegionSize = 
StatisticsUtil.getGuidePostDepth(guidepostPerRegion, guidepostWidth, desc);
+estRowSize = SchemaUtil.estimateRowSize(table);
+estimatedParallelThresholdBytes = 
services.getProps().getLong(HConstants.HREGION_MAX_FILESIZE,
+HConstants.DEFAULT_MAX_FILE_SIZE);
 } else {
-// Region size estimated based on total number of bytes divided by 
number of regions
 long totByteSize = 0;
+long totRowCount = 0;
 for (long byteCount : gpsInfo.getByteCounts()) {
 totByteSize += byteCount;
 }
-estRegionSize = totByteSize / (gpsInfo.getGuidePostsCount()+1);
+for (long rowCount : gpsIn

phoenix git commit: PHOENIX-2949 Fix estimated region size when checking for serial query

2016-06-23 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 bb8d7cd0d -> 6e75b6aff


PHOENIX-2949 Fix estimated region size when checking for serial query


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/6e75b6af
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/6e75b6af
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/6e75b6af

Branch: refs/heads/4.x-HBase-0.98
Commit: 6e75b6aff59583517208031e2ed3117e705abdc5
Parents: bb8d7cd
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu Jun 23 13:57:52 2016 -0700
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu Jun 23 13:57:52 2016 -0700

--
 .../org/apache/phoenix/execute/ScanPlan.java| 46 ++--
 .../org/apache/phoenix/query/QueryServices.java |  2 +-
 2 files changed, 25 insertions(+), 23 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/6e75b6af/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java 
b/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
index c55a1cc..0975b3f 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/execute/ScanPlan.java
@@ -25,7 +25,7 @@ import java.sql.SQLException;
 import java.util.Collections;
 import java.util.List;
 
-import org.apache.hadoop.hbase.HTableDescriptor;
+import org.apache.hadoop.hbase.HConstants;
 import org.apache.hadoop.hbase.client.Scan;
 import org.apache.phoenix.compile.GroupByCompiler.GroupBy;
 import org.apache.phoenix.compile.OrderByCompiler.OrderBy;
@@ -62,7 +62,6 @@ import org.apache.phoenix.schema.SaltingUtil;
 import org.apache.phoenix.schema.TableRef;
 import org.apache.phoenix.schema.stats.GuidePostsInfo;
 import org.apache.phoenix.schema.stats.PTableStats;
-import org.apache.phoenix.schema.stats.StatisticsUtil;
 import org.apache.phoenix.util.LogUtil;
 import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ScanUtil;
@@ -118,7 +117,7 @@ public class ScanPlan extends BaseQueryPlan {
 Scan scan = context.getScan();
 /*
  * If a limit is provided and we have no filter, run the scan serially 
when we estimate that
- * the limit's worth of data will fit into a single region.
+ * the limit's worth of data is less than the threshold bytes provided 
in QueryServices.QUERY_PARALLEL_LIMIT_THRESHOLD
  */
 Integer perScanLimit = !allowPageFilter ? null : limit;
 if (perScanLimit == null || scan.getFilter() != null) {
@@ -127,32 +126,35 @@ public class ScanPlan extends BaseQueryPlan {
 long scn = context.getConnection().getSCN() == null ? Long.MAX_VALUE : 
context.getConnection().getSCN();
 PTableStats tableStats = 
context.getConnection().getQueryServices().getTableStats(table.getName().getBytes(),
 scn);
 GuidePostsInfo gpsInfo = 
tableStats.getGuidePosts().get(SchemaUtil.getEmptyColumnFamily(table));
-long estRowSize = SchemaUtil.estimateRowSize(table);
-long estRegionSize;
+ConnectionQueryServices services = 
context.getConnection().getQueryServices();
+long estRowSize;
+long estimatedParallelThresholdBytes;
 if (gpsInfo == null) {
-// Use guidepost depth as minimum size
-ConnectionQueryServices services = 
context.getConnection().getQueryServices();
-HTableDescriptor desc = 
services.getTableDescriptor(table.getPhysicalName().getBytes());
-int guidepostPerRegion = 
services.getProps().getInt(QueryServices.STATS_GUIDEPOST_PER_REGION_ATTRIB,
-QueryServicesOptions.DEFAULT_STATS_GUIDEPOST_PER_REGION);
-long guidepostWidth = 
services.getProps().getLong(QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB,
-QueryServicesOptions.DEFAULT_STATS_GUIDEPOST_WIDTH_BYTES);
-estRegionSize = 
StatisticsUtil.getGuidePostDepth(guidepostPerRegion, guidepostWidth, desc);
+estRowSize = SchemaUtil.estimateRowSize(table);
+estimatedParallelThresholdBytes = 
services.getProps().getLong(HConstants.HREGION_MAX_FILESIZE,
+HConstants.DEFAULT_MAX_FILE_SIZE);
 } else {
-// Region size estimated based on total number of bytes divided by 
number of regions
 long totByteSize = 0;
+long totRowCount = 0;
 for (long byteCount : gpsInfo.getByteCounts()) {
 totByteSize += byteCount;
 }
-estRegionSize = totByteSize / (gpsInfo.getGuidePostsCount()+1);
+for

phoenix git commit: PHOENIX-2169 Illegal data error on UPSERT SELECT and JOIN with salted tables(Ankit Singhal)

2016-02-04 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 35944997a -> 0e8f4b23c


PHOENIX-2169 Illegal data error on UPSERT SELECT and JOIN with salted 
tables(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/0e8f4b23
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/0e8f4b23
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/0e8f4b23

Branch: refs/heads/4.x-HBase-1.0
Commit: 0e8f4b23cfe44488e14f77b37b9426dd5707f6c9
Parents: 3594499
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu Feb 4 15:29:44 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu Feb 4 15:29:44 2016 +0530

--
 .../salted/SaltedTableUpsertSelectIT.java   | 57 
 .../expression/ProjectedColumnExpression.java   | 11 +++-
 .../visitor/CloneExpressionVisitor.java |  2 +-
 3 files changed, 68 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/0e8f4b23/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
index 0a11ec7..65eeb20 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
@@ -225,4 +225,61 @@ public class SaltedTableUpsertSelectIT extends 
BaseHBaseManagedTimeIT {
 conn.close();
 }
 }
+
+@Test
+public void testUpsertSelectWithJoinOnSaltedTables() throws Exception {
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+Connection conn = DriverManager.getConnection(getUrl(), props);
+conn.setAutoCommit(false);
+try {
+String ddl = "CREATE TABLE IF NOT EXISTS source1" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl);
+
+for (int i = 0; i < 1000; i++) {
+String upsert = "UPSERT INTO source1(pk1, pk2, pk3, col1) 
VALUES (?,?,?,?)";
+PreparedStatement stmt = conn.prepareStatement(upsert);
+stmt.setString(1, Integer.toString(i));
+stmt.setString(2, Integer.toString(i));
+stmt.setInt(3, i);
+stmt.setInt(4, i);
+stmt.execute();
+}
+conn.commit();
+
+String ddl2 = "CREATE TABLE IF NOT EXISTS source2" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl2);
+
+for (int i = 0; i < 1000; i++) {
+String upsert = "UPSERT INTO source2(pk1, pk2, pk3, col1) 
VALUES (?,?,?,?)";
+PreparedStatement stmt = conn.prepareStatement(upsert);
+stmt.setString(1, Integer.toString(i));
+stmt.setString(2, Integer.toString(i));
+stmt.setInt(3, i);
+stmt.setInt(4, i);
+stmt.execute();
+}
+conn.commit();
+
+String ddl3 = "CREATE TABLE IF NOT EXISTS dest" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl3);
+
+String query = "UPSERT INTO dest(pk1, pk2, pk3, col1) SELECT 
S1.pk1, S1.pk2, S2.pk3, S2.col1 FROM source1 AS S1 JOIN source2 AS S2 ON S1.pk1 
= S2.pk1 AND S1.pk2 = S2.pk2 AND S1.pk3 = S2.pk3";
+conn.createStatement().execute(query);
+conn.commit();
+
+query = "SELECT COUNT(*) FROM dest";
+PreparedStatement stmt = conn.prepareStatement(query);
+ResultSet rs = stmt.executeQuery();
+assertTrue(rs.next());
+assertEquals(1000, rs.getInt(1));
+} finally {
+conn.close();
+}
+}
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/0e8f4b23/phoenix-core/src/main/java/org/apache/phoenix/expression/ProjectedColumnExpression.java

phoenix git commit: PHOENIX-2169 Illegal data error on UPSERT SELECT and JOIN with salted tables(Ankit Singhal)

2016-02-04 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master 12f6a6f48 -> 79724226c


PHOENIX-2169 Illegal data error on UPSERT SELECT and JOIN with salted 
tables(Ankit Singhal)


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

Branch: refs/heads/master
Commit: 79724226c737c905b748d73fe8f4d70dca743578
Parents: 12f6a6f
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu Feb 4 15:27:04 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu Feb 4 15:27:04 2016 +0530

--
 .../salted/SaltedTableUpsertSelectIT.java   | 57 
 .../expression/ProjectedColumnExpression.java   | 11 +++-
 .../visitor/CloneExpressionVisitor.java |  2 +-
 3 files changed, 68 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/79724226/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
index 0a11ec7..65eeb20 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
@@ -225,4 +225,61 @@ public class SaltedTableUpsertSelectIT extends 
BaseHBaseManagedTimeIT {
 conn.close();
 }
 }
+
+@Test
+public void testUpsertSelectWithJoinOnSaltedTables() throws Exception {
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+Connection conn = DriverManager.getConnection(getUrl(), props);
+conn.setAutoCommit(false);
+try {
+String ddl = "CREATE TABLE IF NOT EXISTS source1" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl);
+
+for (int i = 0; i < 1000; i++) {
+String upsert = "UPSERT INTO source1(pk1, pk2, pk3, col1) 
VALUES (?,?,?,?)";
+PreparedStatement stmt = conn.prepareStatement(upsert);
+stmt.setString(1, Integer.toString(i));
+stmt.setString(2, Integer.toString(i));
+stmt.setInt(3, i);
+stmt.setInt(4, i);
+stmt.execute();
+}
+conn.commit();
+
+String ddl2 = "CREATE TABLE IF NOT EXISTS source2" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl2);
+
+for (int i = 0; i < 1000; i++) {
+String upsert = "UPSERT INTO source2(pk1, pk2, pk3, col1) 
VALUES (?,?,?,?)";
+PreparedStatement stmt = conn.prepareStatement(upsert);
+stmt.setString(1, Integer.toString(i));
+stmt.setString(2, Integer.toString(i));
+stmt.setInt(3, i);
+stmt.setInt(4, i);
+stmt.execute();
+}
+conn.commit();
+
+String ddl3 = "CREATE TABLE IF NOT EXISTS dest" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl3);
+
+String query = "UPSERT INTO dest(pk1, pk2, pk3, col1) SELECT 
S1.pk1, S1.pk2, S2.pk3, S2.col1 FROM source1 AS S1 JOIN source2 AS S2 ON S1.pk1 
= S2.pk1 AND S1.pk2 = S2.pk2 AND S1.pk3 = S2.pk3";
+conn.createStatement().execute(query);
+conn.commit();
+
+query = "SELECT COUNT(*) FROM dest";
+PreparedStatement stmt = conn.prepareStatement(query);
+ResultSet rs = stmt.executeQuery();
+assertTrue(rs.next());
+assertEquals(1000, rs.getInt(1));
+} finally {
+conn.close();
+}
+}
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/79724226/phoenix-core/src/main/java/org/apache/phoenix/expression/ProjectedColumnExpression.java
--

phoenix git commit: PHOENIX-2169 Illegal data error on UPSERT SELECT and JOIN with salted tables(Ankit Singhal)

2016-02-04 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 d0174744c -> 20a995e55


PHOENIX-2169 Illegal data error on UPSERT SELECT and JOIN with salted 
tables(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/20a995e5
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/20a995e5
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/20a995e5

Branch: refs/heads/4.x-HBase-0.98
Commit: 20a995e554cafc99ab1a35fa8b8f957dc1f2c54f
Parents: d017474
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu Feb 4 15:30:23 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu Feb 4 15:30:23 2016 +0530

--
 .../salted/SaltedTableUpsertSelectIT.java   | 57 
 .../expression/ProjectedColumnExpression.java   | 11 +++-
 .../visitor/CloneExpressionVisitor.java |  2 +-
 3 files changed, 68 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/20a995e5/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
index 0a11ec7..65eeb20 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/salted/SaltedTableUpsertSelectIT.java
@@ -225,4 +225,61 @@ public class SaltedTableUpsertSelectIT extends 
BaseHBaseManagedTimeIT {
 conn.close();
 }
 }
+
+@Test
+public void testUpsertSelectWithJoinOnSaltedTables() throws Exception {
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+Connection conn = DriverManager.getConnection(getUrl(), props);
+conn.setAutoCommit(false);
+try {
+String ddl = "CREATE TABLE IF NOT EXISTS source1" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl);
+
+for (int i = 0; i < 1000; i++) {
+String upsert = "UPSERT INTO source1(pk1, pk2, pk3, col1) 
VALUES (?,?,?,?)";
+PreparedStatement stmt = conn.prepareStatement(upsert);
+stmt.setString(1, Integer.toString(i));
+stmt.setString(2, Integer.toString(i));
+stmt.setInt(3, i);
+stmt.setInt(4, i);
+stmt.execute();
+}
+conn.commit();
+
+String ddl2 = "CREATE TABLE IF NOT EXISTS source2" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl2);
+
+for (int i = 0; i < 1000; i++) {
+String upsert = "UPSERT INTO source2(pk1, pk2, pk3, col1) 
VALUES (?,?,?,?)";
+PreparedStatement stmt = conn.prepareStatement(upsert);
+stmt.setString(1, Integer.toString(i));
+stmt.setString(2, Integer.toString(i));
+stmt.setInt(3, i);
+stmt.setInt(4, i);
+stmt.execute();
+}
+conn.commit();
+
+String ddl3 = "CREATE TABLE IF NOT EXISTS dest" +
+" (pk1 varchar NULL, pk2 varchar NULL, pk3 integer NOT 
NULL, col1 INTEGER" +
+" CONSTRAINT pk PRIMARY KEY (pk1, pk2, pk3)) 
SALT_BUCKETS=4";
+createTestTable(getUrl(), ddl3);
+
+String query = "UPSERT INTO dest(pk1, pk2, pk3, col1) SELECT 
S1.pk1, S1.pk2, S2.pk3, S2.col1 FROM source1 AS S1 JOIN source2 AS S2 ON S1.pk1 
= S2.pk1 AND S1.pk2 = S2.pk2 AND S1.pk3 = S2.pk3";
+conn.createStatement().execute(query);
+conn.commit();
+
+query = "SELECT COUNT(*) FROM dest";
+PreparedStatement stmt = conn.prepareStatement(query);
+ResultSet rs = stmt.executeQuery();
+assertTrue(rs.next());
+assertEquals(1000, rs.getInt(1));
+} finally {
+conn.close();
+}
+}
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/20a995e5/phoenix-core/src/main/java/org/apache/phoenix/expression/ProjectedColumnExpression.java

phoenix git commit: PHOENIX-2647 Duplicate results in reverse scan when guideposts are traversed (Ankit Singhal)

2016-02-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 650ae264d -> 7bbca60c4


PHOENIX-2647 Duplicate results in reverse scan when guideposts are traversed 
(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/7bbca60c
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/7bbca60c
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/7bbca60c

Branch: refs/heads/4.x-HBase-0.98
Commit: 7bbca60c4a1add594d37e50107a1a7613bdd59bf
Parents: 650ae26
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Feb 5 23:41:36 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Feb 5 23:41:36 2016 +0530

--
 .../apache/phoenix/end2end/ReverseScanIT.java   | 21 +
 .../phoenix/end2end/StatsCollectorIT.java   | 28 +++
 .../java/org/apache/phoenix/util/ScanUtil.java  | 49 ++--
 3 files changed, 64 insertions(+), 34 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/7bbca60c/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
index 35a8025..2722be1 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
@@ -168,6 +168,27 @@ public class ReverseScanIT extends BaseHBaseManagedTimeIT {
 }
 
 @Test
+public void testReverseScanForSpecificRangeInRegion() throws Exception {
+Connection conn;
+ResultSet rs;
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+conn = DriverManager.getConnection(getUrl(), props);
+conn.createStatement()
+.execute("CREATE TABLE T" + " ( k VARCHAR, c1.a bigint,c2.b 
bigint CONSTRAINT pk PRIMARY KEY (k)) ");
+conn.createStatement().execute("upsert into T values ('a',1,3)");
+conn.createStatement().execute("upsert into T values ('b',1,3)");
+conn.createStatement().execute("upsert into T values ('c',1,3)");
+conn.createStatement().execute("upsert into T values ('d',1,3)");
+conn.createStatement().execute("upsert into T values ('e',1,3)");
+conn.commit();
+rs = conn.createStatement().executeQuery("SELECT k FROM T where k>'b' 
and k<'d' order by k desc");
+assertTrue(rs.next());
+assertEquals("c", rs.getString(1));
+assertTrue(!rs.next());
+conn.close();
+}
+
+@Test
 public void testReverseScanIndex() throws Exception {
 String tenantId = getOrganizationId();
 initATableValues(tenantId, getSplitsAtRowKeys(tenantId), getUrl());

http://git-wip-us.apache.org/repos/asf/phoenix/blob/7bbca60c/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
index caba259..4450152 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
@@ -123,31 +123,41 @@ public class StatsCollectorIT extends 
StatsCollectorAbstractIT {
 conn.close();
 }
 
-@Test
-public void testNoDuplicatesAfterUpdateStats() throws Throwable {
+private void testNoDuplicatesAfterUpdateStats(String splitKey) throws 
Throwable {
 Connection conn;
 PreparedStatement stmt;
 ResultSet rs;
 Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
 conn = DriverManager.getConnection(getUrl(), props);
 conn.createStatement()
-.execute("CREATE TABLE " + fullTableName +" ( k VARCHAR, c1.a 
bigint,c2.b bigint CONSTRAINT pk PRIMARY KEY (k))" + tableDDLOptions );
-conn.createStatement().execute("upsert into " + fullTableName +" 
values ('abc',1,3)");
-conn.createStatement().execute("upsert into " + fullTableName +" 
values ('def',2,4)");
+.execute("CREATE TABLE " + fullTableName
++ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k)) "
++ (splitKey != null ? "split on (" + splitKey + ")" : 
""));
+conn.createStatement().execute("up

phoenix git commit: PHOENIX-2647 Duplicate results in reverse scan when guideposts are traversed (Ankit Singhal)

2016-02-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master a82a0ff60 -> b64edb754


PHOENIX-2647 Duplicate results in reverse scan when guideposts are traversed 
(Ankit Singhal)


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

Branch: refs/heads/master
Commit: b64edb75455d56fc2a5086043bdd6fa1064f2ca7
Parents: a82a0ff
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Feb 5 23:45:04 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Feb 5 23:45:04 2016 +0530

--
 .../apache/phoenix/end2end/ReverseScanIT.java   | 21 +
 .../phoenix/end2end/StatsCollectorIT.java   | 28 +++
 .../java/org/apache/phoenix/util/ScanUtil.java  | 49 ++--
 3 files changed, 64 insertions(+), 34 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/b64edb75/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
index 35a8025..2722be1 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
@@ -168,6 +168,27 @@ public class ReverseScanIT extends BaseHBaseManagedTimeIT {
 }
 
 @Test
+public void testReverseScanForSpecificRangeInRegion() throws Exception {
+Connection conn;
+ResultSet rs;
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+conn = DriverManager.getConnection(getUrl(), props);
+conn.createStatement()
+.execute("CREATE TABLE T" + " ( k VARCHAR, c1.a bigint,c2.b 
bigint CONSTRAINT pk PRIMARY KEY (k)) ");
+conn.createStatement().execute("upsert into T values ('a',1,3)");
+conn.createStatement().execute("upsert into T values ('b',1,3)");
+conn.createStatement().execute("upsert into T values ('c',1,3)");
+conn.createStatement().execute("upsert into T values ('d',1,3)");
+conn.createStatement().execute("upsert into T values ('e',1,3)");
+conn.commit();
+rs = conn.createStatement().executeQuery("SELECT k FROM T where k>'b' 
and k<'d' order by k desc");
+assertTrue(rs.next());
+assertEquals("c", rs.getString(1));
+assertTrue(!rs.next());
+conn.close();
+}
+
+@Test
 public void testReverseScanIndex() throws Exception {
 String tenantId = getOrganizationId();
 initATableValues(tenantId, getSplitsAtRowKeys(tenantId), getUrl());

http://git-wip-us.apache.org/repos/asf/phoenix/blob/b64edb75/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
index caba259..4450152 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
@@ -123,31 +123,41 @@ public class StatsCollectorIT extends 
StatsCollectorAbstractIT {
 conn.close();
 }
 
-@Test
-public void testNoDuplicatesAfterUpdateStats() throws Throwable {
+private void testNoDuplicatesAfterUpdateStats(String splitKey) throws 
Throwable {
 Connection conn;
 PreparedStatement stmt;
 ResultSet rs;
 Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
 conn = DriverManager.getConnection(getUrl(), props);
 conn.createStatement()
-.execute("CREATE TABLE " + fullTableName +" ( k VARCHAR, c1.a 
bigint,c2.b bigint CONSTRAINT pk PRIMARY KEY (k))" + tableDDLOptions );
-conn.createStatement().execute("upsert into " + fullTableName +" 
values ('abc',1,3)");
-conn.createStatement().execute("upsert into " + fullTableName +" 
values ('def',2,4)");
+.execute("CREATE TABLE " + fullTableName
++ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k)) "
++ (splitKey != null ? "split on (" + splitKey + ")" : 
""));
+conn.createStatement().execute("upsert into &quo

phoenix git commit: PHOENIX-2647 Duplicate results in reverse scan when guideposts are traversed (Ankit Singhal)

2016-02-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 a2fe62e24 -> 5cd5fe45c


PHOENIX-2647 Duplicate results in reverse scan when guideposts are traversed 
(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/5cd5fe45
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/5cd5fe45
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/5cd5fe45

Branch: refs/heads/4.x-HBase-1.0
Commit: 5cd5fe45c425fc84d1ff2568e101ff026e3c24c4
Parents: a2fe62e
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Feb 5 23:42:22 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Feb 5 23:42:22 2016 +0530

--
 .../apache/phoenix/end2end/ReverseScanIT.java   | 21 +
 .../phoenix/end2end/StatsCollectorIT.java   | 28 +++
 .../java/org/apache/phoenix/util/ScanUtil.java  | 49 ++--
 3 files changed, 64 insertions(+), 34 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/5cd5fe45/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
index 35a8025..2722be1 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/ReverseScanIT.java
@@ -168,6 +168,27 @@ public class ReverseScanIT extends BaseHBaseManagedTimeIT {
 }
 
 @Test
+public void testReverseScanForSpecificRangeInRegion() throws Exception {
+Connection conn;
+ResultSet rs;
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+conn = DriverManager.getConnection(getUrl(), props);
+conn.createStatement()
+.execute("CREATE TABLE T" + " ( k VARCHAR, c1.a bigint,c2.b 
bigint CONSTRAINT pk PRIMARY KEY (k)) ");
+conn.createStatement().execute("upsert into T values ('a',1,3)");
+conn.createStatement().execute("upsert into T values ('b',1,3)");
+conn.createStatement().execute("upsert into T values ('c',1,3)");
+conn.createStatement().execute("upsert into T values ('d',1,3)");
+conn.createStatement().execute("upsert into T values ('e',1,3)");
+conn.commit();
+rs = conn.createStatement().executeQuery("SELECT k FROM T where k>'b' 
and k<'d' order by k desc");
+assertTrue(rs.next());
+assertEquals("c", rs.getString(1));
+assertTrue(!rs.next());
+conn.close();
+}
+
+@Test
 public void testReverseScanIndex() throws Exception {
 String tenantId = getOrganizationId();
 initATableValues(tenantId, getSplitsAtRowKeys(tenantId), getUrl());

http://git-wip-us.apache.org/repos/asf/phoenix/blob/5cd5fe45/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
index 35889cd..b1d21c7 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
@@ -124,31 +124,41 @@ public class StatsCollectorIT extends 
StatsCollectorAbstractIT {
 conn.close();
 }
 
-@Test
-public void testNoDuplicatesAfterUpdateStats() throws Throwable {
+private void testNoDuplicatesAfterUpdateStats(String splitKey) throws 
Throwable {
 Connection conn;
 PreparedStatement stmt;
 ResultSet rs;
 Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
 conn = DriverManager.getConnection(getUrl(), props);
 conn.createStatement()
-.execute("CREATE TABLE " + fullTableName +" ( k VARCHAR, c1.a 
bigint,c2.b bigint CONSTRAINT pk PRIMARY KEY (k))" + tableDDLOptions );
-conn.createStatement().execute("upsert into " + fullTableName +" 
values ('abc',1,3)");
-conn.createStatement().execute("upsert into " + fullTableName +" 
values ('def',2,4)");
+.execute("CREATE TABLE " + fullTableName
++ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k)) "
++ (splitKey != null ? "split on (" + splitKey + ")" : 
""));
+conn.createStatement().execute("up

phoenix git commit: PHOENIX-2647 Fix errors in 2 tests related to DDL issues for transaction (addendum)

2016-02-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 7bbca60c4 -> 9d52105e5


PHOENIX-2647 Fix errors in 2 tests related to DDL issues for transaction 
(addendum)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/9d52105e
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/9d52105e
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/9d52105e

Branch: refs/heads/4.x-HBase-0.98
Commit: 9d52105e54198a271491f0337b79ec1d64ad8bd2
Parents: 7bbca60
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Sat Feb 6 01:12:50 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Sat Feb 6 01:12:50 2016 +0530

--
 .../src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/9d52105e/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
index 4450152..e72f41f 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
@@ -131,8 +131,8 @@ public class StatsCollectorIT extends 
StatsCollectorAbstractIT {
 conn = DriverManager.getConnection(getUrl(), props);
 conn.createStatement()
 .execute("CREATE TABLE " + fullTableName
-+ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k)) "
-+ (splitKey != null ? "split on (" + splitKey + ")" : 
""));
++ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k))"+ tableDDLOptions
++ (splitKey != null ? " split on (" + splitKey + ")" : 
"") );
 conn.createStatement().execute("upsert into " + fullTableName + " 
values ('abc',1,3)");
 conn.createStatement().execute("upsert into " + fullTableName + " 
values ('def',2,4)");
 conn.commit();



phoenix git commit: PHOENIX-2647 Fix errors in 2 tests related to DDL issues for transaction (addendum)

2016-02-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 5cd5fe45c -> bd2cf10c5


PHOENIX-2647 Fix errors in 2 tests related to DDL issues for transaction 
(addendum)


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

Branch: refs/heads/4.x-HBase-1.0
Commit: bd2cf10c5c7ef9fbd7b202dd094928f63b69e901
Parents: 5cd5fe4
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Sat Feb 6 01:12:00 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Sat Feb 6 01:12:00 2016 +0530

--
 .../src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/bd2cf10c/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
index b1d21c7..ff2bcda 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
@@ -132,8 +132,8 @@ public class StatsCollectorIT extends 
StatsCollectorAbstractIT {
 conn = DriverManager.getConnection(getUrl(), props);
 conn.createStatement()
 .execute("CREATE TABLE " + fullTableName
-+ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k)) "
-+ (splitKey != null ? "split on (" + splitKey + ")" : 
""));
++ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k))"+ tableDDLOptions
++ (splitKey != null ? " split on (" + splitKey + ")" : 
"") );
 conn.createStatement().execute("upsert into " + fullTableName + " 
values ('abc',1,3)");
 conn.createStatement().execute("upsert into " + fullTableName + " 
values ('def',2,4)");
 conn.commit();



phoenix git commit: PHOENIX-2647 Fix errors in 2 tests related to DDL issues for transaction (addendum)

2016-02-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master b64edb754 -> fa58fc5fc


PHOENIX-2647 Fix errors in 2 tests related to DDL issues for transaction 
(addendum)


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

Branch: refs/heads/master
Commit: fa58fc5fccd11cbeb14e701a59122b3cba77d67e
Parents: b64edb7
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Sat Feb 6 01:11:22 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Sat Feb 6 01:11:22 2016 +0530

--
 .../src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/fa58fc5f/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
index 4450152..e72f41f 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorIT.java
@@ -131,8 +131,8 @@ public class StatsCollectorIT extends 
StatsCollectorAbstractIT {
 conn = DriverManager.getConnection(getUrl(), props);
 conn.createStatement()
 .execute("CREATE TABLE " + fullTableName
-+ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k)) "
-+ (splitKey != null ? "split on (" + splitKey + ")" : 
""));
++ " ( k VARCHAR, c1.a bigint,c2.b bigint CONSTRAINT pk 
PRIMARY KEY (k))"+ tableDDLOptions
++ (splitKey != null ? " split on (" + splitKey + ")" : 
"") );
 conn.createStatement().execute("upsert into " + fullTableName + " 
values ('abc',1,3)");
 conn.createStatement().execute("upsert into " + fullTableName + " 
values ('def',2,4)");
 conn.commit();



phoenix git commit: PHOENIX-2671 System.STATS table getting truncated every time on new client connection(Ankit Singhal)

2016-02-14 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 ee8a2e423 -> a8b3a03ef


PHOENIX-2671 System.STATS table getting truncated every time on new client 
connection(Ankit Singhal)


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

Branch: refs/heads/4.x-HBase-0.98
Commit: a8b3a03ef8c4c0a1df459a8950686ae3f1d24789
Parents: ee8a2e4
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon Feb 15 12:02:07 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon Feb 15 12:02:07 2016 +0530

--
 .../query/ConnectionQueryServicesImpl.java  | 48 ++--
 .../org/apache/phoenix/util/UpgradeUtil.java| 16 +++
 2 files changed, 22 insertions(+), 42 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/a8b3a03e/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
index 998b7f8..a9af8ea 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
@@ -189,11 +189,6 @@ import org.apache.twill.zookeeper.ZKClients;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import co.cask.tephra.TransactionSystemClient;
-import co.cask.tephra.TxConstants;
-import co.cask.tephra.distributed.PooledClientProvider;
-import co.cask.tephra.distributed.TransactionServiceClient;
-
 import com.google.common.annotations.VisibleForTesting;
 import com.google.common.base.Joiner;
 import com.google.common.base.Throwables;
@@ -673,6 +668,11 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 });
 }
 
+import co.cask.tephra.TransactionSystemClient;
+import co.cask.tephra.TxConstants;
+import co.cask.tephra.distributed.PooledClientProvider;
+import co.cask.tephra.distributed.TransactionServiceClient;
+
 
 @Override
 public PhoenixConnection connect(String url, Properties info) throws 
SQLException {
@@ -2364,14 +2364,16 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 // parts we haven't yet done).
 metaConnection = 
addColumnsIfNotExists(metaConnection, PhoenixDatabaseMetaData.SYSTEM_CATALOG, 
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 2,
 
PhoenixDatabaseMetaData.TRANSACTIONAL + " " + 
PBoolean.INSTANCE.getSqlTypeName());
-metaConnection = 
addColumnsIfNotExists(metaConnection, PhoenixDatabaseMetaData.SYSTEM_CATALOG, 
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 1, 
-
PhoenixDatabaseMetaData.UPDATE_CACHE_FREQUENCY + " " + 
PLong.INSTANCE.getSqlTypeName());
+// Drop old stats table so that new stats 
table is created
+metaConnection = 
dropStatsTable(metaConnection,
+
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 1);
+metaConnection = 
addColumnsIfNotExists(metaConnection,
+
PhoenixDatabaseMetaData.SYSTEM_CATALOG,
+
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0,
+
PhoenixDatabaseMetaData.UPDATE_CACHE_FREQUENCY + " "
++ 
PLong.INSTANCE.getSqlTypeName());
 
setImmutableTableIndexesImmutable(metaConnection);
-   // Drop 
old stats table so that new stats table is created
-   
metaConnection = dropStatsTable(metaConnection,
-   
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0);
-   // 
Clear the server cache so the above changes make it over to any clients
-   // that 
already have cached data.
+   

phoenix git commit: PHOENIX-2671 System.STATS table getting truncated every time on new client connection(Ankit Singhal)

2016-02-14 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 6a6b64b23 -> 19012c026


PHOENIX-2671 System.STATS table getting truncated every time on new client 
connection(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/19012c02
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/19012c02
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/19012c02

Branch: refs/heads/4.x-HBase-1.0
Commit: 19012c0265d37cd0ae7655648810b275659b8d6e
Parents: 6a6b64b
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon Feb 15 12:03:21 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon Feb 15 12:03:21 2016 +0530

--
 .../query/ConnectionQueryServicesImpl.java  | 48 ++--
 .../org/apache/phoenix/util/UpgradeUtil.java| 16 +++
 2 files changed, 22 insertions(+), 42 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/19012c02/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
index a8d0b39..26d7a3d 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
@@ -188,11 +188,6 @@ import org.apache.twill.zookeeper.ZKClients;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import co.cask.tephra.TransactionSystemClient;
-import co.cask.tephra.TxConstants;
-import co.cask.tephra.distributed.PooledClientProvider;
-import co.cask.tephra.distributed.TransactionServiceClient;
-
 import com.google.common.annotations.VisibleForTesting;
 import com.google.common.base.Joiner;
 import com.google.common.base.Throwables;
@@ -254,6 +249,11 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 private ScheduledExecutorService renewLeaseExecutor;
 private final boolean renewLeaseEnabled;
 
+import co.cask.tephra.TransactionSystemClient;
+import co.cask.tephra.TxConstants;
+import co.cask.tephra.distributed.PooledClientProvider;
+import co.cask.tephra.distributed.TransactionServiceClient;
+
 
 private static interface FeatureSupported {
 boolean isSupported(ConnectionQueryServices services);
@@ -2364,14 +2364,16 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 // parts we haven't yet done).
 metaConnection = 
addColumnsIfNotExists(metaConnection, PhoenixDatabaseMetaData.SYSTEM_CATALOG, 
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 2,
 
PhoenixDatabaseMetaData.TRANSACTIONAL + " " + 
PBoolean.INSTANCE.getSqlTypeName());
-metaConnection = 
addColumnsIfNotExists(metaConnection, PhoenixDatabaseMetaData.SYSTEM_CATALOG, 
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 1, 
-
PhoenixDatabaseMetaData.UPDATE_CACHE_FREQUENCY + " " + 
PLong.INSTANCE.getSqlTypeName());
+// Drop old stats table so that new stats 
table is created
+metaConnection = 
dropStatsTable(metaConnection,
+
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 1);
+metaConnection = 
addColumnsIfNotExists(metaConnection,
+
PhoenixDatabaseMetaData.SYSTEM_CATALOG,
+
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0,
+
PhoenixDatabaseMetaData.UPDATE_CACHE_FREQUENCY + " "
++ 
PLong.INSTANCE.getSqlTypeName());
 
setImmutableTableIndexesImmutable(metaConnection);
-   // Drop 
old stats table so that new stats table is created
-   
metaConnection = dropStatsTable(metaConnection,
-   
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0);
-   // 
Clear the server cache so the above changes make it over to any clients
-  

phoenix git commit: PHOENIX-2671 System.STATS table getting truncated every time on new client connection(Ankit Singhal)

2016-02-14 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master cdaca287c -> 6881aef0c


PHOENIX-2671 System.STATS table getting truncated every time on new client 
connection(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/6881aef0
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/6881aef0
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/6881aef0

Branch: refs/heads/master
Commit: 6881aef0cfaae8643303f0612a2a4b997b8a5138
Parents: cdaca28
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon Feb 15 12:04:20 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon Feb 15 12:04:20 2016 +0530

--
 .../query/ConnectionQueryServicesImpl.java  | 48 ++--
 .../org/apache/phoenix/util/UpgradeUtil.java| 16 +++
 2 files changed, 22 insertions(+), 42 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/6881aef0/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
index 897c207..9a385b2 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
@@ -188,11 +188,6 @@ import org.apache.twill.zookeeper.ZKClients;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import co.cask.tephra.TransactionSystemClient;
-import co.cask.tephra.TxConstants;
-import co.cask.tephra.distributed.PooledClientProvider;
-import co.cask.tephra.distributed.TransactionServiceClient;
-
 import com.google.common.annotations.VisibleForTesting;
 import com.google.common.base.Joiner;
 import com.google.common.base.Throwables;
@@ -205,6 +200,11 @@ import com.google.common.collect.Maps;
 import com.google.common.collect.Sets;
 import com.google.common.util.concurrent.ThreadFactoryBuilder;
 
+import co.cask.tephra.TransactionSystemClient;
+import co.cask.tephra.TxConstants;
+import co.cask.tephra.distributed.PooledClientProvider;
+import co.cask.tephra.distributed.TransactionServiceClient;
+
 
 public class ConnectionQueryServicesImpl extends DelegateQueryServices 
implements ConnectionQueryServices {
 private static final Logger logger = 
LoggerFactory.getLogger(ConnectionQueryServicesImpl.class);
@@ -2370,14 +2370,16 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 // parts we haven't yet done).
 metaConnection = 
addColumnsIfNotExists(metaConnection, PhoenixDatabaseMetaData.SYSTEM_CATALOG, 
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 2,
 
PhoenixDatabaseMetaData.TRANSACTIONAL + " " + 
PBoolean.INSTANCE.getSqlTypeName());
-metaConnection = 
addColumnsIfNotExists(metaConnection, PhoenixDatabaseMetaData.SYSTEM_CATALOG, 
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 1, 
-
PhoenixDatabaseMetaData.UPDATE_CACHE_FREQUENCY + " " + 
PLong.INSTANCE.getSqlTypeName());
+// Drop old stats table so that new stats 
table is created
+metaConnection = 
dropStatsTable(metaConnection,
+
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0 - 1);
+metaConnection = 
addColumnsIfNotExists(metaConnection,
+
PhoenixDatabaseMetaData.SYSTEM_CATALOG,
+
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0,
+
PhoenixDatabaseMetaData.UPDATE_CACHE_FREQUENCY + " "
++ 
PLong.INSTANCE.getSqlTypeName());
 
setImmutableTableIndexesImmutable(metaConnection);
-   // Drop 
old stats table so that new stats table is created
-   
metaConnection = dropStatsTable(metaConnection,
-   
MetaDataProtocol.MIN_SYSTEM_TABLE_TIMESTAMP_4_7_0);
-   // 
Clear the server cache so 

phoenix git commit: PHOENIX-2671 System.STATS table getting truncated every time on new client connection(addendum)

2016-02-15 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 a8b3a03ef -> 07dd49674


PHOENIX-2671 System.STATS table getting truncated every time on new client 
connection(addendum)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/07dd4967
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/07dd4967
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/07dd4967

Branch: refs/heads/4.x-HBase-0.98
Commit: 07dd49674630353dfb0e6310187a341806191250
Parents: a8b3a03
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon Feb 15 22:48:53 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon Feb 15 22:48:53 2016 +0530

--
 .../apache/phoenix/query/ConnectionQueryServicesImpl.java | 10 ++
 1 file changed, 6 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/07dd4967/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
index a9af8ea..f7a72a0 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
@@ -201,6 +201,12 @@ import com.google.common.collect.Maps;
 import com.google.common.collect.Sets;
 import com.google.common.util.concurrent.ThreadFactoryBuilder;
 
+import co.cask.tephra.TransactionSystemClient;
+import co.cask.tephra.TxConstants;
+import co.cask.tephra.distributed.PooledClientProvider;
+import co.cask.tephra.distributed.TransactionServiceClient;
+
+
 public class ConnectionQueryServicesImpl extends DelegateQueryServices 
implements ConnectionQueryServices {
 private static final Logger logger = 
LoggerFactory.getLogger(ConnectionQueryServicesImpl.class);
 private static final int INITIAL_CHILD_SERVICES_CAPACITY = 100;
@@ -668,10 +674,6 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 });
 }
 
-import co.cask.tephra.TransactionSystemClient;
-import co.cask.tephra.TxConstants;
-import co.cask.tephra.distributed.PooledClientProvider;
-import co.cask.tephra.distributed.TransactionServiceClient;
 
 
 @Override



phoenix git commit: PHOENIX-2671 System.STATS table getting truncated every time on new client connection(addendum)

2016-02-15 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 19012c026 -> 6a3d6090f


PHOENIX-2671 System.STATS table getting truncated every time on new client 
connection(addendum)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/6a3d6090
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/6a3d6090
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/6a3d6090

Branch: refs/heads/4.x-HBase-1.0
Commit: 6a3d6090f2aaa7ce272bbb25b403f6530df58605
Parents: 19012c0
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon Feb 15 22:52:17 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon Feb 15 22:52:17 2016 +0530

--
 .../apache/phoenix/query/ConnectionQueryServicesImpl.java | 10 ++
 1 file changed, 6 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/6a3d6090/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
index 26d7a3d..a8c9324 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java
@@ -200,6 +200,12 @@ import com.google.common.collect.Maps;
 import com.google.common.collect.Sets;
 import com.google.common.util.concurrent.ThreadFactoryBuilder;
 
+import co.cask.tephra.TransactionSystemClient;
+import co.cask.tephra.TxConstants;
+import co.cask.tephra.distributed.PooledClientProvider;
+import co.cask.tephra.distributed.TransactionServiceClient;
+
+
 public class ConnectionQueryServicesImpl extends DelegateQueryServices 
implements ConnectionQueryServices {
 private static final Logger logger = 
LoggerFactory.getLogger(ConnectionQueryServicesImpl.class);
 private static final int INITIAL_CHILD_SERVICES_CAPACITY = 100;
@@ -249,10 +255,6 @@ public class ConnectionQueryServicesImpl extends 
DelegateQueryServices implement
 private ScheduledExecutorService renewLeaseExecutor;
 private final boolean renewLeaseEnabled;
 
-import co.cask.tephra.TransactionSystemClient;
-import co.cask.tephra.TxConstants;
-import co.cask.tephra.distributed.PooledClientProvider;
-import co.cask.tephra.distributed.TransactionServiceClient;
 
 
 private static interface FeatureSupported {



phoenix git commit: PHOENIX-2683 store rowCount and byteCount at guidePost level(Ankit Singhal)

2016-02-16 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 0b80eef66 -> 8f1370f55


PHOENIX-2683 store rowCount and byteCount at guidePost level(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/8f1370f5
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/8f1370f5
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/8f1370f5

Branch: refs/heads/4.x-HBase-0.98
Commit: 8f1370f55bab620abdb14321c1518076be1002d2
Parents: 0b80eef
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Tue Feb 16 22:04:39 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Tue Feb 16 22:04:39 2016 +0530

--
 .../StatsCollectorWithSplitsAndMultiCFIT.java   |  66 +++-
 .../generated/PGuidePostsProtos.java| 336 ++-
 .../org/apache/phoenix/execute/ScanPlan.java|   5 +-
 .../org/apache/phoenix/schema/PTableImpl.java   |  25 +-
 .../phoenix/schema/stats/GuidePostsInfo.java|  69 ++--
 .../schema/stats/GuidePostsInfoBuilder.java |  61 ++--
 .../schema/stats/StatisticsCollector.java   |  21 +-
 .../phoenix/schema/stats/StatisticsWriter.java  |  18 +-
 phoenix-protocol/src/main/PGuidePosts.proto |   2 +
 9 files changed, 502 insertions(+), 101 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/8f1370f5/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
index dfe8b60..13cd54c 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
@@ -26,9 +26,11 @@ import java.sql.Connection;
 import java.sql.DriverManager;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
+import java.sql.SQLException;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
+import java.util.Random;
 
 import org.apache.hadoop.hbase.HRegionLocation;
 import org.apache.hadoop.hbase.util.Bytes;
@@ -102,10 +104,10 @@ public class StatsCollectorWithSplitsAndMultiCFIT extends 
StatsCollectorAbstract
 
 TestUtil.analyzeTable(conn, STATS_TEST_TABLE_NAME_NEW);
 String query = "UPDATE STATISTICS " + STATS_TEST_TABLE_NAME_NEW + " 
SET \""
-+ QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB + "\"=" + 
Long.toString(2000);
++ QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB + "\"=" + 
Long.toString(250);
 conn.createStatement().execute(query);
 keyRanges = getAllSplits(conn, STATS_TEST_TABLE_NAME_NEW);
-assertEquals(6, keyRanges.size());
+assertEquals(26, keyRanges.size());
 
 rs = conn.createStatement().executeQuery(
 "SELECT 
COLUMN_FAMILY,SUM(GUIDE_POSTS_ROW_COUNT),SUM(GUIDE_POSTS_WIDTH),COUNT(*) from 
SYSTEM.STATS where PHYSICAL_NAME = '"
@@ -115,27 +117,71 @@ public class StatsCollectorWithSplitsAndMultiCFIT extends 
StatsCollectorAbstract
 assertTrue(rs.next());
 assertEquals("A", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(11040, rs.getInt(3));
-assertEquals(5, rs.getInt(4));
+assertEquals(12420, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("B", rs.getString(1));
 assertEquals(20, rs.getInt(2));
-assertEquals(4432, rs.getInt(3));
-assertEquals(2, rs.getInt(4));
+assertEquals(5540, rs.getInt(3));
+assertEquals(20, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("C", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(6652, rs.getInt(3));
-assertEquals(3, rs.getInt(4));
+assertEquals(6930, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("D", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(6652, rs.getInt(3));
-assertEquals(3, rs.getInt(4));
+assertEquals(6930, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 }
 
+@Test
+public void testRowCountAndByteCounts() throws SQLException {
+Connection conn;
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+conn = DriverManager.getConnection(getUrl(), props);
+String tabl

phoenix git commit: PHOENIX-2683 store rowCount and byteCount at guidePost level(Ankit Singhal)

2016-02-16 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master e797b36c2 -> d2fcd21d4


PHOENIX-2683 store rowCount and byteCount at guidePost level(Ankit Singhal)


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

Branch: refs/heads/master
Commit: d2fcd21d4f55c17585adbbc41f72027323a8a870
Parents: e797b36
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Tue Feb 16 22:03:58 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Tue Feb 16 22:03:58 2016 +0530

--
 .../StatsCollectorWithSplitsAndMultiCFIT.java   |  66 +++-
 .../generated/PGuidePostsProtos.java| 336 ++-
 .../org/apache/phoenix/execute/ScanPlan.java|   5 +-
 .../org/apache/phoenix/schema/PTableImpl.java   |  25 +-
 .../phoenix/schema/stats/GuidePostsInfo.java|  69 ++--
 .../schema/stats/GuidePostsInfoBuilder.java |  61 ++--
 .../schema/stats/StatisticsCollector.java   |  21 +-
 .../phoenix/schema/stats/StatisticsWriter.java  |  18 +-
 phoenix-protocol/src/main/PGuidePosts.proto |   2 +
 9 files changed, 502 insertions(+), 101 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/d2fcd21d/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
index dfe8b60..13cd54c 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
@@ -26,9 +26,11 @@ import java.sql.Connection;
 import java.sql.DriverManager;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
+import java.sql.SQLException;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
+import java.util.Random;
 
 import org.apache.hadoop.hbase.HRegionLocation;
 import org.apache.hadoop.hbase.util.Bytes;
@@ -102,10 +104,10 @@ public class StatsCollectorWithSplitsAndMultiCFIT extends 
StatsCollectorAbstract
 
 TestUtil.analyzeTable(conn, STATS_TEST_TABLE_NAME_NEW);
 String query = "UPDATE STATISTICS " + STATS_TEST_TABLE_NAME_NEW + " 
SET \""
-+ QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB + "\"=" + 
Long.toString(2000);
++ QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB + "\"=" + 
Long.toString(250);
 conn.createStatement().execute(query);
 keyRanges = getAllSplits(conn, STATS_TEST_TABLE_NAME_NEW);
-assertEquals(6, keyRanges.size());
+assertEquals(26, keyRanges.size());
 
 rs = conn.createStatement().executeQuery(
 "SELECT 
COLUMN_FAMILY,SUM(GUIDE_POSTS_ROW_COUNT),SUM(GUIDE_POSTS_WIDTH),COUNT(*) from 
SYSTEM.STATS where PHYSICAL_NAME = '"
@@ -115,27 +117,71 @@ public class StatsCollectorWithSplitsAndMultiCFIT extends 
StatsCollectorAbstract
 assertTrue(rs.next());
 assertEquals("A", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(11040, rs.getInt(3));
-assertEquals(5, rs.getInt(4));
+assertEquals(12420, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("B", rs.getString(1));
 assertEquals(20, rs.getInt(2));
-assertEquals(4432, rs.getInt(3));
-assertEquals(2, rs.getInt(4));
+assertEquals(5540, rs.getInt(3));
+assertEquals(20, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("C", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(6652, rs.getInt(3));
-assertEquals(3, rs.getInt(4));
+assertEquals(6930, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("D", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(6652, rs.getInt(3));
-assertEquals(3, rs.getInt(4));
+assertEquals(6930, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 }
 
+@Test
+public void testRowCountAndByteCounts() throws SQLException {
+Connection conn;
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+conn = DriverManager.getConnection(getUrl(), props);
+String tabl

phoenix git commit: PHOENIX-2683 store rowCount and byteCount at guidePost level(Ankit Singhal)

2016-02-16 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 75e4f4132 -> 6ef45b677


PHOENIX-2683 store rowCount and byteCount at guidePost level(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/6ef45b67
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/6ef45b67
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/6ef45b67

Branch: refs/heads/4.x-HBase-1.0
Commit: 6ef45b677d90ec0a75c8e99f47fe15b83db5628f
Parents: 75e4f41
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Tue Feb 16 22:05:15 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Tue Feb 16 22:05:15 2016 +0530

--
 .../StatsCollectorWithSplitsAndMultiCFIT.java   |  66 +++-
 .../generated/PGuidePostsProtos.java| 336 ++-
 .../org/apache/phoenix/execute/ScanPlan.java|   5 +-
 .../org/apache/phoenix/schema/PTableImpl.java   |  25 +-
 .../phoenix/schema/stats/GuidePostsInfo.java|  69 ++--
 .../schema/stats/GuidePostsInfoBuilder.java |  61 ++--
 .../schema/stats/StatisticsCollector.java   |  21 +-
 .../phoenix/schema/stats/StatisticsWriter.java  |  18 +-
 phoenix-protocol/src/main/PGuidePosts.proto |   2 +
 9 files changed, 502 insertions(+), 101 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/6ef45b67/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
index dfe8b60..13cd54c 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/StatsCollectorWithSplitsAndMultiCFIT.java
@@ -26,9 +26,11 @@ import java.sql.Connection;
 import java.sql.DriverManager;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
+import java.sql.SQLException;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
+import java.util.Random;
 
 import org.apache.hadoop.hbase.HRegionLocation;
 import org.apache.hadoop.hbase.util.Bytes;
@@ -102,10 +104,10 @@ public class StatsCollectorWithSplitsAndMultiCFIT extends 
StatsCollectorAbstract
 
 TestUtil.analyzeTable(conn, STATS_TEST_TABLE_NAME_NEW);
 String query = "UPDATE STATISTICS " + STATS_TEST_TABLE_NAME_NEW + " 
SET \""
-+ QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB + "\"=" + 
Long.toString(2000);
++ QueryServices.STATS_GUIDEPOST_WIDTH_BYTES_ATTRIB + "\"=" + 
Long.toString(250);
 conn.createStatement().execute(query);
 keyRanges = getAllSplits(conn, STATS_TEST_TABLE_NAME_NEW);
-assertEquals(6, keyRanges.size());
+assertEquals(26, keyRanges.size());
 
 rs = conn.createStatement().executeQuery(
 "SELECT 
COLUMN_FAMILY,SUM(GUIDE_POSTS_ROW_COUNT),SUM(GUIDE_POSTS_WIDTH),COUNT(*) from 
SYSTEM.STATS where PHYSICAL_NAME = '"
@@ -115,27 +117,71 @@ public class StatsCollectorWithSplitsAndMultiCFIT extends 
StatsCollectorAbstract
 assertTrue(rs.next());
 assertEquals("A", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(11040, rs.getInt(3));
-assertEquals(5, rs.getInt(4));
+assertEquals(12420, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("B", rs.getString(1));
 assertEquals(20, rs.getInt(2));
-assertEquals(4432, rs.getInt(3));
-assertEquals(2, rs.getInt(4));
+assertEquals(5540, rs.getInt(3));
+assertEquals(20, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("C", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(6652, rs.getInt(3));
-assertEquals(3, rs.getInt(4));
+assertEquals(6930, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 assertTrue(rs.next());
 assertEquals("D", rs.getString(1));
 assertEquals(25, rs.getInt(2));
-assertEquals(6652, rs.getInt(3));
-assertEquals(3, rs.getInt(4));
+assertEquals(6930, rs.getInt(3));
+assertEquals(25, rs.getInt(4));
 
 }
 
+@Test
+public void testRowCountAndByteCounts() throws SQLException {
+Connection conn;
+Properties props = PropertiesUtil.deepCopy(TEST_PROPERTIES);
+conn = DriverManager.getConnection(getUrl(), props);
+String tabl

phoenix git commit: PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts found for that region(Ankit Singhal)

2016-02-19 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master c2cc1be60 -> 9dd6babd8


PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts 
found for that region(Ankit Singhal)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/9dd6babd
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/9dd6babd
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/9dd6babd

Branch: refs/heads/master
Commit: 9dd6babd86186242b55d01afcb857aa02497ea95
Parents: c2cc1be
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Feb 19 22:28:07 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Feb 19 22:28:07 2016 +0530

--
 .../phoenix/schema/stats/DefaultStatisticsCollector.java | 8 
 1 file changed, 8 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/9dd6babd/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
index 96b35f1..cb6f5d4 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
@@ -126,6 +126,14 @@ class DefaultStatisticsCollector implements 
StatisticsCollector {
 throws IOException {
 try {
 // update the statistics table
+// Delete statistics for a region if no guidepost is collected for 
that region during UPDATE STATISTICS
+// This will not impact a stats collection of single column family 
during compaction as
+// guidePostsInfoWriterMap cannot be empty in this case.
+if (guidePostsInfoWriterMap.keySet().isEmpty()) {
+for (Store store : region.getStores()) {
+statsTable.deleteStats(region, this, new 
ImmutableBytesPtr(store.getFamily().getName()), mutations);
+}
+}
 for (ImmutableBytesPtr fam : guidePostsInfoWriterMap.keySet()) {
 if (delete) {
 if (logger.isDebugEnabled()) {



phoenix git commit: PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts found for that region(Ankit Singhal)

2016-02-19 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 f88b76662 -> 918990971


PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts 
found for that region(Ankit Singhal)


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

Branch: refs/heads/4.x-HBase-1.0
Commit: 918990971d321ed70b37f74cb8e7b4844f427841
Parents: f88b766
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Feb 19 22:28:56 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Feb 19 22:28:56 2016 +0530

--
 .../phoenix/schema/stats/DefaultStatisticsCollector.java | 8 
 1 file changed, 8 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/91899097/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
index 38e1ca5..ce6e7db 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
@@ -125,6 +125,14 @@ class DefaultStatisticsCollector implements 
StatisticsCollector {
 throws IOException {
 try {
 // update the statistics table
+// Delete statistics for a region if no guidepost is collected for 
that region during UPDATE STATISTICS
+// This will not impact a stats collection of single column family 
during compaction as
+// guidePostsInfoWriterMap cannot be empty in this case.
+if (guidePostsInfoWriterMap.keySet().isEmpty()) {
+for (Store store : region.getStores()) {
+statsTable.deleteStats(region, this, new 
ImmutableBytesPtr(store.getFamily().getName()), mutations);
+}
+}
 for (ImmutableBytesPtr fam : guidePostsInfoWriterMap.keySet()) {
 if (delete) {
 if (logger.isDebugEnabled()) {



phoenix git commit: PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts found for that region(Ankit Singhal)

2016-02-19 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 508751847 -> eac2ba7e7


PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts 
found for that region(Ankit Singhal)


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

Branch: refs/heads/4.x-HBase-0.98
Commit: eac2ba7e770cfd0bec9d4f1a2e5e08bf7a3aa171
Parents: 5087518
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Feb 19 22:29:43 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Feb 19 22:29:43 2016 +0530

--
 .../phoenix/schema/stats/DefaultStatisticsCollector.java | 8 
 1 file changed, 8 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/eac2ba7e/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
index e7ba443..c56c102 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
@@ -124,6 +124,14 @@ public class DefaultStatisticsCollector implements 
StatisticsCollector {
 throws IOException {
 try {
 // update the statistics table
+// Delete statistics for a region if no guidepost is collected for 
that region during UPDATE STATISTICS
+// This will not impact a stats collection of single column family 
during compaction as
+// guidePostsInfoWriterMap cannot be empty in this case.
+if (guidePostsInfoWriterMap.keySet().isEmpty()) {
+for (Store store : region.getStores()) {
+statsTable.deleteStats(region, this, new 
ImmutableBytesPtr(store.getFamily().getName()), mutations);
+}
+}
 for (ImmutableBytesPtr fam : guidePostsInfoWriterMap.keySet()) {
 if (delete) {
 if (logger.isDebugEnabled()) {



phoenix git commit: PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts found for that region(addendum)

2016-02-19 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 eac2ba7e7 -> 072657081


PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts 
found for that region(addendum)


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

Branch: refs/heads/4.x-HBase-0.98
Commit: 072657081bf8774a4bf9e0c9720cb65b13aabb2b
Parents: eac2ba7
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Feb 19 23:38:50 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Feb 19 23:38:50 2016 +0530

--
 .../apache/phoenix/schema/stats/DefaultStatisticsCollector.java  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/07265708/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
index c56c102..adce23c 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
@@ -128,8 +128,8 @@ public class DefaultStatisticsCollector implements 
StatisticsCollector {
 // This will not impact a stats collection of single column family 
during compaction as
 // guidePostsInfoWriterMap cannot be empty in this case.
 if (guidePostsInfoWriterMap.keySet().isEmpty()) {
-for (Store store : region.getStores()) {
-statsTable.deleteStats(region, this, new 
ImmutableBytesPtr(store.getFamily().getName()), mutations);
+for (byte[] fam : region.getStores().keySet()) {
+statsTable.deleteStats(region, this, new 
ImmutableBytesPtr(fam), mutations);
 }
 }
 for (ImmutableBytesPtr fam : guidePostsInfoWriterMap.keySet()) {



phoenix git commit: PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts found for that region(addendum)

2016-02-19 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 918990971 -> e27aa029f


PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts 
found for that region(addendum)


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

Branch: refs/heads/4.x-HBase-1.0
Commit: e27aa029f51456e49fdc919c86eae8e82c6090f1
Parents: 9189909
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Feb 19 23:43:14 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Feb 19 23:43:14 2016 +0530

--
 .../apache/phoenix/schema/stats/DefaultStatisticsCollector.java  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/e27aa029/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
index ce6e7db..845f6d4 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
@@ -129,8 +129,8 @@ class DefaultStatisticsCollector implements 
StatisticsCollector {
 // This will not impact a stats collection of single column family 
during compaction as
 // guidePostsInfoWriterMap cannot be empty in this case.
 if (guidePostsInfoWriterMap.keySet().isEmpty()) {
-for (Store store : region.getStores()) {
-statsTable.deleteStats(region, this, new 
ImmutableBytesPtr(store.getFamily().getName()), mutations);
+for (byte[] fam : region.getStores().keySet()) {
+statsTable.deleteStats(region, this, new 
ImmutableBytesPtr(fam), mutations);
 }
 }
 for (ImmutableBytesPtr fam : guidePostsInfoWriterMap.keySet()) {



phoenix git commit: PHOENIX-2817 Phoenix-Spark plugin doesn't work in secured env(Sergey Soldatov)

2016-04-06 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 cede5a991 -> 8cf6457bb


PHOENIX-2817 Phoenix-Spark plugin doesn't work in secured env(Sergey Soldatov)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/8cf6457b
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/8cf6457b
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/8cf6457b

Branch: refs/heads/4.x-HBase-1.0
Commit: 8cf6457bbc252fc78a55af2b7761a91d69e2239c
Parents: cede5a9
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Wed Apr 6 12:10:01 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Wed Apr 6 12:10:01 2016 +0530

--
 .../apache/phoenix/spark/PhoenixSparkIT.scala   |  7 +
 .../phoenix/spark/ConfigurationUtil.scala   | 27 
 .../org/apache/phoenix/spark/PhoenixRDD.scala   | 13 +-
 3 files changed, 30 insertions(+), 17 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/8cf6457b/phoenix-spark/src/it/scala/org/apache/phoenix/spark/PhoenixSparkIT.scala
--
diff --git 
a/phoenix-spark/src/it/scala/org/apache/phoenix/spark/PhoenixSparkIT.scala 
b/phoenix-spark/src/it/scala/org/apache/phoenix/spark/PhoenixSparkIT.scala
index 08c123a..ad4791d 100644
--- a/phoenix-spark/src/it/scala/org/apache/phoenix/spark/PhoenixSparkIT.scala
+++ b/phoenix-spark/src/it/scala/org/apache/phoenix/spark/PhoenixSparkIT.scala
@@ -53,16 +53,11 @@ class PhoenixSparkIT extends FunSuite with Matchers with 
BeforeAndAfterAll {
 
   lazy val hbaseConfiguration = {
 val conf = PhoenixSparkITHelper.getTestClusterConfig
-// The zookeeper quorum address defaults to "localhost" which is 
incorrect, let's fix it
-val quorum = conf.get("hbase.zookeeper.quorum")
-val clientPort = conf.get("hbase.zookeeper.property.clientPort")
-val znodeParent = conf.get("zookeeper.znode.parent")
-conf.set(HConstants.ZOOKEEPER_QUORUM, s"$quorum:$clientPort:$znodeParent")
 conf
   }
 
   lazy val quorumAddress = {
-hbaseConfiguration.get(HConstants.ZOOKEEPER_QUORUM)
+ConfigurationUtil.getZookeeperURL(hbaseConfiguration).get
   }
 
   override def beforeAll() {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/8cf6457b/phoenix-spark/src/main/scala/org/apache/phoenix/spark/ConfigurationUtil.scala
--
diff --git 
a/phoenix-spark/src/main/scala/org/apache/phoenix/spark/ConfigurationUtil.scala 
b/phoenix-spark/src/main/scala/org/apache/phoenix/spark/ConfigurationUtil.scala
index 2f306f0..2f4311f 100644
--- 
a/phoenix-spark/src/main/scala/org/apache/phoenix/spark/ConfigurationUtil.scala
+++ 
b/phoenix-spark/src/main/scala/org/apache/phoenix/spark/ConfigurationUtil.scala
@@ -15,6 +15,7 @@ package org.apache.phoenix.spark
 
 import org.apache.hadoop.conf.Configuration
 import org.apache.hadoop.hbase.{HBaseConfiguration, HConstants}
+import org.apache.phoenix.jdbc.PhoenixEmbeddedDriver
 import org.apache.phoenix.mapreduce.util.{ColumnInfoToStringEncoderDecoder, 
PhoenixConfigurationUtil}
 import org.apache.phoenix.util.ColumnInfo
 import scala.collection.JavaConversions._
@@ -38,20 +39,29 @@ object ConfigurationUtil extends Serializable {
 
 // Override the Zookeeper URL if present. Throw exception if no address 
given.
 zkUrl match {
-  case Some(url) => config.set(HConstants.ZOOKEEPER_QUORUM, url )
+  case Some(url) => setZookeeperURL(config, url)
   case _ => {
-if(config.get(HConstants.ZOOKEEPER_QUORUM) == null) {
+if (ConfigurationUtil.getZookeeperURL(config).isEmpty) {
   throw new UnsupportedOperationException(
 s"One of zkUrl or '${HConstants.ZOOKEEPER_QUORUM}' config property 
must be provided"
   )
 }
   }
 }
-
 // Return the configuration object
 config
   }
 
+  def setZookeeperURL(conf: Configuration, zkUrl: String) = {
+val info = PhoenixEmbeddedDriver.ConnectionInfo.create(zkUrl)
+conf.set(HConstants.ZOOKEEPER_QUORUM, info.getZookeeperQuorum)
+if (info.getPort != null)
+  conf.setInt(HConstants.ZOOKEEPER_CLIENT_PORT, info.getPort)
+if (info.getRootNode != null)
+  conf.set(HConstants.ZOOKEEPER_ZNODE_PARENT, info.getRootNode)
+
+  }
+
   // Return a serializable representation of the columns
   def encodeColumns(conf: Configuration) = {
 ColumnInfoToStringEncoderDecoder.encode(conf, 
PhoenixConfigurationUtil.getUpsertColumnMetadataList(conf)
@@ -62,8 +72,15 @@ object ConfigurationUtil extends Serializable {
   def decodeColumns(conf: Configuration): List[ColumnInfo] = {
 ColumnInfoToStringEncoderDecoder.decod

[1/3] phoenix git commit: PHOENIX-2722 support mysql offset clause

2016-04-08 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master 91800b703 -> 776eea9ce


http://git-wip-us.apache.org/repos/asf/phoenix/blob/776eea9c/phoenix-core/src/main/java/org/apache/phoenix/parse/ParseNodeFactory.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/parse/ParseNodeFactory.java 
b/phoenix-core/src/main/java/org/apache/phoenix/parse/ParseNodeFactory.java
index b485666..4c6c1e6 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/parse/ParseNodeFactory.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/parse/ParseNodeFactory.java
@@ -681,11 +681,11 @@ public class ParseNodeFactory {
 }
 
 public SelectStatement select(TableNode from, HintNode hint, boolean 
isDistinct, List select, ParseNode where,
-List groupBy, ParseNode having, List 
orderBy, LimitNode limit, int bindCount, boolean isAggregate, 
+List groupBy, ParseNode having, List 
orderBy, LimitNode limit, OffsetNode offset, int bindCount, boolean 
isAggregate, 
 boolean hasSequence, List selects, Map udfParseNodes) {
 
 return new SelectStatement(from, hint, isDistinct, select, where, 
groupBy == null ? Collections.emptyList() : groupBy, having,
-orderBy == null ? Collections.emptyList() : 
orderBy, limit, bindCount, isAggregate, hasSequence, selects == null ? 
Collections.emptyList() : selects, udfParseNodes);
+orderBy == null ? Collections.emptyList() : 
orderBy, limit, offset, bindCount, isAggregate, hasSequence, selects == null ? 
Collections.emptyList() : selects, udfParseNodes);
 } 
 
 public UpsertStatement upsert(NamedTableNode table, HintNode hint, 
List columns, List values, SelectStatement select, int 
bindCount, Map udfParseNodes) {
@@ -698,89 +698,90 @@ public class ParseNodeFactory {
 
 public SelectStatement select(SelectStatement statement, ParseNode where) {
 return select(statement.getFrom(), statement.getHint(), 
statement.isDistinct(), statement.getSelect(), where, statement.getGroupBy(), 
statement.getHaving(),
-statement.getOrderBy(), statement.getLimit(), 
statement.getBindCount(), statement.isAggregate(), statement.hasSequence(), 
statement.getSelects(), statement.getUdfParseNodes());
+statement.getOrderBy(), statement.getLimit(), 
statement.getOffset(), statement.getBindCount(), statement.isAggregate(), 
statement.hasSequence(), statement.getSelects(), statement.getUdfParseNodes());
 }
 
 public SelectStatement select(SelectStatement statement, ParseNode where, 
ParseNode having) {
 return select(statement.getFrom(), statement.getHint(), 
statement.isDistinct(), statement.getSelect(), where, statement.getGroupBy(), 
having,
-statement.getOrderBy(), statement.getLimit(), 
statement.getBindCount(), statement.isAggregate(), statement.hasSequence(), 
statement.getSelects(), statement.getUdfParseNodes());
+statement.getOrderBy(), statement.getLimit(), 
statement.getOffset(), statement.getBindCount(), statement.isAggregate(), 
statement.hasSequence(), statement.getSelects(), statement.getUdfParseNodes());
 }
 
 public SelectStatement select(SelectStatement statement, List 
select, ParseNode where, List groupBy, ParseNode having, 
List orderBy) {
 return select(statement.getFrom(), statement.getHint(), 
statement.isDistinct(), 
-select, where, groupBy, having, orderBy, statement.getLimit(), 
statement.getBindCount(), statement.isAggregate(), statement.hasSequence(), 
statement.getSelects(), statement.getUdfParseNodes());
+select, where, groupBy, having, orderBy, statement.getLimit(), 
statement.getOffset(), statement.getBindCount(), statement.isAggregate(), 
statement.hasSequence(), statement.getSelects(), statement.getUdfParseNodes());
 }
 
 public SelectStatement select(SelectStatement statement, TableNode table) {
 return select(table, statement.getHint(), statement.isDistinct(), 
statement.getSelect(), statement.getWhere(), statement.getGroupBy(),
-statement.getHaving(), statement.getOrderBy(), 
statement.getLimit(), statement.getBindCount(), statement.isAggregate(),
+statement.getHaving(), statement.getOrderBy(), 
statement.getLimit(), statement.getOffset(), statement.getBindCount(), 
statement.isAggregate(),
 statement.hasSequence(), statement.getSelects(), 
statement.getUdfParseNodes());
 }
 
 public SelectStatement select(SelectStatement statement, TableNode table, 
ParseNode where) {
 return select(table, statement.getHint(), statement.isDistinct(), 
statement.getSelect(), where, statement.getGroupBy(),
-statement.getHaving(), statement.getOrderBy(), 
statement.getLimit(), statement.getBindCount(), statement.isAggregate(),
+   

[2/3] phoenix git commit: PHOENIX-2722 support mysql offset clause

2016-04-08 Thread ankit
http://git-wip-us.apache.org/repos/asf/phoenix/blob/776eea9c/phoenix-core/src/main/java/org/apache/phoenix/execute/AggregatePlan.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/execute/AggregatePlan.java 
b/phoenix-core/src/main/java/org/apache/phoenix/execute/AggregatePlan.java
index 5670dae..b125ecc 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/execute/AggregatePlan.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/execute/AggregatePlan.java
@@ -42,6 +42,7 @@ import 
org.apache.phoenix.iterate.FilterAggregatingResultIterator;
 import org.apache.phoenix.iterate.GroupedAggregatingResultIterator;
 import org.apache.phoenix.iterate.LimitingResultIterator;
 import org.apache.phoenix.iterate.MergeSortRowKeyResultIterator;
+import org.apache.phoenix.iterate.OffsetResultIterator;
 import org.apache.phoenix.iterate.OrderedAggregatingResultIterator;
 import org.apache.phoenix.iterate.OrderedResultIterator;
 import org.apache.phoenix.iterate.ParallelIteratorFactory;
@@ -63,8 +64,6 @@ import org.apache.phoenix.schema.TableRef;
 import org.apache.phoenix.schema.types.PInteger;
 import org.apache.phoenix.util.ScanUtil;
 
-
-
 /**
  *
  * Query plan for aggregating queries
@@ -78,18 +77,19 @@ public class AggregatePlan extends BaseQueryPlan {
 private List splits;
 private List scans;
 
-public AggregatePlan(
-StatementContext context, FilterableStatement statement, TableRef 
table, RowProjector projector,
-Integer limit, OrderBy orderBy, ParallelIteratorFactory 
parallelIteratorFactory, GroupBy groupBy,
-Expression having) {
-this(context, statement, table, projector, limit, orderBy, 
parallelIteratorFactory, groupBy, having, null);
+public AggregatePlan(StatementContext context, FilterableStatement 
statement, TableRef table,
+RowProjector projector, Integer limit, Integer offset, OrderBy 
orderBy,
+ParallelIteratorFactory parallelIteratorFactory, GroupBy groupBy, 
Expression having) {
+this(context, statement, table, projector, limit, offset, orderBy, 
parallelIteratorFactory, groupBy, having,
+null);
 }
-
-private AggregatePlan(
-StatementContext context, FilterableStatement statement, TableRef 
table, RowProjector projector,
-Integer limit, OrderBy orderBy, ParallelIteratorFactory 
parallelIteratorFactory, GroupBy groupBy,
-Expression having, Expression dynamicFilter) {
-super(context, statement, table, projector, 
context.getBindManager().getParameterMetaData(), limit, orderBy, groupBy, 
parallelIteratorFactory, dynamicFilter);
+
+private AggregatePlan(StatementContext context, FilterableStatement 
statement, TableRef table,
+RowProjector projector, Integer limit, Integer offset, OrderBy 
orderBy,
+ParallelIteratorFactory parallelIteratorFactory, GroupBy groupBy, 
Expression having,
+Expression dynamicFilter) {
+super(context, statement, table, projector, 
context.getBindManager().getParameterMetaData(), limit, offset,
+orderBy, groupBy, parallelIteratorFactory, dynamicFilter);
 this.having = having;
 this.aggregators = context.getAggregationManager().getAggregators();
 }
@@ -195,12 +195,13 @@ public class AggregatePlan extends BaseQueryPlan {
  *order, so we can early exit, even when aggregate 
functions are used, as
  *the rows in the group are contiguous.
  */
-
context.getScan().setAttribute(BaseScannerRegionObserver.GROUP_BY_LIMIT, 
PInteger.INSTANCE.toBytes(limit));
+
context.getScan().setAttribute(BaseScannerRegionObserver.GROUP_BY_LIMIT,
+PInteger.INSTANCE.toBytes(limit + (offset == null ? 0 
: offset)));
 }
 }
-BaseResultIterators iterators = 
statement.getHint().hasHint(HintNode.Hint.SERIAL) ?
-new SerialIterators(this, null, wrapParallelIteratorFactory(), 
scanGrouper) :
-new ParallelIterators(this, null, 
wrapParallelIteratorFactory());
+BaseResultIterators iterators = 
statement.getHint().hasHint(HintNode.Hint.SERIAL)
+? new SerialIterators(this, null, null, 
wrapParallelIteratorFactory(), scanGrouper)
+: new ParallelIterators(this, null, 
wrapParallelIteratorFactory());
 
 splits = iterators.getSplits();
 scans = iterators.getScans();
@@ -228,13 +229,17 @@ public class AggregatePlan extends BaseQueryPlan {
 
 ResultIterator resultScanner = aggResultIterator;
 if (orderBy.getOrderByExpressions().isEmpty()) {
+if (offset != null) {
+resultScanner = new OffsetResultIterator(aggResultIterator, 
offset);
+}
 if (limit != null) {
-

[3/3] phoenix git commit: PHOENIX-2722 support mysql offset clause

2016-04-08 Thread ankit
PHOENIX-2722 support mysql offset clause


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/776eea9c
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/776eea9c
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/776eea9c

Branch: refs/heads/master
Commit: 776eea9ce1c4828f959b9ef76dd244941972f6ec
Parents: 91800b7
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Apr 8 15:04:17 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Apr 8 15:04:17 2016 +0530

--
 .../apache/phoenix/end2end/AutoCommitIT.java|  14 +-
 .../apache/phoenix/end2end/CreateTableIT.java   |   2 +-
 .../apache/phoenix/end2end/DerivedTableIT.java  | 144 -
 .../org/apache/phoenix/end2end/HashJoinIT.java  | 161 ++
 .../phoenix/end2end/QueryWithOffsetIT.java  | 211 +++
 .../org/apache/phoenix/end2end/ReadOnlyIT.java  |  12 +-
 .../apache/phoenix/end2end/SortMergeJoinIT.java |  44 
 phoenix-core/src/main/antlr3/PhoenixSQL.g   |  16 +-
 .../apache/phoenix/compile/DeleteCompiler.java  |  13 +-
 .../apache/phoenix/compile/JoinCompiler.java|  10 +-
 .../phoenix/compile/ListJarsQueryPlan.java  |   5 +
 .../apache/phoenix/compile/OffsetCompiler.java  | 114 ++
 .../apache/phoenix/compile/OrderByCompiler.java |   3 +-
 .../apache/phoenix/compile/PostDDLCompiler.java |   3 +-
 .../apache/phoenix/compile/QueryCompiler.java   |  54 +++--
 .../org/apache/phoenix/compile/QueryPlan.java   |   2 +
 .../phoenix/compile/StatementNormalizer.java|   2 +-
 .../phoenix/compile/SubqueryRewriter.java   |  10 +-
 .../phoenix/compile/SubselectRewriter.java  |  17 +-
 .../apache/phoenix/compile/TraceQueryPlan.java  |   5 +
 .../apache/phoenix/compile/UpsertCompiler.java  |   2 +-
 .../coprocessor/BaseScannerRegionObserver.java  |   1 +
 .../phoenix/coprocessor/ScanRegionObserver.java |  95 -
 .../apache/phoenix/execute/AggregatePlan.java   |  43 ++--
 .../apache/phoenix/execute/BaseQueryPlan.java   |   9 +-
 .../phoenix/execute/ClientAggregatePlan.java|  19 +-
 .../phoenix/execute/ClientProcessingPlan.java   |  10 +-
 .../apache/phoenix/execute/ClientScanPlan.java  |  38 ++--
 .../phoenix/execute/DegenerateQueryPlan.java|   2 +-
 .../phoenix/execute/DelegateQueryPlan.java  |   4 +
 .../execute/LiteralResultIterationPlan.java |  13 +-
 .../org/apache/phoenix/execute/ScanPlan.java|  58 +++--
 .../phoenix/execute/SortMergeJoinPlan.java  |   5 +
 .../org/apache/phoenix/execute/UnionPlan.java   |  15 +-
 .../phoenix/iterate/BaseResultIterators.java|  14 +-
 .../apache/phoenix/iterate/ExplainTable.java|  16 +-
 .../phoenix/iterate/LimitingResultIterator.java |   2 +-
 .../iterate/MergeSortTopNResultIterator.java|  21 +-
 .../phoenix/iterate/OffsetResultIterator.java   |  62 ++
 .../OrderedAggregatingResultIterator.java   |   6 +-
 .../phoenix/iterate/OrderedResultIterator.java  |  58 +++--
 .../phoenix/iterate/ParallelIterators.java  |   4 +-
 .../apache/phoenix/iterate/SerialIterators.java |  19 +-
 .../phoenix/iterate/TableResultIterator.java|  22 +-
 .../apache/phoenix/jdbc/PhoenixStatement.java   |  18 +-
 .../org/apache/phoenix/join/HashJoinInfo.java   |   2 +-
 .../apache/phoenix/optimize/QueryOptimizer.java |   2 +-
 .../apache/phoenix/parse/DeleteStatement.java   |   6 +
 .../phoenix/parse/FilterableStatement.java  |   1 +
 .../org/apache/phoenix/parse/OffsetNode.java|  67 ++
 .../apache/phoenix/parse/ParseNodeFactory.java  |  55 +++--
 .../apache/phoenix/parse/ParseNodeRewriter.java |   2 +-
 .../apache/phoenix/parse/SelectStatement.java   |  35 ++-
 .../apache/phoenix/query/QueryConstants.java|   6 +
 .../java/org/apache/phoenix/util/QueryUtil.java |  30 ++-
 .../java/org/apache/phoenix/util/ScanUtil.java  |   4 +
 .../phoenix/execute/CorrelatePlanTest.java  |  39 +++-
 .../execute/LiteralResultIteratorPlanTest.java  | 192 +
 .../phoenix/execute/UnnestArrayPlanTest.java|   3 +-
 .../query/ParallelIteratorsSplitTest.java   |   5 +
 60 files changed, 1622 insertions(+), 225 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/776eea9c/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java
index aa92c5e..469f2de 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java
@@ -42,21 +42,21 @@ public class AutoCommitIT extends BaseHBaseM

[3/3] phoenix git commit: PHOENIX-2722 support mysql offset clause

2016-04-08 Thread ankit
PHOENIX-2722 support mysql offset clause


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

Branch: refs/heads/4.x-HBase-0.98
Commit: f65d0481d00e2fa70b03d97345377cb26d7fcb22
Parents: 4c588f4
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Fri Apr 8 16:06:50 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Fri Apr 8 16:06:50 2016 +0530

--
 .../apache/phoenix/end2end/AutoCommitIT.java|  14 +-
 .../apache/phoenix/end2end/CreateTableIT.java   |   2 +-
 .../apache/phoenix/end2end/DerivedTableIT.java  | 144 -
 .../org/apache/phoenix/end2end/HashJoinIT.java  | 161 ++
 .../phoenix/end2end/QueryWithOffsetIT.java  | 211 +++
 .../org/apache/phoenix/end2end/ReadOnlyIT.java  |  12 +-
 .../apache/phoenix/end2end/SortMergeJoinIT.java |  44 
 phoenix-core/src/main/antlr3/PhoenixSQL.g   |  16 +-
 .../apache/phoenix/compile/DeleteCompiler.java  |  13 +-
 .../apache/phoenix/compile/JoinCompiler.java|  10 +-
 .../phoenix/compile/ListJarsQueryPlan.java  |   5 +
 .../apache/phoenix/compile/OffsetCompiler.java  | 114 ++
 .../apache/phoenix/compile/OrderByCompiler.java |   3 +-
 .../apache/phoenix/compile/PostDDLCompiler.java |   3 +-
 .../apache/phoenix/compile/QueryCompiler.java   |  52 +++--
 .../org/apache/phoenix/compile/QueryPlan.java   |   2 +
 .../phoenix/compile/StatementNormalizer.java|   2 +-
 .../phoenix/compile/SubqueryRewriter.java   |  10 +-
 .../phoenix/compile/SubselectRewriter.java  |  15 +-
 .../apache/phoenix/compile/TraceQueryPlan.java  |   5 +
 .../apache/phoenix/compile/UpsertCompiler.java  |   2 +-
 .../coprocessor/BaseScannerRegionObserver.java  |   1 +
 .../phoenix/coprocessor/ScanRegionObserver.java |  95 -
 .../apache/phoenix/execute/AggregatePlan.java   |  43 ++--
 .../apache/phoenix/execute/BaseQueryPlan.java   |   9 +-
 .../phoenix/execute/ClientAggregatePlan.java|  19 +-
 .../phoenix/execute/ClientProcessingPlan.java   |  10 +-
 .../apache/phoenix/execute/ClientScanPlan.java  |  38 ++--
 .../phoenix/execute/DegenerateQueryPlan.java|   2 +-
 .../phoenix/execute/DelegateQueryPlan.java  |   4 +
 .../execute/LiteralResultIterationPlan.java |  13 +-
 .../org/apache/phoenix/execute/ScanPlan.java|  58 +++--
 .../phoenix/execute/SortMergeJoinPlan.java  |   5 +
 .../org/apache/phoenix/execute/UnionPlan.java   |  15 +-
 .../phoenix/iterate/BaseResultIterators.java|  14 +-
 .../apache/phoenix/iterate/ExplainTable.java|  16 +-
 .../phoenix/iterate/LimitingResultIterator.java |   2 +-
 .../iterate/MergeSortTopNResultIterator.java|  21 +-
 .../phoenix/iterate/OffsetResultIterator.java   |  62 ++
 .../OrderedAggregatingResultIterator.java   |   6 +-
 .../phoenix/iterate/OrderedResultIterator.java  |  58 +++--
 .../phoenix/iterate/ParallelIterators.java  |   4 +-
 .../apache/phoenix/iterate/SerialIterators.java |  19 +-
 .../phoenix/iterate/TableResultIterator.java|  22 +-
 .../apache/phoenix/jdbc/PhoenixStatement.java   |  18 +-
 .../org/apache/phoenix/join/HashJoinInfo.java   |   2 +-
 .../apache/phoenix/optimize/QueryOptimizer.java |   2 +-
 .../apache/phoenix/parse/DeleteStatement.java   |   6 +
 .../phoenix/parse/FilterableStatement.java  |   1 +
 .../org/apache/phoenix/parse/OffsetNode.java|  67 ++
 .../apache/phoenix/parse/ParseNodeFactory.java  |  55 +++--
 .../apache/phoenix/parse/ParseNodeRewriter.java |   2 +-
 .../apache/phoenix/parse/SelectStatement.java   |  35 ++-
 .../apache/phoenix/query/QueryConstants.java|   6 +
 .../java/org/apache/phoenix/util/QueryUtil.java |  30 ++-
 .../java/org/apache/phoenix/util/ScanUtil.java  |   4 +
 .../phoenix/execute/CorrelatePlanTest.java  |  39 +++-
 .../execute/LiteralResultIteratorPlanTest.java  | 192 +
 .../phoenix/execute/UnnestArrayPlanTest.java|   3 +-
 .../query/ParallelIteratorsSplitTest.java   |   5 +
 60 files changed, 1621 insertions(+), 222 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/f65d0481/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java
index aa92c5e..469f2de 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/AutoCommitIT.java
@@ -42,21 +42,21 @@ public class AutoCommitIT extends BaseHBaseM

svn commit: r1733569 - in /phoenix/site: publish/team.html source/src/site/markdown/team.md

2016-03-04 Thread ankit
Author: ankit
Date: Fri Mar  4 09:10:24 2016
New Revision: 1733569

URL: http://svn.apache.org/viewvc?rev=1733569=rev
Log:
Updated team page with Ankit Singhal addition

Modified:
phoenix/site/publish/team.html
phoenix/site/source/src/site/markdown/team.md

Modified: phoenix/site/publish/team.html
URL: 
http://svn.apache.org/viewvc/phoenix/site/publish/team.html?rev=1733569=1733568=1733569=diff
==
--- phoenix/site/publish/team.html (original)
+++ phoenix/site/publish/team.html Fri Mar  4 09:10:24 2016
@@ -1,7 +1,7 @@
 
 
 
 
@@ -305,6 +305,12 @@
mailto:jferna...@apache.org;>jferna...@apache.org  
Committer 

+   
+   Ankit Singhal  
+   Hortonworks  
+   mailto:an...@apache.org;>an...@apache.org  
+   Committer 
+   
   
 


Modified: phoenix/site/source/src/site/markdown/team.md
URL: 
http://svn.apache.org/viewvc/phoenix/site/source/src/site/markdown/team.md?rev=1733569=1733568=1733569=diff
==
--- phoenix/site/source/src/site/markdown/team.md (original)
+++ phoenix/site/source/src/site/markdown/team.md Fri Mar  4 09:10:24 2016
@@ -32,3 +32,4 @@ Thomas D'Silva | Salesforce | tdsilva@ap
 Cody Marcel | Salesforce | codymar...@apache.org | Committer
 Dumindu Buddhika | University of Moratuwa | dumin...@apache.org | Committer
 Jan Fernando | Salesforce | jferna...@apache.org | Committer
+Ankit Singhal | Hortonworks | an...@apache.org | Committer




svn commit: r1733573 - in /phoenix/site: publish/team.html source/src/site/markdown/team.md

2016-03-04 Thread ankit
Author: ankit
Date: Fri Mar  4 10:04:50 2016
New Revision: 1733573

URL: http://svn.apache.org/viewvc?rev=1733573=rev
Log:
Updated Ankit Singhal addition in alphabetical order

Modified:
phoenix/site/publish/team.html
phoenix/site/source/src/site/markdown/team.md

Modified: phoenix/site/publish/team.html
URL: 
http://svn.apache.org/viewvc/phoenix/site/publish/team.html?rev=1733573=1733572=1733573=diff
==
--- phoenix/site/publish/team.html (original)
+++ phoenix/site/publish/team.html Fri Mar  4 10:04:50 2016
@@ -288,29 +288,29 @@
PMC 


+   Ankit Singhal  
+   Hortonworks  
+   mailto:an...@apache.org;>an...@apache.org  
+   Committer 
+   
+   
Cody Marcel  
Salesforce  
mailto:codymar...@apache.org;>codymar...@apache.org  
Committer 

-   
+   
Dumindu Buddhika  
University of Moratuwa  
mailto:dumin...@apache.org;>dumin...@apache.org  
Committer 

-   
+   
Jan Fernando  
Salesforce  
mailto:jferna...@apache.org;>jferna...@apache.org  
Committer 
    
-   
-   Ankit Singhal  
-   Hortonworks  
-   mailto:an...@apache.org;>an...@apache.org  
-   Committer 
-   
   
 


Modified: phoenix/site/source/src/site/markdown/team.md
URL: 
http://svn.apache.org/viewvc/phoenix/site/source/src/site/markdown/team.md?rev=1733573=1733572=1733573=diff
==
--- phoenix/site/source/src/site/markdown/team.md (original)
+++ phoenix/site/source/src/site/markdown/team.md Fri Mar  4 10:04:50 2016
@@ -29,7 +29,7 @@ Samarth Jain | Salesforce | samarth@apac
 Simon Toens | Salesforce | sto...@apache.org | PMC
 Steven Noels | NGDATA | stev...@apache.org | PMC
 Thomas D'Silva | Salesforce | tdsi...@apache.org | PMC
+Ankit Singhal | Hortonworks | an...@apache.org | Committer
 Cody Marcel | Salesforce | codymar...@apache.org | Committer
 Dumindu Buddhika | University of Moratuwa | dumin...@apache.org | Committer
 Jan Fernando | Salesforce | jferna...@apache.org | Committer
-Ankit Singhal | Hortonworks | an...@apache.org | Committer




[7/8] phoenix git commit: PHOENIX-1311 HBase namespaces surfaced in phoenix

2016-04-14 Thread ankit
http://git-wip-us.apache.org/repos/asf/phoenix/blob/70f76539/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
index 4246229..2d79f36 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
@@ -30,6 +30,8 @@ import java.sql.DriverManager;
 import java.sql.ResultSet;
 import java.sql.SQLException;
 import java.sql.Statement;
+import java.util.Arrays;
+import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
@@ -72,19 +74,38 @@ import org.apache.phoenix.util.ByteUtil;
 import org.apache.phoenix.util.MetaDataUtil;
 import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ReadOnlyProps;
+import org.apache.phoenix.util.SchemaUtil;
 import org.apache.phoenix.util.StringUtil;
 import org.apache.phoenix.util.TestUtil;
 import org.junit.BeforeClass;
 import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized;
+import org.junit.runners.Parameterized.Parameters;
 
 import com.google.common.collect.Maps;
 
+@RunWith(Parameterized.class)
 public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 
 private static CountDownLatch latch1 = new CountDownLatch(1);
 private static CountDownLatch latch2 = new CountDownLatch(1);
 private static final int WAIT_TIME_SECONDS = 60;
+private String schemaName="TEST";
+private boolean isNamespaceMapped;
+private String tableName = schemaName + ".T";
+private String indexTableName = schemaName + ".I";
+private String indexName = "I";
+private String indexPhysicalTableName;
+private TableName physicalTableName;
 
+public LocalIndexIT(boolean isNamespaceMapped) {
+this.isNamespaceMapped = isNamespaceMapped;
+this.physicalTableName = 
SchemaUtil.getPhysicalTableName(tableName.getBytes(), isNamespaceMapped);
+this.indexPhysicalTableName = Bytes
+
.toString(MetaDataUtil.getLocalIndexPhysicalName(physicalTableName.getName()));
+}
+
 @BeforeClass 
 @Shadower(classBeingShadowed = BaseHBaseManagedTimeIT.class)
 public static void doSetup() throws Exception {
@@ -96,7 +117,10 @@ public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 }
 
 private void createBaseTable(String tableName, Integer saltBuckets, String 
splits) throws SQLException {
-Connection conn = DriverManager.getConnection(getUrl());
+Connection conn = getConnection();
+if (isNamespaceMapped) {
+conn.createStatement().execute("CREATE SCHEMA IF NOT EXISTS " + 
schemaName);
+}
 String ddl = "CREATE TABLE " + tableName + " (t_id VARCHAR NOT 
NULL,\n" +
 "k1 INTEGER NOT NULL,\n" +
 "k2 INTEGER NOT NULL,\n" +
@@ -108,79 +132,94 @@ public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 conn.createStatement().execute(ddl);
 conn.close();
 }
-
+
+@Parameters(name = "isNamespaceMapped = {0}")
+public static Collection data() {
+return Arrays.asList(true, false);
+}
+
 @Test
 public void testLocalIndexRoundTrip() throws Exception {
-createBaseTable(TestUtil.DEFAULT_DATA_TABLE_NAME, null, null);
+createBaseTable(tableName, null, null);
 Connection conn1 = DriverManager.getConnection(getUrl());
-conn1.createStatement().execute("CREATE LOCAL INDEX " + 
TestUtil.DEFAULT_INDEX_TABLE_NAME + " ON " + TestUtil.DEFAULT_DATA_TABLE_NAME + 
"(v1)");
-conn1.createStatement().executeQuery("SELECT * FROM " + 
TestUtil.DEFAULT_DATA_TABLE_FULL_NAME).next();
-PTable localIndex = conn1.unwrap(PhoenixConnection.class).getTable(new 
PTableKey(null,TestUtil.DEFAULT_INDEX_TABLE_NAME));
+conn1.createStatement().execute("CREATE LOCAL INDEX " + indexName + " 
ON " + tableName + "(v1)");
+conn1.createStatement().executeQuery("SELECT * FROM " + 
tableName).next();
+PTable localIndex = conn1.unwrap(PhoenixConnection.class).getTable(new 
PTableKey(null, indexTableName));
 assertEquals(IndexType.LOCAL, localIndex.getIndexType());
 assertNotNull(localIndex.getViewIndexId());
 }
-
+
 @Test
 public void testLocalIndexCreationWithSplitsShouldFail() throws Exception {
-createBaseTable(TestUtil.DEFAULT_DATA_TABLE_NAME, null, null);
-Connection conn1 = DriverManager.getConnection(getUrl());
-Connection conn2 = DriverManager.getConnection(getUrl());
+createBaseTable(tableName, null, null);
+Connection conn1 = getConnection();
+Connection conn2 = getConnection();
 try {
-

[1/8] phoenix git commit: PHOENIX-1311 HBase namespaces surfaced in phoenix

2016-04-14 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 366e7a779 -> 7e432be79


http://git-wip-us.apache.org/repos/asf/phoenix/blob/7e432be7/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
index 523f684..dbc65d4 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
@@ -41,7 +41,9 @@ import java.util.TreeSet;
 
 import javax.annotation.Nullable;
 
+import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.hbase.KeyValue;
+import org.apache.hadoop.hbase.TableName;
 import org.apache.hadoop.hbase.io.encoding.DataBlockEncoding;
 import org.apache.hadoop.hbase.util.Bytes;
 import org.apache.phoenix.exception.SQLExceptionCode;
@@ -52,14 +54,19 @@ import org.apache.phoenix.jdbc.PhoenixConnection;
 import org.apache.phoenix.jdbc.PhoenixDatabaseMetaData;
 import org.apache.phoenix.query.KeyRange;
 import org.apache.phoenix.query.QueryConstants;
+import org.apache.phoenix.query.QueryServices;
+import org.apache.phoenix.query.QueryServicesOptions;
 import org.apache.phoenix.schema.AmbiguousColumnException;
 import org.apache.phoenix.schema.ColumnFamilyNotFoundException;
 import org.apache.phoenix.schema.ColumnNotFoundException;
+import org.apache.phoenix.schema.MetaDataClient;
 import org.apache.phoenix.schema.PColumn;
 import org.apache.phoenix.schema.PColumnFamily;
 import org.apache.phoenix.schema.PDatum;
 import org.apache.phoenix.schema.PName;
+import org.apache.phoenix.schema.PNameFactory;
 import org.apache.phoenix.schema.PTable;
+import org.apache.phoenix.schema.PTableType;
 import org.apache.phoenix.schema.RowKeySchema;
 import org.apache.phoenix.schema.RowKeySchema.RowKeySchemaBuilder;
 import org.apache.phoenix.schema.SaltingUtil;
@@ -115,6 +122,10 @@ public class SchemaUtil {
 
 };
 public static final RowKeySchema VAR_BINARY_SCHEMA = new 
RowKeySchemaBuilder(1).addField(VAR_BINARY_DATUM, false, 
SortOrder.getDefault()).build();
+public static final String SCHEMA_FOR_DEFAULT_NAMESPACE = "DEFAULT";
+public static final String HBASE_NAMESPACE = "HBASE";
+public static final List NOT_ALLOWED_SCHEMA_LIST = 
Arrays.asList(SCHEMA_FOR_DEFAULT_NAMESPACE,
+HBASE_NAMESPACE);
 
 /**
  * May not be instantiated
@@ -236,6 +247,12 @@ public class SchemaUtil {
 return ByteUtil.concat(tenantId, QueryConstants.SEPARATOR_BYTE_ARRAY, 
functionName);
 }
 
+public static byte[] getKeyForSchema(String tenantId, String schemaName) {
+return ByteUtil.concat(tenantId == null ? ByteUtil.EMPTY_BYTE_ARRAY : 
Bytes.toBytes(tenantId),
+QueryConstants.SEPARATOR_BYTE_ARRAY,
+schemaName == null ? ByteUtil.EMPTY_BYTE_ARRAY : 
Bytes.toBytes(schemaName));
+}
+
 public static byte[] getTableKey(String tenantId, String schemaName, 
String tableName) {
 return ByteUtil.concat(tenantId == null  ? ByteUtil.EMPTY_BYTE_ARRAY : 
Bytes.toBytes(tenantId), QueryConstants.SEPARATOR_BYTE_ARRAY, schemaName == 
null ? ByteUtil.EMPTY_BYTE_ARRAY : Bytes.toBytes(schemaName), 
QueryConstants.SEPARATOR_BYTE_ARRAY, Bytes.toBytes(tableName));
 }
@@ -253,6 +270,11 @@ public class SchemaUtil {
 return cf + QueryConstants.NAME_SEPARATOR + cq;
 }
 
+private static String getName(String name, boolean caseSensitive) {
+String cq = caseSensitive ? "\"" + name + "\"" : name;
+return cq;
+}
+
 public static String getTableName(byte[] schemaName, byte[] tableName) {
 return getName(schemaName, tableName);
 }
@@ -276,9 +298,13 @@ public class SchemaUtil {
 }
 return getName(familyName, columnName, false);
 }
+if ((familyName == null || familyName.isEmpty()) && (columnName == 
null || columnName.isEmpty())
+&& (tableName == null || 
tableName.equals(MetaDataClient.EMPTY_TABLE))) { return getName(schemaName,
+false); }
 if ((familyName == null || familyName.isEmpty()) && (columnName == 
null || columnName.isEmpty())) {
 return getName(schemaName, tableName, false);
 }
+
 return getName(getName(schemaName, tableName, false), 
getName(familyName, columnName, false), false);
 }
 
@@ -414,19 +440,24 @@ public class SchemaUtil {
 }
 
 public static boolean isMetaTable(byte[] tableName) {
-return Bytes.compareTo(tableName, SYSTEM_CATALOG_NAME_BYTES) == 0;
+return Bytes.compareTo(tableName, SYSTEM_CATALOG_NAME_BYTES) == 0 || 
Bytes.compareTo(tableName,
+SchemaUtil.getPhysicalTableName(SYSTEM_CATALOG_NAME_BYTES, 
true).getName()) == 0;
 }
 
 public static boolean 

[7/8] phoenix git commit: PHOENIX-1311 HBase namespaces surfaced in phoenix

2016-04-14 Thread ankit
http://git-wip-us.apache.org/repos/asf/phoenix/blob/7e432be7/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
index 8c804bb..68fcae3 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
@@ -30,6 +30,8 @@ import java.sql.DriverManager;
 import java.sql.ResultSet;
 import java.sql.SQLException;
 import java.sql.Statement;
+import java.util.Arrays;
+import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
@@ -73,19 +75,38 @@ import org.apache.phoenix.util.ByteUtil;
 import org.apache.phoenix.util.MetaDataUtil;
 import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ReadOnlyProps;
+import org.apache.phoenix.util.SchemaUtil;
 import org.apache.phoenix.util.StringUtil;
 import org.apache.phoenix.util.TestUtil;
 import org.junit.BeforeClass;
 import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized;
+import org.junit.runners.Parameterized.Parameters;
 
 import com.google.common.collect.Maps;
 
+@RunWith(Parameterized.class)
 public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 
 private static CountDownLatch latch1 = new CountDownLatch(1);
 private static CountDownLatch latch2 = new CountDownLatch(1);
 private static final int WAIT_TIME_SECONDS = 60;
+private String schemaName="TEST";
+private boolean isNamespaceMapped;
+private String tableName = schemaName + ".T";
+private String indexTableName = schemaName + ".I";
+private String indexName = "I";
+private String indexPhysicalTableName;
+private TableName physicalTableName;
 
+public LocalIndexIT(boolean isNamespaceMapped) {
+this.isNamespaceMapped = isNamespaceMapped;
+this.physicalTableName = 
SchemaUtil.getPhysicalTableName(tableName.getBytes(), isNamespaceMapped);
+this.indexPhysicalTableName = Bytes
+
.toString(MetaDataUtil.getLocalIndexPhysicalName(physicalTableName.getName()));
+}
+
 @BeforeClass 
 @Shadower(classBeingShadowed = BaseHBaseManagedTimeIT.class)
 public static void doSetup() throws Exception {
@@ -97,7 +118,10 @@ public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 }
 
 private void createBaseTable(String tableName, Integer saltBuckets, String 
splits) throws SQLException {
-Connection conn = DriverManager.getConnection(getUrl());
+Connection conn = getConnection();
+if (isNamespaceMapped) {
+conn.createStatement().execute("CREATE SCHEMA IF NOT EXISTS " + 
schemaName);
+}
 String ddl = "CREATE TABLE " + tableName + " (t_id VARCHAR NOT 
NULL,\n" +
 "k1 INTEGER NOT NULL,\n" +
 "k2 INTEGER NOT NULL,\n" +
@@ -109,79 +133,94 @@ public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 conn.createStatement().execute(ddl);
 conn.close();
 }
-
+
+@Parameters(name = "isNamespaceMapped = {0}")
+public static Collection data() {
+return Arrays.asList(true, false);
+}
+
 @Test
 public void testLocalIndexRoundTrip() throws Exception {
-createBaseTable(TestUtil.DEFAULT_DATA_TABLE_NAME, null, null);
+createBaseTable(tableName, null, null);
 Connection conn1 = DriverManager.getConnection(getUrl());
-conn1.createStatement().execute("CREATE LOCAL INDEX " + 
TestUtil.DEFAULT_INDEX_TABLE_NAME + " ON " + TestUtil.DEFAULT_DATA_TABLE_NAME + 
"(v1)");
-conn1.createStatement().executeQuery("SELECT * FROM " + 
TestUtil.DEFAULT_DATA_TABLE_FULL_NAME).next();
-PTable localIndex = conn1.unwrap(PhoenixConnection.class).getTable(new 
PTableKey(null,TestUtil.DEFAULT_INDEX_TABLE_NAME));
+conn1.createStatement().execute("CREATE LOCAL INDEX " + indexName + " 
ON " + tableName + "(v1)");
+conn1.createStatement().executeQuery("SELECT * FROM " + 
tableName).next();
+PTable localIndex = conn1.unwrap(PhoenixConnection.class).getTable(new 
PTableKey(null, indexTableName));
 assertEquals(IndexType.LOCAL, localIndex.getIndexType());
 assertNotNull(localIndex.getViewIndexId());
 }
-
+
 @Test
 public void testLocalIndexCreationWithSplitsShouldFail() throws Exception {
-createBaseTable(TestUtil.DEFAULT_DATA_TABLE_NAME, null, null);
-Connection conn1 = DriverManager.getConnection(getUrl());
-Connection conn2 = DriverManager.getConnection(getUrl());
+createBaseTable(tableName, null, null);
+Connection conn1 = getConnection();
+Connection conn2 = getConnection();
 try {
-

[6/8] phoenix git commit: PHOENIX-1311 HBase namespaces surfaced in phoenix

2016-04-14 Thread ankit
http://git-wip-us.apache.org/repos/asf/phoenix/blob/7e432be7/phoenix-core/src/main/java/org/apache/phoenix/compile/CreateSchemaCompiler.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/compile/CreateSchemaCompiler.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/compile/CreateSchemaCompiler.java
new file mode 100644
index 000..40d1fee
--- /dev/null
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/compile/CreateSchemaCompiler.java
@@ -0,0 +1,65 @@
+/*
+ * 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.
+ */
+package org.apache.phoenix.compile;
+
+import java.sql.SQLException;
+import java.util.Collections;
+
+import org.apache.phoenix.execute.MutationState;
+import org.apache.phoenix.jdbc.PhoenixConnection;
+import org.apache.phoenix.jdbc.PhoenixStatement;
+import org.apache.phoenix.parse.CreateSchemaStatement;
+import org.apache.phoenix.schema.MetaDataClient;
+
+public class CreateSchemaCompiler {
+private final PhoenixStatement statement;
+
+public CreateSchemaCompiler(PhoenixStatement statement) {
+this.statement = statement;
+}
+
+public MutationPlan compile(final CreateSchemaStatement create) throws 
SQLException {
+final PhoenixConnection connection = statement.getConnection();
+final StatementContext context = new StatementContext(statement);
+final MetaDataClient client = new MetaDataClient(connection);
+
+return new BaseMutationPlan(context, create.getOperation()) {
+
+@Override
+public MutationState execute() throws SQLException {
+try {
+return client.createSchema(create);
+} finally {
+if (client.getConnection() != connection) {
+client.getConnection().close();
+}
+}
+}
+
+@Override
+public ExplainPlan getExplainPlan() throws SQLException {
+return new ExplainPlan(Collections.singletonList("CREATE 
SCHEMA"));
+}
+
+@Override
+public StatementContext getContext() {
+return context;
+}
+};
+}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/phoenix/blob/7e432be7/phoenix-core/src/main/java/org/apache/phoenix/compile/FromCompiler.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/compile/FromCompiler.java 
b/phoenix-core/src/main/java/org/apache/phoenix/compile/FromCompiler.java
index ffe9621..a2fc371 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/compile/FromCompiler.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/compile/FromCompiler.java
@@ -42,6 +42,7 @@ import org.apache.phoenix.parse.FamilyWildcardParseNode;
 import org.apache.phoenix.parse.JoinTableNode;
 import org.apache.phoenix.parse.NamedTableNode;
 import org.apache.phoenix.parse.PFunction;
+import org.apache.phoenix.parse.PSchema;
 import org.apache.phoenix.parse.ParseNode;
 import org.apache.phoenix.parse.ParseNodeFactory;
 import org.apache.phoenix.parse.SelectStatement;
@@ -51,6 +52,7 @@ import org.apache.phoenix.parse.TableNode;
 import org.apache.phoenix.parse.TableNodeVisitor;
 import org.apache.phoenix.parse.TableWildcardParseNode;
 import org.apache.phoenix.parse.UDFParseNode;
+import org.apache.phoenix.parse.UseSchemaStatement;
 import org.apache.phoenix.parse.WildcardParseNode;
 import org.apache.phoenix.query.ConnectionQueryServices;
 import org.apache.phoenix.query.QueryConstants;
@@ -73,6 +75,7 @@ import org.apache.phoenix.schema.PTableImpl;
 import org.apache.phoenix.schema.PTableKey;
 import org.apache.phoenix.schema.PTableType;
 import org.apache.phoenix.schema.ProjectedColumn;
+import org.apache.phoenix.schema.SchemaNotFoundException;
 import org.apache.phoenix.schema.SortOrder;
 import org.apache.phoenix.schema.TableNotFoundException;
 import org.apache.phoenix.schema.TableRef;
@@ -124,17 +127,36 @@ public class FromCompiler {
 
 public PFunction resolveFunction(String functionName) throws 

[8/8] phoenix git commit: PHOENIX-1311 HBase namespaces surfaced in phoenix

2016-04-14 Thread ankit
PHOENIX-1311 HBase namespaces surfaced in phoenix


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

Branch: refs/heads/master
Commit: de9a2c7b0249cd5a1a75374aa5244d5ee076f3c1
Parents: 0490484
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu Apr 14 15:11:03 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu Apr 14 15:11:03 2016 +0530

--
 .../apache/phoenix/end2end/CreateSchemaIT.java  |   83 +
 .../apache/phoenix/end2end/CreateTableIT.java   |   70 +-
 .../apache/phoenix/end2end/DropSchemaIT.java|  110 +
 .../end2end/NamespaceSchemaMappingIT.java   |  115 +
 .../phoenix/end2end/PhoenixRuntimeIT.java   |2 +-
 .../end2end/QueryDatabaseMetaDataIT.java|   12 +-
 .../org/apache/phoenix/end2end/UpgradeIT.java   |   87 +
 .../org/apache/phoenix/end2end/UseSchemaIT.java |  133 +
 .../java/org/apache/phoenix/end2end/ViewIT.java |   31 +-
 .../phoenix/end2end/index/LocalIndexIT.java |  450 +-
 .../end2end/index/MutableIndexFailureIT.java|   48 +-
 .../phoenix/end2end/index/ViewIndexIT.java  |   57 +-
 .../org/apache/phoenix/tx/TxCheckpointIT.java   |5 +-
 phoenix-core/src/main/antlr3/PhoenixSQL.g   |   22 +
 .../ipc/controller/MetadataRpcController.java   |   12 +-
 .../apache/phoenix/compile/ColumnResolver.java  |   10 +
 .../phoenix/compile/CreateSchemaCompiler.java   |   65 +
 .../apache/phoenix/compile/FromCompiler.java|  166 +-
 .../apache/phoenix/compile/JoinCompiler.java|   11 +-
 .../apache/phoenix/compile/PostDDLCompiler.java |   24 +-
 .../compile/TupleProjectionCompiler.java|   24 +-
 .../apache/phoenix/compile/UnionCompiler.java   |   11 +-
 .../coprocessor/MetaDataEndpointImpl.java   |  360 +-
 .../phoenix/coprocessor/MetaDataProtocol.java   |   28 +-
 .../coprocessor/generated/MetaDataProtos.java   | 4211 +++---
 .../coprocessor/generated/PSchemaProtos.java|  666 +++
 .../coprocessor/generated/PTableProtos.java |  104 +-
 .../phoenix/exception/SQLExceptionCode.java |   21 +-
 .../hbase/index/master/IndexMasterObserver.java |8 +-
 .../write/ParallelWriterIndexCommitter.java |2 +-
 .../TrackingParallelWriterIndexCommitter.java   |2 +-
 .../index/PhoenixIndexFailurePolicy.java|8 +-
 .../phoenix/iterate/ChunkedResultIterator.java  |6 +-
 .../phoenix/iterate/ParallelIterators.java  |2 +-
 .../apache/phoenix/iterate/SerialIterators.java |2 +-
 .../apache/phoenix/jdbc/PhoenixConnection.java  |   51 +-
 .../phoenix/jdbc/PhoenixDatabaseMetaData.java   |8 +-
 .../apache/phoenix/jdbc/PhoenixStatement.java   |   88 +-
 .../phoenix/mapreduce/AbstractBulkLoadTool.java |   15 +-
 .../phoenix/mapreduce/CsvBulkImportUtil.java|7 +
 .../mapreduce/MultiHfileOutputFormat.java   |4 +-
 .../phoenix/mapreduce/index/IndexTool.java  |   15 +-
 .../phoenix/parse/CreateSchemaStatement.java|   25 +
 .../phoenix/parse/DropSchemaStatement.java  |   38 +
 .../java/org/apache/phoenix/parse/PSchema.java  |   86 +
 .../apache/phoenix/parse/ParseNodeFactory.java  |   12 +
 .../phoenix/parse/UseSchemaStatement.java   |   19 +
 .../apache/phoenix/protobuf/ProtobufUtil.java   |   16 +-
 .../phoenix/query/ConnectionQueryServices.java  |   16 +-
 .../query/ConnectionQueryServicesImpl.java  |  378 +-
 .../query/ConnectionlessQueryServicesImpl.java  |   43 +-
 .../query/DelegateConnectionQueryServices.java  |   43 +-
 .../apache/phoenix/query/MetaDataMutated.java   |5 +-
 .../apache/phoenix/query/QueryConstants.java|7 +
 .../org/apache/phoenix/query/QueryServices.java |4 +
 .../phoenix/query/QueryServicesOptions.java |   11 +-
 .../apache/phoenix/schema/DelegateTable.java|5 +
 .../apache/phoenix/schema/MetaDataClient.java   |  204 +-
 .../NewerSchemaAlreadyExistsException.java  |   26 +
 .../org/apache/phoenix/schema/PMetaData.java|2 +
 .../apache/phoenix/schema/PMetaDataImpl.java|   51 +-
 .../java/org/apache/phoenix/schema/PTable.java  |6 +
 .../org/apache/phoenix/schema/PTableImpl.java   |   58 +-
 .../org/apache/phoenix/schema/PTableKey.java|2 +
 .../schema/SchemaAlreadyExistsException.java|   53 +
 .../phoenix/schema/SchemaNotFoundException.java |   52 +
 .../stats/StatisticsCollectorFactory.java   |5 +
 .../phoenix/schema/stats/StatisticsWriter.java  |6 +-
 .../java/org/apache/phoenix/util/IndexUtil.java |2 +-
 .../java/org/apache/phoenix/util/JDBCUtil.java  |5 +
 .../org/apache/phoenix/util/MetaDataUtil.java   |  106 +-
 .../org/apache/phoenix/util/PhoenixRuntime.java |   79 +-
 .../org/apache/phoenix/util/SchemaUtil.java |  141 +-
 .../org/apache/

[7/8] phoenix git commit: PHOENIX-1311 HBase namespaces surfaced in phoenix

2016-04-14 Thread ankit
http://git-wip-us.apache.org/repos/asf/phoenix/blob/de9a2c7b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
index 4246229..2d79f36 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/LocalIndexIT.java
@@ -30,6 +30,8 @@ import java.sql.DriverManager;
 import java.sql.ResultSet;
 import java.sql.SQLException;
 import java.sql.Statement;
+import java.util.Arrays;
+import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
@@ -72,19 +74,38 @@ import org.apache.phoenix.util.ByteUtil;
 import org.apache.phoenix.util.MetaDataUtil;
 import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ReadOnlyProps;
+import org.apache.phoenix.util.SchemaUtil;
 import org.apache.phoenix.util.StringUtil;
 import org.apache.phoenix.util.TestUtil;
 import org.junit.BeforeClass;
 import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized;
+import org.junit.runners.Parameterized.Parameters;
 
 import com.google.common.collect.Maps;
 
+@RunWith(Parameterized.class)
 public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 
 private static CountDownLatch latch1 = new CountDownLatch(1);
 private static CountDownLatch latch2 = new CountDownLatch(1);
 private static final int WAIT_TIME_SECONDS = 60;
+private String schemaName="TEST";
+private boolean isNamespaceMapped;
+private String tableName = schemaName + ".T";
+private String indexTableName = schemaName + ".I";
+private String indexName = "I";
+private String indexPhysicalTableName;
+private TableName physicalTableName;
 
+public LocalIndexIT(boolean isNamespaceMapped) {
+this.isNamespaceMapped = isNamespaceMapped;
+this.physicalTableName = 
SchemaUtil.getPhysicalTableName(tableName.getBytes(), isNamespaceMapped);
+this.indexPhysicalTableName = Bytes
+
.toString(MetaDataUtil.getLocalIndexPhysicalName(physicalTableName.getName()));
+}
+
 @BeforeClass 
 @Shadower(classBeingShadowed = BaseHBaseManagedTimeIT.class)
 public static void doSetup() throws Exception {
@@ -96,7 +117,10 @@ public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 }
 
 private void createBaseTable(String tableName, Integer saltBuckets, String 
splits) throws SQLException {
-Connection conn = DriverManager.getConnection(getUrl());
+Connection conn = getConnection();
+if (isNamespaceMapped) {
+conn.createStatement().execute("CREATE SCHEMA IF NOT EXISTS " + 
schemaName);
+}
 String ddl = "CREATE TABLE " + tableName + " (t_id VARCHAR NOT 
NULL,\n" +
 "k1 INTEGER NOT NULL,\n" +
 "k2 INTEGER NOT NULL,\n" +
@@ -108,79 +132,94 @@ public class LocalIndexIT extends BaseHBaseManagedTimeIT {
 conn.createStatement().execute(ddl);
 conn.close();
 }
-
+
+@Parameters(name = "isNamespaceMapped = {0}")
+public static Collection data() {
+return Arrays.asList(true, false);
+}
+
 @Test
 public void testLocalIndexRoundTrip() throws Exception {
-createBaseTable(TestUtil.DEFAULT_DATA_TABLE_NAME, null, null);
+createBaseTable(tableName, null, null);
 Connection conn1 = DriverManager.getConnection(getUrl());
-conn1.createStatement().execute("CREATE LOCAL INDEX " + 
TestUtil.DEFAULT_INDEX_TABLE_NAME + " ON " + TestUtil.DEFAULT_DATA_TABLE_NAME + 
"(v1)");
-conn1.createStatement().executeQuery("SELECT * FROM " + 
TestUtil.DEFAULT_DATA_TABLE_FULL_NAME).next();
-PTable localIndex = conn1.unwrap(PhoenixConnection.class).getTable(new 
PTableKey(null,TestUtil.DEFAULT_INDEX_TABLE_NAME));
+conn1.createStatement().execute("CREATE LOCAL INDEX " + indexName + " 
ON " + tableName + "(v1)");
+conn1.createStatement().executeQuery("SELECT * FROM " + 
tableName).next();
+PTable localIndex = conn1.unwrap(PhoenixConnection.class).getTable(new 
PTableKey(null, indexTableName));
 assertEquals(IndexType.LOCAL, localIndex.getIndexType());
 assertNotNull(localIndex.getViewIndexId());
 }
-
+
 @Test
 public void testLocalIndexCreationWithSplitsShouldFail() throws Exception {
-createBaseTable(TestUtil.DEFAULT_DATA_TABLE_NAME, null, null);
-Connection conn1 = DriverManager.getConnection(getUrl());
-Connection conn2 = DriverManager.getConnection(getUrl());
+createBaseTable(tableName, null, null);
+Connection conn1 = getConnection();
+Connection conn2 = getConnection();
 try {
-

[4/8] phoenix git commit: PHOENIX-1311 HBase namespaces surfaced in phoenix

2016-04-14 Thread ankit
http://git-wip-us.apache.org/repos/asf/phoenix/blob/de9a2c7b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/generated/PSchemaProtos.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/generated/PSchemaProtos.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/generated/PSchemaProtos.java
new file mode 100644
index 000..d7dc720
--- /dev/null
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/generated/PSchemaProtos.java
@@ -0,0 +1,666 @@
+// Generated by the protocol buffer compiler.  DO NOT EDIT!
+// source: PSchema.proto
+
+package org.apache.phoenix.coprocessor.generated;
+
+public final class PSchemaProtos {
+  private PSchemaProtos() {}
+  public static void registerAllExtensions(
+  com.google.protobuf.ExtensionRegistry registry) {
+  }
+  public interface PSchemaOrBuilder
+  extends com.google.protobuf.MessageOrBuilder {
+
+// required string schemaName = 1;
+/**
+ * required string schemaName = 1;
+ */
+boolean hasSchemaName();
+/**
+ * required string schemaName = 1;
+ */
+java.lang.String getSchemaName();
+/**
+ * required string schemaName = 1;
+ */
+com.google.protobuf.ByteString
+getSchemaNameBytes();
+
+// required int64 timeStamp = 2;
+/**
+ * required int64 timeStamp = 2;
+ */
+boolean hasTimeStamp();
+/**
+ * required int64 timeStamp = 2;
+ */
+long getTimeStamp();
+  }
+  /**
+   * Protobuf type {@code PSchema}
+   */
+  public static final class PSchema extends
+  com.google.protobuf.GeneratedMessage
+  implements PSchemaOrBuilder {
+// Use PSchema.newBuilder() to construct.
+private PSchema(com.google.protobuf.GeneratedMessage.Builder builder) {
+  super(builder);
+  this.unknownFields = builder.getUnknownFields();
+}
+private PSchema(boolean noInit) { this.unknownFields = 
com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }
+
+private static final PSchema defaultInstance;
+public static PSchema getDefaultInstance() {
+  return defaultInstance;
+}
+
+public PSchema getDefaultInstanceForType() {
+  return defaultInstance;
+}
+
+private final com.google.protobuf.UnknownFieldSet unknownFields;
+@java.lang.Override
+public final com.google.protobuf.UnknownFieldSet
+getUnknownFields() {
+  return this.unknownFields;
+}
+private PSchema(
+com.google.protobuf.CodedInputStream input,
+com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+throws com.google.protobuf.InvalidProtocolBufferException {
+  initFields();
+  int mutable_bitField0_ = 0;
+  com.google.protobuf.UnknownFieldSet.Builder unknownFields =
+  com.google.protobuf.UnknownFieldSet.newBuilder();
+  try {
+boolean done = false;
+while (!done) {
+  int tag = input.readTag();
+  switch (tag) {
+case 0:
+  done = true;
+  break;
+default: {
+  if (!parseUnknownField(input, unknownFields,
+ extensionRegistry, tag)) {
+done = true;
+  }
+  break;
+}
+case 10: {
+  bitField0_ |= 0x0001;
+  schemaName_ = input.readBytes();
+  break;
+}
+case 16: {
+  bitField0_ |= 0x0002;
+  timeStamp_ = input.readInt64();
+  break;
+}
+  }
+}
+  } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+throw e.setUnfinishedMessage(this);
+  } catch (java.io.IOException e) {
+throw new com.google.protobuf.InvalidProtocolBufferException(
+e.getMessage()).setUnfinishedMessage(this);
+  } finally {
+this.unknownFields = unknownFields.build();
+makeExtensionsImmutable();
+  }
+}
+public static final com.google.protobuf.Descriptors.Descriptor
+getDescriptor() {
+  return 
org.apache.phoenix.coprocessor.generated.PSchemaProtos.internal_static_PSchema_descriptor;
+}
+
+protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+internalGetFieldAccessorTable() {
+  return 
org.apache.phoenix.coprocessor.generated.PSchemaProtos.internal_static_PSchema_fieldAccessorTable
+  .ensureFieldAccessorsInitialized(
+  
org.apache.phoenix.coprocessor.generated.PSchemaProtos.PSchema.class, 
org.apache.phoenix.coprocessor.generated.PSchemaProtos.PSchema.Builder.class);
+}
+
+public static com.google.protobuf.Parser PARSER =
+new com.google.protobuf.AbstractParser() {
+  public PSchema parsePartialFrom(
+  com.google.protobuf.CodedInputStream input,
+  com.google.protobuf.ExtensionRegistryLite 

svn commit: r1740762 - /phoenix/site/publish/team.html

2016-04-24 Thread ankit
Author: ankit
Date: Mon Apr 25 05:58:51 2016
New Revision: 1740762

URL: http://svn.apache.org/viewvc?rev=1740762=rev
Log:
Added Ankit Singhal as a PMC

Modified:
phoenix/site/publish/team.html

Modified: phoenix/site/publish/team.html
URL: 
http://svn.apache.org/viewvc/phoenix/site/publish/team.html?rev=1740762=1740761=1740762=diff
==
--- phoenix/site/publish/team.html (original)
+++ phoenix/site/publish/team.html Mon Apr 25 05:58:51 2016
@@ -1,7 +1,7 @@
 
 
 
 
@@ -47,7 +47,7 @@



-   
+   
About 

Overview
@@ -62,12 +62,12 @@
Issue Tracking
Download
Installation
-   
+   
How to Contribute
How to Develop
How to Update 
Website
How to Release
-   
+   
http://www.apache.org/licenses/; title="License" 
class="externalLink">License


@@ -81,7 +81,7 @@
Backward 
Compatibility
Release Notes
Performance Testing
-   
+   
Apache Spark 
Integration
Apache Pig 
Integration
Map Reduce 
Integration
@@ -93,17 +93,17 @@

Transactions
User-defined Functions
-   
+   
Secondary 
Indexes
Statistics 
Collection
Row Timestamp 
Column
Salted Tables
Skip Scan
-   
+   
Views
Multi tenancy
Dynamic Columns
-   
+   
Bulk Loading
Query Server
Tracing
@@ -117,7 +117,7 @@
Functions
Datatypes
   

phoenix git commit: Some phoenix-spark IT tests are broken after PHOENIX-2862

2016-05-20 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master 01405d5d6 -> b20cb245a


Some phoenix-spark IT tests are broken after PHOENIX-2862


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

Branch: refs/heads/master
Commit: b20cb245a4c3a7994eb3562a7855c9464f84f40d
Parents: 01405d5
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Sat May 21 09:43:19 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Sat May 21 09:43:19 2016 +0530

--
 .../main/java/org/apache/phoenix/mapreduce/index/IndexTool.java  | 2 +-
 .../src/main/java/org/apache/phoenix/util/SchemaUtil.java| 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/b20cb245/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java 
b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
index 34694c6..6743688 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
@@ -358,7 +358,7 @@ public class IndexTool extends Configured implements Tool {
 final String indexTable) throws SQLException {
 final DatabaseMetaData dbMetaData = connection.getMetaData();
 final String schemaName = 
SchemaUtil.getSchemaNameFromFullName(masterTable);
-final String tableName = 
SchemaUtil.getTableNameFromFullName(masterTable);
+final String tableName = 
SchemaUtil.normalizeIdentifier(SchemaUtil.getTableNameFromFullName(masterTable));
 
 ResultSet rs = null;
 try {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/b20cb245/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
index cb1ef47..41e5704 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
@@ -641,7 +641,7 @@ public class SchemaUtil {
 if (tableName == null) {
 return null;
 }
-if (isExistingTableMappedToPhoenixName(Bytes.toString(tableName))) { 
return normalizeIdentifier(Bytes.toString(tableName)); }
+if (isExistingTableMappedToPhoenixName(Bytes.toString(tableName))) { 
return Bytes.toString(tableName); }
 int index = indexOf(tableName, QueryConstants.NAME_SEPARATOR_BYTE);
 if (index < 0) {
 index = indexOf(tableName, 
QueryConstants.NAMESPACE_SEPARATOR_BYTE);
@@ -651,7 +651,7 @@ public class SchemaUtil {
 }
 
 public static String getTableNameFromFullName(String tableName) {
-if (isExistingTableMappedToPhoenixName(tableName)) { return 
normalizeIdentifier(tableName); }
+if (isExistingTableMappedToPhoenixName(tableName)) { return tableName; 
}
 if (tableName.contains(QueryConstants.NAMESPACE_SEPARATOR)) { return 
getTableNameFromFullName(tableName,
 QueryConstants.NAMESPACE_SEPARATOR); }
 return getTableNameFromFullName(tableName, 
QueryConstants.NAME_SEPARATOR);



phoenix git commit: Some phoenix-spark IT tests are broken after PHOENIX-2862

2016-05-20 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 626c26ac7 -> e3807d29c


Some phoenix-spark IT tests are broken after PHOENIX-2862


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

Branch: refs/heads/4.x-HBase-1.1
Commit: e3807d29c0f585e5a5326dfcf70ed6bc21347fbd
Parents: 626c26a
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Sat May 21 09:45:14 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Sat May 21 09:45:14 2016 +0530

--
 .../main/java/org/apache/phoenix/mapreduce/index/IndexTool.java  | 2 +-
 .../src/main/java/org/apache/phoenix/util/SchemaUtil.java| 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/e3807d29/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java 
b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
index 34694c6..6743688 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
@@ -358,7 +358,7 @@ public class IndexTool extends Configured implements Tool {
 final String indexTable) throws SQLException {
 final DatabaseMetaData dbMetaData = connection.getMetaData();
 final String schemaName = 
SchemaUtil.getSchemaNameFromFullName(masterTable);
-final String tableName = 
SchemaUtil.getTableNameFromFullName(masterTable);
+final String tableName = 
SchemaUtil.normalizeIdentifier(SchemaUtil.getTableNameFromFullName(masterTable));
 
 ResultSet rs = null;
 try {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/e3807d29/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
index cb1ef47..41e5704 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
@@ -641,7 +641,7 @@ public class SchemaUtil {
 if (tableName == null) {
 return null;
 }
-if (isExistingTableMappedToPhoenixName(Bytes.toString(tableName))) { 
return normalizeIdentifier(Bytes.toString(tableName)); }
+if (isExistingTableMappedToPhoenixName(Bytes.toString(tableName))) { 
return Bytes.toString(tableName); }
 int index = indexOf(tableName, QueryConstants.NAME_SEPARATOR_BYTE);
 if (index < 0) {
 index = indexOf(tableName, 
QueryConstants.NAMESPACE_SEPARATOR_BYTE);
@@ -651,7 +651,7 @@ public class SchemaUtil {
 }
 
 public static String getTableNameFromFullName(String tableName) {
-if (isExistingTableMappedToPhoenixName(tableName)) { return 
normalizeIdentifier(tableName); }
+if (isExistingTableMappedToPhoenixName(tableName)) { return tableName; 
}
 if (tableName.contains(QueryConstants.NAMESPACE_SEPARATOR)) { return 
getTableNameFromFullName(tableName,
 QueryConstants.NAMESPACE_SEPARATOR); }
 return getTableNameFromFullName(tableName, 
QueryConstants.NAME_SEPARATOR);



phoenix git commit: Some phoenix-spark IT tests are broken after PHOENIX-2862

2016-05-20 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 a05137b2f -> 0785d3d18


Some phoenix-spark IT tests are broken after PHOENIX-2862


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/0785d3d1
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/0785d3d1
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/0785d3d1

Branch: refs/heads/4.x-HBase-1.0
Commit: 0785d3d1899b7fc4fc4f8c65138ecf5a415f84a7
Parents: a05137b
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Sat May 21 09:44:42 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Sat May 21 09:44:42 2016 +0530

--
 .../main/java/org/apache/phoenix/mapreduce/index/IndexTool.java  | 2 +-
 .../src/main/java/org/apache/phoenix/util/SchemaUtil.java| 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/0785d3d1/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java 
b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
index 34694c6..6743688 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
@@ -358,7 +358,7 @@ public class IndexTool extends Configured implements Tool {
 final String indexTable) throws SQLException {
 final DatabaseMetaData dbMetaData = connection.getMetaData();
 final String schemaName = 
SchemaUtil.getSchemaNameFromFullName(masterTable);
-final String tableName = 
SchemaUtil.getTableNameFromFullName(masterTable);
+final String tableName = 
SchemaUtil.normalizeIdentifier(SchemaUtil.getTableNameFromFullName(masterTable));
 
 ResultSet rs = null;
 try {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/0785d3d1/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
index cb1ef47..41e5704 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
@@ -641,7 +641,7 @@ public class SchemaUtil {
 if (tableName == null) {
 return null;
 }
-if (isExistingTableMappedToPhoenixName(Bytes.toString(tableName))) { 
return normalizeIdentifier(Bytes.toString(tableName)); }
+if (isExistingTableMappedToPhoenixName(Bytes.toString(tableName))) { 
return Bytes.toString(tableName); }
 int index = indexOf(tableName, QueryConstants.NAME_SEPARATOR_BYTE);
 if (index < 0) {
 index = indexOf(tableName, 
QueryConstants.NAMESPACE_SEPARATOR_BYTE);
@@ -651,7 +651,7 @@ public class SchemaUtil {
 }
 
 public static String getTableNameFromFullName(String tableName) {
-if (isExistingTableMappedToPhoenixName(tableName)) { return 
normalizeIdentifier(tableName); }
+if (isExistingTableMappedToPhoenixName(tableName)) { return tableName; 
}
 if (tableName.contains(QueryConstants.NAMESPACE_SEPARATOR)) { return 
getTableNameFromFullName(tableName,
 QueryConstants.NAMESPACE_SEPARATOR); }
 return getTableNameFromFullName(tableName, 
QueryConstants.NAME_SEPARATOR);



phoenix git commit: Some phoenix-spark IT tests are broken after PHOENIX-2862

2016-05-20 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 7cbb2b9ea -> eb93526ce


Some phoenix-spark IT tests are broken after PHOENIX-2862


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

Branch: refs/heads/4.x-HBase-0.98
Commit: eb93526ce009c677c0e75e7a88cde4ee00bb2cd0
Parents: 7cbb2b9
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Sat May 21 09:44:16 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Sat May 21 09:44:16 2016 +0530

--
 .../main/java/org/apache/phoenix/mapreduce/index/IndexTool.java  | 2 +-
 .../src/main/java/org/apache/phoenix/util/SchemaUtil.java| 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/eb93526c/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java 
b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
index 34694c6..6743688 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/mapreduce/index/IndexTool.java
@@ -358,7 +358,7 @@ public class IndexTool extends Configured implements Tool {
 final String indexTable) throws SQLException {
 final DatabaseMetaData dbMetaData = connection.getMetaData();
 final String schemaName = 
SchemaUtil.getSchemaNameFromFullName(masterTable);
-final String tableName = 
SchemaUtil.getTableNameFromFullName(masterTable);
+final String tableName = 
SchemaUtil.normalizeIdentifier(SchemaUtil.getTableNameFromFullName(masterTable));
 
 ResultSet rs = null;
 try {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/eb93526c/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
index cb1ef47..41e5704 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/SchemaUtil.java
@@ -641,7 +641,7 @@ public class SchemaUtil {
 if (tableName == null) {
 return null;
 }
-if (isExistingTableMappedToPhoenixName(Bytes.toString(tableName))) { 
return normalizeIdentifier(Bytes.toString(tableName)); }
+if (isExistingTableMappedToPhoenixName(Bytes.toString(tableName))) { 
return Bytes.toString(tableName); }
 int index = indexOf(tableName, QueryConstants.NAME_SEPARATOR_BYTE);
 if (index < 0) {
 index = indexOf(tableName, 
QueryConstants.NAMESPACE_SEPARATOR_BYTE);
@@ -651,7 +651,7 @@ public class SchemaUtil {
 }
 
 public static String getTableNameFromFullName(String tableName) {
-if (isExistingTableMappedToPhoenixName(tableName)) { return 
normalizeIdentifier(tableName); }
+if (isExistingTableMappedToPhoenixName(tableName)) { return tableName; 
}
 if (tableName.contains(QueryConstants.NAMESPACE_SEPARATOR)) { return 
getTableNameFromFullName(tableName,
 QueryConstants.NAMESPACE_SEPARATOR); }
 return getTableNameFromFullName(tableName, 
QueryConstants.NAME_SEPARATOR);



[2/3] phoenix git commit: PHOENIX-2862 Do client server compatibility checks before upgrading system tables

2016-05-16 Thread ankit
PHOENIX-2862 Do client server compatibility checks before upgrading system 
tables


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/20ce95b0
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/20ce95b0
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/20ce95b0

Branch: refs/heads/master
Commit: 20ce95b0c09d7aaa394f2e703f6b1e193141ad33
Parents: 33fb201
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:16:47 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:16:47 2016 +0530

--
 .../end2end/QueryDatabaseMetaDataIT.java|  1 +
 .../org/apache/phoenix/end2end/UpgradeIT.java   |  4 +-
 .../apache/phoenix/compile/FromCompiler.java|  3 +
 .../coprocessor/MetaDataEndpointImpl.java   | 30 ---
 .../coprocessor/MetaDataRegionObserver.java |  9 +-
 .../phoenix/exception/SQLExceptionCode.java |  8 +-
 .../phoenix/jdbc/PhoenixDatabaseMetaData.java   |  4 +-
 .../query/ConnectionQueryServicesImpl.java  | 86 ++--
 .../org/apache/phoenix/query/QueryServices.java |  4 +-
 .../phoenix/query/QueryServicesOptions.java |  2 +-
 .../org/apache/phoenix/util/MetaDataUtil.java   | 46 ---
 .../org/apache/phoenix/util/SchemaUtil.java | 15 +++-
 .../org/apache/phoenix/util/UpgradeUtil.java| 48 ++-
 .../apache/phoenix/util/MetaDataUtilTest.java   | 36 
 14 files changed, 216 insertions(+), 80 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/20ce95b0/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
index 1d0f767..fbea0f0 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
@@ -147,6 +147,7 @@ public class QueryDatabaseMetaDataIT extends 
BaseClientManagedTimeIT {
 assertEquals(CUSTOM_ENTITY_DATA_NAME, rs.getString("TABLE_NAME"));
 assertEquals(PTableType.TABLE.toString(), rs.getString("TABLE_TYPE"));
 assertEquals("false", 
rs.getString(PhoenixDatabaseMetaData.TRANSACTIONAL));
+assertEquals(Boolean.FALSE, 
rs.getBoolean(PhoenixDatabaseMetaData.IS_NAMESPACE_MAPPED));
 
 rs = dbmd.getTables(null, CUSTOM_ENTITY_DATA_SCHEMA_NAME, 
CUSTOM_ENTITY_DATA_NAME, null);
 assertTrue(rs.next());

http://git-wip-us.apache.org/repos/asf/phoenix/blob/20ce95b0/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
--
diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
index 1c86039..37d285f 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
@@ -129,7 +129,7 @@ public class UpgradeIT extends BaseHBaseManagedTimeIT {
 String indexName = "IDX";
 String localIndexName = "LIDX";
 String[] tableNames = new String[] { phoenixFullTableName, 
schemaName + "." + indexName,
-schemaName + "." + localIndexName, "diff.v", "test.v" };
+schemaName + "." + localIndexName, "diff.v", "test.v","v"};
 conn.createStatement().execute("CREATE TABLE " + 
phoenixFullTableName
 + "(k VARCHAR PRIMARY KEY, v INTEGER, f INTEGER, g INTEGER 
NULL, h INTEGER NULL)");
 PreparedStatement upsertStmt = conn
@@ -150,6 +150,7 @@ public class UpgradeIT extends BaseHBaseManagedTimeIT {
 conn.createStatement().execute("CREATE VIEW diff.v (col VARCHAR) 
AS SELECT * FROM " + phoenixFullTableName);
 // creating view in schema 'test'
 conn.createStatement().execute("CREATE VIEW test.v (col VARCHAR) 
AS SELECT * FROM " + phoenixFullTableName);
+conn.createStatement().execute("CREATE VIEW v (col VARCHAR) AS 
SELECT * FROM " + phoenixFullTableName);
 // Creating index on views
 conn.createStatement().execute("create index v_idx on 
diff.v(col)");
 conn.createStatement().execute("create index v_idx on 
test.v(col)");
@@ -170,6 +171,7 @@ public class UpgradeIT extends BaseHBaseManag

[3/3] phoenix git commit: PHOENIX-2887 Uberjar application fail with 'IllegalAccessError: class com.google.protobuf.ZeroCopyLiteralByteString cannot access its superclass com.google.protobuf.LiteralBy

2016-05-16 Thread ankit
PHOENIX-2887 Uberjar application fail with 'IllegalAccessError: class 
com.google.protobuf.ZeroCopyLiteralByteString cannot access its superclass 
com.google.protobuf.LiteralByteString'


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/5d641ad3
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/5d641ad3
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/5d641ad3

Branch: refs/heads/master
Commit: 5d641ad34207b8e87b1f460a168664387f143286
Parents: 20ce95b
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:17:05 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:17:05 2016 +0530

--
 dev/test-patch.properties   |  1 +
 dev/test-patch.sh   | 32 
 .../apache/phoenix/cache/ServerCacheClient.java |  3 +-
 .../org/apache/phoenix/schema/PTableImpl.java   |  8 ++---
 4 files changed, 37 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/5d641ad3/dev/test-patch.properties
--
diff --git a/dev/test-patch.properties b/dev/test-patch.properties
index 53f2ad4..8d1e2ed 100644
--- a/dev/test-patch.properties
+++ b/dev/test-patch.properties
@@ -33,3 +33,4 @@ BRANCH_NAMES="4.4-HBase-0.98 4.4-HBase-1.0 4.4-HBase-1.1 
4.x-HBase-0.98 4.x-HBas
 # All supported Hadoop versions that we want to test the compilation with
 HADOOP2_VERSIONS="2.4.1 2.5.2 2.6.0"
 HADOOP3_VERSIONS="3.0.0-SNAPSHOT"
+INCOMPATIBLE_CLASSES="com.google.protobuf.HBaseZeroCopyByteString"

http://git-wip-us.apache.org/repos/asf/phoenix/blob/5d641ad3/dev/test-patch.sh
--
diff --git a/dev/test-patch.sh b/dev/test-patch.sh
index 5ee1607..4454e13 100755
--- a/dev/test-patch.sh
+++ b/dev/test-patch.sh
@@ -520,6 +520,36 @@ checkAntiPatterns () {
 }
 
 ###
+### Check against use of known incompatible classes
+checkUseOfIncompatibleClasses () {
+  echo ""
+  echo ""
+  echo "=="
+  echo "=="
+  echo "Checking against use of known incompatible classes."
+  echo "=="
+  echo "=="
+  echo ""
+  echo ""
+  for INCOMPATIBLE_CLASS in $INCOMPATIBLE_CLASSES ; do
+  warning=`$GREP "+import $INCOMPATIBLE_CLASS" $PATCH_DIR/patch`
+  if [[ $warning != "" ]]; then
+warnings="$warnings
+$INCOMPATIBLE_CLASS"
+(( count = count + 1 ))
+  fi
+  done
+  if [[ $warnings != "" ]]; then
+JIRA_COMMENT="$JIRA_COMMENT
+
+{color:red}-1 Known Incompatible class{color}.  The patch 
appears to have $count incompatible classes:
+ $warnings."
+  return 1
+  fi
+  return 0
+}
+
+###
 ### Check that there are no incorrect annotations
 checkInterfaceAudience () {
   echo ""
@@ -1050,6 +1080,8 @@ fi
 
 checkAntiPatterns
 (( RESULT = RESULT + $? ))
+checkUseOfIncompatibleClasses
+(( RESULT = RESULT + $? ))
 # checkBuildWithHadoopVersions
 # (( RESULT = RESULT + $? ))
 checkJavacWarnings

http://git-wip-us.apache.org/repos/asf/phoenix/blob/5d641ad3/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java 
b/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
index 424482a..aea15c2 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
@@ -71,7 +71,6 @@ import org.apache.phoenix.util.SQLCloseables;
 import org.apache.phoenix.util.ScanUtil;
 
 import com.google.common.collect.ImmutableSet;
-import com.google.protobuf.HBaseZeroCopyByteString;
 
 /**
  * 
@@ -214,7 +213,7 @@ public class ServerCacheClient {
 
ServerCacheFactoryProtos.ServerCacheFactory.Builder svrCacheFactoryBuider = 
ServerCacheFactoryProtos.ServerCacheFactory.newBuilder();
 

[1/3] phoenix git commit: PHOENIX-2884 Fix EXPLAIN plan for offset on salted table

2016-05-16 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master 98e783cf6 -> 5d641ad34


PHOENIX-2884 Fix EXPLAIN plan for offset on salted table


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/33fb201e
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/33fb201e
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/33fb201e

Branch: refs/heads/master
Commit: 33fb201ebe46ba90f81658ef9b487f3b74070a4a
Parents: 98e783c
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:16:21 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:16:21 2016 +0530

--
 .../phoenix/end2end/QueryWithOffsetIT.java  | 25 
 .../phoenix/iterate/BaseResultIterators.java|  4 +---
 2 files changed, 21 insertions(+), 8 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/33fb201e/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
index dd21f31..c5b6959 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
@@ -38,6 +38,7 @@ import java.util.Properties;
 
 import org.apache.phoenix.query.QueryServices;
 import org.apache.phoenix.util.PropertiesUtil;
+import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ReadOnlyProps;
 import org.junit.BeforeClass;
 import org.junit.Test;
@@ -50,16 +51,18 @@ import com.google.common.collect.Maps;
 @RunWith(Parameterized.class)
 public class QueryWithOffsetIT extends BaseOwnClusterHBaseManagedTimeIT {
 
-private String tableName;
+private String tableName = "T";
 private final String[] strings = { "a", "b", "c", "d", "e", "f", "g", "h", 
"i", "j", "k", "l", "m", "n", "o", "p",
 "q", "r", "s", "t", "u", "v", "w", "x", "y", "z" };
 private final String ddl;
+private final boolean isSalted;
 
 public QueryWithOffsetIT(String preSplit) {
 this.tableName=tableName + "_" + preSplit.charAt(2);
 this.ddl = "CREATE TABLE " + tableName + " (t_id VARCHAR NOT NULL,\n" 
+ "k1 INTEGER NOT NULL,\n"
 + "k2 INTEGER NOT NULL,\n" + "C3.k3 INTEGER,\n" + "C2.v1 
VARCHAR,\n"
 + "CONSTRAINT pk PRIMARY KEY (t_id, k1, k2)) " + preSplit;
+this.isSalted = preSplit.startsWith(" SALT_BUCKETS");
 }
 
 @BeforeClass
@@ -122,16 +125,28 @@ public class QueryWithOffsetIT extends 
BaseOwnClusterHBaseManagedTimeIT {
 updateStatistics(conn);
 String query = "SELECT t_id from " + tableName + " offset " + offset;
 ResultSet rs = conn.createStatement().executeQuery("EXPLAIN " + query);
-rs.next();
-rs.next();
-rs.next();
-assertEquals("SERVER OFFSET " + offset, rs.getString(1));
+if(!isSalted){
+assertEquals("CLIENT SERIAL 1-WAY FULL SCAN OVER T_P\n" + "
SERVER FILTER BY FIRST KEY ONLY\n"
++ "SERVER OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+}else{
+assertEquals("CLIENT PARALLEL 10-WAY FULL SCAN OVER T_A\n" + "
SERVER FILTER BY FIRST KEY ONLY\n"
++ "CLIENT MERGE SORT\n" + "CLIENT OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+}
 rs = conn.createStatement().executeQuery(query);
 int i = 0;
 while (i++ < strings.length - offset) {
 assertTrue(rs.next());
 assertEquals(strings[offset + i - 1], rs.getString(1));
 }
+query = "SELECT t_id from " + tableName + " ORDER BY v1 offset " + 
offset;
+rs = conn.createStatement().executeQuery("EXPLAIN " + query);
+if (!isSalted) {
+assertEquals("CLIENT PARALLEL 5-WAY FULL SCAN OVER T_P\n" + "
SERVER SORTED BY [C2.V1]\n"
++ "CLIENT MERGE SORT\n" + "CLIENT OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+} else {
+assertEquals("CLIENT PARALLEL 10-WA

[2/3] phoenix git commit: PHOENIX-2862 Do client server compatibility checks before upgrading system tables

2016-05-16 Thread ankit
PHOENIX-2862 Do client server compatibility checks before upgrading system 
tables


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/3bd2a78e
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/3bd2a78e
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/3bd2a78e

Branch: refs/heads/4.x-HBase-1.1
Commit: 3bd2a78e1f85d44bff1c0bad09f62ca08acaced7
Parents: 156c356
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:19:55 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:19:55 2016 +0530

--
 .../end2end/QueryDatabaseMetaDataIT.java|  1 +
 .../org/apache/phoenix/end2end/UpgradeIT.java   |  4 +-
 .../apache/phoenix/compile/FromCompiler.java|  3 +
 .../coprocessor/MetaDataEndpointImpl.java   | 30 ---
 .../coprocessor/MetaDataRegionObserver.java |  9 +-
 .../phoenix/exception/SQLExceptionCode.java |  8 +-
 .../phoenix/jdbc/PhoenixDatabaseMetaData.java   |  4 +-
 .../query/ConnectionQueryServicesImpl.java  | 86 ++--
 .../org/apache/phoenix/query/QueryServices.java |  4 +-
 .../phoenix/query/QueryServicesOptions.java |  2 +-
 .../org/apache/phoenix/util/MetaDataUtil.java   | 46 ---
 .../org/apache/phoenix/util/SchemaUtil.java | 15 +++-
 .../org/apache/phoenix/util/UpgradeUtil.java| 48 ++-
 .../apache/phoenix/util/MetaDataUtilTest.java   | 36 
 14 files changed, 216 insertions(+), 80 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/3bd2a78e/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
index abcf6ef..aa7a6b2 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
@@ -147,6 +147,7 @@ public class QueryDatabaseMetaDataIT extends 
BaseClientManagedTimeIT {
 assertEquals(CUSTOM_ENTITY_DATA_NAME, rs.getString("TABLE_NAME"));
 assertEquals(PTableType.TABLE.toString(), rs.getString("TABLE_TYPE"));
 assertEquals("false", 
rs.getString(PhoenixDatabaseMetaData.TRANSACTIONAL));
+assertEquals(Boolean.FALSE, 
rs.getBoolean(PhoenixDatabaseMetaData.IS_NAMESPACE_MAPPED));
 
 rs = dbmd.getTables(null, CUSTOM_ENTITY_DATA_SCHEMA_NAME, 
CUSTOM_ENTITY_DATA_NAME, null);
 assertTrue(rs.next());

http://git-wip-us.apache.org/repos/asf/phoenix/blob/3bd2a78e/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
--
diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
index 1c86039..37d285f 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
@@ -129,7 +129,7 @@ public class UpgradeIT extends BaseHBaseManagedTimeIT {
 String indexName = "IDX";
 String localIndexName = "LIDX";
 String[] tableNames = new String[] { phoenixFullTableName, 
schemaName + "." + indexName,
-schemaName + "." + localIndexName, "diff.v", "test.v" };
+schemaName + "." + localIndexName, "diff.v", "test.v","v"};
 conn.createStatement().execute("CREATE TABLE " + 
phoenixFullTableName
 + "(k VARCHAR PRIMARY KEY, v INTEGER, f INTEGER, g INTEGER 
NULL, h INTEGER NULL)");
 PreparedStatement upsertStmt = conn
@@ -150,6 +150,7 @@ public class UpgradeIT extends BaseHBaseManagedTimeIT {
 conn.createStatement().execute("CREATE VIEW diff.v (col VARCHAR) 
AS SELECT * FROM " + phoenixFullTableName);
 // creating view in schema 'test'
 conn.createStatement().execute("CREATE VIEW test.v (col VARCHAR) 
AS SELECT * FROM " + phoenixFullTableName);
+conn.createStatement().execute("CREATE VIEW v (col VARCHAR) AS 
SELECT * FROM " + phoenixFullTableName);
 // Creating index on views
 conn.createStatement().execute("create index v_idx on 
diff.v(col)");
 conn.createStatement().execute("create index v_idx on 
test.v(col)");
@@ -170,6 +171,7 @@ public clas

[1/3] phoenix git commit: PHOENIX-2884 Fix EXPLAIN plan for offset on salted table

2016-05-16 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 52da01463 -> 9c3c849a1


PHOENIX-2884 Fix EXPLAIN plan for offset on salted table


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/156c3566
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/156c3566
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/156c3566

Branch: refs/heads/4.x-HBase-1.1
Commit: 156c356669a5e8ecfb31768e62d9990b459bf31c
Parents: 52da014
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:19:20 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:19:20 2016 +0530

--
 .../phoenix/end2end/QueryWithOffsetIT.java  | 25 
 .../phoenix/iterate/BaseResultIterators.java|  4 +---
 2 files changed, 21 insertions(+), 8 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/156c3566/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
index dd21f31..c5b6959 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
@@ -38,6 +38,7 @@ import java.util.Properties;
 
 import org.apache.phoenix.query.QueryServices;
 import org.apache.phoenix.util.PropertiesUtil;
+import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ReadOnlyProps;
 import org.junit.BeforeClass;
 import org.junit.Test;
@@ -50,16 +51,18 @@ import com.google.common.collect.Maps;
 @RunWith(Parameterized.class)
 public class QueryWithOffsetIT extends BaseOwnClusterHBaseManagedTimeIT {
 
-private String tableName;
+private String tableName = "T";
 private final String[] strings = { "a", "b", "c", "d", "e", "f", "g", "h", 
"i", "j", "k", "l", "m", "n", "o", "p",
 "q", "r", "s", "t", "u", "v", "w", "x", "y", "z" };
 private final String ddl;
+private final boolean isSalted;
 
 public QueryWithOffsetIT(String preSplit) {
 this.tableName=tableName + "_" + preSplit.charAt(2);
 this.ddl = "CREATE TABLE " + tableName + " (t_id VARCHAR NOT NULL,\n" 
+ "k1 INTEGER NOT NULL,\n"
 + "k2 INTEGER NOT NULL,\n" + "C3.k3 INTEGER,\n" + "C2.v1 
VARCHAR,\n"
 + "CONSTRAINT pk PRIMARY KEY (t_id, k1, k2)) " + preSplit;
+this.isSalted = preSplit.startsWith(" SALT_BUCKETS");
 }
 
 @BeforeClass
@@ -122,16 +125,28 @@ public class QueryWithOffsetIT extends 
BaseOwnClusterHBaseManagedTimeIT {
 updateStatistics(conn);
 String query = "SELECT t_id from " + tableName + " offset " + offset;
 ResultSet rs = conn.createStatement().executeQuery("EXPLAIN " + query);
-rs.next();
-rs.next();
-rs.next();
-assertEquals("SERVER OFFSET " + offset, rs.getString(1));
+if(!isSalted){
+assertEquals("CLIENT SERIAL 1-WAY FULL SCAN OVER T_P\n" + "
SERVER FILTER BY FIRST KEY ONLY\n"
++ "SERVER OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+}else{
+assertEquals("CLIENT PARALLEL 10-WAY FULL SCAN OVER T_A\n" + "
SERVER FILTER BY FIRST KEY ONLY\n"
++ "CLIENT MERGE SORT\n" + "CLIENT OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+}
 rs = conn.createStatement().executeQuery(query);
 int i = 0;
 while (i++ < strings.length - offset) {
 assertTrue(rs.next());
 assertEquals(strings[offset + i - 1], rs.getString(1));
 }
+query = "SELECT t_id from " + tableName + " ORDER BY v1 offset " + 
offset;
+rs = conn.createStatement().executeQuery("EXPLAIN " + query);
+if (!isSalted) {
+assertEquals("CLIENT PARALLEL 5-WAY FULL SCAN OVER T_P\n" + "
SERVER SORTED BY [C2.V1]\n"
++ "CLIENT MERGE SORT\n" + "CLIENT OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+} else {
+assertEquals("CLIENT

[2/3] phoenix git commit: PHOENIX-2862 Do client server compatibility checks before upgrading system tables

2016-05-16 Thread ankit
PHOENIX-2862 Do client server compatibility checks before upgrading system 
tables


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/28dbbebf
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/28dbbebf
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/28dbbebf

Branch: refs/heads/4.x-HBase-1.0
Commit: 28dbbebf070eb7a54644d578333b762b1e2ccf30
Parents: c345e09
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:38:04 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:38:04 2016 +0530

--
 .../end2end/QueryDatabaseMetaDataIT.java|  1 +
 .../org/apache/phoenix/end2end/UpgradeIT.java   |  4 +-
 .../apache/phoenix/compile/FromCompiler.java|  3 +
 .../coprocessor/MetaDataEndpointImpl.java   | 30 ---
 .../coprocessor/MetaDataRegionObserver.java |  9 +-
 .../phoenix/exception/SQLExceptionCode.java |  8 +-
 .../phoenix/jdbc/PhoenixDatabaseMetaData.java   |  4 +-
 .../query/ConnectionQueryServicesImpl.java  | 86 ++--
 .../org/apache/phoenix/query/QueryServices.java |  4 +-
 .../phoenix/query/QueryServicesOptions.java |  2 +-
 .../org/apache/phoenix/util/MetaDataUtil.java   | 46 ---
 .../org/apache/phoenix/util/SchemaUtil.java | 15 +++-
 .../org/apache/phoenix/util/UpgradeUtil.java| 48 ++-
 .../apache/phoenix/util/MetaDataUtilTest.java   | 36 
 14 files changed, 216 insertions(+), 80 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/28dbbebf/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
index abcf6ef..aa7a6b2 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
@@ -147,6 +147,7 @@ public class QueryDatabaseMetaDataIT extends 
BaseClientManagedTimeIT {
 assertEquals(CUSTOM_ENTITY_DATA_NAME, rs.getString("TABLE_NAME"));
 assertEquals(PTableType.TABLE.toString(), rs.getString("TABLE_TYPE"));
 assertEquals("false", 
rs.getString(PhoenixDatabaseMetaData.TRANSACTIONAL));
+assertEquals(Boolean.FALSE, 
rs.getBoolean(PhoenixDatabaseMetaData.IS_NAMESPACE_MAPPED));
 
 rs = dbmd.getTables(null, CUSTOM_ENTITY_DATA_SCHEMA_NAME, 
CUSTOM_ENTITY_DATA_NAME, null);
 assertTrue(rs.next());

http://git-wip-us.apache.org/repos/asf/phoenix/blob/28dbbebf/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
--
diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
index 1c86039..37d285f 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
@@ -129,7 +129,7 @@ public class UpgradeIT extends BaseHBaseManagedTimeIT {
 String indexName = "IDX";
 String localIndexName = "LIDX";
 String[] tableNames = new String[] { phoenixFullTableName, 
schemaName + "." + indexName,
-schemaName + "." + localIndexName, "diff.v", "test.v" };
+schemaName + "." + localIndexName, "diff.v", "test.v","v"};
 conn.createStatement().execute("CREATE TABLE " + 
phoenixFullTableName
 + "(k VARCHAR PRIMARY KEY, v INTEGER, f INTEGER, g INTEGER 
NULL, h INTEGER NULL)");
 PreparedStatement upsertStmt = conn
@@ -150,6 +150,7 @@ public class UpgradeIT extends BaseHBaseManagedTimeIT {
 conn.createStatement().execute("CREATE VIEW diff.v (col VARCHAR) 
AS SELECT * FROM " + phoenixFullTableName);
 // creating view in schema 'test'
 conn.createStatement().execute("CREATE VIEW test.v (col VARCHAR) 
AS SELECT * FROM " + phoenixFullTableName);
+conn.createStatement().execute("CREATE VIEW v (col VARCHAR) AS 
SELECT * FROM " + phoenixFullTableName);
 // Creating index on views
 conn.createStatement().execute("create index v_idx on 
diff.v(col)");
 conn.createStatement().execute("create index v_idx on 
test.v(col)");
@@ -170,6 +171,7 @@ public clas

[1/3] phoenix git commit: PHOENIX-2884 Fix EXPLAIN plan for offset on salted table

2016-05-16 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 588eb1732 -> f30442226


PHOENIX-2884 Fix EXPLAIN plan for offset on salted table


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

Branch: refs/heads/4.x-HBase-1.0
Commit: c345e09c889d57a83856db4a65c7c0731f6ff117
Parents: 588eb17
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:36:50 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:36:50 2016 +0530

--
 .../phoenix/end2end/QueryWithOffsetIT.java  | 25 
 .../phoenix/iterate/BaseResultIterators.java|  4 +---
 2 files changed, 21 insertions(+), 8 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/c345e09c/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
index 7f360de..f4b3440 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
@@ -38,6 +38,7 @@ import java.util.Properties;
 
 import org.apache.phoenix.query.QueryServices;
 import org.apache.phoenix.util.PropertiesUtil;
+import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ReadOnlyProps;
 import org.junit.BeforeClass;
 import org.junit.Test;
@@ -50,16 +51,18 @@ import com.google.common.collect.Maps;
 @RunWith(Parameterized.class)
 public class QueryWithOffsetIT extends BaseOwnClusterHBaseManagedTimeIT {
 
-private String tableName;
+private String tableName = "T";
 private final String[] strings = { "a", "b", "c", "d", "e", "f", "g", "h", 
"i", "j", "k", "l", "m", "n", "o", "p",
 "q", "r", "s", "t", "u", "v", "w", "x", "y", "z" };
 private final String ddl;
+private final boolean isSalted;
 
 public QueryWithOffsetIT(String preSplit) {
 this.tableName = tableName + "_" + preSplit.charAt(2);
 this.ddl = "CREATE TABLE " + tableName + " (t_id VARCHAR NOT NULL,\n" 
+ "k1 INTEGER NOT NULL,\n"
 + "k2 INTEGER NOT NULL,\n" + "C3.k3 INTEGER,\n" + "C2.v1 
VARCHAR,\n"
 + "CONSTRAINT pk PRIMARY KEY (t_id, k1, k2)) " + preSplit;
+this.isSalted = preSplit.startsWith(" SALT_BUCKETS");
 }
 
 @BeforeClass
@@ -122,16 +125,28 @@ public class QueryWithOffsetIT extends 
BaseOwnClusterHBaseManagedTimeIT {
 updateStatistics(conn);
 String query = "SELECT t_id from " + tableName + " offset " + offset;
 ResultSet rs = conn.createStatement().executeQuery("EXPLAIN " + query);
-rs.next();
-rs.next();
-rs.next();
-assertEquals("SERVER OFFSET " + offset, rs.getString(1));
+if(!isSalted){
+assertEquals("CLIENT SERIAL 1-WAY FULL SCAN OVER T_P\n" + "
SERVER FILTER BY FIRST KEY ONLY\n"
++ "SERVER OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+}else{
+assertEquals("CLIENT PARALLEL 10-WAY FULL SCAN OVER T_A\n" + "
SERVER FILTER BY FIRST KEY ONLY\n"
++ "CLIENT MERGE SORT\n" + "CLIENT OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+}
 rs = conn.createStatement().executeQuery(query);
 int i = 0;
 while (i++ < strings.length - offset) {
 assertTrue(rs.next());
 assertEquals(strings[offset + i - 1], rs.getString(1));
 }
+query = "SELECT t_id from " + tableName + " ORDER BY v1 offset " + 
offset;
+rs = conn.createStatement().executeQuery("EXPLAIN " + query);
+if (!isSalted) {
+assertEquals("CLIENT PARALLEL 5-WAY FULL SCAN OVER T_P\n" + "
SERVER SORTED BY [C2.V1]\n"
++ "CLIENT MERGE SORT\n" + "CLIENT OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+} else {
+assertEquals("CLIENT

[3/3] phoenix git commit: PHOENIX-2887 Uberjar application fail with 'IllegalAccessError: class com.google.protobuf.ZeroCopyLiteralByteString cannot access its superclass com.google.protobuf.LiteralBy

2016-05-16 Thread ankit
PHOENIX-2887 Uberjar application fail with 'IllegalAccessError: class 
com.google.protobuf.ZeroCopyLiteralByteString cannot access its superclass 
com.google.protobuf.LiteralByteString'


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

Branch: refs/heads/4.x-HBase-1.0
Commit: f304422260bce334db0638a2f18ba8e55ecce2ec
Parents: 28dbbeb
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:38:22 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:38:22 2016 +0530

--
 dev/test-patch.properties   |  1 +
 dev/test-patch.sh   | 32 
 .../apache/phoenix/cache/ServerCacheClient.java |  3 +-
 .../org/apache/phoenix/schema/PTableImpl.java   |  8 ++---
 4 files changed, 37 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/f3044222/dev/test-patch.properties
--
diff --git a/dev/test-patch.properties b/dev/test-patch.properties
index 6a82eee..804d56b 100644
--- a/dev/test-patch.properties
+++ b/dev/test-patch.properties
@@ -33,3 +33,4 @@ BRANCH_NAMES="3.0 3.2 4.0.1 4.2 4.3 4.x-HBase-0.98 master"
 # All supported Hadoop versions that we want to test the compilation with
 HADOOP2_VERSIONS="2.4.1 2.5.2 2.6.0"
 HADOOP3_VERSIONS="3.0.0-SNAPSHOT"
+INCOMPATIBLE_CLASSES="com.google.protobuf.HBaseZeroCopyByteString"

http://git-wip-us.apache.org/repos/asf/phoenix/blob/f3044222/dev/test-patch.sh
--
diff --git a/dev/test-patch.sh b/dev/test-patch.sh
index 1ed7e62..1a24166 100755
--- a/dev/test-patch.sh
+++ b/dev/test-patch.sh
@@ -520,6 +520,36 @@ checkAntiPatterns () {
 }
 
 ###
+### Check against use of known incompatible classes
+checkUseOfIncompatibleClasses () {
+  echo ""
+  echo ""
+  echo "=="
+  echo "=="
+  echo "Checking against use of known incompatible classes."
+  echo "=="
+  echo "=="
+  echo ""
+  echo ""
+  for INCOMPATIBLE_CLASS in $INCOMPATIBLE_CLASSES ; do
+  warning=`$GREP "+import $INCOMPATIBLE_CLASS" $PATCH_DIR/patch`
+  if [[ $warning != "" ]]; then
+warnings="$warnings
+$INCOMPATIBLE_CLASS"
+(( count = count + 1 ))
+  fi
+  done
+  if [[ $warnings != "" ]]; then
+JIRA_COMMENT="$JIRA_COMMENT
+
+{color:red}-1 Known Incompatible class{color}.  The patch 
appears to have $count incompatible classes:
+ $warnings."
+  return 1
+  fi
+  return 0
+}
+
+###
 ### Check that there are no incorrect annotations
 checkInterfaceAudience () {
   echo ""
@@ -1050,6 +1080,8 @@ fi
 
 checkAntiPatterns
 (( RESULT = RESULT + $? ))
+checkUseOfIncompatibleClasses
+(( RESULT = RESULT + $? ))
 # checkBuildWithHadoopVersions
 # (( RESULT = RESULT + $? ))
 checkJavacWarnings

http://git-wip-us.apache.org/repos/asf/phoenix/blob/f3044222/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java 
b/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
index 424482a..aea15c2 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
@@ -71,7 +71,6 @@ import org.apache.phoenix.util.SQLCloseables;
 import org.apache.phoenix.util.ScanUtil;
 
 import com.google.common.collect.ImmutableSet;
-import com.google.protobuf.HBaseZeroCopyByteString;
 
 /**
  * 
@@ -214,7 +213,7 @@ public class ServerCacheClient {
 
ServerCacheFactoryProtos.ServerCacheFactory.Builder svrCacheFactoryBuider = 
ServerCacheFactoryProtos.ServerCacheFactory.newBuilder();
 
svrCacheFactoryBuider.setClassName(cacheFactory.get

[3/3] phoenix git commit: PHOENIX-2887 Uberjar application fail with 'IllegalAccessError: class com.google.protobuf.ZeroCopyLiteralByteString cannot access its superclass com.google.protobuf.LiteralBy

2016-05-16 Thread ankit
PHOENIX-2887 Uberjar application fail with 'IllegalAccessError: class 
com.google.protobuf.ZeroCopyLiteralByteString cannot access its superclass 
com.google.protobuf.LiteralByteString'


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/4837f1ff
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/4837f1ff
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/4837f1ff

Branch: refs/heads/4.x-HBase-0.98
Commit: 4837f1ff9d5a6265a07eecfc9d5d3ee55a56653f
Parents: d45938c
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:46:43 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:46:43 2016 +0530

--
 .../java/org/apache/phoenix/cache/ServerCacheClient.java | 3 +--
 .../src/main/java/org/apache/phoenix/schema/PTableImpl.java  | 8 +++-
 2 files changed, 4 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/4837f1ff/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java 
b/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
index 424482a..aea15c2 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/cache/ServerCacheClient.java
@@ -71,7 +71,6 @@ import org.apache.phoenix.util.SQLCloseables;
 import org.apache.phoenix.util.ScanUtil;
 
 import com.google.common.collect.ImmutableSet;
-import com.google.protobuf.HBaseZeroCopyByteString;
 
 /**
  * 
@@ -214,7 +213,7 @@ public class ServerCacheClient {
 
ServerCacheFactoryProtos.ServerCacheFactory.Builder svrCacheFactoryBuider = 
ServerCacheFactoryProtos.ServerCacheFactory.newBuilder();
 
svrCacheFactoryBuider.setClassName(cacheFactory.getClass().getName());
 
builder.setCacheFactory(svrCacheFactoryBuider.build());
-
builder.setTxState(HBaseZeroCopyByteString.wrap(txState));
+
builder.setTxState(ByteStringer.wrap(txState));
 
instance.addServerCache(controller, builder.build(), rpcCallback);
 
if(controller.getFailedOn() != null) {
 throw 
controller.getFailedOn();

http://git-wip-us.apache.org/repos/asf/phoenix/blob/4837f1ff/phoenix-core/src/main/java/org/apache/phoenix/schema/PTableImpl.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/schema/PTableImpl.java 
b/phoenix-core/src/main/java/org/apache/phoenix/schema/PTableImpl.java
index 70414d5..bd23ab8 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/schema/PTableImpl.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/schema/PTableImpl.java
@@ -66,8 +66,6 @@ import org.apache.phoenix.util.SizedUtil;
 import org.apache.phoenix.util.StringUtil;
 import org.apache.phoenix.util.TrustedByteArrayOutputStream;
 
-import co.cask.tephra.TxConstants;
-
 import com.google.common.base.Objects;
 import com.google.common.base.Preconditions;
 import com.google.common.collect.ArrayListMultimap;
@@ -77,9 +75,10 @@ import com.google.common.collect.ImmutableSortedMap;
 import com.google.common.collect.ListMultimap;
 import com.google.common.collect.Lists;
 import com.google.common.collect.Maps;
-import com.google.protobuf.HBaseZeroCopyByteString;
 import com.sun.istack.NotNull;
 
+import co.cask.tephra.TxConstants;
+
 /**
  *
  * Base class for PTable implementors.  Provides abstraction for
@@ -1069,8 +1068,7 @@ public class PTableImpl implements PTable {
   int maxLength = pGuidePosts.getMaxLength();
   int guidePostsCount = pGuidePosts.getEncodedGuidePostsCount();
 GuidePostsInfo info = new 
GuidePostsInfo(pGuidePosts.getByteCountsList(),
-new ImmutableBytesWritable(
-
HBaseZeroCopyByteString.zeroCopyGetBytes(pGuidePosts.getEncodedGuidePosts())),
+new 
ImmutableBytesWritable(pGuidePosts.getEncodedGuidePosts().toByteArray()),
 pGuidePosts.getRowCountsList(), maxLength, 
guidePostsCount);
   tableGuidePosts.put(pTableStatsProto.getKey().toByteArray(), info);
   }



[2/3] phoenix git commit: PHOENIX-2862 Do client server compatibility checks before upgrading system tables

2016-05-16 Thread ankit
PHOENIX-2862 Do client server compatibility checks before upgrading system 
tables


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

Branch: refs/heads/4.x-HBase-0.98
Commit: d45938c2bb9186d5db9f39eb63069985a35dddb0
Parents: a9934ef
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:45:33 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:45:33 2016 +0530

--
 .../end2end/QueryDatabaseMetaDataIT.java|  1 +
 .../org/apache/phoenix/end2end/UpgradeIT.java   |  4 +-
 .../apache/phoenix/compile/FromCompiler.java|  3 +
 .../coprocessor/MetaDataEndpointImpl.java   | 30 +++---
 .../coprocessor/MetaDataRegionObserver.java |  9 +-
 .../phoenix/exception/SQLExceptionCode.java |  8 +-
 .../phoenix/jdbc/PhoenixDatabaseMetaData.java   |  1 +
 .../query/ConnectionQueryServicesImpl.java  | 98 ++--
 .../org/apache/phoenix/query/QueryServices.java |  4 +-
 .../phoenix/query/QueryServicesOptions.java |  2 +-
 .../org/apache/phoenix/util/MetaDataUtil.java   | 46 +++--
 .../org/apache/phoenix/util/SchemaUtil.java | 15 ++-
 .../org/apache/phoenix/util/UpgradeUtil.java| 48 ++
 .../apache/phoenix/util/MetaDataUtilTest.java   | 36 +++
 14 files changed, 220 insertions(+), 85 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/d45938c2/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
index abcf6ef..aa7a6b2 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryDatabaseMetaDataIT.java
@@ -147,6 +147,7 @@ public class QueryDatabaseMetaDataIT extends 
BaseClientManagedTimeIT {
 assertEquals(CUSTOM_ENTITY_DATA_NAME, rs.getString("TABLE_NAME"));
 assertEquals(PTableType.TABLE.toString(), rs.getString("TABLE_TYPE"));
 assertEquals("false", 
rs.getString(PhoenixDatabaseMetaData.TRANSACTIONAL));
+assertEquals(Boolean.FALSE, 
rs.getBoolean(PhoenixDatabaseMetaData.IS_NAMESPACE_MAPPED));
 
 rs = dbmd.getTables(null, CUSTOM_ENTITY_DATA_SCHEMA_NAME, 
CUSTOM_ENTITY_DATA_NAME, null);
 assertTrue(rs.next());

http://git-wip-us.apache.org/repos/asf/phoenix/blob/d45938c2/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
--
diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
index 1c86039..37d285f 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpgradeIT.java
@@ -129,7 +129,7 @@ public class UpgradeIT extends BaseHBaseManagedTimeIT {
 String indexName = "IDX";
 String localIndexName = "LIDX";
 String[] tableNames = new String[] { phoenixFullTableName, 
schemaName + "." + indexName,
-schemaName + "." + localIndexName, "diff.v", "test.v" };
+schemaName + "." + localIndexName, "diff.v", "test.v","v"};
 conn.createStatement().execute("CREATE TABLE " + 
phoenixFullTableName
 + "(k VARCHAR PRIMARY KEY, v INTEGER, f INTEGER, g INTEGER 
NULL, h INTEGER NULL)");
 PreparedStatement upsertStmt = conn
@@ -150,6 +150,7 @@ public class UpgradeIT extends BaseHBaseManagedTimeIT {
 conn.createStatement().execute("CREATE VIEW diff.v (col VARCHAR) 
AS SELECT * FROM " + phoenixFullTableName);
 // creating view in schema 'test'
 conn.createStatement().execute("CREATE VIEW test.v (col VARCHAR) 
AS SELECT * FROM " + phoenixFullTableName);
+conn.createStatement().execute("CREATE VIEW v (col VARCHAR) AS 
SELECT * FROM " + phoenixFullTableName);
 // Creating index on views
 conn.createStatement().execute("create index v_idx on 
diff.v(col)");
 conn.createStatement().execute("create index v_idx on 
test.v(col)");
@@ -170,6 +171,7 @@ public class UpgradeIT extends BaseHBaseManag

[1/3] phoenix git commit: PHOENIX-2884 Fix EXPLAIN plan for offset on salted table

2016-05-16 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 ea93058f4 -> 4837f1ff9


PHOENIX-2884 Fix EXPLAIN plan for offset on salted table


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

Branch: refs/heads/4.x-HBase-0.98
Commit: a9934ef90aa12e133a5d609e9c6df57e670e5284
Parents: ea93058
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Mon May 16 12:43:09 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Mon May 16 12:43:09 2016 +0530

--
 .../phoenix/end2end/QueryWithOffsetIT.java  | 25 
 .../phoenix/iterate/BaseResultIterators.java|  4 +---
 2 files changed, 21 insertions(+), 8 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/a9934ef9/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
index 7f360de..f4b3440 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/QueryWithOffsetIT.java
@@ -38,6 +38,7 @@ import java.util.Properties;
 
 import org.apache.phoenix.query.QueryServices;
 import org.apache.phoenix.util.PropertiesUtil;
+import org.apache.phoenix.util.QueryUtil;
 import org.apache.phoenix.util.ReadOnlyProps;
 import org.junit.BeforeClass;
 import org.junit.Test;
@@ -50,16 +51,18 @@ import com.google.common.collect.Maps;
 @RunWith(Parameterized.class)
 public class QueryWithOffsetIT extends BaseOwnClusterHBaseManagedTimeIT {
 
-private String tableName;
+private String tableName = "T";
 private final String[] strings = { "a", "b", "c", "d", "e", "f", "g", "h", 
"i", "j", "k", "l", "m", "n", "o", "p",
 "q", "r", "s", "t", "u", "v", "w", "x", "y", "z" };
 private final String ddl;
+private final boolean isSalted;
 
 public QueryWithOffsetIT(String preSplit) {
 this.tableName = tableName + "_" + preSplit.charAt(2);
 this.ddl = "CREATE TABLE " + tableName + " (t_id VARCHAR NOT NULL,\n" 
+ "k1 INTEGER NOT NULL,\n"
 + "k2 INTEGER NOT NULL,\n" + "C3.k3 INTEGER,\n" + "C2.v1 
VARCHAR,\n"
 + "CONSTRAINT pk PRIMARY KEY (t_id, k1, k2)) " + preSplit;
+this.isSalted = preSplit.startsWith(" SALT_BUCKETS");
 }
 
 @BeforeClass
@@ -122,16 +125,28 @@ public class QueryWithOffsetIT extends 
BaseOwnClusterHBaseManagedTimeIT {
 updateStatistics(conn);
 String query = "SELECT t_id from " + tableName + " offset " + offset;
 ResultSet rs = conn.createStatement().executeQuery("EXPLAIN " + query);
-rs.next();
-rs.next();
-rs.next();
-assertEquals("SERVER OFFSET " + offset, rs.getString(1));
+if(!isSalted){
+assertEquals("CLIENT SERIAL 1-WAY FULL SCAN OVER T_P\n" + "
SERVER FILTER BY FIRST KEY ONLY\n"
++ "SERVER OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+}else{
+assertEquals("CLIENT PARALLEL 10-WAY FULL SCAN OVER T_A\n" + "
SERVER FILTER BY FIRST KEY ONLY\n"
++ "CLIENT MERGE SORT\n" + "CLIENT OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+}
 rs = conn.createStatement().executeQuery(query);
 int i = 0;
 while (i++ < strings.length - offset) {
 assertTrue(rs.next());
 assertEquals(strings[offset + i - 1], rs.getString(1));
 }
+query = "SELECT t_id from " + tableName + " ORDER BY v1 offset " + 
offset;
+rs = conn.createStatement().executeQuery("EXPLAIN " + query);
+if (!isSalted) {
+assertEquals("CLIENT PARALLEL 5-WAY FULL SCAN OVER T_P\n" + "
SERVER SORTED BY [C2.V1]\n"
++ "CLIENT MERGE SORT\n" + "CLIENT OFFSET " + offset, 
QueryUtil.getExplainPlan(rs));
+} else {
+assertEquals("CLIENT

svn commit: r1742379 - /phoenix/site/publish/team.html

2016-05-05 Thread ankit
Author: ankit
Date: Thu May  5 08:52:22 2016
New Revision: 1742379

URL: http://svn.apache.org/viewvc?rev=1742379=rev
Log:
Added Ankit Singhal as PMC

Modified:
phoenix/site/publish/team.html

Modified: phoenix/site/publish/team.html
URL: 
http://svn.apache.org/viewvc/phoenix/site/publish/team.html?rev=1742379=1742378=1742379=diff
==
--- phoenix/site/publish/team.html (original)
+++ phoenix/site/publish/team.html Thu May  5 08:52:22 2016
@@ -1,7 +1,7 @@
 
 
 
 
@@ -164,137 +164,137 @@
PMC 


+   Ankit Singhal  
+   Hortonworks  
+   mailto:an...@apache.org;>an...@apache.org  
+   PMC 
+   
+   
Anoop Sam John  
Intel  
mailto:anoopsamj...@apache.org;>anoopsamj...@apache.org  
PMC 

-   
+   
Devaraj Das  
Hortonworks  
mailto:d...@apache.org;>d...@apache.org  
PMC 

-   
+   
Eli Levine  
Salesforce  
mailto:elilev...@apache.org;>elilev...@apache.org  
PMC 

-   
+   
Enis Soztutar  
Hortonworks  
mailto:e...@apache.org;>e...@apache.org  
PMC 

-   
+   
Gabriel Reid  
NGDATA  
mailto:gr...@apache.org;>gr...@apache.org  
PMC 

-   
+   
James Taylor  
Salesforce  
mailto:jamestay...@apache.org;>jamestay...@apache.org  
PMC 

-   
+   
Jeffrey Zhong  
Elementum  
mailto:jeffr...@apache.org;>jeffr...@apache.org  
PMC 

-   
+   
Jesse Yates  
Fineo  
mailto:jya...@apache.org;>jya...@apache.org  
PMC 

-   
+   
Josh Mahonin  
Interset  
mailto:jmaho...@apache.org;>jmaho...@apache.org  
PMC 

-   
+   
Lars Hofhansl  
Salesforce  
mailto:la...@apache.org;>la...@apache.org  
PMC 

-   
+   
Maryann Xue  
Intel  
mailto:maryann...@apache.org;>maryann...@apache.org  
PMC 

-   
+   
Michael Stack  
Cloudera  
mailto:st...@apache.org;>st...@apache.org  
PMC 

-   
+   
Mujtaba Chohan  
Salesforce  
mailto:mujt...@apache.org;>mujt...@apache.org  
PMC 

-   
+   
Nick Dimiduk  
Icebrg  
mailto:ndimi...@apache.org;>ndimi...@apache.org  
PMC 

-   
+   
Rajeshbabu Chintaguntla  
Hortonworks  
mailto:rajeshb...@apache.org;>rajeshb...@apache.org  
PMC 

-   
+   
Ramkrishna Vasudevan  
Intel  
mailto:ramkris...@apache.org;>ramkris...@apache.org  
PMC 

-   
+   
Ravi Magham  
Bazaarvoice  
mailto:ravimag...@apache.org;>ravimag...@apache.org  
PMC 

-   
+   
Samarth Jain  
Salesforce  
mailto:sama...@apache.org;>sama...@apache.org  
PMC 

-   
+   
Simon Toens  
Salesforce  
mailto:sto...@apache.org;>sto...@apache.org  
PMC 

-   
+   
Steven Noels  
NGDATA  
mailto:stev...@apache.org;>stev...@apache.org  
PMC 

-   
+   
Thomas D’Silva  
Salesforce  
mailto:tdsi...@apache.org;>tdsi...@apache.org  
PMC 

-   
-   Ankit Singhal  
-   Hortonworks  
-   mailto:an...@apache.org;>an...@apache.org  
-   Committer 
-   

Cody Marcel  
Salesforce  




phoenix git commit: PHOENIX-2845 Addendum Timestamp ignores nanos in literal expressions

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 f887f4175 -> 5cd74454b


PHOENIX-2845 Addendum Timestamp ignores nanos in literal expressions


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/5cd74454
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/5cd74454
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/5cd74454

Branch: refs/heads/4.x-HBase-0.98
Commit: 5cd74454bf2983684ec6e9d4f9c200919f20fb8f
Parents: f887f41
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 13:10:22 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 13:10:22 2016 +0530

--
 phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java | 1 -
 1 file changed, 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/5cd74454/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
index 557d8ed..5032c38 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
@@ -32,7 +32,6 @@ import java.util.List;
 import java.util.TimeZone;
 
 import org.apache.commons.lang.time.FastDateFormat;
-import org.apache.hadoop.hbase.exceptions.IllegalArgumentIOException;
 import org.apache.phoenix.schema.IllegalDataException;
 import org.apache.phoenix.schema.types.PDataType;
 import org.joda.time.DateTimeZone;



phoenix git commit: PHOENIX-2845 Timestamp ignores nanos in literal expressions(Sergey Soldatov)

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 7b1db0516 -> ffb481040


PHOENIX-2845 Timestamp ignores nanos in literal expressions(Sergey Soldatov)


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

Branch: refs/heads/4.x-HBase-1.1
Commit: ffb481040132af39d0690df17cf7990ad01cfdd4
Parents: 7b1db05
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:47:37 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:47:37 2016 +0530

--
 .../org/apache/phoenix/end2end/DateTimeIT.java  | 22 +
 .../apache/phoenix/end2end/UpsertValuesIT.java  |  1 +
 .../java/org/apache/phoenix/util/DateUtil.java  | 17 -
 .../org/apache/phoenix/util/DateUtilTest.java   | 25 
 4 files changed, 64 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/ffb48104/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
index af8f0c1..7e407bc 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
@@ -693,4 +693,26 @@ public class DateTimeIT extends BaseHBaseManagedTimeIT {
 long actualTime = rs.getDate(1).getTime();
 assertTrue(Math.abs(actualTime - expectedTime) < MILLIS_IN_DAY);
 }
+@Test
+public void testSelectBetweenNanos() throws Exception {
+String ddl =
+"CREATE TABLE IF NOT EXISTS N1 (k1 INTEGER NOT NULL PRIMARY 
KEY, ts " +
+"TIMESTAMP(3))";
+conn.createStatement().execute(ddl);
+String dml = "UPSERT INTO N1 VALUES (1, TIMESTAMP'2015-01-01 
00:00:00.1')";
+conn.createStatement().execute(dml);
+dml = "UPSERT INTO N1 VALUES (2, TIMESTAMP'2015-01-01 
00:00:00.5')";
+conn.createStatement().execute(dml);
+dml = "UPSERT INTO N1 VALUES (3, TIMESTAMP'2015-01-01 
00:00:00.3')";
+conn.createStatement().execute(dml);
+conn.commit();
+
+ResultSet rs = conn.createStatement().executeQuery("SELECT k1,ts from 
N1 where ts between" +
+" TIMESTAMP'2015-01-01 00:00:00.2' AND 
TIMESTAMP'2015-01-01 00:00:00" +
+".4'");
+assertTrue(rs.next());
+assertEquals(3, rs.getInt(1));
+assertEquals(3, rs.getTimestamp(2).getNanos());
+assertFalse(rs.next());
+}
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/ffb48104/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
index a7e70c1..5cefd7d 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
@@ -632,6 +632,7 @@ public class UpsertValuesIT extends BaseClientManagedTimeIT 
{
 
 Date date = toDate(dateStr);
 Timestamp timeStamp = new Timestamp(toDate(timeStampStr).getTime());
+timeStamp.setNanos(Timestamp.valueOf(timeStampStr).getNanos());
 Time time = new Time(toDate(timeStr).getTime());
 props.setProperty(PhoenixRuntime.CURRENT_SCN_ATTRIB, Long.toString(ts 
+ 4));
 try {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/ffb48104/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
index 4d7c27c..557d8ed 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
@@ -32,6 +32,7 @@ import java.util.List;
 import java.util.TimeZone;
 
 import org.apache.commons.lang.time.FastDateFormat;
+import org.apache.hadoop.hbase.exceptions.IllegalArgumentIOException;
 import org.apache.phoenix.schema.IllegalDataException;
 import org.apache.phoenix.schema.types.PDataType;
 import org.joda.time.DateTimeZone;
@@ -17

[1/2] phoenix git commit: PHOENIX-2874 Delete schemas also during clean up after test

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 dab088fae -> b4590f866


PHOENIX-2874 Delete schemas also during clean up after test


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/41bcb7ff
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/41bcb7ff
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/41bcb7ff

Branch: refs/heads/4.x-HBase-0.98
Commit: 41bcb7ff13b26f975270ffbeeebb859950e6e0b2
Parents: dab088f
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:35:19 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:35:19 2016 +0530

--
 .../end2end/BaseClientManagedTimeIT.java|  2 +-
 .../phoenix/end2end/BaseHBaseManagedTimeIT.java |  2 +-
 .../BaseOwnClusterClientManagedTimeIT.java  |  2 +-
 .../BaseOwnClusterHBaseManagedTimeIT.java   |  2 +-
 .../apache/phoenix/end2end/CreateSchemaIT.java  |  2 +-
 .../apache/phoenix/end2end/DropSchemaIT.java| 21 +--
 .../query/ConnectionQueryServicesImpl.java  |  6 +-
 .../java/org/apache/phoenix/query/BaseTest.java | 66 ++--
 8 files changed, 87 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/41bcb7ff/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
index 1acd5b3..dee7200 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
@@ -56,7 +56,7 @@ public abstract class BaseClientManagedTimeIT extends 
BaseTest {
 @After
 public void cleanUpAfterTest() throws Exception {
 long ts = nextTimestamp();
-deletePriorTables(ts - 1, getUrl());
+deletePriorMetaData(ts - 1, getUrl());
 }
 
 public static Map<String,String> getDefaultProps() {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/41bcb7ff/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
index 3a811a8..7439b1d 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
@@ -64,6 +64,6 @@ public abstract class BaseHBaseManagedTimeIT extends BaseTest 
{
 
 @After
 public void cleanUpAfterTest() throws Exception {
-deletePriorTables(HConstants.LATEST_TIMESTAMP, getUrl());
+deletePriorMetaData(HConstants.LATEST_TIMESTAMP, getUrl());
 }
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/41bcb7ff/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
index 01d8538..47f0bdd 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
@@ -26,6 +26,6 @@ public class BaseOwnClusterClientManagedTimeIT extends 
BaseOwnClusterIT {
 @After
 public void cleanUpAfterTest() throws Exception {
 long ts = nextTimestamp();
-deletePriorTables(ts - 1, getUrl());
+deletePriorMetaData(ts - 1, getUrl());
 }
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/41bcb7ff/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
index d4096f9..cbb40a1 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
@@ -26,6 +26,6 @@ import org.junit.After;
 public class BaseOwnClusterHBaseManagedTimeIT extends BaseOwnClusterIT {
 @After
 public 

[2/2] phoenix git commit: PHOENIX-2863 Let's roll up minor version to 8 (4.8.0) because of namespace compatibility checks

2016-05-05 Thread ankit
PHOENIX-2863 Let's roll up minor version to 8 (4.8.0) because of namespace 
compatibility checks


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

Branch: refs/heads/4.x-HBase-0.98
Commit: b4590f866c2e21b18a1b559678ce80ef42bdb914
Parents: 41bcb7f
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:35:23 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:35:23 2016 +0530

--
 .../main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/b4590f86/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
index 8c86b56..f847b97 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
@@ -60,7 +60,7 @@ import com.google.protobuf.ByteString;
  */
 public abstract class MetaDataProtocol extends MetaDataService {
 public static final int PHOENIX_MAJOR_VERSION = 4;
-public static final int PHOENIX_MINOR_VERSION = 7;
+public static final int PHOENIX_MINOR_VERSION = 8;
 public static final int PHOENIX_PATCH_NUMBER = 0;
 public static final int PHOENIX_VERSION =
 VersionUtil.encodeVersion(PHOENIX_MAJOR_VERSION, 
PHOENIX_MINOR_VERSION, PHOENIX_PATCH_NUMBER);



[1/2] phoenix git commit: PHOENIX-2874 Delete schemas also during clean up after test

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 f98cf03d3 -> baa599461


PHOENIX-2874 Delete schemas also during clean up after test


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

Branch: refs/heads/4.x-HBase-1.0
Commit: f57d75e90eaf69481a20534b5da2df6248ff8bb3
Parents: f98cf03
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:34:12 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:34:12 2016 +0530

--
 .../end2end/BaseClientManagedTimeIT.java|  2 +-
 .../phoenix/end2end/BaseHBaseManagedTimeIT.java |  2 +-
 .../BaseOwnClusterClientManagedTimeIT.java  |  2 +-
 .../BaseOwnClusterHBaseManagedTimeIT.java   |  2 +-
 .../apache/phoenix/end2end/CreateSchemaIT.java  |  2 +-
 .../apache/phoenix/end2end/DropSchemaIT.java| 21 +--
 .../query/ConnectionQueryServicesImpl.java  |  6 +-
 .../java/org/apache/phoenix/query/BaseTest.java | 66 ++--
 8 files changed, 87 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/f57d75e9/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
index 1acd5b3..dee7200 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
@@ -56,7 +56,7 @@ public abstract class BaseClientManagedTimeIT extends 
BaseTest {
 @After
 public void cleanUpAfterTest() throws Exception {
 long ts = nextTimestamp();
-deletePriorTables(ts - 1, getUrl());
+deletePriorMetaData(ts - 1, getUrl());
 }
 
 public static Map<String,String> getDefaultProps() {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/f57d75e9/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
index 3a811a8..7439b1d 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
@@ -64,6 +64,6 @@ public abstract class BaseHBaseManagedTimeIT extends BaseTest 
{
 
 @After
 public void cleanUpAfterTest() throws Exception {
-deletePriorTables(HConstants.LATEST_TIMESTAMP, getUrl());
+deletePriorMetaData(HConstants.LATEST_TIMESTAMP, getUrl());
 }
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/f57d75e9/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
index 01d8538..47f0bdd 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
@@ -26,6 +26,6 @@ public class BaseOwnClusterClientManagedTimeIT extends 
BaseOwnClusterIT {
 @After
 public void cleanUpAfterTest() throws Exception {
 long ts = nextTimestamp();
-deletePriorTables(ts - 1, getUrl());
+deletePriorMetaData(ts - 1, getUrl());
 }
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/f57d75e9/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
index d4096f9..cbb40a1 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
@@ -26,6 +26,6 @@ import org.junit.After;
 public class BaseOwnClusterHBaseManagedTimeIT extends BaseOwnClusterIT {
 @After
 public 

[2/2] phoenix git commit: PHOENIX-2863 Let's roll up minor version to 8 (4.8.0) because of namespace compatibility checks

2016-05-05 Thread ankit
PHOENIX-2863 Let's roll up minor version to 8 (4.8.0) because of namespace 
compatibility checks


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

Branch: refs/heads/4.x-HBase-1.0
Commit: baa599461efbb4e8435a068d25556727d2977b03
Parents: f57d75e
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:34:30 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:34:30 2016 +0530

--
 .../main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/baa59946/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
index 8c86b56..f847b97 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
@@ -60,7 +60,7 @@ import com.google.protobuf.ByteString;
  */
 public abstract class MetaDataProtocol extends MetaDataService {
 public static final int PHOENIX_MAJOR_VERSION = 4;
-public static final int PHOENIX_MINOR_VERSION = 7;
+public static final int PHOENIX_MINOR_VERSION = 8;
 public static final int PHOENIX_PATCH_NUMBER = 0;
 public static final int PHOENIX_VERSION =
 VersionUtil.encodeVersion(PHOENIX_MAJOR_VERSION, 
PHOENIX_MINOR_VERSION, PHOENIX_PATCH_NUMBER);



phoenix git commit: PHOENIX-2845 Timestamp ignores nanos in literal expressions(Sergey Soldatov)

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-0.98 b4590f866 -> f887f4175


PHOENIX-2845 Timestamp ignores nanos in literal expressions(Sergey Soldatov)


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

Branch: refs/heads/4.x-HBase-0.98
Commit: f887f41755891633200d4e51b42034cb9f88948e
Parents: b4590f8
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:46:38 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:46:38 2016 +0530

--
 .../org/apache/phoenix/end2end/DateTimeIT.java  | 22 +
 .../apache/phoenix/end2end/UpsertValuesIT.java  |  1 +
 .../java/org/apache/phoenix/util/DateUtil.java  | 17 -
 .../org/apache/phoenix/util/DateUtilTest.java   | 25 
 4 files changed, 64 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/f887f417/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
index af8f0c1..7e407bc 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
@@ -693,4 +693,26 @@ public class DateTimeIT extends BaseHBaseManagedTimeIT {
 long actualTime = rs.getDate(1).getTime();
 assertTrue(Math.abs(actualTime - expectedTime) < MILLIS_IN_DAY);
 }
+@Test
+public void testSelectBetweenNanos() throws Exception {
+String ddl =
+"CREATE TABLE IF NOT EXISTS N1 (k1 INTEGER NOT NULL PRIMARY 
KEY, ts " +
+"TIMESTAMP(3))";
+conn.createStatement().execute(ddl);
+String dml = "UPSERT INTO N1 VALUES (1, TIMESTAMP'2015-01-01 
00:00:00.1')";
+conn.createStatement().execute(dml);
+dml = "UPSERT INTO N1 VALUES (2, TIMESTAMP'2015-01-01 
00:00:00.5')";
+conn.createStatement().execute(dml);
+dml = "UPSERT INTO N1 VALUES (3, TIMESTAMP'2015-01-01 
00:00:00.3')";
+conn.createStatement().execute(dml);
+conn.commit();
+
+ResultSet rs = conn.createStatement().executeQuery("SELECT k1,ts from 
N1 where ts between" +
+" TIMESTAMP'2015-01-01 00:00:00.2' AND 
TIMESTAMP'2015-01-01 00:00:00" +
+".4'");
+assertTrue(rs.next());
+assertEquals(3, rs.getInt(1));
+assertEquals(3, rs.getTimestamp(2).getNanos());
+assertFalse(rs.next());
+}
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/f887f417/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
index a7e70c1..5cefd7d 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
@@ -632,6 +632,7 @@ public class UpsertValuesIT extends BaseClientManagedTimeIT 
{
 
 Date date = toDate(dateStr);
 Timestamp timeStamp = new Timestamp(toDate(timeStampStr).getTime());
+timeStamp.setNanos(Timestamp.valueOf(timeStampStr).getNanos());
 Time time = new Time(toDate(timeStr).getTime());
 props.setProperty(PhoenixRuntime.CURRENT_SCN_ATTRIB, Long.toString(ts 
+ 4));
 try {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/f887f417/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
index 4d7c27c..557d8ed 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
@@ -32,6 +32,7 @@ import java.util.List;
 import java.util.TimeZone;
 
 import org.apache.commons.lang.time.FastDateFormat;
+import org.apache.hadoop.hbase.exceptions.IllegalArgumentIOException;
 import org.apache.phoenix.schema.IllegalDataException;
 import org.apache.phoenix.schema.types.PDataType;
 import org.joda.time.DateTimeZone;
@@ -17

phoenix git commit: PHOENIX-2845 Timestamp ignores nanos in literal expressions(Sergey Soldatov)

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master 4616e98e4 -> 32cf841c4


PHOENIX-2845 Timestamp ignores nanos in literal expressions(Sergey Soldatov)


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/32cf841c
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/32cf841c
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/32cf841c

Branch: refs/heads/master
Commit: 32cf841c467a18ffcc35e5c25c2cd87978b26918
Parents: 4616e98
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:46:06 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:46:06 2016 +0530

--
 .../org/apache/phoenix/end2end/DateTimeIT.java  | 22 +
 .../apache/phoenix/end2end/UpsertValuesIT.java  |  1 +
 .../java/org/apache/phoenix/util/DateUtil.java  | 17 -
 .../org/apache/phoenix/util/DateUtilTest.java   | 25 
 4 files changed, 64 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/32cf841c/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
index af8f0c1..7e407bc 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/DateTimeIT.java
@@ -693,4 +693,26 @@ public class DateTimeIT extends BaseHBaseManagedTimeIT {
 long actualTime = rs.getDate(1).getTime();
 assertTrue(Math.abs(actualTime - expectedTime) < MILLIS_IN_DAY);
 }
+@Test
+public void testSelectBetweenNanos() throws Exception {
+String ddl =
+"CREATE TABLE IF NOT EXISTS N1 (k1 INTEGER NOT NULL PRIMARY 
KEY, ts " +
+"TIMESTAMP(3))";
+conn.createStatement().execute(ddl);
+String dml = "UPSERT INTO N1 VALUES (1, TIMESTAMP'2015-01-01 
00:00:00.1')";
+conn.createStatement().execute(dml);
+dml = "UPSERT INTO N1 VALUES (2, TIMESTAMP'2015-01-01 
00:00:00.5')";
+conn.createStatement().execute(dml);
+dml = "UPSERT INTO N1 VALUES (3, TIMESTAMP'2015-01-01 
00:00:00.3')";
+conn.createStatement().execute(dml);
+conn.commit();
+
+ResultSet rs = conn.createStatement().executeQuery("SELECT k1,ts from 
N1 where ts between" +
+" TIMESTAMP'2015-01-01 00:00:00.2' AND 
TIMESTAMP'2015-01-01 00:00:00" +
+".4'");
+assertTrue(rs.next());
+assertEquals(3, rs.getInt(1));
+assertEquals(3, rs.getTimestamp(2).getNanos());
+assertFalse(rs.next());
+}
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/32cf841c/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
index a7e70c1..5cefd7d 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/UpsertValuesIT.java
@@ -632,6 +632,7 @@ public class UpsertValuesIT extends BaseClientManagedTimeIT 
{
 
 Date date = toDate(dateStr);
 Timestamp timeStamp = new Timestamp(toDate(timeStampStr).getTime());
+timeStamp.setNanos(Timestamp.valueOf(timeStampStr).getNanos());
 Time time = new Time(toDate(timeStr).getTime());
 props.setProperty(PhoenixRuntime.CURRENT_SCN_ATTRIB, Long.toString(ts 
+ 4));
 try {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/32cf841c/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
index 4d7c27c..557d8ed 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
@@ -32,6 +32,7 @@ import java.util.List;
 import java.util.TimeZone;
 
 import org.apache.commons.lang.time.FastDateFormat;
+import org.apache.hadoop.hbase.exceptions.IllegalArgumentIOException;
 import org.apache.phoenix.schema.IllegalDataException;
 import org.apache.phoenix.schema.types.PDataType;
 import org.joda.time.DateTimeZone;
@@ -172,7 +173,21 @@ 

[2/2] phoenix git commit: PHOENIX-2863 Let's roll up minor version to 8 (4.8.0) because of namespace compatibility checks

2016-05-05 Thread ankit
PHOENIX-2863 Let's roll up minor version to 8 (4.8.0) because of namespace 
compatibility checks


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/7b1db051
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/7b1db051
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/7b1db051

Branch: refs/heads/4.x-HBase-1.1
Commit: 7b1db0516786fc80b799e9382d8f16d23c75dbfa
Parents: 0e1d1eb
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:36:06 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:36:06 2016 +0530

--
 .../main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/7b1db051/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
index 8c86b56..f847b97 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
@@ -60,7 +60,7 @@ import com.google.protobuf.ByteString;
  */
 public abstract class MetaDataProtocol extends MetaDataService {
 public static final int PHOENIX_MAJOR_VERSION = 4;
-public static final int PHOENIX_MINOR_VERSION = 7;
+public static final int PHOENIX_MINOR_VERSION = 8;
 public static final int PHOENIX_PATCH_NUMBER = 0;
 public static final int PHOENIX_VERSION =
 VersionUtil.encodeVersion(PHOENIX_MAJOR_VERSION, 
PHOENIX_MINOR_VERSION, PHOENIX_PATCH_NUMBER);



[1/2] phoenix git commit: PHOENIX-2874 Delete schemas also during clean up after test

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 c7150ff8b -> 7b1db0516


PHOENIX-2874 Delete schemas also during clean up after test


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/0e1d1eb4
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/0e1d1eb4
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/0e1d1eb4

Branch: refs/heads/4.x-HBase-1.1
Commit: 0e1d1eb4e19a913b4ac669c653ecda2d1eb470a9
Parents: c7150ff
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:35:57 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:35:57 2016 +0530

--
 .../end2end/BaseClientManagedTimeIT.java|  2 +-
 .../phoenix/end2end/BaseHBaseManagedTimeIT.java |  2 +-
 .../BaseOwnClusterClientManagedTimeIT.java  |  2 +-
 .../BaseOwnClusterHBaseManagedTimeIT.java   |  2 +-
 .../apache/phoenix/end2end/CreateSchemaIT.java  |  2 +-
 .../apache/phoenix/end2end/DropSchemaIT.java| 21 +--
 .../query/ConnectionQueryServicesImpl.java  |  6 +-
 .../java/org/apache/phoenix/query/BaseTest.java | 66 ++--
 8 files changed, 87 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/0e1d1eb4/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
index 1acd5b3..dee7200 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
@@ -56,7 +56,7 @@ public abstract class BaseClientManagedTimeIT extends 
BaseTest {
 @After
 public void cleanUpAfterTest() throws Exception {
 long ts = nextTimestamp();
-deletePriorTables(ts - 1, getUrl());
+deletePriorMetaData(ts - 1, getUrl());
 }
 
 public static Map<String,String> getDefaultProps() {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/0e1d1eb4/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
index 3a811a8..7439b1d 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
@@ -64,6 +64,6 @@ public abstract class BaseHBaseManagedTimeIT extends BaseTest 
{
 
 @After
 public void cleanUpAfterTest() throws Exception {
-deletePriorTables(HConstants.LATEST_TIMESTAMP, getUrl());
+deletePriorMetaData(HConstants.LATEST_TIMESTAMP, getUrl());
 }
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/0e1d1eb4/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
index 01d8538..47f0bdd 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
@@ -26,6 +26,6 @@ public class BaseOwnClusterClientManagedTimeIT extends 
BaseOwnClusterIT {
 @After
 public void cleanUpAfterTest() throws Exception {
 long ts = nextTimestamp();
-deletePriorTables(ts - 1, getUrl());
+deletePriorMetaData(ts - 1, getUrl());
 }
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/0e1d1eb4/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
index d4096f9..cbb40a1 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
@@ -26,6 +26,6 @@ import org.junit.After;
 public class BaseOwnClusterHBaseManagedTimeIT extends BaseOwnClusterIT {
 @After
 public 

[1/2] phoenix git commit: PHOENIX-2874 Delete schemas also during clean up after test

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master d700c1f03 -> 4616e98e4


PHOENIX-2874 Delete schemas also during clean up after test


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/4f5961b1
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/4f5961b1
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/4f5961b1

Branch: refs/heads/master
Commit: 4f5961b1474f8a8edb25fca2a48055b3a61d6ce7
Parents: d700c1f
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:31:55 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:31:55 2016 +0530

--
 .../end2end/BaseClientManagedTimeIT.java|  2 +-
 .../phoenix/end2end/BaseHBaseManagedTimeIT.java |  2 +-
 .../BaseOwnClusterClientManagedTimeIT.java  |  2 +-
 .../BaseOwnClusterHBaseManagedTimeIT.java   |  2 +-
 .../apache/phoenix/end2end/CreateSchemaIT.java  |  2 +-
 .../apache/phoenix/end2end/DropSchemaIT.java| 21 +--
 .../query/ConnectionQueryServicesImpl.java  |  6 +-
 .../java/org/apache/phoenix/query/BaseTest.java | 66 ++--
 8 files changed, 87 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/4f5961b1/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
index 1acd5b3..dee7200 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseClientManagedTimeIT.java
@@ -56,7 +56,7 @@ public abstract class BaseClientManagedTimeIT extends 
BaseTest {
 @After
 public void cleanUpAfterTest() throws Exception {
 long ts = nextTimestamp();
-deletePriorTables(ts - 1, getUrl());
+deletePriorMetaData(ts - 1, getUrl());
 }
 
 public static Map<String,String> getDefaultProps() {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/4f5961b1/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
index 3a811a8..7439b1d 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseHBaseManagedTimeIT.java
@@ -64,6 +64,6 @@ public abstract class BaseHBaseManagedTimeIT extends BaseTest 
{
 
 @After
 public void cleanUpAfterTest() throws Exception {
-deletePriorTables(HConstants.LATEST_TIMESTAMP, getUrl());
+deletePriorMetaData(HConstants.LATEST_TIMESTAMP, getUrl());
 }
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/4f5961b1/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
index 01d8538..47f0bdd 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterClientManagedTimeIT.java
@@ -26,6 +26,6 @@ public class BaseOwnClusterClientManagedTimeIT extends 
BaseOwnClusterIT {
 @After
 public void cleanUpAfterTest() throws Exception {
 long ts = nextTimestamp();
-deletePriorTables(ts - 1, getUrl());
+deletePriorMetaData(ts - 1, getUrl());
 }
 }

http://git-wip-us.apache.org/repos/asf/phoenix/blob/4f5961b1/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
index d4096f9..cbb40a1 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/BaseOwnClusterHBaseManagedTimeIT.java
@@ -26,6 +26,6 @@ import org.junit.After;
 public class BaseOwnClusterHBaseManagedTimeIT extends BaseOwnClusterIT {
 @After
 public void clea

[2/2] phoenix git commit: PHOENIX-2863 Let's roll up minor version to 8 (4.8.0) because of namespace compatibility checks

2016-05-05 Thread ankit
PHOENIX-2863 Let's roll up minor version to 8 (4.8.0) because of namespace 
compatibility checks


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/4616e98e
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/4616e98e
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/4616e98e

Branch: refs/heads/master
Commit: 4616e98e45289289bca849db0fc3790345dbf937
Parents: 4f5961b
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 11:33:06 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 11:33:06 2016 +0530

--
 .../main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/4616e98e/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
index 8c86b56..f847b97 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/coprocessor/MetaDataProtocol.java
@@ -60,7 +60,7 @@ import com.google.protobuf.ByteString;
  */
 public abstract class MetaDataProtocol extends MetaDataService {
 public static final int PHOENIX_MAJOR_VERSION = 4;
-public static final int PHOENIX_MINOR_VERSION = 7;
+public static final int PHOENIX_MINOR_VERSION = 8;
 public static final int PHOENIX_PATCH_NUMBER = 0;
 public static final int PHOENIX_VERSION =
 VersionUtil.encodeVersion(PHOENIX_MAJOR_VERSION, 
PHOENIX_MINOR_VERSION, PHOENIX_PATCH_NUMBER);



phoenix git commit: PHOENIX-2845 Addendum Timestamp ignores nanos in literal expressions

2016-05-05 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 3507a9458 -> 2f114d2b2


PHOENIX-2845 Addendum Timestamp ignores nanos in literal expressions


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/2f114d2b
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/2f114d2b
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/2f114d2b

Branch: refs/heads/4.x-HBase-1.0
Commit: 2f114d2b2dbf06df2bbe740ad011874924c12079
Parents: 3507a94
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Thu May 5 13:23:28 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Thu May 5 13:23:28 2016 +0530

--
 phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java | 1 -
 1 file changed, 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/2f114d2b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
index 557d8ed..5032c38 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/DateUtil.java
@@ -32,7 +32,6 @@ import java.util.List;
 import java.util.TimeZone;
 
 import org.apache.commons.lang.time.FastDateFormat;
-import org.apache.hadoop.hbase.exceptions.IllegalArgumentIOException;
 import org.apache.phoenix.schema.IllegalDataException;
 import org.apache.phoenix.schema.types.PDataType;
 import org.joda.time.DateTimeZone;



[phoenix] Git Push Summary

2016-07-13 Thread ankit
Repository: phoenix
Updated Tags:  refs/tags/v4.8.0-HBase-1.2-rc0 [created] b0a71ea1a


[phoenix] Git Push Summary

2016-07-13 Thread ankit
Repository: phoenix
Updated Tags:  refs/tags/v4.8.0-HBase-1.2-rc0 [deleted] b0a71ea1a


[phoenix] Git Push Summary

2016-07-13 Thread ankit
Repository: phoenix
Updated Tags:  refs/tags/v4.8.0-HBase-1.2-rc0 [created] ea8df0c43


[phoenix] Git Push Summary

2016-07-29 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.8-HBase-1.0 [created] 23ac6a487


[phoenix] Git Push Summary

2016-07-29 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.8-HBase-1.1 [created] e8cb5de17


[phoenix] Git Push Summary

2016-07-29 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.8-HBase-0.98 [created] 3fc406698


[phoenix] Git Push Summary

2016-07-29 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.8-HBase-1.2 [created] cb21c8175


svn commit: r14755 - /release/phoenix/KEYS

2016-08-10 Thread ankit
Author: ankit
Date: Wed Aug 10 17:40:01 2016
New Revision: 14755

Log:
KEYS file updated with Ankit Singhal Key

Modified:
release/phoenix/KEYS

Modified: release/phoenix/KEYS
==
--- release/phoenix/KEYS (original)
+++ release/phoenix/KEYS Wed Aug 10 17:40:01 2016
@@ -165,3 +165,61 @@ uai6r4b7ujS8mtRIH0aDJ8bupmx1NL9IS06zwfc2
 8op2tTQBURD4fvMmk1lYMZo5tuuHZIrLHM78daL752ocq+THn++qdROzlta/
 =aE5F
 -END PGP PUBLIC KEY BLOCK-
+pub   4096R/79FA8AEB 2016-06-22
+uid  Ankit Singhal (CODE SIGNING KEY) <an...@apache.org>
+sig 379FA8AEB 2016-06-22  Ankit Singhal (CODE SIGNING KEY) 
<an...@apache.org>
+sub   4096R/95770845 2016-06-22
+sig  79FA8AEB 2016-06-22  Ankit Singhal (CODE SIGNING KEY) 
<an...@apache.org>
+
+-BEGIN PGP PUBLIC KEY BLOCK-
+Version: GnuPG v1
+
+mQINBFdrI3YBEACwSDbkxMnW9E8BIUFIh9abjG7o3BIIYSK4k888fOwg/Pr5rvmM
+S9zmf/sgvLa0nTbzq6Va0w0rF0XTdS8jKSHUhuOlWtEs4V9h3J9nzi10u0vU6oVy
+gVfUr1lXPEnKa5pbrrNliWTdAl3Mlzq9eRECdNzY4K5qMmymGx5+ZVHFPi3sfAmX
+lp0b56IOiBjzyLipqcHYc2y1GTvbLEKmd4GQZEUozh+h5SWNBHO2SxdZA0pCad13
+616o16d6nUisifznyvJBW0XEimUt7AaSsyEcZFBF2G9HGHf4C5AyK2Pm/YYiiLD4
+we0Yr0ip67MS3ck9X13HyDY3RV6ak/h+YcW/haEX1nL/nsz2aetvtG5ThHGgbgxt
+YzdCbJFWGKhSVKosyfZcpAzcxbww9BGr950SilSoQ31puovVjG1zLBYrTeSuZmIW
+EiP6dJxT2jwgVmGRfpro6O5PDyta2Kxnch5Q/L8DlIHJzwEAcFEgVt4tAEBvS8xY
+m3oSq2KZdVxVuJ0dAKAFDdxxWHxy8JxvQFjPVlcfvIqfvNqgmHGCv0YbrV1fvlU9
+JD9YKz1erk9sjUVkh1T2PPGnXaT7ljY2EngYLW69N4HTw9XDpBAtHKSteGvUNetj
+QLrCkW+dmAktBUBY6cUwM68Rj9oRgfNW6F/IV8oi87wKIpNpWDYiCgiOkwARAQAB
+tDNBbmtpdCBTaW5naGFsIChDT0RFIFNJR05JTkcgS0VZKSA8YW5raXRAYXBhY2hl
+Lm9yZz6JAjkEEwECACMCGwMCHgECF4AFAldrJegGCwkIBwMCBhUKCQgLAgUWAgMB
+AAAKCRANSO8XefqK6/D3EACpZ0rsprDZXruZk72OtXPYkxDcgrU55QSI1p5LFu0e
+MEmdWPQ5RCzuZfaPvkG0ZKM7SEZxJ146HBTy795cgGhpoYRb9ipM9js721KawbDB
+Warr3RWxIbrJQjcEITaKh8hpNJLxY8hsW6vREgiMb+iSxD76+WmedcuTEWEHyv7x
+ryedl+RbT8RFp/8UBCJy/D9XOiGye3pBFbYHZP0kfv7IOxnlYEb8EVgutAVB6xNF
+92rrsjEuHupevQbssOEpOB8s6AaOC4CSVAY+BlFzMDR6RYu1Mf80WNGR7dB8pwrj
+g8JOrcHEFhwZRvLwcfr/v77hQ3zw7QZ12ur4UemRxjItArSaKIDlXh7gs8pilVfH
+ysIx4FXnhG8sGopSWcZEXoIowE+jtc7z94LDlRKLhRIuaQZgiM7pSrpcYAW8SQEb
+bjICPTNTME7wSZyrPTanSU9wX5A08T2o667CELl98eTDeRhj16URB3ve16jK97OY
+E/vERxKtMFvR7FVe6HgPO70y5L4M4qbAgDivC+UlILTw6dKAkduPx0rXj9IRVaFp
+Q1efBhkglkh2W5zR/6KCGIXXIIJ9IDIl/YQUxNmAEKILva8BROY2Kg1FkypCTTSs
+WOSNpIKHpS2/XzptZhIkMuqGI61dRQH1u/zIiCRLk/bz+UHUXzbfzgvHlwX9uIp4
+BLkCDQRXayN2ARAArZQAFLFIz6pc/3rjBvpugLroZyypIzFKUomH+8URtJzYdeb8
+SN2Xn73LKnfADlkny4wX89Shl7ZW82GzANB4pXj2nCBNct6g/vMzbDWFWZgPVYHM
+130KFsaFnex1NRheiVdTai4s6QspqpAlfeNmrjxB53dYDCFbx96MuCaT0ZGnUt27
+PhM3kfMAZG1N37Lub8HHjaS9lDyca0Ofs6IlJX0y9SgoeAfeXQl2JsNRwjqblhEV
+MwDH78mrmJYVJkeKEDeOTe2X+vxoYdkDIxBAcoYulfkvvIoQ8dnNUQZiJ3crqRWY
+D+oQlrsRI1Yaeb6H6JhaTnQPgbPu6WkNs0SzdBLzOMfPPnDxYwbK4PMgqxOxqpXX
+3ooyBFxzi2bjeABJdnkyFs3Ewn1WbK3tB4rZi/xZghhRJPaQgPHVME8kCswh82lo
+3lzQy7tD5Rep+7N5OzhwmqSlhgqeIR+D/5WZazsEwF7vmtcLGQVQt9Y/0sZrcD8Y
+2vmwaAB/yWU9aXDg1yad13k1LfEDsf7mvVWnvKdIkkUXqkRSl+pbHvU2JqZ9kPvZ
+VrII6rwUdpp7qRTDtJeNaIlGZkpfVlfNEsXttS6VpIohhvnEi73OG9ClQfUznkzS
+1yyBhdQg5kGN75BbAOLYzWd/c9kXup0Axv/V9+EHwG0Or2+uVG1AWjRes0cAEQEA
+AYkCHwQYAQIACQUCV2sjdgIbDAAKCRANSO8XefqK6/wPD/49Y33UPALWQxrrK8jm
+vUo4p+sND4bZlKYw8225AUxrL0x5CEh/l2tLcX2Y23i5XI1WUnz8pfdFhCLSlssl
+RHz7YcFrXM2qXHvjd76nQ58pHY8mdvY5KJI0GTjjWz21fxE5sKSuVi9SampoaVHk
+n+pyVcNzZMZiy7wz+gtlQID2wkk5soPjbuEGyVgHavEsYd7l1NZOphBz0iMjsCL6
+aUpW+o12mNCenc1aJB2s9zMTlL+C6tdGrnHHT9hSbSWeuplN+u/jPTY18YE0I9nV
+U5wc2uwmgbwam5i2G8M1WvbbzS4t2KN/7MJ6zTIS3Om6QD+CMHLr1N5n53K7gai3
+gxXZwCxIbZHZq8yyxzfsa+mTJKqHWiSatyRga9FKt2CodNlUH7MtwlEUICmeWju0
+lph7gRzJ6Iuel5Ya+LIVX9qdULmu9ylCkY6bsZgkQSWCu815gU7g73zqCSrISw1B
+fjgjbagOwp+FWCg0kteVxouzBPSIJXSLiBvfhI3g3X+IF7X0Ul6JoqHv3M18A4VY
+pZdF1i7aGjqd5+fYRMMFYz8vuhkJR71M9E4yAutODpxliTexSQP5dH8MvoLVMiIj
+b4Ki2TbCKOPwRYX6+b2vmmOUlZ28yjeAhzHKXS9lh7nY2T+cv5cwkPZ1uw2AKG55
+pcl2PvSVaZeoTjguW8BqFjkEzA==
+=p/IB
+-END PGP PUBLIC KEY BLOCK-




phoenix git commit: PHOENIX-3143 Update KEYS file for 4.8 release

2016-08-03 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.0 01f421a88 -> a231d8faa


PHOENIX-3143 Update KEYS file for 4.8 release


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

Branch: refs/heads/4.x-HBase-1.0
Commit: a231d8faab50d5f2448edaa83d8143a22aab2f72
Parents: 01f421a
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Wed Aug 3 14:23:12 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Wed Aug 3 14:23:12 2016 +0530

--
 KEYS | 58 ++
 1 file changed, 58 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/a231d8fa/KEYS
--
diff --git a/KEYS b/KEYS
index ea1f187..dca2b38 100644
--- a/KEYS
+++ b/KEYS
@@ -71,3 +71,61 @@ 
fMFOWYmlNK8cL+Z7zaEOFYF5ug/i0hZhhzKZc03ryhEaIEVB9Un62rLnbmgIQxF6
 GR2wPntvTGNAWEcuwD1/D1gws5A=
 =nO9e
 -END PGP PUBLIC KEY BLOCK-
+pub   4096R/79FA8AEB 2016-06-22
+uid      Ankit Singhal (CODE SIGNING KEY) <an...@apache.org>
+sig 379FA8AEB 2016-06-22  Ankit Singhal (CODE SIGNING KEY) 
<an...@apache.org>
+sub   4096R/95770845 2016-06-22
+sig  79FA8AEB 2016-06-22  Ankit Singhal (CODE SIGNING KEY) 
<an...@apache.org>
+
+-BEGIN PGP PUBLIC KEY BLOCK-
+Version: GnuPG v1
+
+mQINBFdrI3YBEACwSDbkxMnW9E8BIUFIh9abjG7o3BIIYSK4k888fOwg/Pr5rvmM
+S9zmf/sgvLa0nTbzq6Va0w0rF0XTdS8jKSHUhuOlWtEs4V9h3J9nzi10u0vU6oVy
+gVfUr1lXPEnKa5pbrrNliWTdAl3Mlzq9eRECdNzY4K5qMmymGx5+ZVHFPi3sfAmX
+lp0b56IOiBjzyLipqcHYc2y1GTvbLEKmd4GQZEUozh+h5SWNBHO2SxdZA0pCad13
+616o16d6nUisifznyvJBW0XEimUt7AaSsyEcZFBF2G9HGHf4C5AyK2Pm/YYiiLD4
+we0Yr0ip67MS3ck9X13HyDY3RV6ak/h+YcW/haEX1nL/nsz2aetvtG5ThHGgbgxt
+YzdCbJFWGKhSVKosyfZcpAzcxbww9BGr950SilSoQ31puovVjG1zLBYrTeSuZmIW
+EiP6dJxT2jwgVmGRfpro6O5PDyta2Kxnch5Q/L8DlIHJzwEAcFEgVt4tAEBvS8xY
+m3oSq2KZdVxVuJ0dAKAFDdxxWHxy8JxvQFjPVlcfvIqfvNqgmHGCv0YbrV1fvlU9
+JD9YKz1erk9sjUVkh1T2PPGnXaT7ljY2EngYLW69N4HTw9XDpBAtHKSteGvUNetj
+QLrCkW+dmAktBUBY6cUwM68Rj9oRgfNW6F/IV8oi87wKIpNpWDYiCgiOkwARAQAB
+tDNBbmtpdCBTaW5naGFsIChDT0RFIFNJR05JTkcgS0VZKSA8YW5raXRAYXBhY2hl
+Lm9yZz6JAjkEEwECACMCGwMCHgECF4AFAldrJegGCwkIBwMCBhUKCQgLAgUWAgMB
+AAAKCRANSO8XefqK6/D3EACpZ0rsprDZXruZk72OtXPYkxDcgrU55QSI1p5LFu0e
+MEmdWPQ5RCzuZfaPvkG0ZKM7SEZxJ146HBTy795cgGhpoYRb9ipM9js721KawbDB
+Warr3RWxIbrJQjcEITaKh8hpNJLxY8hsW6vREgiMb+iSxD76+WmedcuTEWEHyv7x
+ryedl+RbT8RFp/8UBCJy/D9XOiGye3pBFbYHZP0kfv7IOxnlYEb8EVgutAVB6xNF
+92rrsjEuHupevQbssOEpOB8s6AaOC4CSVAY+BlFzMDR6RYu1Mf80WNGR7dB8pwrj
+g8JOrcHEFhwZRvLwcfr/v77hQ3zw7QZ12ur4UemRxjItArSaKIDlXh7gs8pilVfH
+ysIx4FXnhG8sGopSWcZEXoIowE+jtc7z94LDlRKLhRIuaQZgiM7pSrpcYAW8SQEb
+bjICPTNTME7wSZyrPTanSU9wX5A08T2o667CELl98eTDeRhj16URB3ve16jK97OY
+E/vERxKtMFvR7FVe6HgPO70y5L4M4qbAgDivC+UlILTw6dKAkduPx0rXj9IRVaFp
+Q1efBhkglkh2W5zR/6KCGIXXIIJ9IDIl/YQUxNmAEKILva8BROY2Kg1FkypCTTSs
+WOSNpIKHpS2/XzptZhIkMuqGI61dRQH1u/zIiCRLk/bz+UHUXzbfzgvHlwX9uIp4
+BLkCDQRXayN2ARAArZQAFLFIz6pc/3rjBvpugLroZyypIzFKUomH+8URtJzYdeb8
+SN2Xn73LKnfADlkny4wX89Shl7ZW82GzANB4pXj2nCBNct6g/vMzbDWFWZgPVYHM
+130KFsaFnex1NRheiVdTai4s6QspqpAlfeNmrjxB53dYDCFbx96MuCaT0ZGnUt27
+PhM3kfMAZG1N37Lub8HHjaS9lDyca0Ofs6IlJX0y9SgoeAfeXQl2JsNRwjqblhEV
+MwDH78mrmJYVJkeKEDeOTe2X+vxoYdkDIxBAcoYulfkvvIoQ8dnNUQZiJ3crqRWY
+D+oQlrsRI1Yaeb6H6JhaTnQPgbPu6WkNs0SzdBLzOMfPPnDxYwbK4PMgqxOxqpXX
+3ooyBFxzi2bjeABJdnkyFs3Ewn1WbK3tB4rZi/xZghhRJPaQgPHVME8kCswh82lo
+3lzQy7tD5Rep+7N5OzhwmqSlhgqeIR+D/5WZazsEwF7vmtcLGQVQt9Y/0sZrcD8Y
+2vmwaAB/yWU9aXDg1yad13k1LfEDsf7mvVWnvKdIkkUXqkRSl+pbHvU2JqZ9kPvZ
+VrII6rwUdpp7qRTDtJeNaIlGZkpfVlfNEsXttS6VpIohhvnEi73OG9ClQfUznkzS
+1yyBhdQg5kGN75BbAOLYzWd/c9kXup0Axv/V9+EHwG0Or2+uVG1AWjRes0cAEQEA
+AYkCHwQYAQIACQUCV2sjdgIbDAAKCRANSO8XefqK6/wPD/49Y33UPALWQxrrK8jm
+vUo4p+sND4bZlKYw8225AUxrL0x5CEh/l2tLcX2Y23i5XI1WUnz8pfdFhCLSlssl
+RHz7YcFrXM2qXHvjd76nQ58pHY8mdvY5KJI0GTjjWz21fxE5sKSuVi9SampoaVHk
+n+pyVcNzZMZiy7wz+gtlQID2wkk5soPjbuEGyVgHavEsYd7l1NZOphBz0iMjsCL6
+aUpW+o12mNCenc1aJB2s9zMTlL+C6tdGrnHHT9hSbSWeuplN+u/jPTY18YE0I9nV
+U5wc2uwmgbwam5i2G8M1WvbbzS4t2KN/7MJ6zTIS3Om6QD+CMHLr1N5n53K7gai3
+gxXZwCxIbZHZq8yyxzfsa+mTJKqHWiSatyRga9FKt2CodNlUH7MtwlEUICmeWju0
+lph7gRzJ6Iuel5Ya+LIVX9qdULmu9ylCkY6bsZgkQSWCu815gU7g73zqCSrISw1B
+fjgjbagOwp+FWCg0kteVxouzBPSIJXSLiBvfhI3g3X+IF7X0Ul6JoqHv3M18A4VY
+pZdF1i7aGjqd5+fYRMMFYz8vuhkJR71M9E4yAutODpxliTexSQP5dH8MvoLVMiIj
+b4Ki2TbCKOPwRYX6+b2vmmOUlZ28yjeAhzHKXS9lh7nY2T+cv5cwkPZ1uw2AKG55
+pcl2PvSVaZeoTjguW8BqFjkEzA==
+=p/IB
+-END PGP PUBLIC KEY BLOCK-



phoenix git commit: PHOENIX-3143 Update KEYS file for 4.8 release

2016-08-03 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.1 61d7e946d -> 5ed82b09c


PHOENIX-3143 Update KEYS file for 4.8 release


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/5ed82b09
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/5ed82b09
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/5ed82b09

Branch: refs/heads/4.x-HBase-1.1
Commit: 5ed82b09c281d6da24c97d60f9b81a0f14764796
Parents: 61d7e94
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Wed Aug 3 14:23:43 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Wed Aug 3 14:23:43 2016 +0530

--
 KEYS | 58 ++
 1 file changed, 58 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/5ed82b09/KEYS
--
diff --git a/KEYS b/KEYS
index ea1f187..dca2b38 100644
--- a/KEYS
+++ b/KEYS
@@ -71,3 +71,61 @@ 
fMFOWYmlNK8cL+Z7zaEOFYF5ug/i0hZhhzKZc03ryhEaIEVB9Un62rLnbmgIQxF6
 GR2wPntvTGNAWEcuwD1/D1gws5A=
 =nO9e
 -END PGP PUBLIC KEY BLOCK-
+pub   4096R/79FA8AEB 2016-06-22
+uid      Ankit Singhal (CODE SIGNING KEY) <an...@apache.org>
+sig 379FA8AEB 2016-06-22  Ankit Singhal (CODE SIGNING KEY) 
<an...@apache.org>
+sub   4096R/95770845 2016-06-22
+sig  79FA8AEB 2016-06-22  Ankit Singhal (CODE SIGNING KEY) 
<an...@apache.org>
+
+-BEGIN PGP PUBLIC KEY BLOCK-
+Version: GnuPG v1
+
+mQINBFdrI3YBEACwSDbkxMnW9E8BIUFIh9abjG7o3BIIYSK4k888fOwg/Pr5rvmM
+S9zmf/sgvLa0nTbzq6Va0w0rF0XTdS8jKSHUhuOlWtEs4V9h3J9nzi10u0vU6oVy
+gVfUr1lXPEnKa5pbrrNliWTdAl3Mlzq9eRECdNzY4K5qMmymGx5+ZVHFPi3sfAmX
+lp0b56IOiBjzyLipqcHYc2y1GTvbLEKmd4GQZEUozh+h5SWNBHO2SxdZA0pCad13
+616o16d6nUisifznyvJBW0XEimUt7AaSsyEcZFBF2G9HGHf4C5AyK2Pm/YYiiLD4
+we0Yr0ip67MS3ck9X13HyDY3RV6ak/h+YcW/haEX1nL/nsz2aetvtG5ThHGgbgxt
+YzdCbJFWGKhSVKosyfZcpAzcxbww9BGr950SilSoQ31puovVjG1zLBYrTeSuZmIW
+EiP6dJxT2jwgVmGRfpro6O5PDyta2Kxnch5Q/L8DlIHJzwEAcFEgVt4tAEBvS8xY
+m3oSq2KZdVxVuJ0dAKAFDdxxWHxy8JxvQFjPVlcfvIqfvNqgmHGCv0YbrV1fvlU9
+JD9YKz1erk9sjUVkh1T2PPGnXaT7ljY2EngYLW69N4HTw9XDpBAtHKSteGvUNetj
+QLrCkW+dmAktBUBY6cUwM68Rj9oRgfNW6F/IV8oi87wKIpNpWDYiCgiOkwARAQAB
+tDNBbmtpdCBTaW5naGFsIChDT0RFIFNJR05JTkcgS0VZKSA8YW5raXRAYXBhY2hl
+Lm9yZz6JAjkEEwECACMCGwMCHgECF4AFAldrJegGCwkIBwMCBhUKCQgLAgUWAgMB
+AAAKCRANSO8XefqK6/D3EACpZ0rsprDZXruZk72OtXPYkxDcgrU55QSI1p5LFu0e
+MEmdWPQ5RCzuZfaPvkG0ZKM7SEZxJ146HBTy795cgGhpoYRb9ipM9js721KawbDB
+Warr3RWxIbrJQjcEITaKh8hpNJLxY8hsW6vREgiMb+iSxD76+WmedcuTEWEHyv7x
+ryedl+RbT8RFp/8UBCJy/D9XOiGye3pBFbYHZP0kfv7IOxnlYEb8EVgutAVB6xNF
+92rrsjEuHupevQbssOEpOB8s6AaOC4CSVAY+BlFzMDR6RYu1Mf80WNGR7dB8pwrj
+g8JOrcHEFhwZRvLwcfr/v77hQ3zw7QZ12ur4UemRxjItArSaKIDlXh7gs8pilVfH
+ysIx4FXnhG8sGopSWcZEXoIowE+jtc7z94LDlRKLhRIuaQZgiM7pSrpcYAW8SQEb
+bjICPTNTME7wSZyrPTanSU9wX5A08T2o667CELl98eTDeRhj16URB3ve16jK97OY
+E/vERxKtMFvR7FVe6HgPO70y5L4M4qbAgDivC+UlILTw6dKAkduPx0rXj9IRVaFp
+Q1efBhkglkh2W5zR/6KCGIXXIIJ9IDIl/YQUxNmAEKILva8BROY2Kg1FkypCTTSs
+WOSNpIKHpS2/XzptZhIkMuqGI61dRQH1u/zIiCRLk/bz+UHUXzbfzgvHlwX9uIp4
+BLkCDQRXayN2ARAArZQAFLFIz6pc/3rjBvpugLroZyypIzFKUomH+8URtJzYdeb8
+SN2Xn73LKnfADlkny4wX89Shl7ZW82GzANB4pXj2nCBNct6g/vMzbDWFWZgPVYHM
+130KFsaFnex1NRheiVdTai4s6QspqpAlfeNmrjxB53dYDCFbx96MuCaT0ZGnUt27
+PhM3kfMAZG1N37Lub8HHjaS9lDyca0Ofs6IlJX0y9SgoeAfeXQl2JsNRwjqblhEV
+MwDH78mrmJYVJkeKEDeOTe2X+vxoYdkDIxBAcoYulfkvvIoQ8dnNUQZiJ3crqRWY
+D+oQlrsRI1Yaeb6H6JhaTnQPgbPu6WkNs0SzdBLzOMfPPnDxYwbK4PMgqxOxqpXX
+3ooyBFxzi2bjeABJdnkyFs3Ewn1WbK3tB4rZi/xZghhRJPaQgPHVME8kCswh82lo
+3lzQy7tD5Rep+7N5OzhwmqSlhgqeIR+D/5WZazsEwF7vmtcLGQVQt9Y/0sZrcD8Y
+2vmwaAB/yWU9aXDg1yad13k1LfEDsf7mvVWnvKdIkkUXqkRSl+pbHvU2JqZ9kPvZ
+VrII6rwUdpp7qRTDtJeNaIlGZkpfVlfNEsXttS6VpIohhvnEi73OG9ClQfUznkzS
+1yyBhdQg5kGN75BbAOLYzWd/c9kXup0Axv/V9+EHwG0Or2+uVG1AWjRes0cAEQEA
+AYkCHwQYAQIACQUCV2sjdgIbDAAKCRANSO8XefqK6/wPD/49Y33UPALWQxrrK8jm
+vUo4p+sND4bZlKYw8225AUxrL0x5CEh/l2tLcX2Y23i5XI1WUnz8pfdFhCLSlssl
+RHz7YcFrXM2qXHvjd76nQ58pHY8mdvY5KJI0GTjjWz21fxE5sKSuVi9SampoaVHk
+n+pyVcNzZMZiy7wz+gtlQID2wkk5soPjbuEGyVgHavEsYd7l1NZOphBz0iMjsCL6
+aUpW+o12mNCenc1aJB2s9zMTlL+C6tdGrnHHT9hSbSWeuplN+u/jPTY18YE0I9nV
+U5wc2uwmgbwam5i2G8M1WvbbzS4t2KN/7MJ6zTIS3Om6QD+CMHLr1N5n53K7gai3
+gxXZwCxIbZHZq8yyxzfsa+mTJKqHWiSatyRga9FKt2CodNlUH7MtwlEUICmeWju0
+lph7gRzJ6Iuel5Ya+LIVX9qdULmu9ylCkY6bsZgkQSWCu815gU7g73zqCSrISw1B
+fjgjbagOwp+FWCg0kteVxouzBPSIJXSLiBvfhI3g3X+IF7X0Ul6JoqHv3M18A4VY
+pZdF1i7aGjqd5+fYRMMFYz8vuhkJR71M9E4yAutODpxliTexSQP5dH8MvoLVMiIj
+b4Ki2TbCKOPwRYX6+b2vmmOUlZ28yjeAhzHKXS9lh7nY2T+cv5cwkPZ1uw2AKG55
+pcl2PvSVaZeoTjguW8BqFjkEzA==
+=p/IB
+-END PGP PUBLIC KEY BLOCK-



svn commit: r14650 - in /dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1: ./ bin/ src/

2016-08-03 Thread ankit
Author: ankit
Date: Wed Aug  3 09:50:04 2016
New Revision: 14650

Log:
Apache Phoenix 4.8.0-HBase-1.0-rc1

Added:
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/

dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz
   (with props)

dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.asc

dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.md5

dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.sha
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/

dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz
   (with props)

dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.asc

dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.md5

dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.sha

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz
==
Binary file - no diff available.

Propchange: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz
--
svn:mime-type = application/octet-stream

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.asc
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.asc
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.asc
 Wed Aug  3 09:50:04 2016
@@ -0,0 +1,17 @@
+-BEGIN PGP SIGNATURE-
+Version: GnuPG v2.0.14 (GNU/Linux)
+
+iQIcBAABAgAGBQJXob3kAAoJEA1I7xd5+orryTMP/idNANMSWvg1g5T7i75wHC5M
+tx7S2WFUm+/jjncclcC7E/yF59szv1Obr8R5FUjmJvUUh8ofevHeGBcGOq6ECw8o
+CRojnzn1TjDtZ6pwrJa7qrJkRPilbC5kVA6tp303iDoVO6HAMafW5h1IpX9LtdZ5
+L2rzANEmRTaZyhk3CAhx3B7DsNEEJyGk4i+epXPPGMQM4d8leeOFTG8aTwr8WgDL
+mZC+u/BvdDiSEg+3YVoKH8z7xfiUWBlPzL2ffuaCmJxZcOHQjqJqlHwWsExCBFev
+qq6QcUXH4df33nru22Cjbz+mMsuEsGWiJqCyo3EFUXg3exV0TWszo3YBIZJ0kH95
++lSOLGM13R8N3ApudXo2Y35zE2K6M7KqLNqUo6amrPAuA25OWcrGHfA8yJUDEyqp
+yp5AdGrvhRkSyxY+JuiQF5u4L5bYpx4bP7c3pMaB72pv80DHh1OCsUF9B8QFcmWS
+Z97t7m+GCAOgaNyhWbtwNXwIE6yhMYvkRwWf0Ri0vp7shQskehw/QlRc7z8vYCKk
+/6kF4Qo6T+k/2e0DWhkdbvaaPMSamOyi3sudiJs7i0kyc1G+o1RtKEBdAuY6CMPF
+l3Ht1Ian+OYvvfLIm3huLv7dsOS86wT0XKejCATxzPRovK0sXgVX8vSp+YjOW1Jk
+B1STeZKREdCQqOsU3r9y
+=gDx+
+-END PGP SIGNATURE-

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.md5
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.md5
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.md5
 Wed Aug  3 09:50:04 2016
@@ -0,0 +1 @@
+755c114b6a84e89b0030867a74c7eec7 *apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.sha
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.sha
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.sha
 Wed Aug  3 09:50:04 2016
@@ -0,0 +1,2 @@
+05dfd84a1f7a2b07e1a387aaaba737b4c857f9ecc41a6704fcbd2dbb532e7e547686dfecfc9a9d9e713700d97628a0773d06afc471d97f82f6d285d872c621ef
 *apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz
+206d437fb79e6432e2d6df63a4a2a828899b77006b219d21f9b074d73d742871 
*apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz
==
Binary file - no diff available.

Propchange: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz
--
svn:mime-type = application/octet-stream

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.asc
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.asc
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.0-rc1/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.asc
 Wed Aug  3 09:50:04 2016
@@ -0,0 +1,17 @@
+-BEGIN PGP

phoenix git commit: PHOENIX-3143 Update KEYS file for 4.8 release

2016-08-03 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/master 27c4027fd -> 0b91b45aa


PHOENIX-3143 Update KEYS file for 4.8 release


Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo
Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/0b91b45a
Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/0b91b45a
Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/0b91b45a

Branch: refs/heads/master
Commit: 0b91b45aa2b4885a47c3641e55b612b8a351e1b2
Parents: 27c4027
Author: Ankit Singhal <ankitsingha...@gmail.com>
Authored: Wed Aug 3 14:17:25 2016 +0530
Committer: Ankit Singhal <ankitsingha...@gmail.com>
Committed: Wed Aug 3 14:17:25 2016 +0530

--
 KEYS | 58 ++
 1 file changed, 58 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/0b91b45a/KEYS
--
diff --git a/KEYS b/KEYS
index ea1f187..dca2b38 100644
--- a/KEYS
+++ b/KEYS
@@ -71,3 +71,61 @@ 
fMFOWYmlNK8cL+Z7zaEOFYF5ug/i0hZhhzKZc03ryhEaIEVB9Un62rLnbmgIQxF6
 GR2wPntvTGNAWEcuwD1/D1gws5A=
 =nO9e
 -END PGP PUBLIC KEY BLOCK-
+pub   4096R/79FA8AEB 2016-06-22
+uid      Ankit Singhal (CODE SIGNING KEY) <an...@apache.org>
+sig 379FA8AEB 2016-06-22  Ankit Singhal (CODE SIGNING KEY) 
<an...@apache.org>
+sub   4096R/95770845 2016-06-22
+sig  79FA8AEB 2016-06-22  Ankit Singhal (CODE SIGNING KEY) 
<an...@apache.org>
+
+-BEGIN PGP PUBLIC KEY BLOCK-
+Version: GnuPG v1
+
+mQINBFdrI3YBEACwSDbkxMnW9E8BIUFIh9abjG7o3BIIYSK4k888fOwg/Pr5rvmM
+S9zmf/sgvLa0nTbzq6Va0w0rF0XTdS8jKSHUhuOlWtEs4V9h3J9nzi10u0vU6oVy
+gVfUr1lXPEnKa5pbrrNliWTdAl3Mlzq9eRECdNzY4K5qMmymGx5+ZVHFPi3sfAmX
+lp0b56IOiBjzyLipqcHYc2y1GTvbLEKmd4GQZEUozh+h5SWNBHO2SxdZA0pCad13
+616o16d6nUisifznyvJBW0XEimUt7AaSsyEcZFBF2G9HGHf4C5AyK2Pm/YYiiLD4
+we0Yr0ip67MS3ck9X13HyDY3RV6ak/h+YcW/haEX1nL/nsz2aetvtG5ThHGgbgxt
+YzdCbJFWGKhSVKosyfZcpAzcxbww9BGr950SilSoQ31puovVjG1zLBYrTeSuZmIW
+EiP6dJxT2jwgVmGRfpro6O5PDyta2Kxnch5Q/L8DlIHJzwEAcFEgVt4tAEBvS8xY
+m3oSq2KZdVxVuJ0dAKAFDdxxWHxy8JxvQFjPVlcfvIqfvNqgmHGCv0YbrV1fvlU9
+JD9YKz1erk9sjUVkh1T2PPGnXaT7ljY2EngYLW69N4HTw9XDpBAtHKSteGvUNetj
+QLrCkW+dmAktBUBY6cUwM68Rj9oRgfNW6F/IV8oi87wKIpNpWDYiCgiOkwARAQAB
+tDNBbmtpdCBTaW5naGFsIChDT0RFIFNJR05JTkcgS0VZKSA8YW5raXRAYXBhY2hl
+Lm9yZz6JAjkEEwECACMCGwMCHgECF4AFAldrJegGCwkIBwMCBhUKCQgLAgUWAgMB
+AAAKCRANSO8XefqK6/D3EACpZ0rsprDZXruZk72OtXPYkxDcgrU55QSI1p5LFu0e
+MEmdWPQ5RCzuZfaPvkG0ZKM7SEZxJ146HBTy795cgGhpoYRb9ipM9js721KawbDB
+Warr3RWxIbrJQjcEITaKh8hpNJLxY8hsW6vREgiMb+iSxD76+WmedcuTEWEHyv7x
+ryedl+RbT8RFp/8UBCJy/D9XOiGye3pBFbYHZP0kfv7IOxnlYEb8EVgutAVB6xNF
+92rrsjEuHupevQbssOEpOB8s6AaOC4CSVAY+BlFzMDR6RYu1Mf80WNGR7dB8pwrj
+g8JOrcHEFhwZRvLwcfr/v77hQ3zw7QZ12ur4UemRxjItArSaKIDlXh7gs8pilVfH
+ysIx4FXnhG8sGopSWcZEXoIowE+jtc7z94LDlRKLhRIuaQZgiM7pSrpcYAW8SQEb
+bjICPTNTME7wSZyrPTanSU9wX5A08T2o667CELl98eTDeRhj16URB3ve16jK97OY
+E/vERxKtMFvR7FVe6HgPO70y5L4M4qbAgDivC+UlILTw6dKAkduPx0rXj9IRVaFp
+Q1efBhkglkh2W5zR/6KCGIXXIIJ9IDIl/YQUxNmAEKILva8BROY2Kg1FkypCTTSs
+WOSNpIKHpS2/XzptZhIkMuqGI61dRQH1u/zIiCRLk/bz+UHUXzbfzgvHlwX9uIp4
+BLkCDQRXayN2ARAArZQAFLFIz6pc/3rjBvpugLroZyypIzFKUomH+8URtJzYdeb8
+SN2Xn73LKnfADlkny4wX89Shl7ZW82GzANB4pXj2nCBNct6g/vMzbDWFWZgPVYHM
+130KFsaFnex1NRheiVdTai4s6QspqpAlfeNmrjxB53dYDCFbx96MuCaT0ZGnUt27
+PhM3kfMAZG1N37Lub8HHjaS9lDyca0Ofs6IlJX0y9SgoeAfeXQl2JsNRwjqblhEV
+MwDH78mrmJYVJkeKEDeOTe2X+vxoYdkDIxBAcoYulfkvvIoQ8dnNUQZiJ3crqRWY
+D+oQlrsRI1Yaeb6H6JhaTnQPgbPu6WkNs0SzdBLzOMfPPnDxYwbK4PMgqxOxqpXX
+3ooyBFxzi2bjeABJdnkyFs3Ewn1WbK3tB4rZi/xZghhRJPaQgPHVME8kCswh82lo
+3lzQy7tD5Rep+7N5OzhwmqSlhgqeIR+D/5WZazsEwF7vmtcLGQVQt9Y/0sZrcD8Y
+2vmwaAB/yWU9aXDg1yad13k1LfEDsf7mvVWnvKdIkkUXqkRSl+pbHvU2JqZ9kPvZ
+VrII6rwUdpp7qRTDtJeNaIlGZkpfVlfNEsXttS6VpIohhvnEi73OG9ClQfUznkzS
+1yyBhdQg5kGN75BbAOLYzWd/c9kXup0Axv/V9+EHwG0Or2+uVG1AWjRes0cAEQEA
+AYkCHwQYAQIACQUCV2sjdgIbDAAKCRANSO8XefqK6/wPD/49Y33UPALWQxrrK8jm
+vUo4p+sND4bZlKYw8225AUxrL0x5CEh/l2tLcX2Y23i5XI1WUnz8pfdFhCLSlssl
+RHz7YcFrXM2qXHvjd76nQ58pHY8mdvY5KJI0GTjjWz21fxE5sKSuVi9SampoaVHk
+n+pyVcNzZMZiy7wz+gtlQID2wkk5soPjbuEGyVgHavEsYd7l1NZOphBz0iMjsCL6
+aUpW+o12mNCenc1aJB2s9zMTlL+C6tdGrnHHT9hSbSWeuplN+u/jPTY18YE0I9nV
+U5wc2uwmgbwam5i2G8M1WvbbzS4t2KN/7MJ6zTIS3Om6QD+CMHLr1N5n53K7gai3
+gxXZwCxIbZHZq8yyxzfsa+mTJKqHWiSatyRga9FKt2CodNlUH7MtwlEUICmeWju0
+lph7gRzJ6Iuel5Ya+LIVX9qdULmu9ylCkY6bsZgkQSWCu815gU7g73zqCSrISw1B
+fjgjbagOwp+FWCg0kteVxouzBPSIJXSLiBvfhI3g3X+IF7X0Ul6JoqHv3M18A4VY
+pZdF1i7aGjqd5+fYRMMFYz8vuhkJR71M9E4yAutODpxliTexSQP5dH8MvoLVMiIj
+b4Ki2TbCKOPwRYX6+b2vmmOUlZ28yjeAhzHKXS9lh7nY2T+cv5cwkPZ1uw2AKG55
+pcl2PvSVaZeoTjguW8BqFjkEzA==
+=p/IB
+-END PGP PUBLIC KEY BLOCK-



svn commit: r14648 - in /dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1: ./ bin/ src/

2016-08-03 Thread ankit
Author: ankit
Date: Wed Aug  3 09:25:24 2016
New Revision: 14648

Log:
Apache Phoenix 4.8.0-HBase-1.2-rc1

Added:
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/

dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz
   (with props)

dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.asc

dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.md5

dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.sha
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/

dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz
   (with props)

dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.asc

dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.md5

dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.sha

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz
==
Binary file - no diff available.

Propchange: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz
--
svn:mime-type = application/octet-stream

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.asc
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.asc
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.asc
 Wed Aug  3 09:25:24 2016
@@ -0,0 +1,17 @@
+-BEGIN PGP SIGNATURE-
+Version: GnuPG v2.0.14 (GNU/Linux)
+
+iQIcBAABAgAGBQJXobTiAAoJEA1I7xd5+orrzmwQAJn/0ZleFwru4nJmr7UxWAXu
+LoN6/dryoPT77KPWx7tKqCR6r7iVDeZLOWlBtPrjhT5XheOuW2IBbDpW4eXvqzXB
+g+QWyaCOlPn8kYwFlXK/4+R3L7SQxBw52daHM8b3QBfAhpqbXNDw/e2x/dIuVZtC
+zy6AaT8dzq4T9G601zR0f3v1mXS5PkDES8Jx+JWiPXxaW5ddgCvumFrShC0GTdF/
+QzaST5KNktGtJx36q++IMJ/Yi2wsDgFCpM+8JSqjoASETswwfFn/DfAGo6QTQJJ3
+aH1cxGE+PHvzF8EwcR5nWu2lVCD+M8Lf94sjoHmGwpHbos6jwtfV6s/4XLOY6KHH
+BAX1GdjF2sNTwZ5Mjdi4qtPMshCCCtTXs5TM49MxMIT/WvwXG0LvLfJGYDOu+kco
+eh5uq+YhCO9fTUF345cuUsebK2YAnPrzbPVwh6DAEoDljMr7CEid0Mg5/szi07UE
+i5C8u/2Mlldj9YUaCBO7dxhNgIKfbgmAybWJ1QaZZAJ5r/fvyeGR/OVVIIoy8P7n
+N3z6SsH0qzgRVeTSG+jZt9Ncmi0AXQPHv/26hn4/ucdqNsIYQcQigUNnQf2IL0iT
+kPqEmuYU06O2azKWOF/laKT6eXkwCbwwVZGfiEkwTO90xDvf2m5/YfKlbOm63DrR
+ZF9nOBEz0jo4G0JkHot4
+=+14F
+-END PGP SIGNATURE-

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.md5
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.md5
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.md5
 Wed Aug  3 09:25:24 2016
@@ -0,0 +1 @@
+472add69555fbdd40f1eab827d3f7780 *apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.sha
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.sha
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.sha
 Wed Aug  3 09:25:24 2016
@@ -0,0 +1,2 @@
+d116ee1b11d58307f65db52cb3255ac3699791d7a5611c8cdbcdd66058ecf833df996c8e51ae01f2e07f7fd02b1ab24663da726e2d023ff44d52fa77bbe7a093
 *apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz
+744a93fcd1973a8eb7a2ecc685401cdb01bccb540cea25d1cbbd4e4cb415eb27 
*apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz
==
Binary file - no diff available.

Propchange: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz
--
svn:mime-type = application/octet-stream

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.asc
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.asc
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-1.2-rc1/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.asc
 Wed Aug  3 09:25:24 2016
@@ -0,0 +1,17 @@
+-BEGIN PGP

svn commit: r14651 - in /dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1: ./ bin/ src/

2016-08-03 Thread ankit
Author: ankit
Date: Wed Aug  3 09:57:51 2016
New Revision: 14651

Log:
Apache Phoenix 4.8.0-HBase-0.98-rc1

Added:
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/

dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz
   (with props)

dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.asc

dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.md5

dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.sha
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/

dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz
   (with props)

dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.asc

dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.md5

dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.sha

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz
==
Binary file - no diff available.

Propchange: 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz
--
svn:mime-type = application/octet-stream

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.asc
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.asc
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.asc
 Wed Aug  3 09:57:51 2016
@@ -0,0 +1,17 @@
+-BEGIN PGP SIGNATURE-
+Version: GnuPG v2.0.14 (GNU/Linux)
+
+iQIcBAABAgAGBQJXob/DAAoJEA1I7xd5+orrDVAP/j5Ub0JFJ6tk2Fu9Mp2mNfZE
+3rXfg7VlKIBc3Jb9SHytOAQhSxPrepy1sHOtOImhWExfYBDTQVtARH8GYF3SX5+7
+mHnsIvNHAxA4CqjIpqIHUU6Ct4fze07EpdAx956gQ8r+cCkR5W878kKJqAWAFaKS
+pt0XODEwQ6APHbXVEyBbzdFrnM13qHFn/GQgRVlIveIjaScqE+nUmb/loW3R+zL2
+t5qcavaUkKpbsG1+rVWp07a/3vldptM0FQdHBamWo0LkR4DGNkOPj+l/OduTkdEN
+B/eG8PQOlRkwyiGDS8JF9Ujp4eDqrM1SKCCnUxAYzlc0gy/DCjpZ0P56gnERUa3a
+ZYR1i0LtKda3aqK7gX/ENynpnViuTuCX6E01CVfIFdzjmVw9xKeaQ60M7FRb9Uw8
+yw1YjEaIAPSxt6GwxNQRAITPfcW1qHBLPJNRneoUHkMmeZOwxybKvHCd633vhCzR
+KjX4B2P9wRuE/VOiVS2aWg86XgJfd25GWwSek+wCMCz6mmFeeD37B/1BDebMQgSB
+BsRBnuDkI6skEwGJSt1KijL46VP9ohqW7A2nbW2qKl9mmiJpuqJgeabAx7eqEnrL
+Uh4NYy2OFnQMB8KLIpumQQWZSSmHZhpHxOPzKUXktCRrb9KdDXuuzGnl4StFlA2Y
+EIX1PhvDPl1+286rswmD
+=HzaK
+-END PGP SIGNATURE-

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.md5
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.md5
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.md5
 Wed Aug  3 09:57:51 2016
@@ -0,0 +1 @@
+52d0b8438c0311121d4f201195472478 *apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.sha
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.sha
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.sha
 Wed Aug  3 09:57:51 2016
@@ -0,0 +1,2 @@
+56bcfd51fa8ffc5672d63e87641dc38e1c5af81add5abeb69e8ea034d7f156d47a9f6be54b6201165c948127121690b8902713ad2811f74b37b7e37d5d979d85
 *apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz
+e655b4d165610a8bc57955775ce70e5475d1b75860a69b8896afa7aa7622e27c 
*apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz
==
Binary file - no diff available.

Propchange: 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz
--
svn:mime-type = application/octet-stream

Added: 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.asc
==
--- 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.asc
 (added)
+++ 
dev/phoenix/apache-phoenix-4.8.0-HBase-0.98-rc1/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.asc
 Wed

[phoenix] Git Push Summary

2016-08-03 Thread ankit
Repository: phoenix
Updated Tags:  refs/tags/v4.8.0-HBase-1.2-rc1 [created] 50e1c6620


[phoenix] Git Push Summary

2016-08-03 Thread ankit
Repository: phoenix
Updated Tags:  refs/tags/v4.8.0-HBase-1.1-rc1 [created] 8158451ad


[phoenix] Git Push Summary

2016-08-03 Thread ankit
Repository: phoenix
Updated Tags:  refs/tags/v4.8.0-HBase-1.0-rc1 [created] a97b5b1a2


[phoenix] Git Push Summary

2016-08-03 Thread ankit
Repository: phoenix
Updated Tags:  refs/tags/v4.8.0-HBase-0.98-rc1 [created] a6f31


svn commit: r14762 - in /release/phoenix: apache-phoenix-4.8.0-HBase-0.98/ apache-phoenix-4.8.0-HBase-0.98/bin/ apache-phoenix-4.8.0-HBase-0.98/src/ apache-phoenix-4.8.0-HBase-1.0/ apache-phoenix-4.8.

2016-08-10 Thread ankit
Author: ankit
Date: Thu Aug 11 01:52:08 2016
New Revision: 14762

Log:
Phoenix 4.8.0 release

Added:
release/phoenix/apache-phoenix-4.8.0-HBase-0.98/
release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin/

release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.asc
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.md5

release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.sha
release/phoenix/apache-phoenix-4.8.0-HBase-0.98/src/

release/phoenix/apache-phoenix-4.8.0-HBase-0.98/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-0.98/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.asc
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-0.98/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.md5

release/phoenix/apache-phoenix-4.8.0-HBase-0.98/src/apache-phoenix-4.8.0-HBase-0.98-src.tar.gz.sha
release/phoenix/apache-phoenix-4.8.0-HBase-1.0/
release/phoenix/apache-phoenix-4.8.0-HBase-1.0/bin/

release/phoenix/apache-phoenix-4.8.0-HBase-1.0/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.0/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.asc
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.0/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.md5

release/phoenix/apache-phoenix-4.8.0-HBase-1.0/bin/apache-phoenix-4.8.0-HBase-1.0-bin.tar.gz.sha
release/phoenix/apache-phoenix-4.8.0-HBase-1.0/src/

release/phoenix/apache-phoenix-4.8.0-HBase-1.0/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.0/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.asc
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.0/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.md5

release/phoenix/apache-phoenix-4.8.0-HBase-1.0/src/apache-phoenix-4.8.0-HBase-1.0-src.tar.gz.sha
release/phoenix/apache-phoenix-4.8.0-HBase-1.1/
release/phoenix/apache-phoenix-4.8.0-HBase-1.1/bin/

release/phoenix/apache-phoenix-4.8.0-HBase-1.1/bin/apache-phoenix-4.8.0-HBase-1.1-bin.tar.gz
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.1/bin/apache-phoenix-4.8.0-HBase-1.1-bin.tar.gz.asc
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.1/bin/apache-phoenix-4.8.0-HBase-1.1-bin.tar.gz.md5

release/phoenix/apache-phoenix-4.8.0-HBase-1.1/bin/apache-phoenix-4.8.0-HBase-1.1-bin.tar.gz.sha
release/phoenix/apache-phoenix-4.8.0-HBase-1.1/src/

release/phoenix/apache-phoenix-4.8.0-HBase-1.1/src/apache-phoenix-4.8.0-HBase-1.1-src.tar.gz
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.1/src/apache-phoenix-4.8.0-HBase-1.1-src.tar.gz.asc
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.1/src/apache-phoenix-4.8.0-HBase-1.1-src.tar.gz.md5

release/phoenix/apache-phoenix-4.8.0-HBase-1.1/src/apache-phoenix-4.8.0-HBase-1.1-src.tar.gz.sha
release/phoenix/apache-phoenix-4.8.0-HBase-1.2/
release/phoenix/apache-phoenix-4.8.0-HBase-1.2/bin/

release/phoenix/apache-phoenix-4.8.0-HBase-1.2/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.2/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.asc
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.2/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.md5

release/phoenix/apache-phoenix-4.8.0-HBase-1.2/bin/apache-phoenix-4.8.0-HBase-1.2-bin.tar.gz.sha
release/phoenix/apache-phoenix-4.8.0-HBase-1.2/src/

release/phoenix/apache-phoenix-4.8.0-HBase-1.2/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.2/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.asc
   (with props)

release/phoenix/apache-phoenix-4.8.0-HBase-1.2/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.md5

release/phoenix/apache-phoenix-4.8.0-HBase-1.2/src/apache-phoenix-4.8.0-HBase-1.2-src.tar.gz.sha

Added: 
release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz
==
Binary file - no diff available.

Propchange: 
release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz
--
svn:mime-type = application/x-gzip

Added: 
release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin/apache-phoenix-4.8.0-HBase-0.98-bin.tar.gz.asc
==
Binary file - no diff available.

Propchange: 
release/phoenix/apache-phoenix-4.8.0-HBase-0.98/bin

[phoenix] Git Push Summary

2016-08-04 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.8.0-HBase-1.1 [created] 5ed82b09c


[phoenix] Git Push Summary

2016-08-04 Thread ankit
Repository: phoenix
Updated Branches:
  refs/heads/4.8.0-HBase-1.2 [created] 0b91b45aa


  1   2   3   4   5   6   >