Apache-Phoenix | 4.x-HBase-1.2 | Build Successful

2018-02-11 Thread Apache Jenkins Server
4.x-HBase-1.2 branch build status Successful

Source repository https://git-wip-us.apache.org/repos/asf?p=phoenix.git;a=shortlog;h=refs/heads/4.x-HBase-1.2

Compiled Artifacts https://builds.apache.org/job/Phoenix-4.x-HBase-1.2/lastSuccessfulBuild/artifact/

Test Report https://builds.apache.org/job/Phoenix-4.x-HBase-1.2/lastCompletedBuild/testReport/

Changes
No changes


Build times for last couple of runsLatest build time is the right most | Legend blue: normal, red: test failure, gray: timeout


[1/7] phoenix git commit: PHOENIX-4130 Avoid server retries for mutable indexes

2018-02-11 Thread pboado
Repository: phoenix
Updated Branches:
  refs/heads/4.x-cdh5.11.2 00940b343 -> 06ecae7a0


http://git-wip-us.apache.org/repos/asf/phoenix/blob/b539cd62/phoenix-core/src/main/java/org/apache/phoenix/util/ServerUtil.java
--
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/util/ServerUtil.java 
b/phoenix-core/src/main/java/org/apache/phoenix/util/ServerUtil.java
index cd23dc5..bc2b625 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/util/ServerUtil.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/util/ServerUtil.java
@@ -119,6 +119,25 @@ public class ServerUtil {
 }
 return new PhoenixIOException(t);
 }
+
+/**
+ * Return the first SQLException in the exception chain, otherwise parse 
it.
+ * When we're receiving an exception locally, there's no need to string 
parse,
+ * as the SQLException will already be part of the chain.
+ * @param t
+ * @return the SQLException, or null if none found
+ */
+public static SQLException parseLocalOrRemoteServerException(Throwable t) {
+while (t.getCause() != null) {
+if (t instanceof NotServingRegionException) {
+return parseRemoteException(new 
StaleRegionBoundaryCacheException());
+} else if (t instanceof SQLException) {
+return (SQLException) t;
+}
+t = t.getCause();
+}
+return parseRemoteException(t);
+}
 
 public static SQLException parseServerExceptionOrNull(Throwable t) {
 while (t.getCause() != null) {
@@ -196,7 +215,7 @@ public class ServerUtil {
 return parseTimestampFromRemoteException(t);
 }
 
-private static long parseTimestampFromRemoteException(Throwable t) {
+public static long parseTimestampFromRemoteException(Throwable t) {
 String message = t.getLocalizedMessage();
 if (message != null) {
 // If the message matches the standard pattern, recover the 
SQLException and throw it.
@@ -216,7 +235,7 @@ public class ServerUtil {
 msg = "";
 }
 if (t instanceof SQLException) {
-msg = constructSQLErrorMessage((SQLException) t, msg);
+msg = t.getMessage() + " " + msg;
 }
 msg += String.format(FORMAT_FOR_TIMESTAMP, timestamp);
 return new DoNotRetryIOException(msg, t);

http://git-wip-us.apache.org/repos/asf/phoenix/blob/b539cd62/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestIndexWriter.java
--
diff --git 
a/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestIndexWriter.java
 
b/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestIndexWriter.java
index b0e3780..918c411 100644
--- 
a/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestIndexWriter.java
+++ 
b/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestIndexWriter.java
@@ -105,6 +105,10 @@ public class TestIndexWriter {
 Configuration conf =new Configuration();
 Mockito.when(e.getConfiguration()).thenReturn(conf);
 Mockito.when(e.getSharedData()).thenReturn(new 
ConcurrentHashMap());
+Region mockRegion = Mockito.mock(Region.class);
+Mockito.when(e.getRegion()).thenReturn(mockRegion);
+HTableDescriptor mockTableDesc = Mockito.mock(HTableDescriptor.class);
+Mockito.when(mockRegion.getTableDesc()).thenReturn(mockTableDesc);
 ExecutorService exec = Executors.newFixedThreadPool(1);
 Map tables = new 
HashMap();
 FakeTableFactory factory = new FakeTableFactory(tables);
@@ -161,6 +165,10 @@ public class TestIndexWriter {
 Configuration conf =new Configuration();
 Mockito.when(e.getConfiguration()).thenReturn(conf);
 Mockito.when(e.getSharedData()).thenReturn(new 
ConcurrentHashMap());
+Region mockRegion = Mockito.mock(Region.class);
+Mockito.when(e.getRegion()).thenReturn(mockRegion);
+HTableDescriptor mockTableDesc = Mockito.mock(HTableDescriptor.class);
+Mockito.when(mockRegion.getTableDesc()).thenReturn(mockTableDesc);
 FakeTableFactory factory = new FakeTableFactory(tables);
 
 byte[] tableName = this.testName.getTableName();

http://git-wip-us.apache.org/repos/asf/phoenix/blob/b539cd62/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestParalleIndexWriter.java
--
diff --git 
a/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestParalleIndexWriter.java
 
b/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestParalleIndexWriter.java
index 3e2b47c..bfe1d0d 100644
--- 
a/phoenix-core/src/test/java/org/apache/phoenix/hbase/index/write/TestParalleIndexWriter.java
+++ 

[6/7] phoenix git commit: PHOENIX-4549 Pherf - Column override and sequenced index creation support

2018-02-11 Thread pboado
PHOENIX-4549 Pherf - Column override and sequenced index creation support


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

Branch: refs/heads/4.x-cdh5.11.2
Commit: 04029fb28bb4a6d9aa30826fccdf9731805e6b43
Parents: 92bd6d6
Author: Mujtaba 
Authored: Wed Feb 7 19:49:15 2018 +
Committer: Pedro Boado 
Committed: Sun Feb 11 15:56:17 2018 +

--
 .../phoenix/pherf/configuration/Column.java |  23 +--
 .../pherf/configuration/DataTypeMapping.java|   6 +-
 .../phoenix/pherf/configuration/Query.java  |  25 
 .../phoenix/pherf/configuration/Scenario.java   |   3 +-
 .../phoenix/pherf/result/QueryResult.java   |  10 +-
 .../phoenix/pherf/result/ResultManager.java |  18 ++-
 .../apache/phoenix/pherf/result/ResultUtil.java |   9 +-
 .../phoenix/pherf/rules/RulesApplier.java   | 142 +++
 .../phoenix/pherf/schema/SchemaReader.java  |   2 +-
 .../apache/phoenix/pherf/util/PhoenixUtil.java  |  48 ++-
 .../pherf/workload/MultiThreadedRunner.java |  35 -
 .../phoenix/pherf/workload/QueryExecutor.java   |  36 ++---
 .../phoenix/pherf/workload/WriteWorkload.java   |  54 ++-
 .../scenario/prod_test_unsalted_scenario.xml|  14 +-
 .../org/apache/phoenix/pherf/ColumnTest.java|   3 +
 .../phoenix/pherf/ConfigurationParserTest.java  |   4 +-
 .../apache/phoenix/pherf/RuleGeneratorTest.java | 107 +-
 .../test/resources/datamodel/test_schema.sql|   4 +
 .../test/resources/scenario/test_scenario.xml   |  48 ++-
 19 files changed, 488 insertions(+), 103 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/04029fb2/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
--
diff --git 
a/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
 
b/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
index 7c9e180..0d64a39 100644
--- 
a/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
+++ 
b/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
@@ -28,7 +28,8 @@ public class Column {
private String name;
 private String prefix;
 private DataSequence dataSequence;
-private int length, minValue, maxValue, precision;
+private int length, precision;
+private long minValue, maxValue;
 private int nullChance;
 private boolean userDefined;
 private List dataValues;
@@ -40,8 +41,8 @@ public class Column {
 // Initialize int to negative value so we can distinguish 0 in 
mutations
 // Object fields can be detected with null
 this.length = Integer.MIN_VALUE;
-this.minValue = Integer.MIN_VALUE;
-this.maxValue = Integer.MIN_VALUE;
+this.minValue = Long.MIN_VALUE;
+this.maxValue = Long.MIN_VALUE;
 this.precision = Integer.MIN_VALUE;
 this.nullChance = Integer.MIN_VALUE;
 this.userDefined = false;
@@ -84,6 +85,10 @@ public class Column {
public int getLength() {
return length;
}
+   
+   public int getLengthExcludingPrefix() {
+   return (this.getPrefix() == null) ? this.length : this.length - 
this.getPrefix().length();
+   }
 
public void setLength(int length) {
this.length = length;
@@ -97,19 +102,19 @@ public class Column {
this.type = type;
}
 
-public int getMinValue() {
+public long getMinValue() {
 return minValue;
 }
 
-public void setMinValue(int minValue) {
+public void setMinValue(long minValue) {
 this.minValue = minValue;
 }
 
-public int getMaxValue() {
+public long getMaxValue() {
 return maxValue;
 }
 
-public void setMaxValue(int maxValue) {
+public void setMaxValue(long maxValue) {
 this.maxValue = maxValue;
 }
 
@@ -134,11 +139,11 @@ public class Column {
  *   obj contains only the fields you want to mutate this 
object into.
  */
 public void mutate(Column column) {
-if (column.getMinValue() != Integer.MIN_VALUE) {
+if (column.getMinValue() != Long.MIN_VALUE) {
 setMinValue(column.getMinValue());
 }
 
-if (column.getMaxValue() != Integer.MIN_VALUE) {
+if (column.getMaxValue() != Long.MIN_VALUE) {
 setMaxValue(column.getMaxValue());
 }
 


[2/7] phoenix git commit: PHOENIX-4130 Avoid server retries for mutable indexes

2018-02-11 Thread pboado
PHOENIX-4130 Avoid server retries for mutable indexes


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

Branch: refs/heads/4.x-cdh5.11.2
Commit: b539cd625bec0d625ddd1dfd61d3b4f58abeabd2
Parents: 00940b3
Author: Vincent Poon 
Authored: Mon Jan 29 23:06:12 2018 +
Committer: Pedro Boado 
Committed: Sun Feb 11 15:54:05 2018 +

--
 .../end2end/index/MutableIndexFailureIT.java|  12 +-
 .../end2end/index/PartialIndexRebuilderIT.java  |  76 ++--
 .../coprocessor/MetaDataEndpointImpl.java   |  53 --
 .../phoenix/coprocessor/MetaDataProtocol.java   |   6 +-
 .../coprocessor/MetaDataRegionObserver.java |  19 +-
 .../UngroupedAggregateRegionObserver.java   |  82 ++--
 .../phoenix/exception/SQLExceptionCode.java |   1 +
 .../apache/phoenix/execute/MutationState.java   |  39 +++-
 .../org/apache/phoenix/hbase/index/Indexer.java |  10 -
 .../index/exception/IndexWriteException.java|  49 -
 .../MultiIndexWriteFailureException.java|  29 ++-
 .../SingleIndexWriteFailureException.java   |  23 ++-
 .../hbase/index/write/IndexWriterUtils.java |  14 +-
 .../write/ParallelWriterIndexCommitter.java |   5 +-
 .../TrackingParallelWriterIndexCommitter.java   |   5 +-
 .../index/PhoenixIndexFailurePolicy.java| 189 +--
 .../phoenix/jdbc/PhoenixDatabaseMetaData.java   |   1 +
 .../apache/phoenix/optimize/QueryOptimizer.java |  29 ++-
 .../org/apache/phoenix/query/QueryServices.java |   2 +
 .../phoenix/query/QueryServicesOptions.java |   1 +
 .../org/apache/phoenix/schema/PIndexState.java  |   7 +-
 .../org/apache/phoenix/util/KeyValueUtil.java   |  12 ++
 .../org/apache/phoenix/util/ServerUtil.java |  23 ++-
 .../hbase/index/write/TestIndexWriter.java  |   8 +
 .../index/write/TestParalleIndexWriter.java |   6 +
 .../write/TestParalleWriterIndexCommitter.java  |   6 +
 26 files changed, 591 insertions(+), 116 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/b539cd62/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexFailureIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexFailureIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexFailureIT.java
index 0318925..c2e0cb6 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexFailureIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/MutableIndexFailureIT.java
@@ -29,7 +29,6 @@ import java.sql.PreparedStatement;
 import java.sql.ResultSet;
 import java.sql.SQLException;
 import java.util.Arrays;
-import java.util.Collections;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
@@ -130,7 +129,6 @@ public class MutableIndexFailureIT extends BaseTest {
 public static void doSetup() throws Exception {
 Map serverProps = Maps.newHashMapWithExpectedSize(10);
 serverProps.put("hbase.coprocessor.region.classes", 
FailingRegionObserver.class.getName());
-serverProps.put(IndexWriterUtils.INDEX_WRITER_RPC_RETRIES_NUMBER, "2");
 serverProps.put(HConstants.HBASE_RPC_TIMEOUT_KEY, "1");
 serverProps.put(IndexWriterUtils.INDEX_WRITER_RPC_PAUSE, "5000");
 serverProps.put("data.tx.snapshot.dir", "/tmp");
@@ -144,7 +142,8 @@ public class MutableIndexFailureIT extends BaseTest {
  * because we want to control it's execution ourselves
  */
 serverProps.put(QueryServices.INDEX_REBUILD_TASK_INITIAL_DELAY, 
Long.toString(Long.MAX_VALUE));
-Map clientProps = 
Collections.singletonMap(QueryServices.TRANSACTIONS_ENABLED, 
Boolean.TRUE.toString());
+Map clientProps = Maps.newHashMapWithExpectedSize(2);
+clientProps.put(HConstants.HBASE_CLIENT_RETRIES_NUMBER, "2");
 NUM_SLAVES_BASE = 4;
 setUpTestDriver(new ReadOnlyProps(serverProps.entrySet().iterator()), 
new ReadOnlyProps(clientProps.entrySet().iterator()));
 indexRebuildTaskRegionEnvironment =
@@ -161,7 +160,8 @@ public class MutableIndexFailureIT extends BaseTest {
 @Parameters(name = 
"MutableIndexFailureIT_transactional={0},localIndex={1},isNamespaceMapped={2},disableIndexOnWriteFailure={3},failRebuildTask={4},throwIndexWriteFailure={5}")
 // name is used by failsafe as file name in reports
 public static List data() {
 return Arrays.asList(new Object[][] { 
-{ false, false, false, true, false, 

[4/7] phoenix git commit: PHOENIX-4546 Projected table cannot be read through ProjectedColumnExpression

2018-02-11 Thread pboado
PHOENIX-4546 Projected table cannot be read through ProjectedColumnExpression


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

Branch: refs/heads/4.x-cdh5.11.2
Commit: 3ef7b1f021cd931b848d54ff494525b7756fd466
Parents: 2121729
Author: Ankit Singhal 
Authored: Thu Feb 8 07:05:21 2018 +
Committer: Pedro Boado 
Committed: Sun Feb 11 15:55:46 2018 +

--
 .../org/apache/phoenix/end2end/DeleteIT.java| 36 
 .../compile/TupleProjectionCompiler.java| 32 -
 2 files changed, 60 insertions(+), 8 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/3ef7b1f0/phoenix-core/src/it/java/org/apache/phoenix/end2end/DeleteIT.java
--
diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/DeleteIT.java 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/DeleteIT.java
index e111e7a..498aeff 100644
--- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/DeleteIT.java
+++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/DeleteIT.java
@@ -710,6 +710,41 @@ public class DeleteIT extends ParallelStatsDisabledIT {
 public void testClientSideDeleteAutoCommitOn() throws Exception {
 testDeleteCount(true, 1000);
 }
+
+@Test
+public void testPointDeleteWithMultipleImmutableIndexes() throws Exception 
{
+testPointDeleteWithMultipleImmutableIndexes(false);
+}
+
+@Test
+public void testPointDeleteWithMultipleImmutableIndexesAfterAlter() throws 
Exception {
+testPointDeleteWithMultipleImmutableIndexes(true);
+}
+
+private void testPointDeleteWithMultipleImmutableIndexes(boolean 
alterTable) throws Exception {
+String tableName = generateUniqueName();
+String commands = "CREATE TABLE IF NOT EXISTS " + tableName
++ " (ID INTEGER PRIMARY KEY,double_id DOUBLE,varchar_id 
VARCHAR (30)) "
++ (alterTable ? ";ALTER TABLE " + tableName + " set " : "") + 
"IMMUTABLE_ROWS=true;"
++ "CREATE INDEX IF NOT EXISTS index_column_varchar_id ON " + 
tableName + "(varchar_id);"
++ "CREATE INDEX IF NOT EXISTS index_column_double_id ON " + 
tableName + "(double_id);" + "UPSERT INTO "
++ tableName + " VALUES (900,0.5,'Sample text extra');" ;
+try (Connection conn = DriverManager.getConnection(getUrl())) {
+conn.setAutoCommit(true);
+Statement stm = conn.createStatement();
+for (String sql : commands.split(";")) {
+stm.execute(sql);
+}
+ResultSet rs = stm.executeQuery("select id,varchar_id,double_id 
from " + tableName + " WHERE ID=900");
+assertTrue(rs.next());
+assertEquals(900, rs.getInt(1));
+assertEquals("Sample text extra", rs.getString(2));
+assertEquals(0.5, rs.getDouble(3),0.01);
+stm.execute("DELETE FROM " + tableName + " WHERE ID=900");
+assertDeleted(conn, tableName, "index_column_varchar_id", 
"index_column_double_id", null);
+stm.close();
+}
+}
 
 private void testDeleteCount(boolean autoCommit, Integer limit) throws 
Exception {
 String tableName = generateUniqueName();
@@ -735,6 +770,7 @@ public class DeleteIT extends ParallelStatsDisabledIT {
 }
 
 }
+
 
 @Test
 public void 
testClientSideDeleteShouldNotFailWhenSameColumnPresentInMultipleIndexes()

http://git-wip-us.apache.org/repos/asf/phoenix/blob/3ef7b1f0/phoenix-core/src/main/java/org/apache/phoenix/compile/TupleProjectionCompiler.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/compile/TupleProjectionCompiler.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/compile/TupleProjectionCompiler.java
index 9883de6..d0b900c 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/compile/TupleProjectionCompiler.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/compile/TupleProjectionCompiler.java
@@ -22,6 +22,7 @@ import java.sql.SQLException;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.HashSet;
+import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Set;
 
@@ -103,6 +104,10 @@ public class TupleProjectionCompiler {
 for (PColumn column : 
parentTableRef.getTable().getColumnFamily(familyName).getColumns()) {
 NODE_FACTORY.column(null, '"' + 

[5/7] phoenix git commit: PHOENIX-4588 Clone expression also if it's children have Determinism.PER_INVOCATION

2018-02-11 Thread pboado
PHOENIX-4588 Clone expression also if it's children have 
Determinism.PER_INVOCATION


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

Branch: refs/heads/4.x-cdh5.11.2
Commit: 92bd6d68229b6689e2a97416593708e3cbcb0960
Parents: 3ef7b1f
Author: Ankit Singhal 
Authored: Fri Feb 9 06:16:56 2018 +
Committer: Pedro Boado 
Committed: Sun Feb 11 15:56:04 2018 +

--
 .../org/apache/phoenix/expression/BaseSingleExpression.java | 5 +
 1 file changed, 5 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/92bd6d68/phoenix-core/src/main/java/org/apache/phoenix/expression/BaseSingleExpression.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/expression/BaseSingleExpression.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/expression/BaseSingleExpression.java
index c0e2fea..fbe8040 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/expression/BaseSingleExpression.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/expression/BaseSingleExpression.java
@@ -113,4 +113,9 @@ public abstract class BaseSingleExpression extends 
BaseExpression {
 public boolean requiresFinalEvaluation() {
 return children.get(0).requiresFinalEvaluation();
 }
+
+@Override
+public Determinism getDeterminism() {
+return children.get(0).getDeterminism();
+}
 }



[3/7] phoenix git commit: PHOENIX-4130 Avoid server retries for mutable indexes (Addendum)

2018-02-11 Thread pboado
PHOENIX-4130 Avoid server retries for mutable indexes (Addendum)


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

Branch: refs/heads/4.x-cdh5.11.2
Commit: 21217292bd77086039b196c867cca5f20e44b463
Parents: b539cd6
Author: Vincent Poon 
Authored: Thu Feb 1 00:33:01 2018 +
Committer: Pedro Boado 
Committed: Sun Feb 11 15:54:19 2018 +

--
 .../end2end/index/PartialIndexRebuilderIT.java  |  3 +--
 .../index/exception/IndexWriteException.java| 21 +++-
 .../MultiIndexWriteFailureException.java| 14 +++--
 .../SingleIndexWriteFailureException.java   | 15 +++---
 .../index/PhoenixIndexFailurePolicy.java| 18 +
 5 files changed, 55 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/21217292/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java
--
diff --git 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java
 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java
index dd986aa..3961d32 100644
--- 
a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java
+++ 
b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java
@@ -1098,8 +1098,7 @@ public class PartialIndexRebuilderIT extends 
BaseUniqueNamesOwnClusterIT {
 conn.createStatement().execute("DELETE FROM " + 
fullTableName);
 fail();
 } catch (SQLException e) {
-// Expected
-
assertEquals(SQLExceptionCode.INDEX_WRITE_FAILURE.getErrorCode(), 
e.getErrorCode());
+// expected
 }
 assertTrue(TestUtil.checkIndexState(conn, fullIndexName, 
PIndexState.DISABLE, null));
 } finally {

http://git-wip-us.apache.org/repos/asf/phoenix/blob/21217292/phoenix-core/src/main/java/org/apache/phoenix/hbase/index/exception/IndexWriteException.java
--
diff --git 
a/phoenix-core/src/main/java/org/apache/phoenix/hbase/index/exception/IndexWriteException.java
 
b/phoenix-core/src/main/java/org/apache/phoenix/hbase/index/exception/IndexWriteException.java
index 531baa6..5dc6f60 100644
--- 
a/phoenix-core/src/main/java/org/apache/phoenix/hbase/index/exception/IndexWriteException.java
+++ 
b/phoenix-core/src/main/java/org/apache/phoenix/hbase/index/exception/IndexWriteException.java
@@ -22,6 +22,8 @@ import java.util.regex.Pattern;
 import org.apache.hadoop.hbase.HBaseIOException;
 import org.apache.phoenix.query.QueryServicesOptions;
 
+import com.google.common.base.Objects;
+
 /**
  * Generic {@link Exception} that an index write has failed
  */
@@ -33,7 +35,7 @@ public class IndexWriteException extends HBaseIOException {
  * server side.
  */
 private static final String DISABLE_INDEX_ON_FAILURE_MSG = 
"disableIndexOnFailure=";
-private boolean disableIndexOnFailure;
+private boolean disableIndexOnFailure = 
QueryServicesOptions.DEFAULT_INDEX_FAILURE_DISABLE_INDEX;
 
   public IndexWriteException() {
 super();
@@ -49,19 +51,15 @@ public class IndexWriteException extends HBaseIOException {
   super(message, cause);
   }
 
-  public IndexWriteException(String message, Throwable cause, boolean 
disableIndexOnFailure) {
-super(prependDisableIndexMsg(message, disableIndexOnFailure), cause);
+  public IndexWriteException(Throwable cause, boolean disableIndexOnFailure) {
+super(cause);
+this.disableIndexOnFailure = disableIndexOnFailure;
   }
 
-  public IndexWriteException(String message, boolean disableIndexOnFailure) {
-super(prependDisableIndexMsg(message, disableIndexOnFailure));
+  public IndexWriteException(boolean disableIndexOnFailure) {
 this.disableIndexOnFailure = disableIndexOnFailure;
   }
 
-  private static String prependDisableIndexMsg(String message, boolean 
disableIndexOnFailure) {
-return DISABLE_INDEX_ON_FAILURE_MSG + disableIndexOnFailure + " " + 
message;
-}
-
 public IndexWriteException(Throwable cause) {
 super(cause);
   }
@@ -81,4 +79,9 @@ public IndexWriteException(Throwable cause) {
 public boolean isDisableIndexOnFailure() {
 return disableIndexOnFailure;
 }
+
+@Override
+public String getMessage() {
+return Objects.firstNonNull(super.getMessage(), "") + " " + 
DISABLE_INDEX_ON_FAILURE_MSG + disableIndexOnFailure + 

[7/7] phoenix git commit: PHOENIX-4571 Adds dependency on servlet-api for PQS

2018-02-11 Thread pboado
PHOENIX-4571 Adds dependency on servlet-api for PQS


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

Branch: refs/heads/4.x-cdh5.11.2
Commit: 06ecae7a073560ea97e3f8818c29739c73166ad8
Parents: 04029fb
Author: Josh Elser 
Authored: Tue Jan 30 21:06:08 2018 +
Committer: Pedro Boado 
Committed: Sun Feb 11 15:59:22 2018 +

--
 phoenix-queryserver/pom.xml | 4 
 pom.xml | 7 ++-
 2 files changed, 10 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/06ecae7a/phoenix-queryserver/pom.xml
--
diff --git a/phoenix-queryserver/pom.xml b/phoenix-queryserver/pom.xml
index a0866a3..7180b18 100644
--- a/phoenix-queryserver/pom.xml
+++ b/phoenix-queryserver/pom.xml
@@ -147,6 +147,10 @@
   commons-logging
   commons-logging
 
+
+  javax.servlet
+  javax.servlet-api
+
 
 
   org.mockito

http://git-wip-us.apache.org/repos/asf/phoenix/blob/06ecae7a/pom.xml
--
diff --git a/pom.xml b/pom.xml
index 513460e..574f8ba 100644
--- a/pom.xml
+++ b/pom.xml
@@ -149,7 +149,7 @@
 2.10
 2.9.5
 1.0.1
-
+3.1.0
 
 1.8.5
 4.12
@@ -979,6 +979,11 @@
 i18n-util
 ${i18n-util.version}
   
+  
+javax.servlet
+javax.servlet-api
+${servlet.api.version}
+  
 
   
 



Apache-Phoenix | 4.x-HBase-1.2 | Build Successful

2018-02-11 Thread Apache Jenkins Server
4.x-HBase-1.2 branch build status Successful

Source repository https://git-wip-us.apache.org/repos/asf?p=phoenix.git;a=shortlog;h=refs/heads/4.x-HBase-1.2

Compiled Artifacts https://builds.apache.org/job/Phoenix-4.x-HBase-1.2/lastSuccessfulBuild/artifact/

Test Report https://builds.apache.org/job/Phoenix-4.x-HBase-1.2/lastCompletedBuild/testReport/

Changes
[pboado] PHOENIX-4549 Pherf - Column override and sequenced index creation



Build times for last couple of runsLatest build time is the right most | Legend blue: normal, red: test failure, gray: timeout


phoenix git commit: PHOENIX-4549 Pherf - Column override and sequenced index creation support

2018-02-11 Thread pboado
Repository: phoenix
Updated Branches:
  refs/heads/4.x-HBase-1.2 618dfb026 -> e4566fcd7


PHOENIX-4549 Pherf - Column override and sequenced index creation support


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

Branch: refs/heads/4.x-HBase-1.2
Commit: e4566fcd78ccd947819fdfca609a73a6c83d11f9
Parents: 618dfb0
Author: Mujtaba 
Authored: Wed Feb 7 19:49:15 2018 +
Committer: Pedro Boado 
Committed: Sun Feb 11 14:51:07 2018 +

--
 .../phoenix/pherf/configuration/Column.java |  23 +--
 .../pherf/configuration/DataTypeMapping.java|   6 +-
 .../phoenix/pherf/configuration/Query.java  |  25 
 .../phoenix/pherf/configuration/Scenario.java   |   3 +-
 .../phoenix/pherf/result/QueryResult.java   |  10 +-
 .../phoenix/pherf/result/ResultManager.java |  18 ++-
 .../apache/phoenix/pherf/result/ResultUtil.java |   9 +-
 .../phoenix/pherf/rules/RulesApplier.java   | 142 +++
 .../phoenix/pherf/schema/SchemaReader.java  |   2 +-
 .../apache/phoenix/pherf/util/PhoenixUtil.java  |  48 ++-
 .../pherf/workload/MultiThreadedRunner.java |  35 -
 .../phoenix/pherf/workload/QueryExecutor.java   |  36 ++---
 .../phoenix/pherf/workload/WriteWorkload.java   |  54 ++-
 .../scenario/prod_test_unsalted_scenario.xml|  14 +-
 .../org/apache/phoenix/pherf/ColumnTest.java|   3 +
 .../phoenix/pherf/ConfigurationParserTest.java  |   4 +-
 .../apache/phoenix/pherf/RuleGeneratorTest.java | 107 +-
 .../test/resources/datamodel/test_schema.sql|   4 +
 .../test/resources/scenario/test_scenario.xml   |  48 ++-
 19 files changed, 488 insertions(+), 103 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/phoenix/blob/e4566fcd/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
--
diff --git 
a/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
 
b/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
index 7c9e180..0d64a39 100644
--- 
a/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
+++ 
b/phoenix-pherf/src/main/java/org/apache/phoenix/pherf/configuration/Column.java
@@ -28,7 +28,8 @@ public class Column {
private String name;
 private String prefix;
 private DataSequence dataSequence;
-private int length, minValue, maxValue, precision;
+private int length, precision;
+private long minValue, maxValue;
 private int nullChance;
 private boolean userDefined;
 private List dataValues;
@@ -40,8 +41,8 @@ public class Column {
 // Initialize int to negative value so we can distinguish 0 in 
mutations
 // Object fields can be detected with null
 this.length = Integer.MIN_VALUE;
-this.minValue = Integer.MIN_VALUE;
-this.maxValue = Integer.MIN_VALUE;
+this.minValue = Long.MIN_VALUE;
+this.maxValue = Long.MIN_VALUE;
 this.precision = Integer.MIN_VALUE;
 this.nullChance = Integer.MIN_VALUE;
 this.userDefined = false;
@@ -84,6 +85,10 @@ public class Column {
public int getLength() {
return length;
}
+   
+   public int getLengthExcludingPrefix() {
+   return (this.getPrefix() == null) ? this.length : this.length - 
this.getPrefix().length();
+   }
 
public void setLength(int length) {
this.length = length;
@@ -97,19 +102,19 @@ public class Column {
this.type = type;
}
 
-public int getMinValue() {
+public long getMinValue() {
 return minValue;
 }
 
-public void setMinValue(int minValue) {
+public void setMinValue(long minValue) {
 this.minValue = minValue;
 }
 
-public int getMaxValue() {
+public long getMaxValue() {
 return maxValue;
 }
 
-public void setMaxValue(int maxValue) {
+public void setMaxValue(long maxValue) {
 this.maxValue = maxValue;
 }
 
@@ -134,11 +139,11 @@ public class Column {
  *   obj contains only the fields you want to mutate this 
object into.
  */
 public void mutate(Column column) {
-if (column.getMinValue() != Integer.MIN_VALUE) {
+if (column.getMinValue() != Long.MIN_VALUE) {
 setMinValue(column.getMinValue());
 }
 
-if (column.getMaxValue() != Integer.MIN_VALUE) {
+if (column.getMaxValue() != Long.MIN_VALUE) {
 setMaxValue(column.getMaxValue());
 }
 


Build failed in Jenkins: Phoenix Compile Compatibility with HBase #545

2018-02-11 Thread Apache Jenkins Server
See 


--
[...truncated 39.70 KB...]
[ERROR] 
:[364,5]
 method does not override or implement a method from a supertype
[ERROR] 
:[370,5]
 method does not override or implement a method from a supertype
[ERROR] 
:[376,5]
 method does not override or implement a method from a supertype
[ERROR] 
:[382,5]
 method does not override or implement a method from a supertype
[ERROR] Failed to execute goal 
org.apache.maven.plugins:maven-compiler-plugin:3.0:compile (default-compile) on 
project phoenix-core: Compilation failure: Compilation failure: 
[ERROR] 
:[34,39]
 cannot find symbol
[ERROR]   symbol:   class MetricRegistry
[ERROR]   location: package org.apache.hadoop.hbase.metrics
[ERROR] 
:[144,16]
 cannot find symbol
[ERROR]   symbol:   class MetricRegistry
[ERROR]   location: class 
org.apache.phoenix.coprocessor.PhoenixMetaDataCoprocessorHost.PhoenixMetaDataControllerEnvironment
[ERROR] 
:[24,35]
 cannot find symbol
[ERROR]   symbol:   class DelegatingHBaseRpcController
[ERROR]   location: package org.apache.hadoop.hbase.ipc
[ERROR] 
:[25,35]
 cannot find symbol
[ERROR]   symbol:   class HBaseRpcController
[ERROR]   location: package org.apache.hadoop.hbase.ipc
[ERROR] 
:[37,37]
 cannot find symbol
[ERROR]   symbol: class DelegatingHBaseRpcController
[ERROR] 
:[56,38]
 cannot find symbol
[ERROR]   symbol:   class HBaseRpcController
[ERROR]   location: class 
org.apache.hadoop.hbase.ipc.controller.MetadataRpcController
[ERROR] 
:[26,35]
 cannot find symbol
[ERROR]   symbol:   class HBaseRpcController
[ERROR]   location: package org.apache.hadoop.hbase.ipc
[ERROR] 
:[40,12]
 cannot find symbol
[ERROR]   symbol:   class HBaseRpcController
[ERROR]   location: class 
org.apache.hadoop.hbase.ipc.controller.InterRegionServerMetadataRpcControllerFactory
[ERROR] 
:[46,12]
 cannot find symbol
[ERROR]   symbol:   class HBaseRpcController
[ERROR]   location: class 
org.apache.hadoop.hbase.ipc.controller.InterRegionServerMetadataRpcControllerFactory
[ERROR] 
:[52,12]
 cannot find symbol
[ERROR]   symbol:   class HBaseRpcController
[ERROR]   location: class 
org.apache.hadoop.hbase.ipc.controller.InterRegionServerMetadataRpcControllerFactory
[ERROR] 
:[57,46]
 cannot