[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-12-06 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15044402#comment-15044402
 ] 

Hudson commented on ZOOKEEPER-2299:
---

SUCCESS: Integrated in ZooKeeper-trunk #2822 (See 
[https://builds.apache.org/job/ZooKeeper-trunk/2822/])
ZOOKEEPER-2299: NullPointerException in LocalPeerBean for ClientAddress
(Arshad Mohammad via rgs) (rgs: 
[http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1718253])
* trunk/CHANGES.txt
* trunk/src/java/main/org/apache/zookeeper/server/quorum/LocalPeerBean.java
* trunk/src/java/test/org/apache/zookeeper/server/quorum/LocalPeerBeanTest.java


> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2, 3.6.0
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-12-06 Thread Raul Gutierrez Segales (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15044137#comment-15044137
 ] 

Raul Gutierrez Segales commented on ZOOKEEPER-2299:
---

lgtm, +1. Please resubmit so CI can run once ZOOKEEPER-2301 is applied. Thanks!

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-26 Thread Arshad Mohammad (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14973936#comment-14973936
 ] 

Arshad Mohammad commented on ZOOKEEPER-2299:


If ZOOKEEPER-2299 is commited before ZOOKEEPER-2301, two test cases in 
{{org.apache.zookeeper.test.ReconfigTest}} will fail

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-26 Thread Arshad Mohammad (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14973932#comment-14973932
 ] 

Arshad Mohammad commented on ZOOKEEPER-2299:


Some test cases were failed because there is another problem in the code. 
Created another jira ZOOKEEPER-2301

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-25 Thread Arshad Mohammad (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14973120#comment-14973120
 ] 

Arshad Mohammad commented on ZOOKEEPER-2299:


Thanks [~eribeiro] for your review comments.
#  In the test case I am testing the complete ClientAddress feature, all three 
scenarios are tested. If I go for the naming convention you are suggesting I 
have to split the test case into three which will take more when executed.
#  In my previous patch [~rgs] suggested to have smaller test case name.  
[Comment | 
https://issues.apache.org/jira/browse/ZOOKEEPER-2269?focusedCommentId=14738160&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-14738160]

So not changing the test case name.

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-25 Thread Arshad Mohammad (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14973113#comment-14973113
 ] 

Arshad Mohammad commented on ZOOKEEPER-2299:


SecureClientAddress also required as it is configurable and can be different 
from ClientAddress.  Created Jira ZOOKEEPER-2300

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-22 Thread Edward Ribeiro (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14969517#comment-14969517
 ] 

Edward Ribeiro commented on ZOOKEEPER-2299:
---

Oops, hit enter before finishing the text. So, {{testClientAddress}} is a very 
generic name, probably very similar to other similar/equal names around. I 
think a more appropriate test name would be 
{{testClientAddressShouldNotBeNull}} or something alike, up to you. :) I am 
fond of Uncle Bob Martin recommendation that test methods should be named the 
more clearly as possible and the places I worked enforced this too. ;) You can 
see some traditional recommendations here: 
https://dzone.com/articles/7-popular-unit-test-naming 

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-22 Thread Edward Ribeiro (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14969507#comment-14969507
 ] 

Edward Ribeiro commented on ZOOKEEPER-2299:
---

Hi [~arshad.mohammad], very nice patch, again. :) My only suggestion would be 
to use a more meaningful name for unit tests. 



> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-22 Thread Rakesh R (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14969466#comment-14969466
 ] 

Rakesh R commented on ZOOKEEPER-2299:
-

bq. Can I raise separate ticket to add SecureClientAddress and SecureClientPort 
jmx property?
Yeah, Agreed for {{SecureClientPort}} jmx property. I think address is not 
required as it will be same, right?

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-22 Thread Arshad Mohammad (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14969136#comment-14969136
 ] 

Arshad Mohammad commented on ZOOKEEPER-2299:


Thanks [~rakeshr] for looking into the issue.
# {quote}
Could you tell me the way qp.myClientAddr would become null value in the real 
cluster.
{quote}
scenario is as follows
1) in zoo.cfg clientPort is configured but clientPortAddress is not 
configured(which is valid configuration).
2) in zoo.cfg servers have following configuration, not added client information
{code}server.1=localhost:2888:3888:participant
server.2=localhost:2889:3889:participant
server.3=localhost:2890:3890:participant{code}
Remark:{{qp.myClientAddr}}  is not null only when   client ip is specified in 
dynamic configuration
like  server.1=localhost:2888:3888:participant;localhost:2181
# yes, if only secureClientPort is configured {{peer.cnxnFactory}} will be null.
I am returning blank string in this case.
{color:blue}I don't think we should show secure client address in ClientAddress 
property.
There should be different jmx property  SecureClientAddress. What you say? Can 
I raise septate ticket to add SecureClientAddress and SecureClientPort jmx 
property?{color}

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-22 Thread Rakesh R (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14969102#comment-14969102
 ] 

Rakesh R commented on ZOOKEEPER-2299:
-

Thanks [~arshad.mohammad] for reporting this. I could see the unit test case is 
written to simulate the scenario. Could you tell me the way {{qp.myClientAddr}} 
would become null value in the real cluster. 

Also, just one quick comment about the patch. Say, if someone use 
secureClientPort, server will use {{peer.secureCnxnFactory}} to handle the 
connections. {{peer.cnxnFactory}} will be null, again this patch will throw 
NPE, right?

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (ZOOKEEPER-2299) NullPointerException in LocalPeerBean for ClientAddress

2015-10-22 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14968881#comment-14968881
 ] 

Hadoop QA commented on ZOOKEEPER-2299:
--

-1 overall.  Here are the results of testing the latest attachment 
  
http://issues.apache.org/jira/secure/attachment/12768006/ZOOKEEPER-2299-01.patch
  against trunk revision 1709293.

+1 @author.  The patch does not contain any @author tags.

+1 tests included.  The patch appears to include 2 new or modified tests.

+1 javadoc.  The javadoc tool did not generate any warning messages.

+1 javac.  The applied patch does not increase the total number of javac 
compiler warnings.

+1 findbugs.  The patch does not introduce any new Findbugs (version 2.0.3) 
warnings.

+1 release audit.  The applied patch does not increase the total number of 
release audit warnings.

-1 core tests.  The patch failed core unit tests.

+1 contrib tests.  The patch passed contrib unit tests.

Test results: 
https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/2922//testReport/
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/2922//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
Console output: 
https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/2922//console

This message is automatically generated.

> NullPointerException in LocalPeerBean for ClientAddress
> ---
>
> Key: ZOOKEEPER-2299
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2299
> Project: ZooKeeper
>  Issue Type: Bug
>  Components: jmx
>Reporter: Arshad Mohammad
>Assignee: Arshad Mohammad
> Fix For: 3.5.2
>
> Attachments: ZOOKEEPER-2299-01.patch
>
>
> When clientPortAddress is not configured LocalPeerBean throws 
> NullPointerException.
> *Expected Behavior:*
> # When only clientPort is configured ClientAddress value should be 
> 0.0.0.0:clientPort or 0:0:0:0:0:0:0:0:clientPort
> # When both clientPort clientPortAddress are configured then expected value 
> is clientPortAddress:clientPort



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)