[jira] [Commented] (RATIS-145) (git)ignore dependency-reduced-pom.xml

2017-11-22 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/RATIS-145?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16263520#comment-16263520
 ] 

Hadoop QA commented on RATIS-145:
-

| (x) *{color:red}-1 overall{color}* |
\\
\\
|| Vote || Subsystem || Runtime || Comment ||
| {color:blue}0{color} | {color:blue} reexec {color} | {color:blue}  3m 
58s{color} | {color:blue} Docker mode activated. {color} |
|| || || || {color:brown} Prechecks {color} ||
| {color:green}+1{color} | {color:green} @author {color} | {color:green}  0m  
0s{color} | {color:green} The patch does not contain any @author tags. {color} |
| {color:red}-1{color} | {color:red} test4tests {color} | {color:red}  0m  
0s{color} | {color:red} The patch doesn't appear to include any new or modified 
tests. Please justify why no new tests are needed for this patch. Also please 
list what manual steps were performed to verify this patch. {color} |
|| || || || {color:brown} master Compile Tests {color} ||
| {color:blue}0{color} | {color:blue} mvndep {color} | {color:blue}  0m 
12s{color} | {color:blue} Maven dependency ordering for branch {color} |
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  1m 
 9s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  1m  
9s{color} | {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 
45s{color} | {color:green} master passed {color} |
|| || || || {color:brown} Patch Compile Tests {color} ||
| {color:blue}0{color} | {color:blue} mvndep {color} | {color:blue}  0m  
8s{color} | {color:blue} Maven dependency ordering for patch {color} |
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  1m 
29s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  1m  
8s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javac {color} | {color:green}  1m  
8s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} whitespace {color} | {color:green}  0m 
 0s{color} | {color:green} The patch has no whitespace issues. {color} |
| {color:green}+1{color} | {color:green} xml {color} | {color:green}  0m  
2s{color} | {color:green} The patch has no ill-formed XML file. {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 
42s{color} | {color:green} the patch passed {color} |
|| || || || {color:brown} Other Tests {color} ||
| {color:red}-1{color} | {color:red} unit {color} | {color:red}  7m 27s{color} 
| {color:red} ratis-examples in the patch failed. {color} |
| {color:red}-1{color} | {color:red} unit {color} | {color:red}  2m 46s{color} 
| {color:red} root in the patch failed. {color} |
| {color:green}+1{color} | {color:green} asflicense {color} | {color:green}  0m 
16s{color} | {color:green} The patch does not generate ASF License warnings. 
{color} |
| {color:black}{color} | {color:black} {color} | {color:black} 21m 24s{color} | 
{color:black} {color} |
\\
\\
|| Reason || Tests ||
| Failed junit tests | ratis.TestBatchAppend |
|   | ratis.examples.filestore.TestFileStoreWithNetty |
|   | ratis.examples.filestore.TestFileStoreWithGrpc |
|   | ratis.server.simulation.TestRaftExceptionWithSimulation |
|   | ratis.server.TestRaftLogMetrics |
|   | ratis.TestBatchAppend |
|   | ratis.examples.filestore.TestFileStoreWithNetty |
|   | ratis.examples.filestore.TestFileStoreWithGrpc |
| Timed out junit tests | org.apache.ratis.server.storage.TestCacheEviction |
|   | org.apache.ratis.server.storage.TestSegmentedRaftLog |
|   | org.apache.ratis.server.simulation.TestRaftWithSimulatedRpc |
|   | 
org.apache.ratis.server.simulation.TestRaftReconfigurationWithSimulatedRpc |
\\
\\
|| Subsystem || Report/Notes ||
| Docker | Client=17.05.0-ce Server=17.05.0-ce Image:yetus/ratis:date2017-11-22 
|
| JIRA Issue | RATIS-145 |
| JIRA Patch URL | 
https://issues.apache.org/jira/secure/attachment/12898952/RATIS-145.002.patch |
| Optional Tests |  asflicense  javac  javadoc  unit  xml  compile  |
| uname | Linux 5f82245b4aa3 3.13.0-116-generic #163-Ubuntu SMP Fri Mar 31 
14:13:22 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux |
| Build tool | maven |
| Personality | 
/home/jenkins/jenkins-slave/workspace/PreCommit-RATIS-Build/yetus-personality.sh
 |
| git revision | master / 2fb731f |
| Default Java | 1.8.0_151 |
| unit | 
https://builds.apache.org/job/PreCommit-RATIS-Build/40/artifact/out/patch-unit-ratis-examples.txt
 |
| unit | 
https://builds.apache.org/job/PreCommit-RATIS-Build/40/artifact/out/patch-unit-root.txt
 |
|  Test Results | 
https://builds.apache.org/job/PreCommit-RATIS-Build/40/testReport/ |
| modules | C: ratis-examples . U: . |
| Console output | 
https://builds.apache.org/job/PreCommit-RATIS-Build/40/console |
| Powered by | Apache Yetus 0.5.0   

[jira] [Updated] (RATIS-145) (git)ignore dependency-reduced-pom.xml

2017-11-22 Thread Elek, Marton (JIRA)

 [ 
https://issues.apache.org/jira/browse/RATIS-145?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Elek, Marton updated RATIS-145:
---
Attachment: RATIS-145-HDFS-7240.002.patch

> (git)ignore dependency-reduced-pom.xml
> --
>
> Key: RATIS-145
> URL: https://issues.apache.org/jira/browse/RATIS-145
> Project: Ratis
>  Issue Type: Bug
>Reporter: Elek, Marton
>Assignee: Elek, Marton
> Attachments: RATIS-145.001.patch
>
>
> Latest nighliy build is failed with asflicense check:
> https://builds.apache.org/job/ratis-qbt-master-java8-linux-x86/18/artifact/out/patch-asflicense-problems.txt
> {code}
> Lines that start with ? in the ASF License  report indicate files that do 
> not have an Apache license header:
>  !? /testptch/ratis/ratis-examples/dependency-reduced-pom.xml
> {code}
> The trivial fix is to add dependency-reduced-pom.xml to the .gitignore file.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Updated] (RATIS-145) (git)ignore dependency-reduced-pom.xml

2017-11-22 Thread Elek, Marton (JIRA)

 [ 
https://issues.apache.org/jira/browse/RATIS-145?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Elek, Marton updated RATIS-145:
---
Attachment: (was: RATIS-145-HDFS-7240.002.patch)

> (git)ignore dependency-reduced-pom.xml
> --
>
> Key: RATIS-145
> URL: https://issues.apache.org/jira/browse/RATIS-145
> Project: Ratis
>  Issue Type: Bug
>Reporter: Elek, Marton
>Assignee: Elek, Marton
> Attachments: RATIS-145.001.patch
>
>
> Latest nighliy build is failed with asflicense check:
> https://builds.apache.org/job/ratis-qbt-master-java8-linux-x86/18/artifact/out/patch-asflicense-problems.txt
> {code}
> Lines that start with ? in the ASF License  report indicate files that do 
> not have an Apache license header:
>  !? /testptch/ratis/ratis-examples/dependency-reduced-pom.xml
> {code}
> The trivial fix is to add dependency-reduced-pom.xml to the .gitignore file.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (RATIS-141) In RaftClientProtocolService, the assumption of consecutive callId is invalid

2017-11-22 Thread Tsz Wo Nicholas Sze (JIRA)

[ 
https://issues.apache.org/jira/browse/RATIS-141?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16263441#comment-16263441
 ] 

Tsz Wo Nicholas Sze commented on RATIS-141:
---

> And just making callIdCounter non-static would do the same job.

That's is true. We could assume that the underlying RPC implementation support 
either sync or async calls.  (when it support async call, the sync call is 
implemented using the async calls.)  Then, callId's are consecutive per client.

Let me try if it works in RATIS-140.

> In RaftClientProtocolService, the assumption of consecutive callId is invalid
> -
>
> Key: RATIS-141
> URL: https://issues.apache.org/jira/browse/RATIS-141
> Project: Ratis
>  Issue Type: Bug
>Reporter: Tsz Wo Nicholas Sze
>Assignee: Tsz Wo Nicholas Sze
> Attachments: r141_20171117.patch, r141_20171119b.patch, 
> r141_20171120.patch
>
>
> {code}
> //RaftClientProtocolService.AppendRequestStreamObserver.onNext(..)
>   // we assume the callId is consecutive for a stream RPC call
>   final PendingAppend pendingForReply = pendingList.get(
>   (int) (replySeq - headSeqNum));
> {code}
> Call id is used for different kinds of calls (e.g. getInfo) so that it may 
> not be consecutive.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (RATIS-143) RaftClientImpl should have upper bound on async requests

2017-11-22 Thread Tsz Wo Nicholas Sze (JIRA)

[ 
https://issues.apache.org/jira/browse/RATIS-143?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16263430#comment-16263430
 ] 

Tsz Wo Nicholas Sze commented on RATIS-143:
---

Thanks for the update.  Some comments:
- close() should not wait for async calls.  Just like that for sync calls, if 
user calls close() (by another thread), it closes immediately and the 
outstanding calls will fail.

- Questsions: Why changing peers to ConcurrentLinkedQueue?  Have you seen any 
bugs with ArrayList?

- RaftAsyncTests should extend BaseTest.  Then, globalTimeout and other stuffs 
do not need to be deplicated in RaftAsyncTests.  
-* Also, not extending BeseTest breaks the idea of globalTimeout that if we 
change it or add a new Rule in BaseTest, then all tests will work.

- For the semaphore, add assertAsyncRequestSemaphore instead of 
getAsyncRequestSemaphore.  Then, it is clearly for testing.
{code}
//RaftClientImpl
  void assertAsyncRequestSemaphore(int expectedAvailablePermits, int 
expectedQueueLength) {
Preconditions.assertTrue(asyncRequestSemaphore.availablePermits() == 
expectedAvailablePermits);
Preconditions.assertTrue(asyncRequestSemaphore.getQueueLength() == 
expectedQueueLength);
  }
{code}
-* Also, please keep RaftClientImpl and assertAsyncRequestSemaphore package 
private.  Adding public changes too much for testing.  Add a RaftClientTestUtil 
as below.
{code}
package org.apache.ratis.client.impl;

import org.apache.ratis.client.RaftClient;

public interface RaftClientTestUtil {
  static void assertAsyncRequestSemaphore(
  RaftClient client, int expectedAvailablePermits, int expectedQueueLength) 
{

((RaftClientImpl)client).assertAsyncRequestSemaphore(expectedAvailablePermits, 
expectedQueueLength);
  }
}
{code}


> RaftClientImpl should have upper bound on async requests
> 
>
> Key: RATIS-143
> URL: https://issues.apache.org/jira/browse/RATIS-143
> Project: Ratis
>  Issue Type: Bug
>Reporter: Lokesh Jain
>Assignee: Lokesh Jain
> Attachments: RATIS-143.001.patch, RATIS-143.002.patch
>
>
> RaftClientImpl should have a upper bound on active async requests. Further 
> request should be blocked until the active one is handled. Idea is to use 
> semaphore so that a request is blocked until a permit is released by one of 
> the active ones.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (RATIS-141) In RaftClientProtocolService, the assumption of consecutive callId is invalid

2017-11-22 Thread Chen Liang (JIRA)

[ 
https://issues.apache.org/jira/browse/RATIS-141?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16263369#comment-16263369
 ] 

Chen Liang commented on RATIS-141:
--

Thanks [~szetszwo] for working on this! Had an offline discussion with 
Nicholas. Seems that we may not really need to add this variable 
{{asyncSeqNum}}. And just making {{callIdCounter}} non-static would do the same 
job.

> In RaftClientProtocolService, the assumption of consecutive callId is invalid
> -
>
> Key: RATIS-141
> URL: https://issues.apache.org/jira/browse/RATIS-141
> Project: Ratis
>  Issue Type: Bug
>Reporter: Tsz Wo Nicholas Sze
>Assignee: Tsz Wo Nicholas Sze
> Attachments: r141_20171117.patch, r141_20171119b.patch, 
> r141_20171120.patch
>
>
> {code}
> //RaftClientProtocolService.AppendRequestStreamObserver.onNext(..)
>   // we assume the callId is consecutive for a stream RPC call
>   final PendingAppend pendingForReply = pendingList.get(
>   (int) (replySeq - headSeqNum));
> {code}
> Call id is used for different kinds of calls (e.g. getInfo) so that it may 
> not be consecutive.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (RATIS-149) TestRaftStream.testSimpleWrite may fail

2017-11-22 Thread Tsz Wo Nicholas Sze (JIRA)

[ 
https://issues.apache.org/jira/browse/RATIS-149?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16263114#comment-16263114
 ] 

Tsz Wo Nicholas Sze commented on RATIS-149:
---

Continue the thoughts above:
In order to keep the client simple, let's make server to handle out-of-order 
requests so that client could just send and retry.  Client does not need any 
queues to maintain request ordering.

> TestRaftStream.testSimpleWrite may fail
> ---
>
> Key: RATIS-149
> URL: https://issues.apache.org/jira/browse/RATIS-149
> Project: Ratis
>  Issue Type: Bug
>Reporter: Tsz Wo Nicholas Sze
>Assignee: Jing Zhao
>
> Two different failure cases:
> - {code}
> java.lang.AssertionError: expected:<500> but was:<350>
>   at 
> org.apache.ratis.grpc.TestRaftStream.checkLog(TestRaftStream.java:106)
>   at 
> org.apache.ratis.grpc.TestRaftStream.testSimpleWrite(TestRaftStream.java:100)
> {code}
> - {code}
> org.junit.internal.ArrayComparisonFailure: arrays first differed at element 
> [0]; expected:<63> but was:<-81>
>   at 
> org.apache.ratis.grpc.TestRaftStream.checkLog(TestRaftStream.java:114)
>   at 
> org.apache.ratis.grpc.TestRaftStream.testSimpleWrite(TestRaftStream.java:100)
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)